Update Domain
curl -s -X PATCH "https://api.yoagent.dev/v0/domains/dom_01je56wqswfmn9pgbc1wq8tjgq" \ -H "Authorization: Bearer $YOAGENT_KEY" \ -H "Content-Type: application/json" \ -d '{"sending":false}'const response = await fetch("https://api.yoagent.dev/v0/domains/dom_01je56wqswfmn9pgbc1wq8tjgq", { method: "PATCH", headers: { Authorization: `Bearer ${process.env.YOAGENT_KEY}`, "Content-Type": "application/json", }, body: JSON.stringify({ "sending": false }),});if (!response.ok) throw new Error(await response.text());const data = await response.json();import os
import requests
response = requests.patch( "https://api.yoagent.dev/v0/domains/dom_01je56wqswfmn9pgbc1wq8tjgq", headers={"Authorization": f"Bearer {os.environ['YOAGENT_KEY']}"}, json={ "sending": False, }, timeout=60,)response.raise_for_status()data = response.json()Turn a custom domain’s sending on or off (the domain verified). On: its DKIM records show in its
records a moment later (not yet in this answer); it sends once SES finds them (sending_status).
Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”Request Bodyrequired
Section titled “Request Bodyrequired”Change a custom domain; omitted fields stay as they are.
Responses
Section titled “Responses”Successful Response
A mail domain as the caller sees it: what it may do with it, and when mail to it stops being accepted.
object
Goes up by one on every change: of two copies, the one with the higher version is the newer.
Chosen by whoever added it (a person or another agent).
Where a domain comes from: our shared domain or the customer’s own.
Whether mail for the domain is accepted: pending (a custom domain waiting for its DNS records), verified
(accepted), failed (its records were not found in time, or were lost: its failure says which).
Why it is failed: a record missing (txt_missing, mx_missing), another MX beside ours
(mx_foreign), or another organization holds the name (taken).
Why a custom domain is failed: what its DNS lacked at the last check, or that another organization holds
the name.
Whether its inboxes send: off; pending until SES finds its DKIM records; verified; failed
— SES did not find them in time, or lost them (turn it off and on again).
The records to add at the domain’s DNS host, each marked when the last check saw it (none for a shared domain).
One DNS record the customer adds at their DNS host, and whether the last check that got an answer saw it.
object
What it is for: receiving (verification, mx), sending (dkim) or recommended for it — the bounce
domain’s MX (mail_from) and SPF (spf), the domain’s DMARC (dmarc).
The record’s full name, without a trailing dot (the domain’s name: chosen by whoever added it).
The last reading that got an answer saw it (an MX: only ours there); dkim and mail_from: as SES last
saw them.
The same records as a zone file, for DNS hosts that import one (empty for a shared domain).
When it fails unless its records are found by then (mail to it is refused from then on): a claim’s deadline, or a verified domain’s while its records are missing; null otherwise, and once it has passed (only a resolver that does not answer keeps the domain as it was).
Whether the caller may check it now and turn its sending on or off (domain_update in its project; a custom
domain only).
Whether the caller may delete it with its inboxes (domain_delete in its project; a custom domain only).
Whether its inboxes may send now: a custom domain’s sending verified on a plan that has it (the send refuses otherwise); a shared domain always.
Example
{ "version": 1, "domain_id": "dom_01je56wqswfmn9pgbc1wq8tjgq", "project_id": "prj_01je56wqswfmn9pgbc1wq8tjgq", "name": "mail.example.com", "kind": "custom", "status": "verified", "failure": null, "sending_status": "off", "records": [ { "key": "verification", "type": "TXT", "name": "_yoagent.mail.example.com", "value": "yoagent-verification=4f8a2c9e1b7d3f6a0c5e8b2d9f1a4c7e", "priority": null, "found": true }, { "key": "mx", "type": "MX", "name": "mail.example.com", "value": "mx.yoagent.email", "priority": 10, "found": true } ], "zone_file": "; DNS records for mail.example.com\n_yoagent.mail.example.com.\t3600\tIN\tTXT\t\"yoagent-verification=4f8a2c9e1b7d3f6a0c5e8b2d9f1a4c7e\"\nmail.example.com.\t3600\tIN\tMX\t10 mx.yoagent.email.\n", "checked_at": "2026-12-01T12:00:00Z", "next_check_at": "2026-12-01T18:00:00Z", "failing_since": null, "verified_at": "2026-12-01T12:00:00Z", "fails_at": null, "editable": true, "deletable": true, "sendable": false}default
Section titled “default”An error (400, 401, 403, 404, 405, 409, 413, 429, 500, 503), in the one shape every call answers: Errors.