Method projects.logServices.list

Lists the log services that have log entries in this project.

HTTP request

GET https://logging.googleapis.com/v1beta3/{projectName=projects/*}/logServices

(This URI uses URI Template syntax.)

Path parameters

Parameter name Type Description
projectName string The resource name of the project whose services are to be listed.

Query parameters

Parameter name Type Description
pageSize number The maximum number of LogService objects to return in one operation.
pageToken string An opaque token, returned as nextPageToken by a prior ListLogServices operation. If pageToken is supplied, then the other fields of this request are ignored, and instead the previous ListLogServices operation is continued.

Request body

The request body must be empty.

Response body

If successful, the response body contains data with the following structure:

Result returned from ListLogServicesRequest.

JSON representation
{
  "logServices": [
    {
      object(LogService)
    }
  ],
  "nextPageToken": string,
}
Field name Type Description
logServices[] object(LogService) A list of log services.
nextPageToken string If there are more results, then nextPageToken is returned in the response. To get the next batch of services, use the value of nextPageToken as pageToken in the next call of ListLogServices. If nextPageToken is empty, then there are no more results.

Authorization

Requires one of the following OAuth scopes:

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

For more information, see the Auth Guide.

LogService

Output only. Describes a service that writes log entries.

JSON representation
{
  "name": string,
  "indexKeys": [
    string
  ],
}
Field name Type Description
name string The service's name. Example: "appengine.googleapis.com". Log names beginning with this string are reserved for this service. This value can appear in the LogEntry.metadata.serviceName field of log entries associated with this log service.
indexKeys[] string

A list of the names of the keys used to index and label individual log entries from this service. The first two keys are used as the primary and secondary index, respectively. Additional keys may be used to label the entries. For example, App Engine indexes its entries by module and by version, so its indexKeys field is the following:

[ "appengine.googleapis.com/module_id",
  "appengine.googleapis.com/version_id" ]

Try it!