Dashboard insights
Base URL: https://api.miridia.io. Read Authentication and Conventions before you call these operations.
| Method | Path | Operation |
|---|---|---|
| GET | /api/v1/insights/dashboard/summary | Get dashboard summary |
| GET | /api/v1/insights/dashboard/shipment-volumes | Get shipment volumes |
| GET | /api/v1/insights/dashboard/dispatch-volumes | Get dispatch volumes |
| GET | /api/v1/insights/dashboard/top-customers | Get top customers |
Get dashboard summary
GET/api/v1/insights/dashboard/summary
Returns the dashboard summary metrics for the business.
Access. Send a bearer token or an API key. The caller needs the Insights view permission.
Response
200. Returns a SingleResult envelope. The data field is DashboardSummaryResponse.
curl -X GET "https://api.miridia.io/api/v1/insights/dashboard/summary" \
-H "Authorization: Bearer $MIRIDIA_TOKEN" \
-H "X-Business-Id: $MIRIDIA_BUSINESS_ID"{
"message": "string",
"messages": [
{
"title": "string",
"message": "string",
"level": "Standard",
"icon": "SyncAlert",
"code": "string"
}
],
"data": {
"monthlyCustomerOverview": {
"current": 0,
"previous": 0,
"percentageChange": 0,
"isIncrease": true
},
"monthlyShipmentOverview": {
"current": 0,
"previous": 0,
"percentageChange": 0,
"isIncrease": true
},
"monthlyDispatchOverview": {
"current": 0,
"previous": 0,
"percentageChange": 0,
"isIncrease": true
},
"monthlyOrderOverview": {
"current": 0,
"previous": 0,
"percentageChange": 0,
"isIncrease": true
},
"weeklyShipmentOverview": {
"current": 0,
"previous": 0,
"percentageChange": 0,
"isIncrease": true
},
"weeklyDispatchOverview": {
"current": 0,
"previous": 0,
"percentageChange": 0,
"isIncrease": true
}
},
"statusCode": "OK",
"canRead": true,
"canEdit": true,
"canDelete": true
}Get shipment volumes
GET/api/v1/insights/dashboard/shipment-volumes
Returns the shipment volume summary for the business.
Access. Send a bearer token or an API key. The caller needs the Insights view permission.
Response
200. Returns a SingleResult envelope. The data field is VolumeSummaryResponse.
curl -X GET "https://api.miridia.io/api/v1/insights/dashboard/shipment-volumes" \
-H "Authorization: Bearer $MIRIDIA_TOKEN" \
-H "X-Business-Id: $MIRIDIA_BUSINESS_ID"{
"message": "string",
"messages": [
{
"title": "string",
"message": "string",
"level": "Standard",
"icon": "SyncAlert",
"code": "string"
}
],
"data": {
"months": [
"string"
],
"volumes": [
0
]
},
"statusCode": "OK",
"canRead": true,
"canEdit": true,
"canDelete": true
}Get dispatch volumes
GET/api/v1/insights/dashboard/dispatch-volumes
Returns the dispatch volume summary for the business.
Access. Send a bearer token or an API key. The caller needs the Insights view permission.
Response
200. Returns a SingleResult envelope. The data field is VolumeSummaryResponse.
curl -X GET "https://api.miridia.io/api/v1/insights/dashboard/dispatch-volumes" \
-H "Authorization: Bearer $MIRIDIA_TOKEN" \
-H "X-Business-Id: $MIRIDIA_BUSINESS_ID"{
"message": "string",
"messages": [
{
"title": "string",
"message": "string",
"level": "Standard",
"icon": "SyncAlert",
"code": "string"
}
],
"data": {
"months": [
"string"
],
"volumes": [
0
]
},
"statusCode": "OK",
"canRead": true,
"canEdit": true,
"canDelete": true
}Get top customers
GET/api/v1/insights/dashboard/top-customers
Returns the top customers by sales for the business.
Access. Send a bearer token or an API key. The caller needs the Insights view permission.
Response
200. Returns a JSON array. Each item is CustomerRankingResponse.
curl -X GET "https://api.miridia.io/api/v1/insights/dashboard/top-customers" \
-H "Authorization: Bearer $MIRIDIA_TOKEN" \
-H "X-Business-Id: $MIRIDIA_BUSINESS_ID"[
{
"sales": 0,
"totalValue": 0,
"customerId": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"fullName": "string",
"email": "string"
}
]Models
The operations on this page use these object types. Select a type to see its fields.
CustomerRankingResponse
| Field | Type | Description |
|---|---|---|
sales | integer (int32) | |
totalValue | number (double) | |
customerId | string (uuid) | |
fullName | string | |
email | string |
DashboardSummaryResponse
| Field | Type | Description |
|---|---|---|
monthlyCustomerOverview | ReportSummaryResponse | |
monthlyShipmentOverview | ReportSummaryResponse | |
monthlyDispatchOverview | ReportSummaryResponse | |
monthlyOrderOverview | ReportSummaryResponse | |
weeklyShipmentOverview | ReportSummaryResponse | |
weeklyDispatchOverview | ReportSummaryResponse |
ReportSummaryResponse
| Field | Type | Description |
|---|---|---|
current | integer (int32) | |
previous | integer (int32) | |
percentageChange | number (double) | |
isIncrease | boolean |
VolumeSummaryResponse
| Field | Type | Description |
|---|---|---|
months | string[] | |
volumes | integer (int32)[] |