Authentication
Requires x402 payment proof in the X-Payment-Proof header.
Request Body
Quote ID from the /email/quote endpoint
to_address
string | string[]
required
Recipient email address(es)
Email body content (plain text)
Array of attachment objects with filename, content_type, and content (base64)
Response
Job ID for tracking the email send status
Job status: pending, processing, completed, or failed
curl -X POST https://win.oneshotagent.com/v1/tools/email/send \
-H "Content-Type: application/json" \
-H "X-Payment-Proof: <your_x402_signature>" \
-d '{
"quote_id": "quote_abc123",
"from_address": "[email protected]",
"to_address": "[email protected]",
"subject": "Hello from OneShot",
"body": "This is a test email"
}'
{
"request_id": "req_xyz789",
"status": "processing",
"message": "Email job queued successfully"
}
Bulk Sending
To send the same email content to multiple recipients, pass an array of email addresses in the to_address field. Each recipient will receive an individual email (not CC/BCC).
curl -X POST https://win.oneshotagent.com/v1/tools/email/send \
-H "Content-Type: application/json" \
-H "X-Payment-Proof: <your_x402_signature>" \
-d '{
"quote_id": "quote_bulk_123",
"from_address": "[email protected]",
"to_address": ["[email protected]", "[email protected]"],
"subject": "Hello Team",
"body": "Weekly update..."
}'
Domain Provisioning
If the domain is new, OneShot will automatically:
- Register the domain with Name.com
- Configure DNS records with Cloudflare
- Set up email sending with Resend
- Verify domain ownership
This process typically takes 2-5 minutes. The email will be sent once provisioning completes.
Notes
- Quote must be used within 1 hour
- Domain provisioning is automatic - no additional steps required
- Job status can be polled using the
request_id