GET /receiving-domains/{domain_id}
Get an inbound domain
Key carrying mail:send AND job:read. Served only when inbound is open to the account (404 not_found otherwise).
API key (Bearer), on the public API endpoint.
Parameters
| Name | In | Type | Description |
|---|---|---|---|
domain_id | path | string · required | inbound domain identifier |
Responses
| Status | Description | Body |
|---|---|---|
200 | Domain and MX to publish | object |
404 | Not found | Error |
401 | Key missing or invalid | Error |
Examples
curl
curl -X GET "$GALON_API_BASE/receiving-domains/<domain_id>" \
-H "Authorization: Bearer $GALON_API_KEY"Node.js (SDK)
import { Galon } from "galon";
const galon = new Galon(process.env.GALON_API_KEY);
const result = await galon.receivingDomains.get("<id>");Python (SDK)
from galon import Galon
galon = Galon() # reads GALON_API_KEY
result = galon.receiving_domains.get("<id>")PATCH /receiving-domains/{domain_id}
Enable or disable an inbound domain
Key carrying mail:send AND job:read. Served only when inbound is open to the account (404 not_found otherwise).
API key (Bearer), on the public API endpoint.
Parameters
| Name | In | Type | Description |
|---|---|---|---|
domain_id | path | string · required | inbound domain identifier |
Request body
application/json
| Field | Type | Description |
|---|---|---|
enabled | boolean · required |
Responses
| Status | Description | Body |
|---|---|---|
200 | Domain updated | object |
404 | Not found | Error |
401 | Key missing or invalid | Error |
Examples
curl
curl -X PATCH "$GALON_API_BASE/receiving-domains/<domain_id>" \
-H "Authorization: Bearer $GALON_API_KEY" \
-H "Content-Type: application/json" \
-d '{"enabled": true}'Node.js (SDK)
import { Galon } from "galon";
const galon = new Galon(process.env.GALON_API_KEY);
const result = await galon.receivingDomains.update("<id>", {"enabled": true});Python (SDK)
from galon import Galon
galon = Galon() # reads GALON_API_KEY
result = galon.receiving_domains.update("<id>", {"enabled": True})DELETE /receiving-domains/{domain_id}
Remove an inbound domain
Key carrying mail:send AND job:read. Served only when inbound is open to the account (404 not_found otherwise). Also removes its rules and its messages.
API key (Bearer), on the public API endpoint.
Parameters
| Name | In | Type | Description |
|---|---|---|---|
domain_id | path | string · required | inbound domain identifier |
Responses
| Status | Description | Body |
|---|---|---|
200 | Domain removed | object |
404 | Not found | Error |
401 | Key missing or invalid | Error |
Examples
curl
curl -X DELETE "$GALON_API_BASE/receiving-domains/<domain_id>" \
-H "Authorization: Bearer $GALON_API_KEY"Node.js (SDK)
import { Galon } from "galon";
const galon = new Galon(process.env.GALON_API_KEY);
const result = await galon.receivingDomains.remove("<id>");Python (SDK)
from galon import Galon
galon = Galon() # reads GALON_API_KEY
result = galon.receiving_domains.remove("<id>")