Docs

GoSent API

Send transactional email and verify addresses with plain HTTPS requests. Every endpoint takes and returns JSON.

Quickstart

1. Request access and verify your sending domain. 2. Copy your API key from the dashboard. 3. Send your first email:

Node.js
const res = await fetch("https://gosent.io/api/v1/emails", {
  method: "POST",
  headers: {
    "Authorization": "Bearer " + process.env.GOSENT_API_KEY,
    "Content-Type": "application/json",
  },
  body: JSON.stringify({
    from: "CT Filings <filings@ctfilings.com>",
    to: "client@example.com",
    subject: "Your annual report was filed",
    html: "<p>We filed your report today.</p>",
  }),
});
const { id } = await res.json();

Authentication

Send your API key in the Authorization header on every request. Keys start with gs_live_. Keep them on your server, never in browser code or a public repository.

Authorization: Bearer gs_live_xxxxxxxxxxxxxxxx

Send an email

POST/api/v1/emails
FieldTypeDescription
fromstringSender, like Acme <billing@acme.com>. Must use a domain you verified.
tostring or string[]One or more recipients (50 total including cc and bcc).
subjectstringSubject line.
html / textstringBody. Send either or both.
cc, bcc, reply_tostring or string[]Optional.
verifybooleanOptional. Checks each recipient first and refuses to send to addresses that would bounce.
Response · 200
{
  "id": "7f3a9c2e-41b8-4d17-9a0e-2c5b8e1f6d01",
  "provider_message_id": "0100018f…"
}

SMTP

Use SMTP when your software can't call an API, such as WordPress or an accounting system. SMTP credentials are issued with your account.

Hostsmtp.gosent.io
Port587 (STARTTLS) or 465 (TLS)
Username / passwordFrom the dashboard, under SMTP

Verify an address

POST/api/v1/verify
Request
{ "email": "jordan@gmial.com" }
Response · 200
{
  "email": "jordan@gmial.com",
  "status": "invalid",          // valid | invalid | risky | unknown
  "reason": "domain_typo",
  "suggestion": "jordan@gmail.com",
  "checks": {
    "syntax": true,
    "domain_exists": true,
    "mx_records": [],
    "disposable": false,
    "role_account": false,
    "free_provider": false,
    "mailbox": "not_checked"
  },
  "billable": true
}
StatusMeaningSend?
validThe domain accepts mail and nothing looks wrong.Yes
riskyCatch-all server or shared inbox like info@.Your choice
invalidBad format, dead domain, typo or throwaway inbox.No
unknownThe domain's servers didn't answer. Not charged.Retry later

Verify a list

Send up to 100 addresses per request. For bigger lists, upload a CSV in the dashboard.

Request
{ "emails": ["a@acme.com", "b@acme.com", "c@gmial.com"] }
Response · 200
{ "results": [ … ], "summary": { "valid": 2, "invalid": 1 } }

Webhooks

Add an endpoint in the dashboard and we'll POST each event to it. Events: email.sent, email.delivered, email.opened, email.clicked, email.bounced, email.complained. Reply with any 2xx status; we retry failures for 24 hours.

Errors

{ "error": { "name": "validation_error", "message": "`subject` is required." } }
StatusNameWhat to do
401missing_api_keyCheck the Authorization header.
403domain_not_verifiedSend from a domain your key is allowed to use.
422validation_errorFix the field named in the message.
429rate_limit_exceededSlow down and retry after a minute.
503sending_not_configuredSending isn't switched on for this account yet.

Limits

New accounts start at 100 emails a day, rising as bounce and complaint rates stay low. Sending pauses automatically if your bounce rate passes 4% or your complaint rate passes 0.08%. See the Acceptable Use Policy.