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
groupIdassociated 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 Name | Required | Type | Description |
|---|---|---|---|
| startTimestamp | No | long | Start time for statistics (millisecond timestamp) |
| endTimestamp | No | long | End 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 Name | Type | Description |
|---|---|---|
| kpiList | array | List of KPI metrics |
| kpiList[].name | string | Metric 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[].title | string | Metric display title |
| kpiList[].value | string | Metric value (formatted string) |
| kpiList[].growthRate | int | Growth rate (integer percentage; e.g., 15 represents 15%) |
| kpiList[].suffix | string | Unit suffix (e.g., %; can be empty) |
Notes
- Send
startTimestampandendTimestampto query a specific time range. - This endpoint applies the time range to the selected Group's device scope. It does not apply
deviceCode,goodsIdorskufilters, 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.