# DNS records

List, create, update, and delete DNS records.

The examples use A2A code mode. MCP exposes the same code mode through its `execute` tool.

## Functions

### `dns_records.add`

```text
dns_records.add(account_id: str, domain: str, name: str, type: str, value: str, prio?: int | null, ttl?: int) -> DNSRecord
```

Create dns records.

| Property | Value | Property | Value |
| --- | --- | --- | --- |
| Requires permission | `dns.record.create` | Auth required | `yes` |
| Execution mode | `sync` | Capability | `dns.record.create` |
| Resource type | `account` | Resource ID field | `account_id` |
| Public API route | `POST /v1/public/accounts/{account_id}/dns-records` |  |  |

  

### Arguments

| Name | Type | Required | Description |
| --- | --- | --- | --- |
| `account_id` | `str` | yes | Account UUID from the route path |
| `domain` | `str` | yes |  |
| `name` | `str` | yes |  |
| `type` | `str` | yes |  |
| `value` | `str` | yes |  |
| `prio` | `int \| null` | no |  |
| `ttl` | `int` | no |  |

  
  

### Returns

| Field | Type | Required | Description |
| --- | --- | --- | --- |
| `id` | `int` | yes |  |
| `name` | `str` | yes |  |
| `ttl` | `int` | yes |  |
| `type` | `str` | yes |  |
| `value` | `str` | yes |  |
| `is_system_managed` | `bool` | no |  |
| `priority` | `int \| null` | no |  |

  
  

### A2A example

Request:

```json
{
  "request_id": "example",
  "session_id": "session_123",
  "code": "dns_records.add(account_id=\"3c90c3cc-0d44-4b50-8888-8dd25736052a\", domain=\"example.com\", name=\"<string>\", type=\"<string>\", value=\"<string>\", prio=123, ttl=123)"
}
```

Response:

```json
{
  "request_id": "example",
  "status": "completed",
  "result": {
    "last_value": 123
  },
  "responses": [
    {
      "index": 0,
      "function": "dns_records.add",
      "status": "completed",
      "result": 123
    }
  ],
  "complexity_score": 1
}
```

  
  

### MCP example

Request:

```json
{
  "jsonrpc": "2.0",
  "id": "example",
  "method": "tools/call",
  "params": {
    "name": "hybridbox_execute",
    "arguments": {
      "code": "dns_records.add(account_id=\"3c90c3cc-0d44-4b50-8888-8dd25736052a\", domain=\"example.com\", name=\"<string>\", type=\"<string>\", value=\"<string>\", prio=123, ttl=123)"
    }
  }
}
```

Response:

```json
{
  "jsonrpc": "2.0",
  "id": "example",
  "result": {
    "content": [
      {
        "type": "text",
        "text": "{\n  \"request_id\": \"example\",\n  \"status\": \"completed\",\n  \"result\": {\n    \"last_value\": 123\n  },\n  \"responses\": [\n    {\n      \"index\": 0,\n      \"function\": \"dns_records.add\",\n      \"status\": \"completed\",\n      \"result\": 123\n    }\n  ],\n  \"complexity_score\": 1\n}"
      }
    ],
    "isError": false
  }
}
```

  

### `dns_records.delete`

```text
dns_records.delete(account_id: str, record_id: int) -> {}
```

Delete dns records.

| Property | Value | Property | Value |
| --- | --- | --- | --- |
| Requires permission | `dns.record.delete` | Auth required | `yes` |
| Execution mode | `sync` | Capability | `dns.record.delete` |
| Resource type | `account` | Resource ID field | `account_id` |
| Public API route | `DELETE /v1/public/accounts/{account_id}/dns-records/{record_id}` |  |  |

  

### Arguments

| Name | Type | Required | Description |
| --- | --- | --- | --- |
| `account_id` | `str` | yes | Account UUID from the route path |
| `record_id` | `int` | yes | DNS record ID from the route path |

  
  

