Execute a NexusQL query and return the result in requested format
POST /workspace/{workspaceCode}/query/sql/{queryId}
curl -X POST "https://nexus.biron-analytics.com/workspace/birondemo_prod/query/sql/http-sample" \
-H "Accept: text/tab-separated-values" \
-H "Content-Type: text/plain" \
-d 'SELECT dimension('\''order_shipping_country_zone'\'') AS d0, metric('\''transactions_order_date.billing_ht'\'') AS m0 FROM datamodel WHERE refDate BETWEEN '\''2026-02-01'\'' AND '\''2026-02-01'\'' GROUP BY d0 ORDER BY m0 DESC'
--basic --user username:passwordAuthorizations
Section intitulée « Authorizations »Parameters
Section intitulée « Parameters »Path Parameters
Section intitulée « Path Parameters »The Nexus workspace code
Example
birondemo_prodAn arbitrary ID used for concurrency. If another query with the same workspaceCode + queryId is currently running, this last one will be cancelled.
Query Parameters
Section intitulée « Query Parameters »If true, the column names are written to the first row, while the column types are in the second row. Default to false.
If true an extra line will be added with the total number of matching lines, without worrying about the paging options. Default to false.
If true an extra line with EOT char \u0004 will be added at end when the query is not cancelled and/or no error occurs. Default to false.
If true, when the HTTP connection is closed by the client, the underlying query will be eagerly killed ; to detect the state of the HTTP connection an extra header line with space characters is added at the beginning of the response. If false a timeout of 15 seconds is applied. Default to false.
If true, when an error occurs, when the headers have already been sent, a line with the CAN(cel) char \u0018 may appear ; if so, all previously sent data should be discarded and the rest of the response should be considered as the error content. Default to false.
Request Body required
Section intitulée « Request Body required »The SQL query to execute
Example
SELECT metric('transactions_order_date.billing_ht') AS total_billing_ht FROM datamodel WHERE refDate BETWEEN '2025-01-01' AND '2025-01-31'Responses
Section intitulée « Responses »Successful query execution
Example
["France",2458.8]["USA / Canada",1408.19]["UK",929.26]Example
France,2458.8USA / Canada,1408.19UK,929.26Example
France 2458.8USA / Canada 1408.19UK 929.26