List domains

GET/api/v1/domains
Requires anorganization API keywith the scopedomains:read

Request

GET/api/v1/domains
curl -X GET 'https://app.mailyte.com/api/v1/domains' \
  -H 'Authorization: Bearer mk_live_YOUR_API_KEY'
The key names its own organization, so no X-Organization-ID header is needed.

Response

Success.

  • dataobject
    • dataarray<object>
      • objectstringdomain
      • idstring

        Unique identifier for the domain.

      • namestring

        The domain itself, e.g. example.com.

      • descriptionstring

        Your own note on the domain. Null when none was set.

      • statestringactive | provisioning | failed | disabled

        The one lifecycle answer. disabled wins over everything: a disabled domain does nothing whatever its provisioning says.

      • provisioningobject

        How far this domain has got on the mail server. This is the detail behind state, not a second answer to it: read state to decide what a domain can do, and this to explain why.

        • statestringpending | provisioning | active | failed | suspended | deleting | deleted

          Where the domain is in setup on the mail server: pending, provisioning, active, failed, suspended, deleting or deleted. For what the domain can do, read state.

        • errorstring

          The last setup or DNS error recorded. Null when there is none. It can be set even on an active domain, so check state or GET /domains/{domain}/verification-status before showing it.

        • retryableboolean

          Whether POST /domains/{domain}/retry-provisioning would do anything. True exactly when state is failed.

      • sendingobject

        Sending needs SPF and DKIM. Separate from receiving, because a customer who only relays through us must not publish an MX record.

        • enabledboolean
        • requiresarray<string>
      • receivingobject

        Receiving needs MX.

        • enabledboolean
        • requiresarray<string>
      • limitsobject

        What this domain is allowed. Every field is always a number. For what the mail server is enforcing right now, use GET /domains/{domain}/limits.

        • storage_bytesinteger

          How many bytes of mail this domain may store in total. The default is 10 GB.

        • max_mailboxesinteger

          How many mailboxes this domain may have. The default is 50.

        • mailboxes_usedinteger

          How many mailboxes the domain has now.

      • defaultsobject

        What a NEW mailbox on this domain inherits. Nothing here describes an existing mailbox.

        • mailbox_storage_bytesinteger

          How many bytes of storage each new mailbox gets. The default is 3 GB.

      • created_atstring
      • updated_atstring
    • pagination_metaany

Returned inside the standard envelope.

Errors

StatusWhen
401The API key is missing, unknown, revoked or expired. All four answer identically, on purpose: distinguishing them would confirm which keys exist.
403The key is valid but may not do this: it lacks the required scope, its IP allowlist does not include you, or this endpoint does not accept API keys.
404No such resource in this organization.
422The request was understood but the values were not acceptable.
429Too many requests, or the organization has spent its sending allowance. `Retry-After` says how long to wait.

Every status, with what causes it and what to do, is on the error reference.