### Returns

| Field | Type | Required | Description |
| --- | --- | --- | --- |
| `result` | `{}` | yes |  |

  
  

### A2A example

Request:

```json
{
  "request_id": "example",
  "session_id": "session_123",
  "code": "dns_records.delete(account_id=\"3c90c3cc-0d44-4b50-8888-8dd25736052a\", record_id=123)"
}
```

Response:

```json
{
  "request_id": "example",
  "status": "completed",
  "result": {
    "last_value": {}
  },
  "responses": [
    {
      "index": 0,
      "function": "dns_records.delete",
      "status": "completed",
      "result": {}
    }
  ],
  "complexity_score": 1
}
```

  
  

### MCP example

Request:

```json
{
  "jsonrpc": "2.0",
  "id": "example",
  "method": "tools/call",
  "params": {
    "name": "hybridbox_execute",
    "arguments": {
      "code": "dns_records.delete(account_id=\"3c90c3cc-0d44-4b50-8888-8dd25736052a\", record_id=123)"
    }
  }
}
```

Response:

```json
{
  "jsonrpc": "2.0",
  "id": "example",
  "result": {
    "content": [
      {
        "type": "text",
        "text": "{\n  \"request_id\": \"example\",\n  \"status\": \"completed\",\n  \"result\": {\n    \"last_value\": {}\n  },\n  \"responses\": [\n    {\n      \"index\": 0,\n      \"function\": \"dns_records.delete\",\n      \"status\": \"completed\",\n      \"result\": {}\n    }\n  ],\n  \"complexity_score\": 1\n}"
      }
    ],
    "isError": false
  }
}
```

  

### `dns_records.list`

```text
dns_records.list(account_id: str, domain?: str | null, name?: str | null, page?: int, page_size?: int, type?: str | null) -> Page[DNSRecord]
```

List dns records.

| Property | Value | Property | Value |
| --- | --- | --- | --- |
| Requires permission | `dns.record.view` | Auth required | `yes` |
| Execution mode | `sync` | Capability | `dns.record.view` |
| Resource type | `account` | Resource ID field | `account_id` |
| Public API route | `GET /v1/public/accounts/{account_id}/dns-records` |  |  |

  

### Arguments

| Name | Type | Required | Description |
| --- | --- | --- | --- |
| `account_id` | `str` | yes | Account UUID from the route path |
| `domain` | `str \| null` | no | Filter by domain name |
| `name` | `str \| null` | no | Filter by record name |
| `page` | `int` | no | One-based DNS record page number |
| `page_size` | `int` | no | Maximum DNS records per page |
| `type` | `str \| null` | no | Filter by record type |

  
  

### Returns

| Field | Type | Required | Description |
| --- | --- | --- | --- |
| `items` | `[{"id": int, "name": str, "ttl": int, "type": str, "value": str, "is_system_managed"?: bool, "priority"?: int \| null}]` | yes |  |
| `page` | `int` | yes |  |
| `page_size` | `int` | yes |  |
| `total` | `int` | yes |  |

  
  

### A2A example

Request:

```json
{
  "request_id": "example",
  "session_id": "session_123",
  "code": "dns_records.list(account_id=\"3c90c3cc-0d44-4b50-8888-8dd25736052a\", domain=\"example.com\", name=\"<string>\", page=123, page_size=123, type=\"<string>\")"
}
```

Response:

```json
{
  "request_id": "example",
  "status": "completed",
  "result": {
    "last_value": 123
  },
  "responses": [
    {
      "index": 0,
      "function": "dns_records.list",
      "status": "completed",
      "result": 123
    }
  ],
  "complexity_score": 1
}
```

  
  

### MCP example

Request:

```json
{
  "jsonrpc": "2.0",
  "id": "example",
  "method": "tools/call",
  "params": {
    "name": "hybridbox_execute",
    "arguments": {
      "code": "dns_records.list(account_id=\"3c90c3cc-0d44-4b50-8888-8dd25736052a\", domain=\"example.com\", name=\"<string>\", page=123, page_size=123, type=\"<string>\")"
    }
  }
}
```

