Method projects.logs.sinks.create

Creates a log sink. All log entries for a specified log are written to the destination.

HTTP request

POST https://logging.googleapis.com/v1beta3/{logName=projects/*/logs/*}/sinks

(This URI uses URI Template syntax.)

Path parameters

Parameter name Type Description
logName string The resource name of the log to which to the sink is bound.

Request body

The request body contains an instance of LogSink.

Response body

If successful, the response body contains an instance of LogSink.

Authorization

Requires one of the following OAuth scopes:

  • https://www.googleapis.com/auth/logging.admin
  • https://www.googleapis.com/auth/cloud-platform

For more information, see the Auth Guide.

Try it!