Serverless APIs for www.analogstudios.net (and friends) using arc.codes.
Assumes valid AWS credentials are either exported as environment variables or you have a relevant configuration setup in ~/aws/credentials.
Additionally, the following credentials files are required to run this project for the various services and APIs exposed.
For running the various APIs using the Architect sandbox.
Name | Service | Role |
---|---|---|
AWS_ACCESS_KEY_ID |
AWS | Publish API |
AWS_SECRET_ACCESS_KEY |
AWS | Publish API |
AWS_CLOUDFRONT_ID |
AWS | Publish API |
CONTENTFUL_ACCESS_TOKEN |
Contentful | Events API |
CONTENTFUL_SPACE |
Contentful | Events API |
CONTENTFUL_WEBHOOK_ACCESS_TOKEN |
Contentful | Publish API |
DATABASE_URL |
Turso | All APIs except Events |
DATABASE_TOKEN |
Turso |
For running Prisma Studio.
Name | Service | Role |
---|---|---|
DATABASE_URL |
Local SQLite | All APIs except Events |
npm ci
npm run arc env
npm start
to use the local Architect sandbox for developmentTo use Prisma Studio, run npm run studio
Data sourced from Turso for the Album resource type. Available at /albums
internally and publicly as /api/v2/albums
.
Options:
?id=xxx
- Filter by the id
of the album?artistId=xxx
- Filter by the id
of an artistYou can only pass one or the other
Data sourced from Turso for the Artist resource type. Available at /artists
internally and publicly as /api/v2/artists
.
Options:
?id=xxx
- Filter by the id
of the artistStructured events content sourced from Contentful for the Event resource type. Available at /events
internally and publicly as /api/v2/events
.
Options:
?id=xxx
- Filter by the id
of the event?tag=xxx
- Filter by tags of the eventYou can only pass one or the other
Data sourced from Turso for the Post resource type. Available at /posts
internally and publicly as /api/v2/posts
.
Options:
?id=xxx
- Filter by the id
of a post