Evaluate whether an agent should pay an endpoint

Changed on

Free pre-payment policy decision for AI agents deciding whether to pay an x402 endpoint.

post/api/agent/can-pay

Request

  • Base URL: https://ontarioprotocol.com
  • URL: https://ontarioprotocol.com/api/agent/can-pay
  • Auth: none required

Request body

agent_policy'strict' | 'standard' | 'permissive'
endpointstring required

Paid API endpoint URL the agent wants Ontario to inspect before payment.

max_usdcstring
require_audit_receiptboolean

true requests the optional 0.002 USDC settlement-backed evidence receipt handoff after an allow decision. This does not submit payment.

verify_liveboolean

Response

Payment decision

agent_policystring
auditable_paid_continuationobject

Optional 0.002 USDC receipt path. It is recommended only after an allow decision and an explicit require_audit_receipt request.

decision'allow' | 'review' | 'deny'
declared_price_usdcnumber nullable
endpointstring
max_usdcnumber nullable
reasonstring
reasonsstring[]
recommendationsobject[]
report_integrity_okboolean
warningsstring[]

Changes

    • info

      added the new optional request property

    • info

      added the optional property to the response with the status