API Documentation
REST API reference for scans, findings, accountability, and supporting workflows.
API Documentation
Base URL: https://<your-railway-backend>/api
On this page
- Authentication
- Health & Discovery
- Authenticated Customer Endpoints (Bearer token required)
- Internal / Automation Endpoints
- Important Notes
Authentication
There is currently no "API Keys" UI in OpsCurb.
Customer-facing endpoints use a Supabase access token:
curl -H "Authorization: Bearer <SUPABASE_ACCESS_TOKEN>" \
https://<your-railway-backend>/api/ai/preferences
Internal automation endpoints use shared-secret headers:
X-Scan-Secretfor scheduled scan triggersX-Digest-Secretfor weekly digest endpointsX-Reconcile-Secretfor subscription reconciliation
Health & Discovery
GET /api— API root (docs + endpoint links)GET /api/health/live— liveness probeGET /api/health— readiness/dependency healthGET /api/docs— Swagger UIGET /api/openapi.json— OpenAPI spec
Authenticated Customer Endpoints (Bearer token required)
-
GET /api/ai/preferences -
PUT /api/ai/preferences -
GET /api/ai/models/available -
GET /api/ai/usage -
GET /api/recommendations/{finding_id}/instructions -
POST /api/deep-inspect/{finding_id} -
PATCH /api/findings/{finding_id}/accountability -
POST /api/scans/trigger -
GET /api/forecasting -
GET /api/forecasting/accounts -
GET /api/forecasting/budget -
PUT /api/forecasting/budget -
GET /api/tagging/policy -
PUT /api/tagging/policy -
POST /api/tagging/apply -
POST /api/anomaly/check -
GET /api/savings-plans(requiresaws_account_idquery param) -
GET /api/reserved-instances(requiresaws_account_idquery param)
Internal / Automation Endpoints
POST /api/scans/run-scheduled— cron-triggered scheduled scans, requiresX-Scan-SecretPOST /api/weekly-digest/send— requiresX-Digest-SecretPOST /api/weekly-digest/send/{customer_id}— requiresX-Digest-SecretPOST /api/reconcile/subscriptions— requiresX-Reconcile-Secret
Important Notes
- The previous docs listing
GET /api/scans,GET /api/findings, andGET /api/recommendationswas outdated; those endpoints are not present in current router code. - For exact request/response schemas, use
GET /api/openapi.jsonor Swagger atGET /api/docs.
Questions? Email support@opscurb.com.