Monitor shipments on Flexport.
Note: This project is not feature complete, until then 1.x releases may contain breaking changes. Development is managed in this project.
This project provides
- a GraphQL API using AWS AppSync to query Flexport's API v2, which simplifies the resolving of links and pagination.
- a webhook receiver to receive shipment event notifications
- a Slack notifier which posts an update to a channel when a shipment event is received
ℹ️ These instructions apply to Unix-based development environments; Linux and Mac users should be fine. Windows users could look into setting up their development environment using WSL2.
npm ci
npx tsc
export FLEXPORT_API_KEY=<your API key>
node cli
Make sure your have AWS credentials in your environment.
npm ci
npx tsc
The Flexport API credentials need to be provided:
aws ssm put-parameter --name /${STACK_NAME:-flexport-shipment-monitor-dev}/flexport/apiKey --type String --value <Flexport API Key>
The Slack webhook endpoint needs to be provided:
# disable URL resolution in the AWS CLI: aws configure set cli_follow_urlparam false
aws ssm put-parameter --name /${STACK_NAME:-flexport-shipment-monitor-dev}/slack/webhook --type String --value <Slack Webhook URL>
If this is the run the first time in an account
npx cdk bootstrap
npx cdk -a 'node dist/aws/cloudformation-sourcecode.js' deploy
Deploy the integration:
npx cdk deploy
This project is continuously tested using a real instance.
see ./adr.