Enable or disable receiving
Turn a verified domain into a receiving domain. Once enabled and the MX record resolves, you can create inboxes on it and read inbound threads.
PATCH
/v1/domains/{id}/receivingEnabling receiving returns the MX record(s) to publish. Mail can only route in once that record resolves. With receiving on, create an inbox on the domain, then read conversations via threads. To read the current state without changing it, issue a GET on the same path.
01 Path parameters
idstringRequired
The domain id, for example
dom_01HZ8K3M9P.02 Body
enabledbooleanRequired
true to turn receiving on, false to turn it off. Disabling stops routing new inbound mail; existing threads and inboxes are preserved.03 Request
curl -X PATCH https://api.drin.run/v1/domains/dom_01HZ8K3M9P/receiving \
-H "Authorization: Bearer $DRIN_API_KEY" \
-H "Content-Type: application/json" \
-d '{ "enabled": true }'04 Response
200 OK — the updated receiving state. When enabling, the records array carries the MX record(s) to publish; each verified flag flips to true once it resolves.
{
"enabled": true,
"records": [
{
"type": "MX",
"name": "acme.com",
"value": "inbound.drin.run",
"priority": 10,
"purpose": "verification",
"verified": false
}
]
}Verify sending firstReceiving can only be enabled on a domain that has already passed verification for sending.