Login

Change template record

HTTP method

PUT

URL

https://api.zilore.com/dns/v1/templates/{template_id}/records/{record_id}

Request parameters

Parameter

Description

template_id

Identifier of template

record_id

Identifier of user template record (can be found using list_custom_templates_records)

Additional parameters

Parameter

Description

record_name

Name of record. Must conform to the standard. Names of national domains must be passed in Punycode format. Absolutely must include the variable {domain_name}. For example: foo.{domain_name}.

record_type

Record type:

  • A — Establishes correspondence between a domain name/subdomain and its IPv4 address
  • AAAA — Establishes correspondence between a domain name/subdomain and its IPv6 address
  • CNAME — Establishes correspondence beteeem a subdomain and another domain name (cannot be used with a domain name directly)
  • ALIAS — Establishes correspondence between a domain name/subdomain and another domain name (can be used without limitation)
  • MX — Show mail servers for domain name/subdomain
  • TXT — Includes arbitrary text information for the domain name/subdomain
  • NS — Show authoritative DNS servers for domain name/subdomain
  • SRV — Show location of servers for different services/domains
  • PTR — Establishes correspondence between an IP address and its domain name/subdomain
  • CAA — Defines SSL/TLS certificate issue policy for domain name/subdomain

record_ttl

Maximum permitted time for record to be cached. The list of possible values depends on your tariff plan and can be found using list_valid_record_ttl.

record_value

Record value. Must conform to the standard. Names of national domains must be passed in Punycode format. The format of the value depends on the record type.

The record_name parameter absolutely must include a {domain_name} template for the domain name to which the template is to be applied. For example: name.{domain_name}
{domain_name} can also be used in record_value in records that permit domain names as values

Value format depending on record type:

  • A - Format: IPv4 address,
    Example: 203.0.113.1
  • AAAA - Format: IPv6 address,
    Example: 2001:0db8:0000:0000:0000:0000:0000:0000
  • CNAME - Format: Domain name,
    Example: www.example.com
  • ALIAS - Format: Domain name,
    Example: www.example.com
  • MX - Format: [Priority] [Domain name],
    Example: 10 mail.example.com
  • TXT - Format: Text enclosed in double quotes
    Example: "v=spf1 mx - all"
  • NS - Format: Domain name,
    Example: ns1.example.com
  • SRV - Format: [Priority] [Weight] [Port] [Domain name],
    Example: 1 10 5269 xmpp.example.com
  • PTR - Format: Domain name,
    Example: www.example.com
  • CAA - Format: [Flags] [Tag] [Value],
    Example: 0 issue "example.com; param=value"
The value of the record_value for TXT records parameter must be enclosed in double quotes.
The value of the record_value for MX, CAA, and SRV records parameter must be space-separated.

Request example

PUT https://api.zilore.com/dns/v1/templates/198/records/31
X-Auth-Key: 6fac94db-691b-ec08-d22c-00000b7c06c0
Content-Type: application/x-www-form-urlencoded

record_value=1.1.1.111

Response example

{
"status": "ok",
"response": {
"record_status": "Custom template record updated",
"record_id": "31"
}
}