{"openapi":"3.1.0","info":{"title":"Relay","version":"1.0.0","description":"Durable webhook inboxes for agents — receive callbacks and approvals without holding a connection open, with long-poll\nwait.","contact":{"email":"support@payweave.app"},"x-guidance":"Durable webhook inboxes for agents — receive callbacks and approvals without holding a connection open, with long-poll\nwait.\nEach endpoint takes a JSON request and returns either a 200 with the result or a 402 Payment Required challenge (MPP / x402). Pricing is fixed per endpoint in USD; the per-operation `x-payment-info` block carries the exact challenge metadata (price, accepted protocols, payment realm).\nFor per-endpoint schemas, examples, and detailed usage, fetch https://api.payweave.app/app/app_z4jqboizri5s1y5cyyp2mnkj/skill.md or `<this-origin>/<path>/skill.md` for a single endpoint."},"x-service-info":{"categories":["Agent infrastructure","Webhooks","Async"]},"servers":[{"url":"https://relay.payweave.services"}],"paths":{"/inboxes":{"get":{"summary":"Relay: List Inboxes","description":"List the inboxes owned by the calling wallet, each with its id, label, and lifetime. Lets a stateless agent rediscover what each inbox is for after a restart. Returns up to 100 inboxes.","x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.001000"},"protocols":[{"mpp":{"method":"tempo","intent":"charge","currency":"0x20c000000000000000000000b9537d11c60e8b50","network":"eip155:4217","amount":"1000"}},{"mpp":{"method":"solana","intent":"charge","currency":"EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v","network":"solana:5eykt4UsFv8P8NJdTREpY1vzqKqZKvdp","amount":"1000"}},{"x402":{"scheme":"exact","network":"eip155:8453","currency":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","amount":"1000","extra":{"name":"USD Coin","version":"2"}}},{"x402":{"scheme":"exact","network":"solana:5eykt4UsFv8P8NJdTREpY1vzqKqZKvdp","currency":"EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v","amount":"1000"}}],"description":"List the inboxes owned by the calling wallet, each with its id, label, and lifetime. Lets a stateless agent rediscover what each inbox is for after a restart. Returns up to 100 inboxes."},"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"type":"object","properties":{"inboxes":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"createdAt":{"type":"number"},"expiresAt":{"type":"number"},"label":{"type":"string"}},"required":["id","createdAt","expiresAt"],"additionalProperties":false}}},"required":["inboxes"],"additionalProperties":false}}}},"402":{"description":"Payment Required"}}},"post":{"summary":"Relay: Create Webhook Inbox","description":"Create a durable webhook inbox and get a public callback URL. External systems (or a human clicking a link) POST to that URL; capture the events later via GET /inboxes/{id}/events. Optional `label`/`metadata` describe the inbox's purpose and are returned on read/info/list. Priced by TTL tier (1d/7d/30d).","x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.003000"},"protocols":[{"mpp":{"method":"tempo","intent":"charge","currency":"0x20c000000000000000000000b9537d11c60e8b50","network":"eip155:4217","amount":"3000"}},{"mpp":{"method":"solana","intent":"charge","currency":"EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v","network":"solana:5eykt4UsFv8P8NJdTREpY1vzqKqZKvdp","amount":"3000"}},{"x402":{"scheme":"exact","network":"eip155:8453","currency":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","amount":"3000","extra":{"name":"USD Coin","version":"2"}}},{"x402":{"scheme":"exact","network":"solana:5eykt4UsFv8P8NJdTREpY1vzqKqZKvdp","currency":"EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v","amount":"3000"}}],"description":"Create a durable webhook inbox and get a public callback URL. External systems (or a human clicking a link) POST to that URL; capture the events later via GET /inboxes/{id}/events. Optional `label`/`metadata` describe the inbox's purpose and are returned on read/info/list. Priced by TTL tier (1d/7d/30d)."},"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string"},"callbackUrl":{"type":"string"},"expiresAt":{"type":"number"},"capacity":{"type":"number"},"ttlDays":{"type":"number"},"label":{"type":"string"},"metadata":{"type":"object","additionalProperties":{}}},"required":["id","callbackUrl","expiresAt","capacity","ttlDays"],"additionalProperties":false}}}},"402":{"description":"Payment Required"}},"requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"ttlDays":{"type":"integer","minimum":1,"maximum":30,"description":"Inbox lifetime in days (1-30, default 1). Priced in tiers: <=1d, <=7d, <=30d."},"label":{"type":"string","minLength":1,"maxLength":128,"description":"Short purpose label, e.g. \"stripe-payment-confirmations\". Returned on read/info/list."},"metadata":{"type":"object","additionalProperties":{},"description":"Arbitrary small JSON object describing the inbox purpose (<=2048 bytes serialized). Returned on read/info/list."}},"additionalProperties":false}}}}}},"/inboxes/{id}":{"delete":{"summary":"Relay: Delete Inbox","description":"Delete an inbox and all its captured events. Owner-scoped.","x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.000500"},"protocols":[{"mpp":{"method":"tempo","intent":"charge","currency":"0x20c000000000000000000000b9537d11c60e8b50","network":"eip155:4217","amount":"500"}},{"mpp":{"method":"solana","intent":"charge","currency":"EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v","network":"solana:5eykt4UsFv8P8NJdTREpY1vzqKqZKvdp","amount":"500"}},{"x402":{"scheme":"exact","network":"eip155:8453","currency":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","amount":"500","extra":{"name":"USD Coin","version":"2"}}},{"x402":{"scheme":"exact","network":"solana:5eykt4UsFv8P8NJdTREpY1vzqKqZKvdp","currency":"EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v","amount":"500"}}],"description":"Delete an inbox and all its captured events. Owner-scoped."},"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"type":"object","properties":{"ok":{"type":"boolean","const":true},"id":{"type":"string"}},"required":["ok","id"],"additionalProperties":false}}}},"402":{"description":"Payment Required"}},"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}]},"get":{"summary":"Relay: Inbox Info","description":"Get an inbox label, metadata, lifetime, event count, and dropped count, without consuming events. Owner-scoped.","x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.000500"},"protocols":[{"mpp":{"method":"tempo","intent":"charge","currency":"0x20c000000000000000000000b9537d11c60e8b50","network":"eip155:4217","amount":"500"}},{"mpp":{"method":"solana","intent":"charge","currency":"EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v","network":"solana:5eykt4UsFv8P8NJdTREpY1vzqKqZKvdp","amount":"500"}},{"x402":{"scheme":"exact","network":"eip155:8453","currency":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","amount":"500","extra":{"name":"USD Coin","version":"2"}}},{"x402":{"scheme":"exact","network":"solana:5eykt4UsFv8P8NJdTREpY1vzqKqZKvdp","currency":"EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v","amount":"500"}}],"description":"Get an inbox label, metadata, lifetime, event count, and dropped count, without consuming events. Owner-scoped."},"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string"},"createdAt":{"type":"number"},"expiresAt":{"type":"number"},"capacity":{"type":"number"},"count":{"type":"number"},"dropped":{"type":"number"},"label":{"type":"string"},"metadata":{"type":"object","additionalProperties":{}}},"required":["id","createdAt","expiresAt","capacity","count","dropped"],"additionalProperties":false}}}},"402":{"description":"Payment Required"}},"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}]}},"/inboxes/{id}/events":{"get":{"summary":"Relay: Read Inbox Events","description":"Read events captured by an inbox. Query params: `since` (cursor from a previous response, returns only newer events) and `wait` (seconds to long-poll for the next event, max 30; returns as soon as one arrives). Echoes the inbox `label`/`metadata` for context. Owner-scoped: only the wallet that created the inbox can read it. Flat price regardless of wait.","x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.001000"},"protocols":[{"mpp":{"method":"tempo","intent":"charge","currency":"0x20c000000000000000000000b9537d11c60e8b50","network":"eip155:4217","amount":"1000"}},{"mpp":{"method":"solana","intent":"charge","currency":"EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v","network":"solana:5eykt4UsFv8P8NJdTREpY1vzqKqZKvdp","amount":"1000"}},{"x402":{"scheme":"exact","network":"eip155:8453","currency":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","amount":"1000","extra":{"name":"USD Coin","version":"2"}}},{"x402":{"scheme":"exact","network":"solana:5eykt4UsFv8P8NJdTREpY1vzqKqZKvdp","currency":"EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v","amount":"1000"}}],"description":"Read events captured by an inbox. Query params: `since` (cursor from a previous response, returns only newer events) and `wait` (seconds to long-poll for the next event, max 30; returns as soon as one arrives). Echoes the inbox `label`/`metadata` for context. Owner-scoped: only the wallet that created the inbox can read it. Flat price regardless of wait."},"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"type":"object","properties":{"events":{"type":"array","items":{"type":"object","properties":{"seq":{"type":"number"},"id":{"type":"string"},"receivedAt":{"type":"number"},"method":{"type":"string"},"headers":{"type":"object","additionalProperties":{"type":"string"}},"query":{"type":"object","additionalProperties":{"type":"string"}},"body":{"type":["string","null"]},"bodyTruncated":{"type":"boolean"},"contentType":{"type":["string","null"]}},"required":["seq","id","receivedAt","method","headers","query","body","bodyTruncated","contentType"],"additionalProperties":false}},"cursor":{"type":"number"},"dropped":{"type":"number"},"label":{"type":"string"},"metadata":{"type":"object","additionalProperties":{}}},"required":["events","cursor","dropped"],"additionalProperties":false}}}},"402":{"description":"Payment Required"}},"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}},{"name":"since","in":"query","required":false,"description":"Cursor from a previous response; returns only events newer than this seq.","schema":{"type":"integer","minimum":0}},{"name":"wait","in":"query","required":false,"description":"Seconds to long-poll for the next event (max 30); returns as soon as one arrives.","schema":{"type":"integer","minimum":0}}]}}}}