cURL
curl --request POST \ --url http://localhost:8080/api/v1/query/postgres \ --header 'Content-Type: application/json' \ --header 'x-api-key: <api-key>' \ --data ' { "sql": "SELECT * FROM test.stock_price WHERE volume > 1000000", "database": "datris", "limit": 100 } '
{ "results": [ {} ], "count": 123 }
Execute a read-only SQL SELECT query against PostgreSQL. Enforces SELECT-only, blocks dangerous keywords, and auto-appends LIMIT.
Optional API key for authentication (enabled via application.yaml)
SQL SELECT query to execute
"SELECT * FROM test.stock_price WHERE volume > 1000000"
PostgreSQL database name
Maximum rows to return (max 1000)
Query results