https://github.com/datamade/govinfo
Scrapes Congressional Hearings from the govinfo API
https://github.com/datamade/govinfo
Last synced: 12 months ago
JSON representation
Scrapes Congressional Hearings from the govinfo API
- Host: GitHub
- URL: https://github.com/datamade/govinfo
- Owner: datamade
- License: mit
- Created: 2018-09-27T15:44:53.000Z (over 7 years ago)
- Default Branch: master
- Last Pushed: 2018-11-05T06:01:18.000Z (over 7 years ago)
- Last Synced: 2025-04-10T19:11:56.465Z (about 1 year ago)
- Language: Python
- Size: 8.79 KB
- Stars: 8
- Watchers: 1
- Forks: 2
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# GovInfo
A Python wrapper for the govinfo API.
You'll need an API key from https://api.data.gov/
## Example
```python
import datetime
import govinfo
import pytz
scraper = govinfo.GovInfo(api_key='YOUR_SECRET_API_KEY')
# Prints out all the different types of collections available
# in the govinfo API
print(scraper.collections())
# Iterate through every congressional hearing
#
# For congressional hearings you need a specify a start
# date time with a timezone
start_time = datetime.datetime(1990, 1, 1, 0, 0, tzinfo=pytz.utc)
for hearing in scraper.congressional_hearings(start_time):
print(hearing)
```