Skip to content

Latest commit

 

History

History
236 lines (176 loc) · 8.32 KB

LoggingLogglyApi.md

File metadata and controls

236 lines (176 loc) · 8.32 KB

Fastly.LoggingLogglyApi

const apiInstance = new Fastly.LoggingLogglyApi();

Methods

Note

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

Method HTTP request Description
createLogLoggly POST /service/{service_id}/version/{version_id}/logging/loggly Create a Loggly log endpoint
deleteLogLoggly DELETE /service/{service_id}/version/{version_id}/logging/loggly/{logging_loggly_name} Delete a Loggly log endpoint
getLogLoggly GET /service/{service_id}/version/{version_id}/logging/loggly/{logging_loggly_name} Get a Loggly log endpoint
listLogLoggly GET /service/{service_id}/version/{version_id}/logging/loggly List Loggly log endpoints
updateLogLoggly PUT /service/{service_id}/version/{version_id}/logging/loggly/{logging_loggly_name} Update a Loggly log endpoint

createLogLoggly

createLogLoggly({ service_id, version_id, [name, ][placement, ][response_condition, ][format, ][format_version, ][token] })

Create a Loggly logging object for a particular service and version.

Example

const options = {
  service_id: "service_id_example", // required
  version_id: 56, // required
  name: "name_example",
  placement: "none",
  response_condition: "response_condition_example",
  format: "'%h %l %u %t \"%r\" %>s %b'",
  format_version: 1,
  token: "token_example",
};

apiInstance.createLogLoggly(options)
  .then((data) => {
    console.log(data, "API called successfully.");
  })
  .catch((error) => {
    console.error(error);
  });

Options

Name Type Description Notes
service_id String Alphanumeric string identifying the service.
version_id Number 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 Number 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]
token String The token to use for authentication (https://www.loggly.com/docs/customer-token-authentication-token/). [optional]

Return type

LoggingLogglyResponse

deleteLogLoggly

deleteLogLoggly({ service_id, version_id, logging_loggly_name })

Delete the Loggly logging object for a particular service and version.

Example

const options = {
  service_id: "service_id_example", // required
  version_id: 56, // required
  logging_loggly_name: "logging_loggly_name_example", // required
};

apiInstance.deleteLogLoggly(options)
  .then((data) => {
    console.log(data, "API called successfully.");
  })
  .catch((error) => {
    console.error(error);
  });

Options

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

Return type

InlineResponse200

getLogLoggly

getLogLoggly({ service_id, version_id, logging_loggly_name })

Get the Loggly logging object for a particular service and version.

Example

const options = {
  service_id: "service_id_example", // required
  version_id: 56, // required
  logging_loggly_name: "logging_loggly_name_example", // required
};

apiInstance.getLogLoggly(options)
  .then((data) => {
    console.log(data, "API called successfully.");
  })
  .catch((error) => {
    console.error(error);
  });

Options

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

Return type

LoggingLogglyResponse

listLogLoggly

listLogLoggly({ service_id, version_id })

List all Loggly logging objects for a particular service and version.

Example

const options = {
  service_id: "service_id_example", // required
  version_id: 56, // required
};

apiInstance.listLogLoggly(options)
  .then((data) => {
    console.log(data, "API called successfully.");
  })
  .catch((error) => {
    console.error(error);
  });

Options

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

Return type

[LoggingLogglyResponse]

updateLogLoggly

updateLogLoggly({ service_id, version_id, logging_loggly_name, [name, ][placement, ][response_condition, ][format, ][format_version, ][token] })

Update the Loggly logging object for a particular service and version.

Example

const options = {
  service_id: "service_id_example", // required
  version_id: 56, // required
  logging_loggly_name: "logging_loggly_name_example", // required
  name: "name_example",
  placement: "none",
  response_condition: "response_condition_example",
  format: "'%h %l %u %t \"%r\" %>s %b'",
  format_version: 1,
  token: "token_example",
};

apiInstance.updateLogLoggly(options)
  .then((data) => {
    console.log(data, "API called successfully.");
  })
  .catch((error) => {
    console.error(error);
  });

Options

Name Type Description Notes
service_id String Alphanumeric string identifying the service.
version_id Number Integer identifying a service version.
logging_loggly_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 Number 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]
token String The token to use for authentication (https://www.loggly.com/docs/customer-token-authentication-token/). [optional]

Return type

LoggingLogglyResponse

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