Pull Buffered Webhook Events from Agent Inbox
Poll or drain captured webhook HTTP requests from the past 7 days for a NAT-isolated local AI agent.
curl -sG "https://api.agentapigate.ai/v1/agent/webhook/pull" \ --data-urlencode "inbox_id=whi_demo00000000000000000000" \ --data-urlencode "limit=10" \ --data-urlencode "format=md" \ -H "Authorization: Bearer aag_live_YOUR_KEY" \ -H "X-AAG-Max-Cost: 0.0100"
# Pull Buffered Webhook Events from Agent Inbox (`agent.webhook.pull`) **inbox_id**: whi_demo00000000000000000000 · **count**: 1 · **next_since_id**: 101 ## events - [1] id: 101, method: POST, content_type: application/json, query: , body_json: event: build.completed, status: success
Endpoint Parameters, Cost & Token Economy Reference
Endpoint ID:agent.webhook.pull · Method: GET| Parameter | Type | Req | Sample / Default | Description |
|---|---|---|---|---|
| inbox_id | string | required | whi_demo00000000000000000000 | Webhook inbox_id returned by agent.webhook.inbox_create |
| read_token | string | optional | — | Inbox read_token (optional when authenticated with the owning account API key) |
| since_id | number | optional | — | Optional cursor event ID; returns only events with id > since_id |
| limit | number | optional | 10 | Maximum buffered webhook events to return (1-100, default: 25) |
| ack_delete | boolean | optional | false | Delete returned events from the inbox after reading (default: false) |
| format | enum | optional | json | compact | md | Response format; compact or md cuts LLM tokens. |
| dry_run | 0 | 1 | optional | 1 | Returns exact pre-flight price quote & validation at $0.00 cost. |
| Access Rail / Metric | Value | Policy & SLA |
|---|---|---|
| API Key (PAYG) | $0.0010 / call | $0/mo · Balance never expires |
| Remote MCP Tool | agent_webhook_pull | OAuth 2.1 Hub & /mcp/intel |
| x402 Base USDC | $0.0020 / call | Zero-signup USDC enabled |
| P50 Latency | 1 ms | $0 billed on empty or 4xx/5xx |
| Token Economy | 178t → 76t (-57%) | Partner credit: eligible |
More agent.webhook Sibling Endpoints
Frequently Asked Questions
How do I call Pull Buffered Webhook Events from Agent Inbox (agent.webhook.pull) over REST and Remote MCP?
Send GET requests to https://api.agentapigate.ai/v1/agent/webhook/pull with an aag_live_* / aag_agent_* Bearer key, pay per call via x402 USDC, or call MCP tool agent_webhook_pull on https://mcp.agentapigate.ai/mcp.
What does agent.webhook.pull cost per call and are failed calls billed?
Each successful HTTP 200 response costs $0.001 USD from a non-expiring PAYG balance ($0/month minimum). Upstream errors, empty responses, and ?dry_run=1 pre-flight quotes always bill $0.00.
How does ?format=md or ?format=compact optimize AI agent token usage on agent.webhook.pull?
Passing ?format=md transforms the response into normalized Markdown (~76 tokens vs ~178 raw tokens, saving 57% of LLM context budget) while preserving structured JSON via ?format=json.
Can I restrict an AI agent key to only intel endpoints with a daily USD cap?
Yes. Create a scoped aag_agent_* sub-key via POST /v1/keys with allowed_packs: ["intel"], optional allowed_endpoints: ["agent.webhook.pull"], read_only: true, and a hard daily_cap_usd enforced atomically in Redis.