Statistics

Available endpoints:
NameMethodPath
post/v3/stats/{type}
post/v3/stats/bandwidth/percentile
post/v3/stats/cdns/{type}
post/v3/stats/datacenters/{type}

Get stats

posthttps://api.cdn77.com/v3/stats/{type}

Request parameters

typerequiredstring in path

Available values: bandwidth, costs, headers, headers-detail, hit-miss, hit-miss-detail, traffic, traffic-detail, traffic-miss

Request bodyrequired

cdn_idsarray of integers

List of CDN Resource IDs. Use if you want statistics only for specific CDN Resources. More information in our CDN Resources API documentation.

location_idsarray of strings

List of Datacenters. Use if you want statistics only for specific Datacenters. Example values: "chicago", "los angeles"

aggregationrequiredstring

Accepts values in minutes, hours or days in the following formatting: 5-m, 1-h, 1-d, etc. (minutes must be divisible by five)

fromrequiredinteger

UNIX Timestamp from.

torequiredinteger

UNIX Timestamp to.

Responses

200Sizes of cached and non-cached served content grouped by CDN IDs (e.g. 1599436800).
// response
{
  "1599436800": {
    "sizeCached": 443741901,
    "sizeNonCached": 1004.1212242332124
  }
}
404Could not get statistics by type without grouping.

Get bandwidth 95th percentile

posthttps://api.cdn77.com/v3/stats/bandwidth/percentile

Request bodyrequired

cdn_idsarray of integers

List of CDN Resource IDs. Use if you want statistics only for specific CDN Resources. More information in our CDN Resources API documentation.

location_idsarray of strings

List of Datacenters. Use if you want statistics only for specific Datacenters. Example values: "chicago", "los angeles"

fromrequiredinteger

UNIX Timestamp

torequiredinteger

UNIX Timestamp

Responses

200Bandwidth 95th percentile returned.
// response
{
  "percentile": 12346
}
404Could not get Statistics. For specific error message check the request response.

Get stats by CDN Resource

posthttps://api.cdn77.com/v3/stats/cdns/{type}

Request parameters

typerequiredstring in path

Available values: bandwidth, costs, headers, headers-detail, hit-miss, hit-miss-detail, traffic, traffic-detail, traffic-miss

Request bodyrequired

cdn_idsarray of integers

List of CDN Resource IDs. Use if you want statistics only for specific CDN Resources. More information in our CDN Resources API documentation.

location_idsarray of strings

List of Datacenters. Use if you want statistics only for specific Datacenters. Example values: "chicago", "los angeles"

aggregationrequiredstring

Accepts values in minutes, hours or days in the following formatting: 5-m, 1-h, 1-d, etc. (minutes must be divisible by five)

fromrequiredinteger

UNIX Timestamp from.

torequiredinteger

UNIX Timestamp to.

Responses

200Statistics grouped by resource returned.
// response
{
  "1234567890": {
    "1599436800": {
      "sizeCached": 443741901,
      "sizeNonCached": 1004.1212242332124
    }
  }
}
404Could not get statistics grouped by resource.

Get stats by datacenter

posthttps://api.cdn77.com/v3/stats/datacenters/{type}

Request parameters

typerequiredstring in path

Available values: bandwidth, costs, headers, headers-detail, hit-miss, hit-miss-detail, traffic, traffic-detail, traffic-miss

Request bodyrequired

cdn_idsarray of integers

List of CDN Resource IDs. Use if you want statistics only for specific CDN Resources. More information in our CDN Resources API documentation.

location_idsarray of strings

List of Datacenters. Use if you want statistics only for specific Datacenters. Example values: "chicago", "los angeles"

aggregationrequiredstring

Accepts values in minutes, hours or days in the following formatting: 5-m, 1-h, 1-d, etc. (minutes must be divisible by five)

fromrequiredinteger

UNIX Timestamp from.

torequiredinteger

UNIX Timestamp to.

Responses

200Statistics by type grouped by datacenters returned.
// response
{
  "NA": {
    "los angeles": {
      "1234567890": {
        "sizeCached": 443741901,
        "sizeNonCached": 1004.1212242332124
      }
    }
  }
}
404Could not get Statistics. For specific error message check the request response.