GET
/
cdn
/
statistics
/
raw_logs_usage
/
series
Python
from gcore import Gcore

client = Gcore(
    api_key="My API Key",
)
usage_series_stats = client.cdn.statistics.get_logs_usage_series(
    from_="from",
    to="to",
)
print(usage_series_stats)
[
  {
    "id": 1,
    "active_from": "2020-01-21T04:36:35.473Z",
    "active_to": null,
    "client_id": 1,
    "resource_id": 1,
    "cname": "resource-1.com"
  },
  {
    "id": 2,
    "active_from": "2020-03-21T04:36:30.269Z",
    "active_to": "2020-04-21T04:36:33.062Z",
    "client_id": 1,
    "cname": "resource-2.com"
  }
]

Authorizations

Authorization
string
header
required

API key for authentication. Make sure to include the word apikey, followed by a single space and then your token. Example: apikey 1234$abcdef

Query Parameters

from
string
required

Beginning of the requested time period (ISO 8601/RFC 3339 format, UTC.)

Example: * &from=2020-01-01T00:00:00.000

to
string
required

End of the requested time period (ISO 8601/RFC 3339 format, UTC.)

Example: * &from=2020-01-01T00:00:00.000

resource
integer

CDN resources IDs by that statistics data is grouped.

To request multiple values, use: * &resource=1&resource=2

Response

200 - application/json

Successful.

active_from
string

Date and time when paid feature was enabled (ISO 8601/RFC 3339 format, UTC.)

active_to
string | null

Date and time when paid feature was disabled (ISO 8601/RFC 3339 format, UTC.)

It returns null if the paid feature is enabled.

client_id
integer

Client ID.

resource_id
integer

CDN resource ID.

cname
string

CDN resource CNAME.