Skip to main content

KPI summary

Applies to: API integrators with third-party API access.

Use Content-Type: application/json and optionally X-Locale: en. The third-api-token header is required. See common headers and error handling.

Brief Description

  • Query Phambox Dashboard KPI summary metrics (total sales, number of transactions, units sold, conversion rate, etc.)
  • Data scope aligns with the user identity and groupId associated with the Token.

Request URL

  • https://{GATEWAY_HOST}/third-center-web/openapi/v1/phamboxDashboard/summary

Request Method

  • POST

Parameters

Send a JSON object as the request body. When using only defaults, send {}; optional fields do not make the body optional.

Request Body:

Parameter NameRequiredTypeDescription
startTimestampNolongStart time for statistics (millisecond timestamp)
endTimestampNolongEnd time for statistics (millisecond timestamp)

Response Example

{
"code": 200,
"msg": "success",
"enMsg": null,
"data": {
"kpiList": [
{
"name": "totalSales",
"title": "Total Sales",
"value": "12,345.67",
"growthRate": 15,
"suffix": ""
},
{
"name": "totalTransactions",
"title": "Total Transactions",
"value": "1,234",
"growthRate": 8,
"suffix": ""
}
]
}
}

Response Parameter Description

Response data: object containing kpiList on success. KPI values are formatted strings, not numeric JSON values.

Errors: data may be null, a string or an array of messages. Check the HTTP status and code before reading success data. See error handling.

Response:

Parameter NameTypeDescription
kpiListarrayList of KPI metrics
kpiList[].namestringMetric identifier:
totalSales Total sales;
totalTransactions Total number of transactions;
unitsSold Number of units sold;
conversionRate Conversion rate;
grossProfit Gross profit;
revenuePerTransaction Average revenue per transaction;
unitsPerTransaction Average number of items per order
kpiList[].titlestringMetric display title
kpiList[].valuestringMetric value (formatted string)
kpiList[].growthRateintGrowth rate (integer percentage; e.g., 15 represents 15%)
kpiList[].suffixstringUnit suffix (e.g., %; can be empty)

Notes

  • Send startTimestamp and endTimestamp to query a specific time range.
  • This endpoint applies the time range to the selected Group's device scope. It does not apply deviceCode, goodsId or sku filters, even though related product endpoints accept some of those fields.
  • Growth rates compare against the immediately preceding interval of the same duration. See time handling.