TanqoryDocs

tanqoryExtReportRun

  • Query
  • Apps and platform

Runs a report query and answers its table. A query with an error answers parseErrors ("Line 3: Column 'x' not found.") and no rows. Amounts are in the store currency; percentages are fractions (0.25 = 25%).

Arguments

ArgumentTypeRequiredDefaultDescription
currencyCodeStringOptional

The currency to show money in (the Controls panel's Currency). Converted from the store currency at the store's exchange rate; without a rate the answer stays in the store currency (currencyCode says which).

queryString!Required

Returns

TanqoryExtReportResult! The answer of a report query.

FieldTypeDescription
availableDimensions[TanqoryExtReportField!]!
availableMetrics[TanqoryExtReportField!]!

The table's metrics and dimensions (the Controls panel's add lists).

columns[TanqoryExtReportColumn!]!

Dimensions first, then each metric followed by its comparison, percent change and group totals columns.

compareSinceDateTime
compareUntilDateTime
currencyCodeString!
otherDimensions[TanqoryExtReportField!]!

The dimensions of the other data sets, each with its data set in table (the pickers' categories open when any data set has a field in them; picking one adds its data set to FROM). Empty without a valid FROM.

otherMetrics[TanqoryExtReportField!]!

The metrics of the other data sets, each with its data set in table (one picker for every metric, as the reference's: picking one adds its data set to FROM, e.g. FROM sales, inventory). Empty without a valid FROM.

parseErrors[String!]!

The query's errors; empty when it ran.

productCards[TanqoryExtReportProductCard!]!

The products behind the rows' product titles, for the product cell's card (image, title, ID, status), as the reference's product report cells. Empty when the query has no product_title column.

rows[JSON!]!

One object per row, keyed by column name.

sinceDateTime

The period the query covered, and its comparison period (COMPARE TO).

tableString

The table the query reads (FROM), as written.

timeseriesString

The time dimension of a time series (day, week, month ...), else null.

totalsJSON

WITH TOTALS: the metrics over the whole period (computed, not summed), keyed by column name.

untilDateTime
visualizationTanqoryExtReportVisualization

VISUALIZE: the chart type and the columns it draws.

Example request

A starting point: required arguments as variables and a few fields of the result. Replace the placeholders.

Set STORE_ID and TANQORY_ACCESS_TOKEN in your environment first (Make your first API call).

curl
curl -X POST "https://api.tanqory.com/admin/2026-10/stores/$STORE_ID/graphql" \
  -H "Authorization: Bearer $TANQORY_ACCESS_TOKEN" \
  -H "Content-Type: application/json" \
  --data '{"query":"query TanqoryExtReportRun($query: String!) {\n  tanqoryExtReportRun(query: $query) {\n    compareSince\n    compareUntil\n    currencyCode\n    parseErrors\n    productCards { id }\n    rows\n    since\n    table\n    timeseries\n    totals\n  }\n}","variables":{"query":""}}'

Built from commit c0b3fb3fdef7 · API version 2026-10