Cloud logging

Dialogflow API requests and responses can optionally be logged to Cloud logging for your agent. You can also control the region in which these logs are stored.

Enable Cloud logging

To enable or disable Cloud logging for your agent, see the logging options in the agent's general settings.

Viewing Cloud logs

Once you enable Cloud logging for an agent, you can browse these logs using the Cloud Logs Explorer.

Log format

For detailed information on the log format, see Log entry structure.

The following is a partial list of log entry titles used by Dialogflow:

  • Dialogflow Request
  • Dialogflow Response
  • Dialogflow webhook request
  • Dialogflow webhook response
  • Dialogflow webhook error
Request and response log entries have a jsonPayload field in the JSON format. The content of this payload resembles the structure of like-named Dialogflow API REST requests and responses as defined in Dialogflow reference documentation.

Regionalization

By default, Dialogflow Cloud log entries are routed to the _Default logs bucket, which is global. If you have data residency requirements for your project, you can route your logs to a region-specific logs bucket. For instructions, see regionalizing your project's logs using logs buckets.

Limitations

If Dialogflow response exceeds the Cloud logging log entry size limit, the QueryResult.diagnosticInfo field is not included in the logs.

At most 500 turns will be logged for each conversation.