Execute SQL query against Kafka topics
Parse and execute a SQL query against a Kafka topic.
POST
/topics/queryAuthorization
AuthorizationBearer token · headerrequiredRequest body
requiredapplication/jsonsqlstringrequiredSQL query string (e.g., SELECT * FROM topic_name WHERE ... LIMIT 10)
min length 1 · max length 10000
max_time_secondsintegerMaximum execution time in seconds before the query is terminated
min 1 · max 120 · default: 30
Responses
200
Successful Response
columnsstring[]Column names in the result set
rowsobject[]Result rows as dicts
metadataKafkaSqlQueryResultMetadataMetadata about query execution for the results panel.
Show propertiesHide properties
records_scannedintegerdefault: 0
records_matchedintegerdefault: 0
partitions_scannedinteger[]execution_time_msnumberdefault: 0
terminated_bystringlimit, max_time, max_bytes, or end_of_topic
default: ""
bytes_scannedintegerdefault: 0
topicstringThe topic that was queried
default: ""
errorstring | anyError message if the query failed
Show propertiesHide properties
Any of:
string
stringany
any422
Validation Error
detailValidationError[]Show propertiesHide properties
Array of
ValidationErrorlocstring | integer[]requiredShow propertiesHide properties
Array of
string | integerAny of:
string
stringinteger
integermsgstringrequiredtypestringrequiredinputanyctxobject