Skip to main content

Gets traffic usage data for selected period

GET <your-unleash-url>/api/admin/metrics/traffic/:period

Authorization

name: Authorizationtype: apiKeyin: headerdescription: API key needed to access this API

Gets traffic usage data numbers per API for a period given by the parameter

Request

Path Parameters

  • period string required
Responses

trafficUsageDataSegmentedSchema

Schema
  • period string required

    The year-month period for which the data usage is counted

  • apiData object[]required

    Contains the recorded daily data usage for each API path

  • Array [
  • days object[]required

    An array containing each day in the selected period that has data usage recorded

  • Array [
  • day date-time required

    The day of the period for which the usage is recorded

  • trafficTypes object[]required

    Contains the recorded data usage for each type of traffic group

  • Array [
  • group string required

    The traffic group

  • count number required

    The number of requests

  • ]
  • ]
  • apiPath string required

    The path of the API that the recorded data usage is for

  • ]

Authorization

name: Authorizationtype: apiKeyin: headerdescription: API key needed to access this API

Request

Base URL
<your-unleash-url>
Security Scheme
apiKey
period — path required
curl / cURL
curl -L -X GET '<your-unleash-url>/api/admin/metrics/traffic/:period' \
-H 'Accept: application/json' \
-H 'Authorization: <API_KEY_VALUE>'