For now, I've hardcoded PrimeGovSite.scrape() to scrape only the first endpoint with a default search period of the past 30 days. In the future, if necessary, we could add a way to choose which endpoint to query.
Contrary to my initial impression, each endpoint seems to return identically structured JSON data across cities. Each city can choose whether or not to use a particular endpoint in the implementation of their agenda search front-end.
Currently, tests/primegov_test.py scrapes meetings for the following cities:
Ventura, CA
San Antonio, TX
Los Angeles, CA
Las Vegas, NV
Santa Fe, NM
Testing Instructions
Run docker-compose run --rm scraper python tests/primegov_test.py
Overview
This PR adds the
PrimeGovSite
class to scrape PrimeGov sites. For each city, I've found multiple PrimeGov API endpoints that can be queried:For now, I've hardcoded
PrimeGovSite.scrape()
to scrape only the first endpoint with a default search period of the past 30 days. In the future, if necessary, we could add a way to choose which endpoint to query.Contrary to my initial impression, each endpoint seems to return identically structured JSON data across cities. Each city can choose whether or not to use a particular endpoint in the implementation of their agenda search front-end.
Currently,
tests/primegov_test.py
scrapes meetings for the following cities:Testing Instructions
Run
docker-compose run --rm scraper python tests/primegov_test.py