# create_dns_record

> Create one DNS record in a domain's zone and return the stored record with its new `id`.

- Tier: W
- Required scope: write:dns
- Annotations: none
- Docs: https://api.inleed.com/tools/create-dns-record

## Description

Create one DNS record in a domain's zone and return the stored record with its new `id`. Send `@` or an empty string for the zone root — not the full fqdn. Put MX preference in `priority`, never inline in `value`. A `value` without a trailing dot has the zone name appended by DirectAdmin, so end a hostname value with `.` to keep it absolute.

## Input schema

- `input` — string (required). A domain, email address, website URL, numeric service id, or hosting-account username the customer actually owns. Resolved to the owning account automatically; the resolved target is echoed back in the response.
- `type` — enum (required). The record type. One of A, AAAA, CNAME, MX, TXT, NS, SRV, CAA.
- `name` — string (required). The record name (left-hand side). Send @ or an empty string for the zone root — not the full fqdn www.example.com.
- `value` — string (required). The record value: an IP for A/AAAA, a hostname for cname/ns (end it with . to stop the zone name being appended), the full text for TXT. Do not put MX priority here.
- `ttl` — integer. Time-to-live in seconds (60–604800). Omit to use the zone default. Range 60–604800.
- `priority` — integer. MX preference (0–65535, lower wins). Only for MX; it goes here, never inline in value. Range 0–65535.

## Example call

```json
{
  "name": "create_dns_record",
  "arguments": {
    "input": "example.se",
    "type": "A",
    "name": "@",
    "value": "203.0.113.10"
  }
}
```

## Example conversation

**User:** Point blog.example.se at 203.0.113.10.

**Assistant:** Creating an A record blog → 203.0.113.10, TTL 3600. Done.

