Metadata-Version: 2.5
Name: capitolscraper
Version: 0.1.1
Summary: Web scraper for capitoltrades.com
Requires-Python: >=3.9
Requires-Dist: beautifulsoup4>=4.12.3
Requires-Dist: httpx>=0.28.1
Description-Content-Type: text/markdown

# CapitolScraper
A web scraper for [capitoltrades](https://www.capitoltrades.com/), a website dedicated to tracking
Congress stock trades.

## Quickstart
Install from [PyPi](https://pypi.org/project/capitolscraper/) using `pip install capitolscraper`

```python
from capitolscraper import Trades

scraper = Trades()
print(scraper.trades)
```

### Configuring requests
capitoltrades rate limits aggressive clients, so requests are throttled by default. Pass a
`RequestConfig` to tune headers, timeouts, retries, concurrency, and delays:

```python
from capitolscraper import RequestConfig, Trades

config = RequestConfig(max_concurrency=2, delay=1.0, timeout=20)
scraper = Trades(page_count=5, config=config)
```

## Testing
`uv run poe test` runs the offline test suite. Tests that hit capitoltrades.com are marked
`live` and only run with `uv run poe test-live`. To run every test, use `uv run poe test-all`.

## Authors
* [TonyGrif](https://github.com/TonyGrif) - Creator and Maintainer
