Replacing all existing Service location (SRV) records in the API requires specific syntax depending on whether you are using REST or SOAP. Use this table to find the syntax for your command.
See RFC 2782 for more information about SRV records.
Understanding How The API Works »
REST Syntax
Click to view all REST Resources |
/REST/SRVRecord/ PUT — Replaces all existing SRV record on the zone/node indicated.
HTTP Action — PUT
URI — https://api.dynect.net/REST/SRVRecord/<zone>/<fqdn>/ |
Arguments — Click for More Info
- array
SRVRecords — Required. Individual records.
- hash
rdata — Required. RData defining the records.
- string
port — Required. Indicates the port where the service is running.
- string
priority — Required. Numeric value for priority usage. Lower value takes precedence over higher value where two records of the same type exist on the zone/node.
- string
target — Required. The domain name of a host where the service is running on the specified port .
- string
weight — Required. Secondary prioritizing of records to serve. Records of equal priority should be served based on their weight. Higher values are served more often.
- string
ttl — TTL for the record. Set to “0” to use zone default
|
Response — Click for More Info
- array — Individual records.
- string
fqdn — Name of the node where the records exist.
- hash
rdata — RData defining the record.
- string
port — Indicates the port where the service is running.
- string
priority — Numeric value for priority usage. Lower value takes precedence over higher value where two records of the same type exist on the zone/node.
- string
target — The domain name of a host where the service is running on the specified port .
- string
weight — Secondary prioritizing of records to serve. Records of equal priority should be served based on their weight. Higher values are served more often.
- string
record_type — RRType of the record.
- string
ttl — TTL for the record. Set to “0” to use zone default
- string
zone — Name of the zone.
|
SOAP Syntax
Click to view all SOAP Commands |
ReplaceSRVRecords — Replaces all existing SRV records on the zone/node indicated. |
Arguments — Click for More Info
- array
SRVRecords — Required.
- string
fqdn — Required. Name of the node where the record exists.
- hash
rdata — Required. RData defining the record.
- string
port — Required. Indicates the port where the service is running.
- string
priority — Required. Numeric value for priority usage. Lower value takes precedence over higher value where two records of the same type exist on the zone/node.
- string
target — Required. The domain name of a host where the service is running on the specified port .
- string
weight — Required. Secondary prioritizing of records to serve. Records of equal priority should be served based on their weight. Higher values are served more often.
- string
ttl — TTL for the record. Set to “0” to use zone default.
- string
zone — Required. Name of the zone where the record will reside.
- string
token — Required. Session Identifier.
|
Response — Click for More Info
- array
data
- string
fqdn — Name of the node where the record exists.
- hash
rdata — RData defining the record.
- string
port — Indicates the port where the service is running.
- string
priority — Numeric value for priority usage. Lower value takes precedence over higher value where two records of the same type exist on the zone/node.
- string
target — The domain name of a host where the service is running on the specified port .
- string
weight — Secondary prioritizing of records to serve. Records of equal priority should be served based on their weight. Higher values are served more often.
- string
record_id — Numeric identifier for the record.
- string
record_type — RRType of the record.
- string
ttl — TTL for the record. Set to “0” to use zone default
- string
zone — Name of the zone.
|
Example Request — Click for More Info
{
'SRVRecords' => [
{
'fqdn' => 'www.example.com',
'rdata' => {
'priority' => '10',
'weight' => '10',
'port' => '80',
'target' => 'www.example.com',
},
'ttl' => '3600',
'zone' => 'example.com',
},
{
'fqdn' => 'www.example.com',
'rdata' => {
'priority' => '10',
'weight' => '10',
'port' => '80',
'target' => 'www.example.com',
},
'ttl' => '3600',
'zone' => 'example.com',
}
],
'token' => 'asdlkfjasl23j4879afa',
}
|
DNS API Knowledge Base