Response:

```json
{
  "jsonrpc": "2.0",
  "id": "example",
  "result": {
    "content": [
      {
        "type": "text",
        "text": "{\n  \"request_id\": \"example\",\n  \"status\": \"completed\",\n  \"result\": {\n    \"last_value\": 123\n  },\n  \"responses\": [\n    {\n      \"index\": 0,\n      \"function\": \"dns_records.list\",\n      \"status\": \"completed\",\n      \"result\": 123\n    }\n  ],\n  \"complexity_score\": 1\n}"
      }
    ],
    "isError": false
  }
}
```

  

### `dns_records.update`

```text
dns_records.update(account_id: str, record_id: int, disabled?: bool | null, name?: str | null, prio?: int | null, ttl?: int | null, value?: str | null) -> DNSRecord
```

Update dns records.

| Property | Value | Property | Value |
| --- | --- | --- | --- |
| Requires permission | `dns.record.update` | Auth required | `yes` |
| Execution mode | `sync` | Capability | `dns.record.update` |
| Resource type | `account` | Resource ID field | `account_id` |
| Public API route | `PATCH /v1/public/accounts/{account_id}/dns-records/{record_id}` |  |  |

  

### Arguments

| Name | Type | Required | Description |
| --- | --- | --- | --- |
| `account_id` | `str` | yes | Account UUID from the route path |
| `record_id` | `int` | yes | DNS record ID from the route path |
| `disabled` | `bool \| null` | no |  |
| `name` | `str \| null` | no |  |
| `prio` | `int \| null` | no |  |
| `ttl` | `int \| null` | no |  |
| `value` | `str \| null` | no |  |

  
  

### Returns

| Field | Type | Required | Description |
| --- | --- | --- | --- |
| `id` | `int` | yes |  |
| `name` | `str` | yes |  |
| `ttl` | `int` | yes |  |
| `type` | `str` | yes |  |
| `value` | `str` | yes |  |
| `is_system_managed` | `bool` | no |  |
| `priority` | `int \| null` | no |  |

  
  

### A2A example

Request:

```json
{
  "request_id": "example",
  "session_id": "session_123",
  "code": "dns_records.update(account_id=\"3c90c3cc-0d44-4b50-8888-8dd25736052a\", record_id=123, disabled=true, name=\"<string>\", prio=123, ttl=123, value=\"<string>\")"
}
```

Response:

```json
{
  "request_id": "example",
  "status": "completed",
  "result": {
    "last_value": 123
  },
  "responses": [
    {
      "index": 0,
      "function": "dns_records.update",
      "status": "completed",
      "result": 123
    }
  ],
  "complexity_score": 1
}
```

  
  

### MCP example

Request:

```json
{
  "jsonrpc": "2.0",
  "id": "example",
  "method": "tools/call",
  "params": {
    "name": "hybridbox_execute",
    "arguments": {
      "code": "dns_records.update(account_id=\"3c90c3cc-0d44-4b50-8888-8dd25736052a\", record_id=123, disabled=true, name=\"<string>\", prio=123, ttl=123, value=\"<string>\")"
    }
  }
}
```

Response:

```json
{
  "jsonrpc": "2.0",
  "id": "example",
  "result": {
    "content": [
      {
        "type": "text",
        "text": "{\n  \"request_id\": \"example\",\n  \"status\": \"completed\",\n  \"result\": {\n    \"last_value\": 123\n  },\n  \"responses\": [\n    {\n      \"index\": 0,\n      \"function\": \"dns_records.update\",\n      \"status\": \"completed\",\n      \"result\": 123\n    }\n  ],\n  \"complexity_score\": 1\n}"
      }
    ],
    "isError": false
  }
}
```
