sendsend.email

Official libraries

Libraries for Python, PHP, Ruby, Go, .NET, Java and Rust, plus a Node library, a CLI and an MCP server. Each covers the whole API.

Every library is generated from the same description as this API reference, so a call that exists in the API exists in the library, with the same name. They have no dependencies, retry safely, and raise one error type that carries the status, the error code and the request id.

LanguageInstallSend an email
Pythonpip install sendsendclient.emails.send({...}, idempotency_key="k")
PHPcomposer require sendsend/sendsend$client->emails->send([...], 'k')
Rubygem install sendsendclient.emails.deliver({...}, idempotency_key: 'k')
Gogo get github.com/sendsend/sendsend-goclient.Emails.Send(ctx, body, sendsend.WithIdempotencyKey("k"))
.NETdotnet add package SendSendawait client.Emails.SendAsync(body, new RequestOptions { IdempotencyKey = "k" })
Javaemail.sendsend:sendsend (Maven)client.emails.send(body, RequestOptions.create().idempotencyKey("k"))
Rustcargo add sendsendclient.emails().send(&body, Some(&opts)).await
Not on the package registries yet. The libraries are finished and tested against the real API, but the install commands above only work once each one is published (PyPI, Packagist, RubyGems, Go, NuGet, Maven Central and crates.io). Until then, call the REST API directly, which every guide here shows, or email us for a copy.

The same shape in every language

client = SendSend("ss_live_...")                       # or set SENDSEND_API_KEY

email = client.emails.send({"from": "Acme <hello@mail.acme.com>", "to": ["maria@example.com"],
                            "subject": "Welcome", "html": "<p>Hi!</p>"}, idempotency_key="signup-123")

audience = client.audiences.create({"name": "Customers"})
client.contacts.import_(audience["id"], {"contacts": [{"email": "li@example.com"}]})
client.broadcasts.send(broadcast_id, {"scheduled_at": "in 1 hour"})

Every group of the API is a field of the client (emails, audiences, broadcasts, inbound and so on). Path parameters come first, then the body, then options such as the idempotency key and query parameters.

Safe retries

Reads and deletes are retried twice on 429, 502, 503, 504 and network errors, waiting for Retry-After. A write is only retried when you give it an idempotency key, so a retry can never send an email twice.

Verify webhooks

Each library has a function that checks the signature on a webhook and returns the event, using the raw request body.

Also

  • Node and TypeScript: the @sendsendemail/sdk package, with React Email support.
  • Command line: sendsend, to send and inspect email from a terminal.
  • MCP server: lets AI assistants send and look up email.
  • Anything else: the OpenAPI file works with any code generator.