Dns-zone:GET

From Hostway API Documentation
Revision as of 17:04, 18 February 2013 by Mike.robski (Talk | contribs)
Jump to: navigation, search

GET /dns/{zone}

Returns the details of a DNS zone.

Contents

Request

GET /dns/{zone}

Parameters

zone - string
The name of the DNS zone.

Request Headers

Authorization
Base64-encoded username:password string

Response

Status Code

200 OK
Success
401 Unauthorized
The server could not verify the credentials from the authorization header.
404 Not Found
The specified zone does not exist.

Response Body

{
  "minimumTTL": {minimumTTL},
  "retry": {retry},
  "name": "{zone}",
  "primaryNS": "{primaryNS}",
  "refresh": {refresh},
  "expire": {expire},
  "emailAddress": "{emailAddress}",
  "ttl": {ttl},
  "serial": {serial},
  "links": [
    {"href": "https://api.hostway.com/dns/{zone}", "rel": "self"},
    {"href": "https://api.hostway.com/dns/{zone}/records", "rel": "related"}
  ]
}

Examples

Request:

GET /dns/test.com
 

Response:

401 Unauthorized 
 

Request:

GET /dns/unknown-zone.com
Authorization: Basic {base64_encoded(username:password)}
 

Response:

403 Forbidden

{
  "forbidden": {"message": "Unauthorized: Dns failed permission check", "code": 403, "details": ""}
}
 

Request:

GET /dns/test.com
Authorization: Basic {base64_encoded(username:password)}
 

Response:

200 OK

{
  "minimumTTL": 300,
  "retry": 7200,
  "name": "test.com.",
  "links": [
    {"href": "http://127.0.0.1/dns/test.com/", "rel": "self"},
    {"href": "http://127.0.0.1/dns/test.com/records", "rel": "related"}
  ],
  "primaryNS": "a.dns.hostway.net.",
  "refresh": 28800,
  "expire": 604800,
  "emailAddress": "hostmaster.siteprotect.com.",
  "ttl": 14400,
  "serial": 1359151749
}
 

See also


blog comments powered by Disqus

Personal tools
Namespaces
Variants
Actions
APIs
Navigation
Toolbox