PUT api/Zone/Import/{zone_handle}?user={user}
Import to an existing zone - entire zone is replaced by supplied details
Request Information
URI Parameters
| Name | Description | Type | Additional information |
|---|---|---|---|
| zone_handle |
Handle of a zone |
string |
Required |
| user |
Optional user handle - if empty logged in user will be used |
string |
None. |
Body Parameters
Details of zone to import
Import| Name | Description | Type | Additional information |
|---|---|---|---|
| Name |
Zone name |
string |
Required String length: inclusive between 1 and 255 |
| BindData |
Bind file contents |
string |
Required |
| NsList |
List of name servers |
Collection of string |
Required Min length: 2 |
Request Formats
application/json, text/json
{
"Name": "sample string 1",
"BindData": "sample string 2",
"NsList": [
"sample string 1",
"sample string 2"
]
}
application/xml, text/xml
<Import xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/Namebay.Rest.Api.Models.Zone">
<BindData>sample string 2</BindData>
<Name>sample string 1</Name>
<NsList xmlns:d2p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
<d2p1:string>sample string 1</d2p1:string>
<d2p1:string>sample string 2</d2p1:string>
</NsList>
</Import>
application/x-www-form-urlencoded
Response Information
Resource Description
zone object on success
Collection of errors on failure
Return codes
200 - ok
300 - ambiguous
401 - unauthorized
404 - not found
500 - internal server error
702 - Zone not found
703 - Zone is inactive
712 - You're neither Owner, Tech, Admin nor Reseller of the domain
713 - You don't have Advanced DNS Management active for the domain
| Name | Description | Type | Additional information |
|---|---|---|---|
| Handle |
Zone handle |
string |
None. |
| Name |
Zone name |
string |
Required String length: inclusive between 1 and 255 |
| SoaExpire | integer |
Range: inclusive between 1209600 and 2419200 |
|
| SoaMinimum | integer |
Range: inclusive between 3600 and 86400 |
|
| SoaPrimaryNs | string |
Required String length: inclusive between 1 and 200 |
|
| SoaSerial |
Used To refresh the zone, When the serial changes Bind knows the zone has to be refreshed. This field is updated automaticaly on zone changes |
string |
None. |
| SoaRefresh | integer |
Range: inclusive between 1200 and 43200 |
|
| SoaRespPerson | string |
String length: inclusive between 0 and 200 |
|
| SoaRetry | integer |
Range: inclusive between 180 and 900 |
|
| Ttl |
Time to live |
integer |
Range: inclusive between 0 and 2147483647 |
Response Formats
application/json, text/json
{
"Handle": "sample string 1",
"Name": "sample string 2",
"SoaExpire": 3,
"SoaMinimum": 4,
"SoaPrimaryNs": "sample string 5",
"SoaSerial": "sample string 6",
"SoaRefresh": 7,
"SoaRespPerson": "sample string 8",
"SoaRetry": 9,
"Ttl": 10
}
application/xml, text/xml
<Zone xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/Namebay.Rest.Api.Models.Zone"> <Handle>sample string 1</Handle> <Name>sample string 2</Name> <SoaExpire>3</SoaExpire> <SoaMinimum>4</SoaMinimum> <SoaPrimaryNs>sample string 5</SoaPrimaryNs> <SoaRefresh>7</SoaRefresh> <SoaRespPerson>sample string 8</SoaRespPerson> <SoaRetry>9</SoaRetry> <SoaSerial>sample string 6</SoaSerial> <Ttl>10</Ttl> </Zone>