Sendio.Domains (sendio v1.1.0)
Manage domains in Sendio.
Summary
Types
What a domain does, Resend-style: :sending and/or :receiving set to "enabled" or "disabled".
Functions
Creates a new domain.
Gets a domain given an ID.
Lists all domains.
Removes a domain. Caution: This can't be undone!
Updates a domain.
Begins the verification process for a domain.
Types
Link to this type
capabilities()
What a domain does, Resend-style: :sending and/or :receiving set to "enabled" or "disabled".
Sending is always on; sending: "disabled" is rejected with a 422.
Functions
Link to this function
create(client \\ Sendio.client(), opts)
@spec create(Sendio.Client.t(), Keyword.t()) :: Sendio.Client.response(Sendio.Domains.Domain.t())
Creates a new domain.
Parameter options:
:name- The domain name (required):region- Region to deliver emails from, one of:["us-east-1", "eu-west-1", "sa-east-1"]:capabilities-capabilities/0.%{receiving: "enabled"}also receives email on the domain (send.io then requires its MX record). Sending can't be disabled (422).
Example
Sendio.Domains.create(name: "example.com", capabilities: %{receiving: "enabled"})
Link to this function
get(client \\ Sendio.client(), domain_id)
@spec get(Sendio.Client.t(), String.t()) :: Sendio.Client.response(Sendio.Domains.Domain.t())
Gets a domain given an ID.
Link to this function
list(client \\ Sendio.client())
@spec list(Sendio.Client.t()) :: Sendio.Client.response(Sendio.List.t(Sendio.Domains.Domain.t()))
Lists all domains.
Link to this function
remove(client \\ Sendio.client(), domain_id)
@spec remove(Sendio.Client.t(), String.t()) :: Sendio.Client.response(Sendio.Domains.Domain.t())
Removes a domain. Caution: This can't be undone!
Link to this function
update(client \\ Sendio.client(), domain_id, opts)
@spec update(Sendio.Client.t(), String.t(), Keyword.t()) :: Sendio.Client.response(Sendio.Domains.Domain.t())
Updates a domain.
Options
:click_tracking- Enable click tracking for this domain:open_tracking- Enable open tracking for this domain:tls- TLS setting:"opportunistic"(default) or"enforced":capabilities-capabilities/0.%{receiving: "disabled"}turns receiving off: send.io stops accepting email for the domain and no longer requires its MX record, so remove that record from your DNS.%{receiving: "enabled"}turns it back on and asks for the domain's MX record (publish it to start receiving email). Sending can't be disabled (422).
Example
Sendio.Domains.update(domain_id, capabilities: %{receiving: "disabled"})
Link to this function
verify(client \\ Sendio.client(), domain_id)
@spec verify(Sendio.Client.t(), String.t()) :: Sendio.Client.response(Sendio.Domains.Domain.t())
Begins the verification process for a domain.