Api Endpoint

GW8 Spend Policy

[Spend policy: agent payment rules check, plus a signed audit record] Check one proposed payment against the buyer's rules (per-tx limit, rolling cap with spent-so-far, categories, allow/deny lists, hours+timezone, assets/chains, human-approval threshold). Returns allow / deny / needs_approval, which rules fired, and a signed audit record (decisionReceipt). Verify free at POST /api/receipt/verify; public key at GET /.well-known/gw8-receipt-key. Stateless, deterministic; moves no money. $0.02.

Open interactive test console

Offering

Provider
micro-saas-agent.onrender.com
Method
POST
Offering type
Api Endpoint
Transport type
http
Category
Other
Delivery
Not provided
Pricing model
Not provided
x402 version
2

Endpoint context

URL
https://micro-saas-agent.onrender.com/api/spend/check
MIME type
application/json
First seen
2026-10-23T22:13:16.843Z
Last seen
Tags
spend policy, payment risk, allow or deny, agent payment, X402

Payment pricing

x402 payment terms are the authoritative price for calling this endpoint.

Payment option 1
0.02 USDC
Atomic price: 20000 · Network: eip155:8453 · Asset: USDC · Scheme: exact
Raw x402 terms
[
  {
    "scheme": "exact",
    "network": "eip155:8453",
    "asset": "0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913",
    "amount": "20000",
    "payTo": "0xB4527dccaC81eB73d4988A51a4cb1FBBF2C3CaBd"
  }
]

Observed health

Status
Healthy
Latest latency
37 ms
Average latency
44 ms
HTTP status
200
Last checked
Reachability
100% over 12 checks

Latency is measured to the first response headers. A reachable result does not verify response accuracy or merchant identity.

Input schema

{
  "type": "object",
  "properties": {
    "type": {
      "type": "string",
      "const": "http"
    },
    "method": {
      "type": "string",
      "enum": [
        "POST"
      ]
    },
    "bodyType": {
      "type": "string",
      "enum": [
        "json"
      ]
    },
    "body": {
      "type": "object",
      "properties": {
        "payment": {
          "type": "object",
          "description": "Proposed payment: amount, currency, recipient, category, chain, and time.",
          "example": {
            "amount": "420.00",
            "currency": "USDC",
            "chain": "base",
            "recipientId": "acct_acme_supplies",
            "recipientDomain": "acme-supplies.com",
            "merchantCategory": "office-supplies",
            "timestamp": "2026-10-21T15:30:00Z",
            "agentId": "ap-agent-7",
            "memo": "INV-10442"
          }
        },
        "policy": {
          "type": "object",
          "description": "Buyer spend policy: per-transaction limit, rolling cap, lists, hours, assets, and chains.",
          "example": {
            "currency": "USDC",
            "perTxLimit": "1000",
            "rollingCap": {
              "limit": "5000",
              "spentSoFar": "1200",
              "windowHours": 24
            },
            "blockedCategories": [
              "gambling",
              "crypto-exchange"
            ],
            "allowList": [
              "acme-supplies.com"
            ],
            "allowedHours": {
              "start": "08:00",
              "end": "18:00",
              "timezone": "America/Denver",
              "days": [
                "mon",
                "tue",
                "wed",
                "thu",
                "fri"
              ]
            },
            "allowedAssets": [
              "USDC"
            ],
            "allowedChains": [
              "base"
            ],
            "requireApprovalAbove": "750"
          }
        }
      },
      "additionalProperties": false,
      "required": [
        "payment",
        "policy"
      ],
      "description": "JSON body for this paid call."
    }
  },
  "required": [
    "type",
    "method",
    "bodyType",
    "body"
  ],
  "additionalProperties": false
}

Output schema

{
  "type": "object",
  "description": "[Spend policy: agent payment rules check, plus a signed audit record] Check one proposed payment against the buyer's rules (per-tx limit, rolling cap with spent-so-far, categories, allow/deny lists, hours+timezone, assets/chains, human-approval threshold). Returns allow / deny / needs_approval, which rules fired, and a signed audit record (decisionReceipt). Verify free at POST /api/receipt/verify; public key at GET /.well-known/gw8-receipt-key. Stateless, deterministic; moves no money. $0.02.",
  "properties": {
    "type": {
      "type": "string",
      "const": "json"
    },
    "example": {
      "type": "object",
      "properties": {
        "engine": {
          "type": "string",
          "description": "Rule engine id for the spend-policy check."
        },
        "decision": {
          "type": "string",
          "description": "allow, deny, or needs_approval."
        },
        "reasons": {
          "type": "array",
          "items": {
            "type": "object",
            "description": "The reasons item field in this route's paid JSON."
          },
          "description": "Rules that fired on this proposed payment."
        },
        "checks": {
          "type": "array",
          "items": {
            "type": "object",
            "properties": {
              "rule": {
                "type": "string",
                "description": "The rule field in this route's paid JSON."
              },
              "result": {
                "type": "string",
                "description": "The result field in this route's paid JSON."
              },
              "detail": {
                "type": "string",
                "description": "The detail field in this route's paid JSON."
              }
            },
            "description": "The checks item field in this route's paid JSON."
          },
          "description": "Every spend-policy check and whether it passed."
        },
        "remaining": {
          "type": "object",
          "properties": {
            "perTx": {
              "type": "string",
              "description": "The per tx field in this route's paid JSON."
            },
            "rollingCapBefore": {
              "type": "string",
              "description": "The rolling cap before field in this route's paid JSON."
            },
            "rollingCapAfter": {
              "type": "string",
              "description": "The rolling cap after field in this route's paid JSON."
            }
          },
          "description": "Per-transaction and rolling-cap room after this payment."
        },
        "decisionReceipt": {
          "type": "object",
          "properties": {
            "endpoint": {
              "type": "string",
              "description": "The endpoint field in this route's paid JSON."
            },
            "accessType": {
              "type": "string",
              "description": "The access type field in this route's paid JSON."
            },
            "query": {
              "type": "object",
              "properties": {
                "decision": {
                  "type": "string",
                  "description": "The decision field in this route's paid JSON."
                },
                "requestSha256": {
                  "type": "string",
                  "description": "The request sha256 field in this route's paid JSON."
                }
              },
              "description": "The query field in this route's paid JSON."
            },
            "response_sha256": {
              "type": "string",
              "description": "The response sha256 field in this route's paid JSON."
            },
            "payload": {
              "type": "string",
              "description": "The payload field in this route's paid JSON."
            },
            "signature": {
              "type": "string",
              "description": "The signature field in this route's paid JSON."
            },
            "signed": {
              "type": "boolean",
              "description": "The signed field in this route's paid JSON."
            },
            "alg": {
              "type": "string",
              "description": "The alg field in this route's paid JSON."
            },
            "verify_url": {
              "type": "string",
              "description": "The verify url field in this route's paid JSON."
            }
          },
          "description": "Receipt bound to this spend-policy decision (signature present when signing is enabled)."
        }
      },
      "description": "Spend-policy decision: allow, deny, or needs_approval, plus the rules that fired."
    }
  },
  "required": [
    "type",
    "example"
  ]
}