Health & Hygiene

Put Routing Policy

Create or update the caller's routing policy.

Requires X-API-Key or x402 payment ($0.01). Validates that:

  • All 6 grades (A-F) are assigned to exactly one category
  • escrow_disabled consistency (no escrow grades when disabled)
  • Allowlist addresses are valid, max 1000
  • No self-allowlisting (caller's own address)
  • Allowlisted addresses must have AHS Grade C or above
put/ahs/route/policy

Request

  • Base URL: https://agenthealthmonitor.xyz (the document declares no server; this is the origin it was published from)
  • URL: https://agenthealthmonitor.xyz/ahs/route/policy
  • Auth: none declared

Request body

instant_gradesstring[] required

Grades that map to instant_settle

escrow_gradesstring[] required

Grades that map to escrow

reject_gradesstring[] required

Grades that map to reject

escrow_disabledboolean

If true, escrow grades fall through to reject (binary mode)

allowliststring[] nullable

Wallet addresses to bypass routing (always instant_settle). Max 1000.

confidence_overridesobject nullable

Per-grade confidence-level overrides. Outer keys are grades (A-F), inner keys are confidence levels (HIGH, MEDIUM, LOW, INSUFFICIENT), values are routing actions (instant_settle, escrow, reject).

Example request

{
  "instant_grades": [
    "A",
    "B"
  ],
  "escrow_grades": [
    "C"
  ],
  "reject_grades": [
    "D",
    "E",
    "F"
  ],
  "confidence_overrides": {
    "C": {
      "HIGH": "instant_settle"
    },
    "D": {
      "HIGH": "escrow"
    }
  }
}

Response

Successful Response

instant_gradesstring[] required

Grades that map to instant_settle

escrow_gradesstring[] required

Grades that map to escrow

reject_gradesstring[] required

Grades that map to reject

escrow_disabledboolean required

Binary mode — no escrow tier

allowlist_countinteger required

Number of addresses in the allowlist

confidence_overridesobject nullable

Active confidence-level overrides (null if none configured)

updated_atstring required

ISO 8601 timestamp of last policy update

Changes

No recorded changes to this operation across all 1 revision of this API.