---
title: "Add a DNS record"
method: POST
path: "/domains/{domain}/dns"
tags: ["Domains"]
---

# Add a DNS record

`POST /domains/{domain}/dns`

## Request

- Base URL: `https://api.imprezahost.com/v1`
- URL: `https://api.imprezahost.com/v1/domains/{domain}/dns`
- Auth: API key in header `X-API-Key` and API key in header `X-API-Secret`

## Path parameters

- `domain` string, required

## Request body

- object
  - `type` 'A' | 'AAAA' | 'CNAME' | 'MX' | 'TXT' | 'NS' | 'SRV', required
  - `host` string, required
  - `value` string, required
  - `ttl` integer
  - `priority` integer: Required for MX records

## Response `201`

Record created

---

[API](https://skmtc.dev/imprezahost/apis/impreza-host-public-api.md) · [All operations](https://skmtc.dev/imprezahost/apis/impreza-host-public-api/llms.txt) · [OpenAPI document](https://skmtc.dev/imprezahost/apis/impreza-host-public-api/revisions/db86511f604f?raw)
