GET
/
cdn
/
raw_log_settings
Python
from gcore import Gcore

client = Gcore(
    api_key="My API Key",
)
log_settings = client.cdn.logs.settings.get()
print(log_settings.s3_access_key_id)
{
  "client": 123,
  "enabled": true,
  "ignore_empty_logs": true,
  "storage_type": "<string>",
  "for_all_resources": true,
  "all_resources_bucket": "<string>",
  "all_resources_folder": "<string>",
  "s3_type": "<string>",
  "s3_aws_region": "<string>",
  "s3_hostname": "<string>",
  "s3_host_bucket": "<string>",
  "s3_bucket_location": "<string>",
  "s3_access_key_id": "<string>",
  "ftp_hostname": "<string>",
  "ftp_login": "<string>",
  "ftp_prepend_folder": "<string>",
  "sftp_hostname": "<string>",
  "sftp_login": "<string>",
  "sftp_prepend_folder": "<string>",
  "folders": [
    {
      "id": 123,
      "bucket": "<string>",
      "folder": "<string>",
      "cdn_resource": 123
    }
  ],
  "status": "<string>",
  "comment": "<string>",
  "archive_size_mb": 1250
}

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

Response

Successful.

client
integer

Client ID.

enabled
boolean

Enables or disables a log forwarding feature.

Possible values:

  • true - log forwarding feature is active.
  • false - log forwarding feature is deactivated.
ignore_empty_logs
boolean

Enables or disables the forwarding of empty logs.

Possible values:

  • true - Empty logs are not sent.
  • false - Empty logs are sent.
storage_type
string

Storage type.

Possible values:

  • ftp
  • sftp
  • s3
for_all_resources
boolean

Defines whether logs of all CDN resources are delivered to one folder/bucket or to separate ones.

Possible values:

  • true - Logs of all CDN resources are delivered to one folder/bucket.
  • false - Logs of CDN resources are delivered to separate folders/buckets.
all_resources_bucket
string

Name of the S3 bucket to which logs of all CDN resources are delivered.

Applicable for "storage_type": S3.

all_resources_folder
string

Parameter meaning depends on the value of the "storage_type" value:

  • s3 - Name of the S3 bucket sub-folder to which logs for all CDN resources are delivered.
  • ftp/sftp - Name of the folder (or path) to which logs for all CDN resources are delivered.
s3_type
string

Storage type compatible with S3.

Possible values:

  • amazon – AWS S3 storage.
  • other – Other (not AWS) S3 compatible storage.
s3_aws_region
string

Amazon AWS region.

s3_hostname
string

S3 storage hostname.

s3_host_bucket
string

S3 storage bucket hostname.

Restrictions:

  • Maximum 255 symbols.
  • Latin letters (A-Z, a-z,) digits (0-9,) dots, colons, dashes, and underscores.
s3_bucket_location
string

S3 storage location.

Restrictions:

  • Maximum 255 symbols.
  • Latin letters (A-Z, a-z,) digits (0-9,) dots, colons, dashes, and underscores (.:_-).
s3_access_key_id
string

Access key ID for the S3 account.

Access Key ID is 20 alpha-numeric characters like 022QF06E7MXBSH9DHM02

ftp_hostname
string

FTP storage hostname.

ftp_login
string

FTP storage login.

ftp_prepend_folder
string

Name of prepend FTP folder for log delivery.

sftp_hostname
string

SFTP storage hostname.

sftp_login
string

SFTP storage login.

sftp_prepend_folder
string

Name of prepend SFTP folder for log delivery.

folders
object[]

List of folders/buckets for receiving CDN resources logs.

status
string

Log delivery status.

Possible values:

  • ok – All/part of attempts to deliver logs were successful.
  • failed – All attempts to deliver logs failed.
  • pending - No logs delivery attempts yet.
  • disabled - Log delivery is disabled.
comment
string | null

System comment on the status of settings, if they are suspended.

archive_size_mb
integer | null

The size of a single piece of the archive in MB. In case of null value logs are delivered without slicing.

Required range: 500 <= x <= 2000