Domains

GET /domains

List the domains the organization has added, alphabetically by default. Supports cursor pagination.

Requires the settings:read permission.

Query parameters

limitnumber

The number of records to return.

cursorstring

A pagination cursor. Fetch the next page by passing the nextCursor value from the previous response.

sortdomain | -domain | createdAt | -createdAt

The sort order. Prefix a field with - to sort descending. Defaults to domain.

Request
curl \
  "https://your-store.meisei.app/api/domains" \
  -H "Authorization: Bearer sk_YOUR_SECRET_KEY"
Response
{
  "data": [
    {
      "id": "A4Ws1igz",
      "domain": "string",
      "verificationToken": "string",
      "verifiedAt": "2025-01-15T09:30:00Z",
      "emailProvider": "string",
      "emailVerifiedAt": "2025-01-15T09:30:00Z",
      "records": ["..."],
      "lastCheckedAt": "2025-01-15T09:30:00Z",
      "createdAt": "2025-01-15T09:30:00Z",
      "updatedAt": "2025-01-15T09:30:00Z"
    }
  ],
  "nextCursor": "string"
}

POST /domains

Add a domain you own. The response carries the TXT record to create; once it is in place, call POST /domains/:id/verify. Fails if another account has already claimed the domain.

Requires the settings:write permission.

Body parameters

domainstringrequired

The domain or subdomain you own, such as example.com or shop.example.com. Leave off the scheme, the port and any path.

Request
curl \
  -X POST \
  "https://your-store.meisei.app/api/domains" \
  -H "Authorization: Bearer sk_YOUR_SECRET_KEY" \
  -H "Content-Type: application/json" \
  -d '{
  "domain": "string"
}'
Response
{
  "id": "A4Ws1igz",
  "domain": "string",
  "verificationToken": "string",
  "verifiedAt": "2025-01-15T09:30:00Z",
  "emailProvider": "string",
  "emailVerifiedAt": "2025-01-15T09:30:00Z",
  "records": [
    {
      "type": "TXT",
      "name": "string",
      "value": "string",
      "purpose": "dkim",
      "verified": true
    }
  ],
  "lastCheckedAt": "2025-01-15T09:30:00Z",
  "createdAt": "2025-01-15T09:30:00Z",
  "updatedAt": "2025-01-15T09:30:00Z"
}

GET /domains/{id}

Get a single domain by ID, with every DNS record it needs.

Requires the settings:read permission.

Path parameters

idstringrequired

The ID of the domain.

Request
curl \
  "https://your-store.meisei.app/api/domains/A4Ws1igz" \
  -H "Authorization: Bearer sk_YOUR_SECRET_KEY"
Response
{
  "id": "A4Ws1igz",
  "domain": "string",
  "verificationToken": "string",
  "verifiedAt": "2025-01-15T09:30:00Z",
  "emailProvider": "string",
  "emailVerifiedAt": "2025-01-15T09:30:00Z",
  "records": [
    {
      "type": "TXT",
      "name": "string",
      "value": "string",
      "purpose": "dkim",
      "verified": true
    }
  ],
  "lastCheckedAt": "2025-01-15T09:30:00Z",
  "createdAt": "2025-01-15T09:30:00Z",
  "updatedAt": "2025-01-15T09:30:00Z"
}

DELETE /domains/{id}

Remove a domain. Its custom hostnames go with it, and any site sending from it goes back to sending through Meisei.

Requires the settings:write permission.

Path parameters

idstringrequired

The ID of the domain to remove.

Request
curl \
  -X DELETE \
  "https://your-store.meisei.app/api/domains/A4Ws1igz" \
  -H "Authorization: Bearer sk_YOUR_SECRET_KEY"
Response
{
  "id": "A4Ws1igz",
  "domain": "string",
  "verificationToken": "string",
  "verifiedAt": "2025-01-15T09:30:00Z",
  "emailProvider": "string",
  "emailVerifiedAt": "2025-01-15T09:30:00Z",
  "records": [
    {
      "type": "TXT",
      "name": "string",
      "value": "string",
      "purpose": "dkim",
      "verified": true
    }
  ],
  "lastCheckedAt": "2025-01-15T09:30:00Z",
  "createdAt": "2025-01-15T09:30:00Z",
  "updatedAt": "2025-01-15T09:30:00Z"
}

POST /domains/{id}/verify

Check the domain's DNS records now. It looks for the ownership record if the domain is not verified yet, and asks the email provider how email setup is going if it has been started.

Requires the settings:write permission.

Costs 5 rate limit tokens instead of the usual one. See Rate limits.

Path parameters

idstringrequired

The ID of the domain to check.

Request
curl \
  -X POST \
  "https://your-store.meisei.app/api/domains/A4Ws1igz/verify" \
  -H "Authorization: Bearer sk_YOUR_SECRET_KEY"
Response
{
  "id": "A4Ws1igz",
  "domain": "string",
  "verificationToken": "string",
  "verifiedAt": "2025-01-15T09:30:00Z",
  "emailProvider": "string",
  "emailVerifiedAt": "2025-01-15T09:30:00Z",
  "records": [
    {
      "type": "TXT",
      "name": "string",
      "value": "string",
      "purpose": "dkim",
      "verified": true
    }
  ],
  "lastCheckedAt": "2025-01-15T09:30:00Z",
  "createdAt": "2025-01-15T09:30:00Z",
  "updatedAt": "2025-01-15T09:30:00Z"
}

POST /domains/{id}/email

Start setting the domain up to send email. The response carries the DKIM and return-path records to create. The domain's ownership has to be verified first.

Requires the settings:write permission.

Costs 5 rate limit tokens instead of the usual one. See Rate limits.

Path parameters

idstringrequired

The ID of the domain.

Request
curl \
  -X POST \
  "https://your-store.meisei.app/api/domains/A4Ws1igz/email" \
  -H "Authorization: Bearer sk_YOUR_SECRET_KEY"
Response
{
  "id": "A4Ws1igz",
  "domain": "string",
  "verificationToken": "string",
  "verifiedAt": "2025-01-15T09:30:00Z",
  "emailProvider": "string",
  "emailVerifiedAt": "2025-01-15T09:30:00Z",
  "records": [
    {
      "type": "TXT",
      "name": "string",
      "value": "string",
      "purpose": "dkim",
      "verified": true
    }
  ],
  "lastCheckedAt": "2025-01-15T09:30:00Z",
  "createdAt": "2025-01-15T09:30:00Z",
  "updatedAt": "2025-01-15T09:30:00Z"
}