---
title: "Add a sending domain"
method: POST
path: "/v1/projectId/{projectId}/domains"
tags: ["Domains"]
---

# Add a sending domain

`POST /v1/projectId/{projectId}/domains`

## Request

- Base URL: `https://api.bluefox.email`
- URL: `https://api.bluefox.email/v1/projectId/{projectId}/domains`
- Auth: HTTP bearer

Production-access projects only. Returns the required DNS records to add before the domain can send.

## Path parameters

- `projectId` string, required

## Request body

- DomainInput
  - `domain` string, required
  - `region` string, required

## Response `201`

Created

- object
  - `status` integer
  - `result` Domain
    - `_id` string
    - `domain` string
    - `region` string
    - `tenant` object
      - `name` string
      - `configurationSet` string
    - `requiredDns` object: DNS records (DKIM CNAMEs, SPF, MX, DMARC) the domain owner must add.
    - `observed` object: Last-checked DNS verification state, per record.
      - `spf` object
        - `present` boolean
        - `raw` string
        - `checkedAt` string, date-time
      - `dmarc` object
        - `present` boolean
        - `raw` string
        - `checkedAt` string, date-time
      - `mx` object
        - `present` boolean
        - `raw` string
        - `checkedAt` string, date-time
      - `dkim` object
        - `selectors` string[]
        - `allOk` boolean
        - `checkedAt` string, date-time
      - `allOk` boolean: True only when SPF, DMARC, MX, and DKIM are all present/verified.

## Other responses

- `400`: Invalid request body or query - every violation found (missing/invalid/unexpected fields) is reported in one response, semicolon-separated, not just the first one hit.
- `403`: Missing or invalid API key
- `405`: The operation is blocked by a business rule (e.g. the resource is still in use)

---

[API](https://skmtc.dev/bluefox/apis/bluefox-email-public-api.md) · [All operations](https://skmtc.dev/bluefox/apis/bluefox-email-public-api/llms.txt) · [OpenAPI document](https://skmtc.dev/bluefox/apis/bluefox-email-public-api/revisions/fa1a0a835c7f?raw)
