Metadata-Version: 2.4
Name: hyperlink-extractor-jda
Version: 1.3.0
Summary: Extract hyperlinks and their labels from .docx, .odt, .html, and .pdf documents.
Author-email: Josh Allen <data@bigj.ai>
License-Expression: MIT
Project-URL: Homepage, https://github.com/pqexpert/extract-links
Project-URL: Repository, https://github.com/pqexpert/extract-links
Project-URL: Bug Tracker, https://github.com/pqexpert/extract-links/issues
Classifier: Programming Language :: Python :: 3
Classifier: Operating System :: OS Independent
Requires-Python: >=3.7
Description-Content-Type: text/markdown
License-File: LICENSE.txt
Requires-Dist: beautifulsoup4
Requires-Dist: python-docx
Requires-Dist: odfpy
Requires-Dist: openpyxl
Requires-Dist: PyMuPDF
Requires-Dist: lxml
Dynamic: license-file

**# extract-links**



\*\*extract-links\*\* is a command-line tool for extracting text-label + hyperlink pairs from `.docx`, `.odt`, `.html`, and `.pdf` files.



\- PDF support includes intelligent bounding-box text parsing

\- Outputs formats: `txt`, `csv`, `md`, `json`, `xlsx`

\- Optional deduplication and sorting

\- Works across Windows, Linux, macOS



---



\## **Install**



Clone and install locally:



```bash

pip install .

Or use the CLI directly from source:

python -m extract\\\_links.cli \\\[file]

**Usage**

extract-links input.docx -o output --format csv --dedupe --sort

**Arguments**

| Flag       | Description                                   |

| ---------- | --------------------------------------------- |

| `input`    | Input file (`.docx`, `.odt`, `.html`, `.pdf`) |

| `-o`       | Output file prefix (no extension)             |

| `--format` | `txt`, `csv`, `md`, `json`, `xlsx`            |

| `--dedupe` | Deduplicate URLs                              |

| `--sort`   | Sort by label                                 |


**Example**

extract-links report.pdf -o links --format xlsx --dedupe --sort

**Output Example**

CSV


Text,URL

Project Plan,https://example.com/plan

Resources,https://example.com/resources

**Markdown**


\[Project Plan](https://example.com/plan)


**Supported Formats**

.docx → via python-docx
.odt → via odfpy
.html → via BeautifulSoup
.pdf → via PyMuPDF (bounding box + OCR-style matching)


## Windows Standalone `.exe`

For Windows users without Python, download the `.exe` from the [Releases](https://github.com/pqexpert/extract-links/releases) page.

### Example:
```powershell
extract-links.exe project_plan.docx -o pp_links_out --format csv

### Notes for `.exe` usage:
Place `extract-links.exe` in the same folder as your input file  
Or provide the full path to your input file when running  






