curl -X GET "https://win.oneshotagent.com/v1/tools/inbox?include_body=true&limit=10" \
-H "X-Agent-ID: <your_agent_uuid>"
const response = await fetch(
"https://win.oneshotagent.com/v1/tools/inbox?include_body=true&limit=10",
{
headers: {
"X-Agent-ID": agentUuid,
},
},
);
{
"emails": [
{
"id": "email_123",
"from": "[email protected]",
"authenticated": true,
"subject": "Re: Your inquiry",
"hidden_removed": 0,
"untrusted_content": true,
"body": "Thanks for reaching out!",
"received_at": "2025-12-28T12:00:00Z",
"thread_id": "thread_abc",
"attachments": [
{
"filename": "document.pdf",
"content_type": "application/pdf",
"size": 102400,
"content": "JVBERi0xLjQK..."
}
]
}
],
"count": 1,
"hidden_removed": 0,
"has_more": false,
"agent_id": "agent_xyz"
}
Email Inbox
Email Inbox
Poll for inbound emails, returning only essential fields
GET
/
v1
/
tools
/
inbox
curl -X GET "https://win.oneshotagent.com/v1/tools/inbox?include_body=true&limit=10" \
-H "X-Agent-ID: <your_agent_uuid>"
const response = await fetch(
"https://win.oneshotagent.com/v1/tools/inbox?include_body=true&limit=10",
{
headers: {
"X-Agent-ID": agentUuid,
},
},
);
{
"emails": [
{
"id": "email_123",
"from": "[email protected]",
"authenticated": true,
"subject": "Re: Your inquiry",
"hidden_removed": 0,
"untrusted_content": true,
"body": "Thanks for reaching out!",
"received_at": "2025-12-28T12:00:00Z",
"thread_id": "thread_abc",
"attachments": [
{
"filename": "document.pdf",
"content_type": "application/pdf",
"size": 102400,
"content": "JVBERi0xLjQK..."
}
]
}
],
"count": 1,
"hidden_removed": 0,
"has_more": false,
"agent_id": "agent_xyz"
}
Returns your agent’s inbound emails with essential fields only. Poll it with since to fetch only new mail. Add include_body=true for bodies and attachments.
Authentication
Requires theX-Agent-ID header with your wallet address.
Reads require a signed read proof (x-agent-proof header) showing you control that wallet.
Query Parameters
string
ISO 8601 timestamp. Returns emails received after it
number
default:"50"
Maximum emails to return (max: 100)
boolean
default:"false"
Include body and attachments
authenticated to true only when From-domain alignment is established. Failed, missing and historical results are false. This authenticates the domain, not the safety of the message content.
Response
array
Inbound email objects
Show Email Object
Show Email Object
string
Email ID
string
Sender email address
string
Email subject
string
ISO 8601 timestamp
string
Thread ID for conversation tracking
string
Readable body (only if
include_body=true), derived from filtered HTML when available (its visible text if the HTML cannot be converted to Markdown)string
HTML body with hidden content removed (only if
include_body=true)number
Sum of removed segments across returned emails. Each email also has
hidden_removed and untrusted_content: true. Counts cover only the subject and bodies included in this response.number
Number of emails returned
boolean
Whether more emails are available
curl -X GET "https://win.oneshotagent.com/v1/tools/inbox?include_body=true&limit=10" \
-H "X-Agent-ID: <your_agent_uuid>"
const response = await fetch(
"https://win.oneshotagent.com/v1/tools/inbox?include_body=true&limit=10",
{
headers: {
"X-Agent-ID": agentUuid,
},
},
);
{
"emails": [
{
"id": "email_123",
"from": "[email protected]",
"authenticated": true,
"subject": "Re: Your inquiry",
"hidden_removed": 0,
"untrusted_content": true,
"body": "Thanks for reaching out!",
"received_at": "2025-12-28T12:00:00Z",
"thread_id": "thread_abc",
"attachments": [
{
"filename": "document.pdf",
"content_type": "application/pdf",
"size": 102400,
"content": "JVBERi0xLjQK..."
}
]
}
],
"count": 1,
"hidden_removed": 0,
"has_more": false,
"agent_id": "agent_xyz"
}
Notes
- Returns only essential fields (no raw headers or metadata)
- Poll with
sinceto fetch only new mail - Attachments are base64-encoded
thread_idgroups messages into conversations