Metadata-Version: 2.3
Name: markdown-this
Version: 0.1.0
Summary: Extract web pages and supported special URLs as Markdown
Keywords: html,markdown,readability,github,arxiv
Author: Martín Gaitán
Author-email: Martín Gaitán <gaitan@gmail.com>
License: MIT
Requires-Dist: beautifulsoup4>=4.14.3
Requires-Dist: markdownify>=1.2.2
Requires-Dist: readability-lxml>=0.8.4.1
Requires-Dist: requests>=2.32.5
Requires-Python: >=3.12
Project-URL: Homepage, https://github.com/mgaitan/lobstersgram/tree/main/packages/markdown-this
Project-URL: Repository, https://github.com/mgaitan/lobstersgram
Project-URL: Issues, https://github.com/mgaitan/lobstersgram/issues
Description-Content-Type: text/markdown

# markdown-this

[![PyPI](https://img.shields.io/pypi/v/markdown-this)](https://pypi.org/project/markdown-this/)

Extract the readable content of a URL and convert it to Markdown. The package
also handles GitHub repositories and Markdown files through the GitHub API,
and arXiv abstract pages through their HTML representation.

## Installation

```bash
uv add markdown-this
```

## Usage

```python
from markdown_this import extract_main_content

title, markdown, fallback_text, intro = extract_main_content(
    "https://example.com/article"
)
```

`extract_main_content` returns the title, extracted Markdown, plain-text
fallback, and a short introduction suitable for a notification or preview.

The lower-level fetchers and normalization helpers are available from the
package modules when an application needs more control over the pipeline.

## Development

```bash
uv run pytest packages/markdown-this/tests
uv run ruff check packages/markdown-this
```

## License

MIT
