Scripts for automatically downloading reports from the pavement management information system (PMIS) used by the City of Austin Transportation Public Works. The vendor's platform is called AgileAssets.
Have an account created for you in AgileAssets with admin privileges.
Add the desired report name to the list of allowed API reports under:
Home System > Utilities > Allowed Web API Views
Also, if you are looking to eventually upload this report to Socrata set up a dataset and
supply its resource ID in config.py.
Copy the provided template (.env.template) as .env and populate your username and password,
along with the base url of your agileassets instance.
# Base URL of the agileassets instance
BASE_URL=
# Account with Admin privileges required
USERNAME= your_agileassets_username
PASSWORD= your_agileassets_password
- Make a python environment and install the required packages,
pip install -r requirements.txt(or see Docker instructions below) - Supply your created
.envfile and runpython request_client.py - Make note of the Client ID and Client Secret printed to the command line in your
.envfile. By default, the script will make your Client IDAPI_VIEWER
This script will download the desired report from AgileAssets and upload it to a Socrata dataset. The selected report must
be first configured in etl/config.py, then passed via a command line argument using --report or -r.
As an example, this command will download (then upload to socrata) the VW_UPDATED_PROJECTS_SEGMENTS report:
python etl/report_to_socrata.py --report VW_UPDATED_PROJECTS_SEGMENTSThe github actions associated with this repository will build a docker image and upload it to our dockerhub account.
The image can be pulled using the following command:
docker pull atddocker/dts-pavement-ops-reporting:productionOr, if you would like to build it locally:
docker build . -t atddocker/dts-pavement-ops-reporting:localAnd, running commands locally:
docker run --env-file .env -it atddocker/dts-pavement-ops-reporting:local /bin/bashThen, inside of the container, as an example:
python etl/report_to_socrata.py --report VW_UPDATED_PROJECTS_SEGMENTS