Saved queries allow users to store and reuse common natural language queries across your organization.
Bearer token obtained from the authenticate endpoint.
Response
List of saved queries.
Unique identifier for the saved query.
Organization the query belongs to.
Display title for the query.
The natural language query text.
Optional raw SQL associated with the query.
Member ID of the user who last modified this query.
Display name of the user who last modified this query.
ISO 8601 timestamp when the query was created.
ISO 8601 timestamp when the query was last modified.
curl -X GET https://api.trellis.sh/v1/queries \
-H "Authorization: Bearer YOUR_TOKEN"
{
"queries": [
{
"id": "sq_001",
"organization_id": "org_abc123",
"title": "Monthly Revenue",
"query": "Show me total revenue by month for 2025",
"sql": null,
"last_updated_by": "member_xyz789",
"last_updated_by_name": "John Doe",
"created_at": "2025-11-01T10:00:00Z",
"updated_at": "2025-12-01T15:30:00Z"
}
]
}