API ReferenceEndpointsDatabase
Run a query against a database component
Runs over a real protocol driver, not a shell, and executes whatever is sent — including writes and DDL. Redis and MongoDB take their own command syntax rather than SQL.
Authorization
cloady AuthorizationBearer <token>
Personal API token (cldy_…)
In: header
Path Parameters
workspaceSlug*string
appSlug*string
Query Parameters
env?string
Value in
- "production"
- "preview"
- "development"
region?string
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
application/json
application/json
application/json
application/json
curl -X POST "https://example.com/api/workspaces/string/apps/string/db/query" \ -H "Content-Type: application/json" \ -d '{ "component": "string", "sql": "string" }'{ "engine": "postgres", "columns": [ "string" ], "rows": [ [ "string" ] ], "rowCount": 0, "affected": 0, "tag": "string", "ms": 0}List a database component's schemas and tables GET
Previous Page
Read the working tree of a development app: branch, changes and recent commits GET
Reads the repository inside the running container by pod exec, so it is ground truth rather than the deploy record. Returns `{ok:false, reason}` when the app has no repo, no pod, or no git.