Skip to main content

vaemail — Python SDK

Email infrastructure for AI agents and applications. Send transactional email, authenticate sending domains, track delivery, and diagnose deliverability.

No dependencies: the SDK uses only the standard library, so it installs without pulling anything behind it.

pip install vaemail

Send an email

from vaemail import VaEmail

client = VaEmail(api_key="your-api-key")

client.send({
    "to": "customer@example.com",
    "subject": "Your order is on its way",
    "html": "<p>Tracking number: 1Z999</p>",
}, idempotency_key="order-4711")

The idempotency key makes the call safe to replay for 24 hours: retrying after a timeout will not send a second email.

Try before sending

client.validate({"to": "customer@example.com", "subject": "Hi", "html": "<p>Hi</p>"})

Same checks as a real send — key scope, quotas, sending domain, suppression list — but nothing leaves. Useful when an agent builds a message on its own.

Authenticate a sending domain

result = client.add_domain("news.example.com", dkim_tokens=["aaa111", "bbb222", "ccc333"])

for record in result["data"]["dns_records"]:
    if record["publishable"]:
        print(record["type"], record["host"], "->", record["value"])

The three DKIM tokens come from Amazon SES when the domain identity is created. Every record says whether it is publishable as-is: a value that still depends on something unknown is flagged instead of being handed over, so an agent never publishes a record that would break the domain's authentication.

Errors say what to do next

from vaemail import VaEmailError

try:
    client.send({"to": "customer@example.com"})
except VaEmailError as error:
    print(error.code)        # DOMAIN_NOT_VERIFIED
    print(error.retryable)   # False
    print(error.for_agent()) # reason, corrective action, whether to retry

Everything else

capabilities(), health(), get_message(), list_messages(), list_domains(), verify_domain(), dns_records(), diagnose_deliverability(), list_suppressions(), usage(), audit_logs().

Full API reference: https://vaemail.fr/docs/api

Tests

python -m unittest discover -s tests

MIT licensed.

Release files for vaemail 1.0.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for vaemail 1.0.0
File Size Uploaded
vaemail-1.0.0.tar.gz 6.1 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for vaemail 1.0.0
File Interpreter ABI Platform
vaemail-1.0.0-py3-none-any.whl Python 3 none any Details

Total release size: 11.0 kB

Release files / vaemail-1.0.0.tar.gz

Download URL vaemail-1.0.0.tar.gz
Size 6.1 kB
Tags Source
SHA-256 checksum
How to use checksums
4f1e437ece284eed7b09abc67c7c95da17bc80c63a7d49ca41edbad2b05718ec
BLAKE2b-256 checksum
How to use checksums
5b96887cded13561413f9179cddd3c198cda59fe88fca9294d37c05bfb78eb3f
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.14.7

Release files / vaemail-1.0.0-py3-none-any.whl

Download URL vaemail-1.0.0-py3-none-any.whl
Size 4.9 kB
Tags Python 3
SHA-256 checksum
How to use checksums
85711b9c5b8c0a7b7c652f290995d5b2734bd3289c8961647474605791e1addc
BLAKE2b-256 checksum
How to use checksums
94d18fd18e6f8e78b0461367d7d1d2476d8bc8617a083334e2b9f282215fcfbf
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.14.7

Release history Release notifications | RSS feed

This release

1.0.0 This release

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page