###A API
To start the server:
$ bun install
$ bun api
Access the Swagger UI at:
To generate code:
$ bun hygen:generate
The corresponding file will be generated under internal
.
- Update the database schema at
service/api/schema/db/schema.ts
using Drizzle. - Modify
wrangler.toml
as needed:
[[d1_databases]]
binding = "DB" # i.e., available in your Worker on env.DB
database_name = "test-app"
database_id = "xxx" # <- update this
To migrate the local database:
$ bun migrate:local
# If necessary, insert seed data
$ bun seed:local