Database
Execute a raw SQL query
Execute a raw SQL query against the project's SQLite database. Use positional parameters (params or args) to avoid injection. Accepts params, args, or named_args interchangeably. Use ? placeholders in the query when using params/args. The statement is executed verbatim against the underlying database, with no keyword filtering. Requires a service credential (secret key).
post/api/db/{project_id}/sql
Request
- Base URLhttps://core.blink.new
- URLhttps://core.blink.new/api/db/{project_id}/sql
- AuthHTTP bearer
Path parameters
project_idstring required
Example:my-project-123
Unique identifier for the project
Request body
Example request
{
"query": "SELECT * FROM users WHERE status = $1 AND age > $2",
"params": [
"active",
18
]
}Response
Query executed successfully
Changes
No recorded changes to this operation across all 1 revision of this API.