Tools
Database Query
Run a natural language query against connected SQL databases.
post/v1/tools/database-query
Request body
Example request
{
"query": "What were the Q4 revenue trends?",
"artifacts": [
{
"context_filter": {
"collection": "collection_name",
"artifacts": [
"artifact_id_1, artifact_id_2"
],
"metadata_filter": [
{
"key": "file_id",
"operator": "==",
"value": "artifact_id_1"
}
]
}
}
]
}Response
Database query completed successfully.
Example response
{
"content": [
{
"text": "The analysis shows that Q4 revenue increased by 25% compared to Q3.",
"type": "text"
}
],
"is_error": false
}