pub async fn validate_policy(
state: &SharedState,
a: ValidatePolicyArgs,
) -> Result<Value, ToolError>Expand description
Validates + compiles a policy against the live supernodes, plugin configs
and stores, without persisting. Mirrors what put_policy(dry_run) checks
for the policy itself (cross-references from routes are not included).
The result’s buffering array names every upstream the policy forces to
buffer instead of stream, and the node responsible for each — the same
information the Admin API’s POST /api/policies/validate reports to a
human, so an agent driving the gateway sees it too. A policy that forces
buffering is still valid; buffering is informational, not an error.