Skip to content

Latest commit

 

History

History
239 lines (178 loc) · 11.9 KB

LoggingPapertrailApi.md

File metadata and controls

239 lines (178 loc) · 11.9 KB

Fastly\Api\LoggingPapertrailApi

$apiInstance = new Fastly\Api\LoggingPapertrailApi(
    // If you want use custom http client, pass your client which implements `GuzzleHttp\ClientInterface`.
    // This is optional, `GuzzleHttp\Client` will be used as default.
    new GuzzleHttp\Client(),
    $config
);

Methods

Note

All URIs are relative to https://api.fastly.com

Method HTTP request Description
createLogPapertrail() POST /service/{service_id}/version/{version_id}/logging/papertrail Create a Papertrail log endpoint
deleteLogPapertrail() DELETE /service/{service_id}/version/{version_id}/logging/papertrail/{logging_papertrail_name} Delete a Papertrail log endpoint
getLogPapertrail() GET /service/{service_id}/version/{version_id}/logging/papertrail/{logging_papertrail_name} Get a Papertrail log endpoint
listLogPapertrail() GET /service/{service_id}/version/{version_id}/logging/papertrail List Papertrail log endpoints
updateLogPapertrail() PUT /service/{service_id}/version/{version_id}/logging/papertrail/{logging_papertrail_name} Update a Papertrail log endpoint

createLogPapertrail()

createLogPapertrail($options): \Fastly\Model\LoggingPapertrailResponse // Create a Papertrail log endpoint

Create a Papertrail for a particular service and version.

Example

    $options['service_id'] = 'service_id_example'; // string | Alphanumeric string identifying the service.
$options['version_id'] = 56; // int | Integer identifying a service version.
$options['name'] = 'name_example'; // string | The name for the real-time logging configuration.
$options['placement'] = 'placement_example'; // string | 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`.
$options['response_condition'] = 'response_condition_example'; // string | The name of an existing condition in the configured endpoint, or leave blank to always execute.
$options['format'] = '%h %l %u %t \"%r\" %>s %b'; // string | A Fastly [log format string](https://docs.fastly.com/en/guides/custom-log-formats).
$options['format_version'] = self::FORMAT_VERSION_v2; // int | 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`.
$options['address'] = 'address_example'; // string | A hostname or IPv4 address.
$options['port'] = 514; // int | The port number.

try {
    $result = $apiInstance->createLogPapertrail($options);
} catch (Exception $e) {
    echo 'Exception when calling LoggingPapertrailApi->createLogPapertrail: ', $e->getMessage(), PHP_EOL;
}

Options

Note: the input parameter is an associative array with the keys listed below.

Name Type Description Notes
service_id string Alphanumeric string identifying the service.
version_id int Integer identifying a service version.
name string The name for the real-time logging configuration. [optional]
placement string 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] [one of: 'none', 'waf_debug', 'null']
response_condition string The name of an existing condition in the configured endpoint, or leave blank to always execute. [optional]
format string A Fastly log format string. [optional] [defaults to '%h %l %u %t "%r" %>s %b']
format_version int 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] [one of: 1, 2]
address string A hostname or IPv4 address. [optional]
port int The port number. [optional] [defaults to 514]

Return type

\Fastly\Model\LoggingPapertrailResponse

[Back to top] [Back to API list] [Back to README]

deleteLogPapertrail()

deleteLogPapertrail($options): \Fastly\Model\InlineResponse200 // Delete a Papertrail log endpoint

Delete the Papertrail for a particular service and version.

Example

    $options['service_id'] = 'service_id_example'; // string | Alphanumeric string identifying the service.
$options['version_id'] = 56; // int | Integer identifying a service version.
$options['logging_papertrail_name'] = 'logging_papertrail_name_example'; // string | The name for the real-time logging configuration.

try {
    $result = $apiInstance->deleteLogPapertrail($options);
} catch (Exception $e) {
    echo 'Exception when calling LoggingPapertrailApi->deleteLogPapertrail: ', $e->getMessage(), PHP_EOL;
}

Options

Note: the input parameter is an associative array with the keys listed below.

Name Type Description Notes
service_id string Alphanumeric string identifying the service.
version_id int Integer identifying a service version.
logging_papertrail_name string The name for the real-time logging configuration.

