execute_query
Run SQL or natural-language queries against connected databases to analyze data, build reports, and perform database operations within API key permissions and connector policies.
Instructions
Execute a SQL query or natural language query against your data through SyneHQ Kole. Supports SQL queries subject to the API key permission and connector policy. Perfect for data analysis, reporting, and database operations.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"query": "<query>"
},
"name": "execute_query"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| psql | No | Deprecated: CLI metacommands are disabled; use ordinary SQL | |
| limit | No | Maximum number of rows to return (helps with large result sets) | |
| query | Yes | SQL query or natural language query to execute. Examples: - 'SELECT * FROM users LIMIT 10' - 'Show me the top 5 customers by revenue' - 'What are the active subscriptions?' | |
| userId | No | User ID for query tracking and audit logs | |
| timeout | No | Query timeout in milliseconds (default: 30000) | |
| database | No | Database name to execute the query against. | |
| connectionId | No | Connection ID for the database. If not provided, uses SYNEHQ_CONNECTION_ID environment variable. |