---
title: "Register a domain"
method: POST
path: "/v1/domains"
tags: ["Domains"]
---

# Register a domain

`POST /v1/domains`

## Request

- Base URL: `https://api.usemektup.com`
- URL: `https://api.usemektup.com/v1/domains`
- Auth: HTTP bearer

Generates a real DKIM keypair and returns the exact DNS records to add. Never modifies DNS itself.

## Request body

- object
  - `domain` string, required

## Response `201`

Created

- CreateDomainResult
  - `domain` Domain
    - `domain` string
    - `verified` boolean
    - `created_at` string, date-time
  - `dkimKeyPath` string
  - `records` DnsRecord[]
    - `type` 'MX' | 'TXT'
    - `host` string
    - `value` string
    - `priority` integer
    - `label` string
  - `recommendation` Recommendation
    - `nameservers` string[]
    - `detectedHost` 'cloudflare' | 'simply.com' | 'godaddy' | 'route53' | 'vercel' | 'null', nullable
    - `action` 'delegate' | 'push-to-known-host' | 'manual'
    - `note` string: Present only if NS lookup failed

## Other responses

- `400`: Invalid request
- `402`: Billing tier limit reached

---

[API](https://skmtc.dev/usemektup/apis/mektup-api.md) · [All operations](https://skmtc.dev/usemektup/apis/mektup-api/llms.txt) · [OpenAPI document](https://skmtc.dev/usemektup/apis/mektup-api/revisions/e394b91cbc53?raw)
