Event Logging Example
With Traffic Policy, you can connect your API to ngrok's event logging system for smarter troubleshooting, testing, and integration of logging services like Datadog for your API gateway and upstream services.
This rule:
- Checks if the response status code is not in the 200 range
- Logs the unsuccessful request with a custom message and metadata
You can use one of the following snippets:
Policy
- YAML
- JSON
Loading…
Loading…
Agent Config
- YAML
- JSON
Loading…
Loading…
See the log
Traffic Policy action docs for more information.