---
title: "Submit an asynchronous query"
method: POST
path: "/v3/InsightsDomains/Conversations/QueryJobs"
tags: ["TwilioInsightsAsync"]
---

# Submit an asynchronous query

`POST /v3/InsightsDomains/Conversations/QueryJobs`

## Request

- Base URL: `https://insights.twilio.com`
- URL: `https://insights.twilio.com/v3/InsightsDomains/Conversations/QueryJobs`
- Auth: HTTP basic

Submit a long-running semantic query against the Conversations domain.
Returns 202 Accepted with an operationId and a Location header pointing
to the QueryJobs status endpoint for polling.

## Headers

- `Idempotency-Key` string, uuid

## Request body

- InsightsQueryRequest
  - `domain` string: The business domain to execute the query against
  - `query` QueryDefinition, required: Structured query definition that specifies what data to retrieve and how to filter, group, and order it
    - `measures` string[]: Array of measures to retrieve, representing quantitative values or metrics to be calculated
    - `dimensions` string[]: Array of dimensions to retrieve, representing categorical attributes for grouping and organizing data
    - `filters` object[]: Nested filter conditions. Always use `op` and `expressions`.
      - `op` 'AND' | 'OR' | 'EQ' | 'NE' | 'GT' | 'LT' | 'IN'
      - `expressions` object[], required
        - `op` 'AND' | 'OR' | 'EQ' | 'NE' | 'GT' | 'LT' | 'IN', required
        - `field` string, required
        - `values` string[]
    - `orderBy` object[]: Specifications for sorting the query results by specific fields in ascending or descending order
      - `field` string: Dimension or measure to order by
      - `direction` 'ASC' | 'DESC': Sort order direction, ascending or descending

## Response `202`

Async query accepted

- QueryJobSubmitResponse: The initial 202 response for an async query submission. Conforms to LongRunningOperation202Response from Twilio API Standards.
  - `operationId` string, Proc_JobTtid, required: The unique identifier for the asynchronous query operation, in TTID format.
  - `status` 'PENDING' | 'RUNNING' | 'CANCELLED' | 'COMPLETED' | 'FAILED', required: The valid status values for long-running operations.
  - `statusUrl` string, uri, required: The URI to poll for operation status.
  - `createdAt` string, date-time, required: The time when the operation was accepted, in RFC 3339 UTC format.

## Other responses

- `400`: Bad request
- `422`: Unprocessable content (idempotency key payload mismatch)
- `429`: Too Many requests (rate limit exceeded for request originating from public API)
- `500`: Internal server error

## Changes

- **2026-09-09** (v3) `3ac5589aa4e8`: 1 info
  - endpoint added
- **2026-08-13** (v3) `d70749dd30fe`: 1 breaking
  - api path removed without deprecation
- **2026-08-11** (v3) `f1a111f65ec1`: 1 info
  - endpoint added

[Operation history](https://skmtc.dev/twilio/apis/insights-v3/changes/v3/InsightsDomains/Conversations/QueryJobs/post.md)

---

[API](https://skmtc.dev/twilio/apis/insights-v3.md) - [All operations](https://skmtc.dev/twilio/apis/insights-v3/llms.txt) - [OpenAPI document](https://skmtc.dev/twilio/apis/insights-v3/revisions/68c9e65dfd52?raw)
