Skip to content
Docs Sending submissions

Docs

Sending submissions

Every endpoint gets one . Send it a POST request with your form's fields, and PostTo stores and delivers them. There's no schema to register up front — PostTo doesn't require specific field names, and any field you send is stored. In practice, though, you'll want to send at least a message and a way to reply (typically email and message) — see below for why.

The endpoint URL

Every endpoint has its own URL in this shape:

https://postto.dev/api/v1/send/YOUR_TOKEN

YOUR_TOKEN is a unique, unguessable identifier generated when you create the endpoint — it's shown in the dashboard and doubles as the credential for token mode. You'll find the exact URL to copy on your endpoint's page.

Sending a request

PostTo accepts JSON, standard form encoding, and multipart form data — whatever your form or HTTP client sends by default is fine. The request body must include at least one field, or PostTo rejects it with empty_submission; beyond that, any field name is accepted and stored as-is.

Four field names are also read as shortcuts for building the outgoing email — subject, message, email, and name (see field mapping for the full detail, including how to use different names). None of them are individually required by PostTo, but if you skip message and email entirely, the email you receive won't have a body or a reply-to address — so in practice, include at least those two.

curl -X POST https://postto.dev/api/v1/send/YOUR_TOKEN \
  -H "Content-Type: application/json" \
  -d '{"subject":"Contact form","message":"Hello, I would like to...","email":"[email protected]","name":"Jane Smith"}'

What comes back

A plain HTML form (no special headers) gets redirected to a hosted "thanks" page — nothing for you to build. If your client sends Accept: application/json, you get a JSON response instead — the right choice for a fetch/AJAX submission that shows its own success or error message without a full page reload. Full detail on both shapes is on the response format page.

Server-to-server (signed mode) requests always get JSON back, regardless of the Accept header — there's no browser involved to redirect.

Try it against your own form

Create an endpoint and get a working URL in under a minute — free plan, no credit card.

Start for free