curl --request POST \
--url https://api.contiguity.com/send/email \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"to": "john.doe@example.com",
"from": "Contiguity <no-reply@contiguity.com>",
"subject": "Hello, world!"
}
'import requests
url = "https://api.contiguity.com/send/email"
payload = {
"to": "john.doe@example.com",
"from": "Contiguity <no-reply@contiguity.com>",
"subject": "Hello, world!"
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
to: 'john.doe@example.com',
from: 'Contiguity <no-reply@contiguity.com>',
subject: 'Hello, world!'
})
};
fetch('https://api.contiguity.com/send/email', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.contiguity.com/send/email",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'to' => 'john.doe@example.com',
'from' => 'Contiguity <no-reply@contiguity.com>',
'subject' => 'Hello, world!'
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.contiguity.com/send/email"
payload := strings.NewReader("{\n \"to\": \"john.doe@example.com\",\n \"from\": \"Contiguity <no-reply@contiguity.com>\",\n \"subject\": \"Hello, world!\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.contiguity.com/send/email")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"to\": \"john.doe@example.com\",\n \"from\": \"Contiguity <no-reply@contiguity.com>\",\n \"subject\": \"Hello, world!\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.contiguity.com/send/email")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"to\": \"john.doe@example.com\",\n \"from\": \"Contiguity <no-reply@contiguity.com>\",\n \"subject\": \"Hello, world!\"\n}"
response = http.request(request)
puts response.read_body{
"id": "req_xxxxxxxxxxxxxxxx",
"timestamp": 1787117739720,
"api_version": "v2026.8.19",
"object": "response",
"data": {
"email_id": "eml_1234567890"
}
}{
"id": "err_xxxxxxxxxxxxxxxx",
"timestamp": 1787117739720,
"api_version": "v2026.8.19",
"object": "error",
"data": {
"error": "Bad Request",
"status": 400
}
}{
"id": "err_xxxxxxxxxxxxxxxx",
"timestamp": 1787117739720,
"api_version": "v2026.8.19",
"object": "error",
"data": {
"error": "Unauthorized",
"status": 401
}
}{
"id": "err_xxxxxxxxxxxxxxxx",
"timestamp": 1787117739720,
"api_version": "v2026.8.19",
"object": "error",
"data": {
"error": "Forbidden",
"status": 403
}
}{
"id": "err_xxxxxxxxxxxxxxxx",
"timestamp": 1787117739720,
"api_version": "v2026.8.19",
"object": "error",
"data": {
"error": "Internal Server Error",
"status": 500
}
}Send an Email
curl --request POST \
--url https://api.contiguity.com/send/email \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"to": "john.doe@example.com",
"from": "Contiguity <no-reply@contiguity.com>",
"subject": "Hello, world!"
}
'import requests
url = "https://api.contiguity.com/send/email"
payload = {
"to": "john.doe@example.com",
"from": "Contiguity <no-reply@contiguity.com>",
"subject": "Hello, world!"
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
to: 'john.doe@example.com',
from: 'Contiguity <no-reply@contiguity.com>',
subject: 'Hello, world!'
})
};
fetch('https://api.contiguity.com/send/email', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.contiguity.com/send/email",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'to' => 'john.doe@example.com',
'from' => 'Contiguity <no-reply@contiguity.com>',
'subject' => 'Hello, world!'
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.contiguity.com/send/email"
payload := strings.NewReader("{\n \"to\": \"john.doe@example.com\",\n \"from\": \"Contiguity <no-reply@contiguity.com>\",\n \"subject\": \"Hello, world!\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.contiguity.com/send/email")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"to\": \"john.doe@example.com\",\n \"from\": \"Contiguity <no-reply@contiguity.com>\",\n \"subject\": \"Hello, world!\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.contiguity.com/send/email")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"to\": \"john.doe@example.com\",\n \"from\": \"Contiguity <no-reply@contiguity.com>\",\n \"subject\": \"Hello, world!\"\n}"
response = http.request(request)
puts response.read_body{
"id": "req_xxxxxxxxxxxxxxxx",
"timestamp": 1787117739720,
"api_version": "v2026.8.19",
"object": "response",
"data": {
"email_id": "eml_1234567890"
}
}{
"id": "err_xxxxxxxxxxxxxxxx",
"timestamp": 1787117739720,
"api_version": "v2026.8.19",
"object": "error",
"data": {
"error": "Bad Request",
"status": 400
}
}{
"id": "err_xxxxxxxxxxxxxxxx",
"timestamp": 1787117739720,
"api_version": "v2026.8.19",
"object": "error",
"data": {
"error": "Unauthorized",
"status": 401
}
}{
"id": "err_xxxxxxxxxxxxxxxx",
"timestamp": 1787117739720,
"api_version": "v2026.8.19",
"object": "error",
"data": {
"error": "Forbidden",
"status": 403
}
}{
"id": "err_xxxxxxxxxxxxxxxx",
"timestamp": 1787117739720,
"api_version": "v2026.8.19",
"object": "error",
"data": {
"error": "Internal Server Error",
"status": 500
}
}from behavior is highly dependent on your account’s setup!- If you haven’t verified a domain: You can only use Contiguity’s email infrastructure. Simply provide your sender name (e.g. ‘Contiguity’).
-
If you have verified a domain: You can either:
- Use your verified domain (e.g. ‘Contiguity <custom@your-domain.com>’)
- Or still use Contiguity’s email address (e.g. ‘Contiguity <random-hash@contiguity.email>’)
body{
"body": {,
"html": "<p>Hello, world!</p>",
"text": "Hello, world!"
}
}
html / text properties.{
...,
"html": "<p>Hello, world!</p>",
"text": "Hello, world!"
}

Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Body
Recipient email address(es). Can be a string or array of up to 10 addresses
"john.doe@example.com"
Accepts: "Example <email@domain.com>" or "Contiguity" or "email@domain.com"
"Contiguity <no-reply@contiguity.com>"
Subject of the email
"Hello, world!"
Text content of the email (preferred over body.text)
"Hello, world!"
HTML content of the email (preferred over body.html)
"<p>Hello, world!</p>"
Deprecated: use top-level text/html instead.
Show child attributes
Show child attributes
Reply-to email address
"john.doe@example.com"
Carbon copy email address(es). Can be a string or array of up to 10 addresses
[
"john.doe@example.com",
"jane.doe@example.com"
]
Blind carbon copy email address(es). Can be a string or array of up to 10 addresses
["secret@example.com"]
Custom email headers as key-value object
Show child attributes
Show child attributes
{ "X-Priority": "1" }
Was this page helpful?