Address Groups
Address groups allow a single DNS record to resolve to multiple IPs with load balancing.
List Address Groups
curl -s "https://api.1bytedns.ru/client/v1/zones/42/address_groups?type=A" \
-H "Authorization: Bearer TOKEN" | python3 -m json.tool
Query Parameters: page, per_page, type (A or AAAA)
{
"success": true,
"result": [
{
"id": 5,
"name": "web-servers",
"type": "A",
"lb_policy": "round_robin",
"evaluate_health": true,
"member_count": 3,
"created_on": "2024-01-15T12:00:00Z",
"modified_on": "2024-06-01T10:30:00Z"
}
],
"result_info": {"page": 1, "per_page": 20, "count": 1, "total_count": 1, "total_pages": 1},
"errors": [],
"messages": []
}
Get Address Group
curl -s https://api.1bytedns.ru/client/v1/zones/42/address_groups/5 \
-H "Authorization: Bearer TOKEN" | python3 -m json.tool
{
"success": true,
"result": {
"id": 5,
"name": "web-servers",
"type": "A",
"lb_policy": "round_robin",
"evaluate_health": true,
"members": [
{"id": 10, "address": "192.0.2.1", "weight": 1, "role": "primary", "sort_order": 0}
],
"created_on": "2024-01-15T12:00:00Z",
"modified_on": "2024-06-01T10:30:00Z"
},
"errors": [],
"messages": []
}
Create Address Group
curl -s -X POST https://api.1bytedns.ru/client/v1/zones/42/address_groups \
-H "Authorization: Bearer TOKEN" \
-H "Content-Type: application/json" \
-d '{"name": "web-servers", "type": "A"}' | python3 -m json.tool
Body Parameters:
| Field | Type | Required | Description |
|---|---|---|---|
name | string | Yes | Group name (unique per zone, case-insensitive) |
type | string | Yes | A (IPv4) or AAAA (IPv6) |
Delete Address Group
curl -s -X DELETE https://api.1bytedns.ru/client/v1/zones/42/address_groups/5 \
-H "Authorization: Bearer TOKEN"
Cascading delete: removes all members first.
Address Group Members
List Members
curl -s https://api.1bytedns.ru/client/v1/zones/42/address_groups/5/members \
-H "Authorization: Bearer TOKEN" | python3 -m json.tool
{
"success": true,
"result": [
{"id": 10, "address": "192.0.2.1", "weight": 1, "role": "primary", "sort_order": 0, "healthy": true},
{"id": 11, "address": "192.0.2.2", "weight": 1, "role": "secondary", "sort_order": 1, "healthy": false}
],
"errors": [],
"messages": []
}
Add Member
curl -s -X POST https://api.1bytedns.ru/client/v1/zones/42/address_groups/5/members \
-H "Authorization: Bearer TOKEN" \
-H "Content-Type: application/json" \
-d '{"address": "192.0.2.3", "weight": 1, "role": "primary"}' | python3 -m json.tool
Body Parameters:
| Field | Type | Required | Description |
|---|---|---|---|
address | string | Yes | IP address (IPv4 for type A, IPv6 for type AAAA) |
weight | int | No | Load balancing weight (default: 1) |
role | string | No | primary or secondary |
Update Member
curl -s -X PATCH https://api.1bytedns.ru/client/v1/zones/42/address_groups/5/members/12 \
-H "Authorization: Bearer TOKEN" \
-H "Content-Type: application/json" \
-d '{"weight": 5, "role": "secondary"}'
Delete Member
curl -s -X DELETE https://api.1bytedns.ru/client/v1/zones/42/address_groups/5/members/12 \
-H "Authorization: Bearer TOKEN"
Last updated: 2026-06-26