Via the Fastly API you can perform any of the operations that are possible within the management console, including creating services, domains, and backends, configuring rules or uploading your own application code, as well as account operations such as user administration and billing reports. The API is organized into collections of endpoints that allow manipulation of objects related to Fastly services and accounts. For the most accurate and up-to-date API reference content, visit our [Developer Hub](https://developer.fastly.com/reference/api/)
# @param string $service_id Alphanumeric string identifying the service. (required)
# @param int $version_id Integer identifying a service version. (required)
# @param string $name The name for the real-time logging configuration. (optional)
# @param string $placement Where in the generated VCL the logging call should be placed. If not set, endpoints with `format_version` of 2 are placed in `vcl_log` and those with `format_version` of 1 are placed in `vcl_deliver`. (optional)
# @param int $format_version The version of the custom logging format used for the configured endpoint. The logging call gets placed by default in `vcl_log` if `format_version` is set to `2` and in `vcl_deliver` if `format_version` is set to `1`. (optional, default to 2)
# @param string $response_condition The name of an existing condition in the configured endpoint, or leave blank to always execute. (optional)
# @param string $message_type How the message should be formatted. (optional, default to 'classic')
# @param string $timestamp_format A timestamp format (optional)
# @param int $period How frequently log files are finalized so they can be available for reading (in seconds). (optional, default to 3600)
# @param int $gzip_level The level of gzip encoding when sending logs (default `0`, no compression). Specifying both `compression_codec` and `gzip_level` in the same API request will result in an error. (optional, default to 0)
# @param string $compression_codec The codec used for compressing your logs. Valid values are `zstd`, `snappy`, and `gzip`. Specifying both `compression_codec` and `gzip_level` in the same API request will result in an error. (optional)
# @param string $access_key The access key for your S3 account. Not required if `iam_role` is provided. (optional)
# @param string $bucket_name The bucket name for S3 account. (optional)
# @param string $domain The domain of the Amazon S3 endpoint. (optional)
# @param string $iam_role The Amazon Resource Name (ARN) for the IAM role granting Fastly access to S3. Not required if `access_key` and `secret_key` are provided. (optional)
# @param string $path The path to upload logs to. (optional, default to 'null')
# @param string $public_key A PGP public key that Fastly will use to encrypt your log files before writing them to disk. (optional, default to 'null')
# @param string $redundancy The S3 redundancy level. (optional, default to 'null')
# @param string $secret_key The secret key for your S3 account. Not required if `iam_role` is provided. (optional)
# @param string $server_side_encryption_kms_key_id Optional server-side KMS Key Id. Must be set if `server_side_encryption` is set to `aws:kms` or `AES256`. (optional, default to 'null')
# @param string $server_side_encryption Set this to `AES256` or `aws:kms` to enable S3 Server Side Encryption. (optional, default to 'null')
{
my$params= {
'service_id'=> {
data_type=> 'string',
description=> 'Alphanumeric string identifying the service.',
required=> '1',
},
'version_id'=> {
data_type=> 'int',
description=> 'Integer identifying a service version.',
required=> '1',
},
'name'=> {
data_type=> 'string',
description=> 'The name for the real-time logging configuration.',
required=> '0',
},
'placement'=> {
data_type=> 'string',
description=> 'Where in the generated VCL the logging call should be placed. If not set, endpoints with `format_version` of 2 are placed in `vcl_log` and those with `format_version` of 1 are placed in `vcl_deliver`. ',
required=> '0',
},
'format_version'=> {
data_type=> 'int',
description=> 'The version of the custom logging format used for the configured endpoint. The logging call gets placed by default in `vcl_log` if `format_version` is set to `2` and in `vcl_deliver` if `format_version` is set to `1`. ',
required=> '0',
},
'response_condition'=> {
data_type=> 'string',
description=> 'The name of an existing condition in the configured endpoint, or leave blank to always execute.',
description=> 'How the message should be formatted.',
required=> '0',
},
'timestamp_format'=> {
data_type=> 'string',
description=> 'A timestamp format',
required=> '0',
},
'period'=> {
data_type=> 'int',
description=> 'How frequently log files are finalized so they can be available for reading (in seconds).',
required=> '0',
},
'gzip_level'=> {
data_type=> 'int',
description=> 'The level of gzip encoding when sending logs (default `0`, no compression). Specifying both `compression_codec` and `gzip_level` in the same API request will result in an error.',
required=> '0',
},
'compression_codec'=> {
data_type=> 'string',
description=> 'The codec used for compressing your logs. Valid values are `zstd`, `snappy`, and `gzip`. Specifying both `compression_codec` and `gzip_level` in the same API request will result in an error.',
required=> '0',
},
'access_key'=> {
data_type=> 'string',
description=> 'The access key for your S3 account. Not required if `iam_role` is provided.',
description=> 'The domain of the Amazon S3 endpoint.',
required=> '0',
},
'iam_role'=> {
data_type=> 'string',
description=> 'The Amazon Resource Name (ARN) for the IAM role granting Fastly access to S3. Not required if `access_key` and `secret_key` are provided.',
required=> '0',
},
'path'=> {
data_type=> 'string',
description=> 'The path to upload logs to.',
required=> '0',
},
'public_key'=> {
data_type=> 'string',
description=> 'A PGP public key that Fastly will use to encrypt your log files before writing them to disk.',
required=> '0',
},
'redundancy'=> {
data_type=> 'string',
description=> 'The S3 redundancy level.',
required=> '0',
},
'secret_key'=> {
data_type=> 'string',
description=> 'The secret key for your S3 account. Not required if `iam_role` is provided.',
required=> '0',
},
'server_side_encryption_kms_key_id'=> {
data_type=> 'string',
description=> 'Optional server-side KMS Key Id. Must be set if `server_side_encryption` is set to `aws:kms` or `AES256`.',
required=> '0',
},
'server_side_encryption'=> {
data_type=> 'string',
description=> 'Set this to `AES256` or `aws:kms` to enable S3 Server Side Encryption.',
# @param string $service_id Alphanumeric string identifying the service. (required)
# @param int $version_id Integer identifying a service version. (required)
# @param string $logging_s3_name The name for the real-time logging configuration. (required)
# @param string $name The name for the real-time logging configuration. (optional)
# @param string $placement Where in the generated VCL the logging call should be placed. If not set, endpoints with `format_version` of 2 are placed in `vcl_log` and those with `format_version` of 1 are placed in `vcl_deliver`. (optional)
# @param int $format_version The version of the custom logging format used for the configured endpoint. The logging call gets placed by default in `vcl_log` if `format_version` is set to `2` and in `vcl_deliver` if `format_version` is set to `1`. (optional, default to 2)
# @param string $response_condition The name of an existing condition in the configured endpoint, or leave blank to always execute. (optional)
# @param string $message_type How the message should be formatted. (optional, default to 'classic')
# @param string $timestamp_format A timestamp format (optional)
# @param int $period How frequently log files are finalized so they can be available for reading (in seconds). (optional, default to 3600)
# @param int $gzip_level The level of gzip encoding when sending logs (default `0`, no compression). Specifying both `compression_codec` and `gzip_level` in the same API request will result in an error. (optional, default to 0)
# @param string $compression_codec The codec used for compressing your logs. Valid values are `zstd`, `snappy`, and `gzip`. Specifying both `compression_codec` and `gzip_level` in the same API request will result in an error. (optional)
# @param string $access_key The access key for your S3 account. Not required if `iam_role` is provided. (optional)
# @param string $bucket_name The bucket name for S3 account. (optional)
# @param string $domain The domain of the Amazon S3 endpoint. (optional)
# @param string $iam_role The Amazon Resource Name (ARN) for the IAM role granting Fastly access to S3. Not required if `access_key` and `secret_key` are provided. (optional)
# @param string $path The path to upload logs to. (optional, default to 'null')
# @param string $public_key A PGP public key that Fastly will use to encrypt your log files before writing them to disk. (optional, default to 'null')
# @param string $redundancy The S3 redundancy level. (optional, default to 'null')
# @param string $secret_key The secret key for your S3 account. Not required if `iam_role` is provided. (optional)
# @param string $server_side_encryption_kms_key_id Optional server-side KMS Key Id. Must be set if `server_side_encryption` is set to `aws:kms` or `AES256`. (optional, default to 'null')
# @param string $server_side_encryption Set this to `AES256` or `aws:kms` to enable S3 Server Side Encryption. (optional, default to 'null')
{
my$params= {
'service_id'=> {
data_type=> 'string',
description=> 'Alphanumeric string identifying the service.',
required=> '1',
},
'version_id'=> {
data_type=> 'int',
description=> 'Integer identifying a service version.',
required=> '1',
},
'logging_s3_name'=> {
data_type=> 'string',
description=> 'The name for the real-time logging configuration.',
required=> '1',
},
'name'=> {
data_type=> 'string',
description=> 'The name for the real-time logging configuration.',
required=> '0',
},
'placement'=> {
data_type=> 'string',
description=> 'Where in the generated VCL the logging call should be placed. If not set, endpoints with `format_version` of 2 are placed in `vcl_log` and those with `format_version` of 1 are placed in `vcl_deliver`. ',
required=> '0',
},
'format_version'=> {
data_type=> 'int',
description=> 'The version of the custom logging format used for the configured endpoint. The logging call gets placed by default in `vcl_log` if `format_version` is set to `2` and in `vcl_deliver` if `format_version` is set to `1`. ',
required=> '0',
},
'response_condition'=> {
data_type=> 'string',
description=> 'The name of an existing condition in the configured endpoint, or leave blank to always execute.',
description=> 'How the message should be formatted.',
required=> '0',
},
'timestamp_format'=> {
data_type=> 'string',
description=> 'A timestamp format',
required=> '0',
},
'period'=> {
data_type=> 'int',
description=> 'How frequently log files are finalized so they can be available for reading (in seconds).',
required=> '0',
},
'gzip_level'=> {
data_type=> 'int',
description=> 'The level of gzip encoding when sending logs (default `0`, no compression). Specifying both `compression_codec` and `gzip_level` in the same API request will result in an error.',
required=> '0',
},
'compression_codec'=> {
data_type=> 'string',
description=> 'The codec used for compressing your logs. Valid values are `zstd`, `snappy`, and `gzip`. Specifying both `compression_codec` and `gzip_level` in the same API request will result in an error.',
required=> '0',
},
'access_key'=> {
data_type=> 'string',
description=> 'The access key for your S3 account. Not required if `iam_role` is provided.',
description=> 'The domain of the Amazon S3 endpoint.',
required=> '0',
},
'iam_role'=> {
data_type=> 'string',
description=> 'The Amazon Resource Name (ARN) for the IAM role granting Fastly access to S3. Not required if `access_key` and `secret_key` are provided.',
required=> '0',
},
'path'=> {
data_type=> 'string',
description=> 'The path to upload logs to.',
required=> '0',
},
'public_key'=> {
data_type=> 'string',
description=> 'A PGP public key that Fastly will use to encrypt your log files before writing them to disk.',
required=> '0',
},
'redundancy'=> {
data_type=> 'string',
description=> 'The S3 redundancy level.',
required=> '0',
},
'secret_key'=> {
data_type=> 'string',
description=> 'The secret key for your S3 account. Not required if `iam_role` is provided.',
required=> '0',
},
'server_side_encryption_kms_key_id'=> {
data_type=> 'string',
description=> 'Optional server-side KMS Key Id. Must be set if `server_side_encryption` is set to `aws:kms` or `AES256`.',
required=> '0',
},
'server_side_encryption'=> {
data_type=> 'string',
description=> 'Set this to `AES256` or `aws:kms` to enable S3 Server Side Encryption.',