Skip to main content
POST
https://win.oneshotagent.com
/
v1
/
tools
/
email
/
send
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"
}

Authentication

Requires x402 payment proof in the X-Payment-Proof header.

Request Body

quote_id
string
required
Quote ID from the /email/quote endpoint
from_address
string
required
Sender email address
to_address
string | string[]
required
Recipient email address(es)
subject
string
required
Email subject line
body
string
required
Email body content (plain text)
attachments
array
Array of attachment objects with filename, content_type, and content (base64)

Response

request_id
string
Job ID for tracking the email send status
status
string
Job status: pending, processing, completed, or failed
message
string
Status message
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:
  1. Register the domain with Name.com
  2. Configure DNS records with Cloudflare
  3. Set up email sending with Resend
  4. 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