{
  "purpose": "Illustrative Direct API decision cases. Result describes whether this request can reach route dispatch.",
  "examplePolicy": {
    "apiActivity": "offer.read",
    "roleGrant": {"role": "inquiry-reader", "activity": "offer.read"},
    "channelRule": {"channel": "internal-inquiry", "consumer": "sample-consumer", "service": "sample-inquiry", "allowedSourceNetwork": "192.0.2.0/24"},
    "payloadRule": {"consumer": "sample-consumer", "service": "sample-inquiry", "policy": "standard-body"}
  },
  "baseline": {
    "rateBudget": "available",
    "token": "valid-for-this-api",
    "roleAllowsActivity": true,
    "channelAllowsTrustedClientIP": true,
    "payloadPolicy": "scan",
    "literalMatch": false
  },
  "cases": [
    {"case": "All required checks pass", "change": {}, "decision": "dispatch"},
    {"case": "Proxy budget exhausted", "change": {"rateBudget": "empty"}, "decision": "local-rate-rejection", "reachesDirect": false},
    {"case": "Expired token", "change": {"token": "expired"}, "decision": "authentication-denied", "trustedPrincipal": false},
    {"case": "Valid principal without activity grant", "change": {"roleAllowsActivity": false}, "decision": "authorization-denied"},
    {"case": "Known caller from a disallowed channel address", "change": {"channelAllowsTrustedClientIP": false}, "decision": "channel-policy-denied"},
    {"case": "Mapped scanner finds a blocked literal", "change": {"literalMatch": true}, "decision": "payload-policy-denied"}
  ]
}