Return type

\Fastly\Model\InlineResponse200

[Back to top] [Back to API list] [Back to README]

getLogPapertrail()

getLogPapertrail($options): \Fastly\Model\LoggingPapertrailResponse // Get a Papertrail log endpoint

Get the Papertrail for a particular service and version.

Example

    $options['service_id'] = 'service_id_example'; // string | Alphanumeric string identifying the service.
$options['version_id'] = 56; // int | Integer identifying a service version.
$options['logging_papertrail_name'] = 'logging_papertrail_name_example'; // string | The name for the real-time logging configuration.

try {
    $result = $apiInstance->getLogPapertrail($options);
} catch (Exception $e) {
    echo 'Exception when calling LoggingPapertrailApi->getLogPapertrail: ', $e->getMessage(), PHP_EOL;
}

Options

Note: the input parameter is an associative array with the keys listed below.

Name Type Description Notes
service_id string Alphanumeric string identifying the service.
version_id int Integer identifying a service version.
logging_papertrail_name string The name for the real-time logging configuration.

Return type

\Fastly\Model\LoggingPapertrailResponse

[Back to top] [Back to API list] [Back to README]

listLogPapertrail()

listLogPapertrail($options): \Fastly\Model\LoggingPapertrailResponse[] // List Papertrail log endpoints

List all of the Papertrails for a particular service and version.

Example

    $options['service_id'] = 'service_id_example'; // string | Alphanumeric string identifying the service.
$options['version_id'] = 56; // int | Integer identifying a service version.

try {
    $result = $apiInstance->listLogPapertrail($options);
} catch (Exception $e) {
    echo 'Exception when calling LoggingPapertrailApi->listLogPapertrail: ', $e->getMessage(), PHP_EOL;
}

Options

Note: the input parameter is an associative array with the keys listed below.

Name Type Description Notes
service_id string Alphanumeric string identifying the service.
version_id int Integer identifying a service version.

Return type

\Fastly\Model\LoggingPapertrailResponse[]

[Back to top] [Back to API list] [Back to README]

updateLogPapertrail()

updateLogPapertrail($options): \Fastly\Model\LoggingPapertrailResponse // Update a Papertrail log endpoint

Update the Papertrail for a particular service and version.

Example

    $options['service_id'] = 'service_id_example'; // string | Alphanumeric string identifying the service.
$options['version_id'] = 56; // int | Integer identifying a service version.
$options['logging_papertrail_name'] = 'logging_papertrail_name_example'; // string | The name for the real-time logging configuration.
$options['name'] = 'name_example'; // string | The name for the real-time logging configuration.
$options['placement'] = 'placement_example'; // string | 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`.
$options['response_condition'] = 'response_condition_example'; // string | The name of an existing condition in the configured endpoint, or leave blank to always execute.
$options['format'] = '%h %l %u %t \"%r\" %>s %b'; // string | A Fastly [log format string](https://docs.fastly.com/en/guides/custom-log-formats).
$options['format_version'] = self::FORMAT_VERSION_v2; // int | 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`.
$options['address'] = 'address_example'; // string | A hostname or IPv4 address.
$options['port'] = 514; // int | The port number.

try {
    $result = $apiInstance->updateLogPapertrail($options);
} catch (Exception $e) {
    echo 'Exception when calling LoggingPapertrailApi->updateLogPapertrail: ', $e->getMessage(), PHP_EOL;
}

Options

Note: the input parameter is an associative array with the keys listed below.

Name Type Description Notes
service_id string Alphanumeric string identifying the service.
version_id int Integer identifying a service version.
logging_papertrail_name string The name for the real-time logging configuration.
name string The name for the real-time logging configuration. [optional]
placement string 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] [one of: 'none', 'waf_debug', 'null']
response_condition string The name of an existing condition in the configured endpoint, or leave blank to always execute. [optional]
format string A Fastly log format string. [optional] [defaults to '%h %l %u %t "%r" %>s %b']
format_version int 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] [one of: 1, 2]
address string A hostname or IPv4 address. [optional]
port int The port number. [optional] [defaults to 514]

Return type

\Fastly\Model\LoggingPapertrailResponse

[Back to top] [Back to API list] [Back to README]