Skip to content

GET   /mids/{midId}/analytics

Get MID analytics

Retrieve analytics data for a specific MID

Authentication Required

Authorization: Bearer {token}   header string

This header is required to access this endpoint

Required Parameters

x-account-id   header string

Account ID for the request

midId   path string

The ID of the MID

Optional Parameters

Click here to view an exhaustive list of all available parameters
period   query string

Period for analytics (e.g., month, quarter, year)

dateFrom   query string

Start date for analytics

dateTo   query string

End date for analytics

Try it out

Loading...

Output:

Responses

Description

Successful response

{
"summary": {
"totalVolume": 0,
"totalTransactions": 0,
"successRate": 0,
"declineRate": 0,
"averageTicket": 0,
"chargebackRate": 0,
"refundRate": 0,
"netRevenue": 0
},
"analyticsData": [
{}
],
"recentActivity": [
{}
],
"period": {
"from": "string",
"to": "string"
}
}

References

#/components/parameters/xAccountIdHeader

in: header
name: x-account-id
schema:
type: string
description: Account ID for the request
required: true
example: "2311"

#/components/schemas/MidAnalytics

type: object
properties:
summary:
type: object
properties:
totalVolume:
type: number
totalTransactions:
type: integer
successRate:
type: number
declineRate:
type: number
averageTicket:
type: number
chargebackRate:
type: number
refundRate:
type: number
netRevenue:
type: number
analyticsData:
type: array
items:
type: object
recentActivity:
type: array
items:
type: object
period:
type: object
properties:
from:
type: string
format: date-time
to:
type: string
format: date-time

Route Source Code

Check out the source code for this route entrypoint here: /mids/[midId]/analytics/route.ts

Or the swagger.yaml spec this documentation was generated from: /mids/swagger.yaml