Galon Cloud
Galon API v1

/receiving-domains/{domain_id}

Base URL https://api.galon.ai/v1 · export GALON_API_BASE="https://api.galon.ai/v1"

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

NameInTypeDescription
domain_idpathstring · requiredinbound domain identifier

Responses

StatusDescriptionBody
200Domain and MX to publishobject
404Not foundError
401Key missing or invalidError

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

NameInTypeDescription
domain_idpathstring · requiredinbound domain identifier

Request body

application/json

FieldTypeDescription
enabledboolean · required

Responses

StatusDescriptionBody
200Domain updatedobject
404Not foundError
401Key missing or invalidError

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

NameInTypeDescription
domain_idpathstring · requiredinbound domain identifier

Responses

StatusDescriptionBody
200Domain removedobject
404Not foundError
401Key missing or invalidError

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>")