Domains
Domains
Domain objects
The VisualDNS REST Domain API let's you:
-
list the user KEY associated domains,
-
create new ones,
-
or delete any domain that belongs to your user.
Authentication
Authentication is managed using your API Key, which must be included in the auth_token parameter for every call.
The authentication key can be reset from your user console at any time
Supported Formats
json
GET /api/v1/domains
List your account domains
Supported Formats
jsonErrors
302 Unauthorized, redirected401 Unauthorized
422 Bad parameter
404 Not found
500 Server crashed for some reason
Examples
GET /api/v1/domains/?auth_token=HVBuTMUfcnZi3UCuHsf5 200 [ { "id": 1, "name": "domain1.com", "last_check": null }, { "id": 2, "name": "domain2.com", "last_check": null } ]
Params
Param name | Description |
---|---|
auth_token required |
API authentication key Value: Must be String |
POST /api/v1/domains
Create a new domain
Supported Formats
jsonErrors
302 Unauthorized, redirected401 Unauthorized
422 Bad parameter
404 Not found
500 Server crashed for some reason
Examples
POST /api/v1/domains/ auth_token=XPpLxAyCMSwEuwqnZ2Db&domain[name]=my-new-domain.com&domain[ip]=3.4.5.6 201 { "id": 3, "name": "my-new-domain.com", "last_check": null }
POST /api/v1/domains/ auth_token=NMp81oz3xzKSfDeZnaSg&domain[name]=my_new_domain.com&domain[ip]=3.4.5.6 422 { "errors": { "name": [ "is invalid" ] } }
Params
Param name | Description |
---|---|
auth_token required |
API authentication key Value: Must be String |
domain required |
Value: Must be a Hash |
domain[name] required |
domain name to be registered in the dns Value: Must be String |
domain[ip] required |
domain's main IP address Value: Must be String |
GET /api/v1/domains/:id
Get domain's information
Supported Formats
jsonErrors
302 Unauthorized, redirected401 Unauthorized
422 Bad parameter
404 Not found
500 Server crashed for some reason
Examples
GET /api/v1/domains/1?auth_token=6mWpQor7z8ktqUrs3KsK 200 { "id": 1, "name": "domain18.com", "last_check": null }
Params
Param name | Description |
---|---|
auth_token required |
API authentication key Value: Must be String |
id required |
Domain ID Value: Must be Fixnum |
DELETE /api/v1/domains/:id
Delete a domain
Deletes the domain identified by id, along all it's records
Supported Formats
jsonErrors
302 Unauthorized, redirected401 Unauthorized
422 Bad parameter
404 Not found
500 Server crashed for some reason
Examples
DELETE /api/v1/domains/1 auth_token=xVN9NTTEefUvgJXLWX7v 204
Params
Param name | Description |
---|---|
auth_token required |
API authentication key Value: Must be String |
id required |
Domain ID Value: Must be Fixnum |