Publishing pending Zone changes using the API requires specific syntax depending on whether you are using REST or SOAP. Use this table to find the syntax for your command.
Understanding How The API Works »
NOTE: Once the Zone is published, the GetZoneChangeset command will return an empty result because the pending items are published.
REST Syntax
Click to view all REST Resources |
Zone/ PUT — Publish pending zone changes.
HTTP Action — PUT
URI — https://api.dynect.net/REST/Zone/<zone>/ |
Arguments:
- boolean
publish — Required. Causes all pending changes to become part of the zone. The serial number increments based on its serial style and the data is pushed out to the nameservers.
- string
notes — Comments regarding this zone publish. The notes will be added to the zone notes. You can access them anytime on the Zone’s Simple Editor page.
|
Response — Click for More Info
- integer
serial — The current serial number of the zone.
- string
serial_style — The style in which serial numbers are generated for this zone.
Valid values:
increment
epoch
day
minute
- string
zone — The name of the zone.
- string
zone_type — Indicates whether the zone is Primary or Secondary.
- string
notes — Comments regarding this zone publish. The notes will be added to the zone notes. You can access them anytime on the Zone’s Simple Editor page.
|
SOAP Syntax
Click to view all SOAP Commands |
PublishZone — Causes all pending changes to become part of the zone. |
Arguments:
- string
token — Required. The session identifier.
- string
zone — Required. Name of zone to publish.
- string
notes — Comments regarding this zone publish. The notes will be added to the zone notes. You can access them anytime on the Zone’s Simple Editor page.
|
Response — Click for More Info
- hash
data
- integer
serial — The current serial number of the zone.
- string
serial_style — The style in which serial numbers are generated for this zone.
Valid values: increment , epoch , day , minute
- string
zone — The name of the zone.
- string
zone_type — Indicates whether the zone is Primary or Secondary.
- string
notes — Comments regarding this zone publish. The notes will be added to the zone notes. You can access them anytime on the Zone’s Simple Editor page.
|
Example Request — Click for More Info
{
'token' => 'zaq12wsxcDe34rf89gt56nh',
'zone' => 'example.com',
'notes' => 'added new IP addresses: 1.2.3.4, 1.4.3.2, 1.3.2.4',
}
|
DNS API Knowledge Base