REST API
HTTP endpoints exposed by gaet serve.
Start the dashboard
gaet servegaet serve --no-openThe default port is 6161 and can be changed with GAET_DASHBOARD_PORT.
Endpoints
GET/api/statusGET/api/checkGET/api/doctorGET/api/diffGET/api/exportGET/api/detectGET/api/logsPOST/api/local/testPOST/api/remote/testGET/api/snapshotsGET/api/snapshots/downloadPOST/api/snapshots/deleteGET, POST/api/configPOST/api/pushPOST/api/fetchPOST/api/restoreGET, POST, DELETE/api/schedulePOST/api/stopGET/api/jobsGET/api/jobs/{id}Status and diagnostics
GET /api/statusReturns local_ok, the resolved host, port, user, and database, whether a password is set, remote configuration state, the environment file path, scheduler state, and per-table row counts.
GET /api/check
GET /api/doctor
GET /api/diffThese wrap the matching CLI checks. /api/export returns the environment as shell exports, /api/detect lists local PostgreSQL instances, and /api/logs accepts an optional lines query parameter.
Connection tests
POST /api/local/test
Content-Type: application/json
{"url": "postgresql://user:pass@127.0.0.1:5432/app"}The local test accepts url or local_url. Without a URL it uses the configured local connection. The remote test accepts url or remote_url plus an optional sslmode, and falls back to the configured remote URL.
Both respond with ok, connected, msg, and output.
Snapshots
GET /api/snapshots
GET /api/snapshots/download?file=gaet_20260101_120000.dump
POST /api/snapshots/delete?file=gaet_20260101_120000.dumpDownload streams the archive as an attachment. Delete accepts the filename in the query string or in a JSON body as filename or file. Path separators and .. are rejected.
Configuration
GET /api/configReturns config, masked_config, and env_file. Keys containing PASS, SECRET, or URL are masked in masked_config.
POST /api/config
Content-Type: application/json
{"config": {"GAET_RETENTION_DAYS": "14"}}An empty value deletes the key. Values that still contain a mask are ignored, so submitting the masked form does not overwrite a stored secret. The environment file is rewritten with 0600 permissions.
Backup operations
POST /api/push
Content-Type: application/json
{"dry_run": true}POST /api/fetchPOST /api/restore
Content-Type: application/json
{"filename": "gaet_20260101_120000.dump"}Restore defaults to latest when no filename is provided. Fetch and restore always run with confirmation enabled because the request itself is the confirmation.
Asynchronous jobs
Add ?async=1 to a push, fetch, or restore request to run it in the background. The response is 202 with ok, job_id, and status:
POST /api/push?async=1Poll the job:
GET /api/jobs
GET /api/jobs/{id}Schedule and stop
GET /api/scheduleReturns active, hours, and the platform scheduler name.
POST /api/schedule
Content-Type: application/json
{"hours": 6}DELETE /api/schedule and POST /api/stop both stop the scheduler.
Status codes
Wrong methods return 405, invalid snapshot filenames return 400, and missing snapshots or jobs return 404. A backup operation that fails still returns 200 with ok: false and a message, so check the body rather than the status code alone.