Traffic Policy Overview
The ngrok Traffic Policy engine enables you to manage traffic consistently across your endpoints. It allows you to inspect, manipulate, and route traffic in a structured way.
Traffic Policy is composed of a few key components:
- Phases: Defined points in the traffic lifecycle where you can apply logic.
- Phase Rules: The set of conditions and actions applied during specific phases to filter, manipulate, or manage traffic.
- Expressions: Conditions used in Phase Rules to determine when an action should be applied.
- Actions: Logic that is triggered when a Phase Rule condition is met.
- CEL Interpolation: A way to dynamically evaluate variables and macros inside configuration values, such as URLs or headers.
By combining these components, Traffic Policy provides a powerful way to control your traffic flow at a fine-grained level.