Method: logs.classify

Full name: projects.locations.instances.logs.classify

Classify the logs to the corresponding logType.

HTTP request

POST https://chronicle.googleapis.com/v1alpha/{parent=projects/*/locations/*/instances/*}/logs:classify

The URL uses gRPC Transcoding syntax.

Path parameters

Parameters
parent

string

Required. The parent, which requests the classification.

Request body

The request body contains data with the following structure:

JSON representation
{
  "log_data": [
    string
  ]
}
Fields
log_data[]

string (bytes format)

Required. The batch of log data to classify.

A base64-encoded string.

Response body

Response message for classifying logs to the corresponding logType classes.

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

JSON representation
{
  "predictions": [
    {
      object (LogTypePrediction)
    }
  ]
}
Fields
predictions[]

object (LogTypePrediction)

The logType predictions for the log_data. Sorted in descending order of confidence score.

Authorization scopes

Requires the following OAuth scope:

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

For more information, see the Authentication Overview.

IAM Permissions

Requires the following IAM permission on the parent resource:

  • chronicle.instances.logTypeClassifier

For more information, see the IAM documentation.

LogTypePrediction

A single logtype prediction.

JSON representation
{
  "log_type": string,
  "score": number
}
Fields
log_type

string

The log type that was classified.

score

number

Score for this log type (for example, the probability the item belongs to this log type).