api calls

This commit is contained in:
2026-09-06 19:14:59 +02:00
parent 13627a369a
commit 2dc9a30644
9 changed files with 1096 additions and 31 deletions
+18 -1
View File
@@ -1,16 +1,33 @@
# sqlc.yaml
version: "2"
sql:
- engine: "postgresql"
queries: "queries"
# Only the in-database DDL. scripts/bootstrap.sql is deliberately absent:
# sqlc parses SQL to learn the schema and cannot handle CREATE ROLE,
# ALTER DEFAULT PRIVILEGES or DO $$ blocks.
schema:
- "migrations/001_types.sql"
- "migrations/002_core.sql"
- "migrations/003_api.sql"
- "migrations/004_logbook.sql"
gen:
go:
package: "db"
out: "internal/db"
sql_package: "pgx/v5"
# Nullable columns become *T rather than sql.NullT, which is what
# internal/api/store.go expects for expires_at.
emit_pointers_for_null_types: true
emit_empty_slices: true
overrides:
# The domains are text underneath; sqlc should not invent a type.
- db_type: "core.callsign"
go_type: "string"
- db_type: "core.email"
go_type: "string"
- db_type: "core.gridsquare"
go_type: "string"