Provides an automated telephone service which reads out MBTA elevator outages.
The Connect contact flow is currently not managed in Terraform; the source of
truth is the AWS dashboard. An export of the flow is committed to this repo as
hotline_prod.json and hotline_dev.json. When making changes in Connect, be
sure to re-export and update the committed files.
The Lambda function in this repo is called by the Connect contact flow when a user calls the hotline. It in turn calls the V3 API to get current alerts and affected stations, returning a set of voice lines to Connect.
- Clone this repo
- Install
asdf - Install
direnv asdf plugin add nodejsasdf installcp .envrc.template .envrcdirenv allownpm install
npm test: Run testsnpm run format: Format codenpx tsc: Check typesnpx eslint .: Run lint checksnpm run local: Run the Lambda locally and print output- This requires filling in
API_KEYin.envrcwith a V3 API key. Check Notion for ways to do this securely, without storing the key unencrypted
- This requires filling in
scripts/deploy.sh dev: Package the local code and deploy it to devscripts/invoke.sh dev: Invoke the dev Lambda and print the result- Both of the above scripts require that you have
awsCLI access set up
- Both of the above scripts require that you have
