Querying the Name Server in a Private Zone
Function
This API is used to query the name server in a private zone.
Calling Method
For details, see Calling APIs.
URI
GET /v2/zones/{zone_id}/nameservers
Parameter |
Mandatory |
Type |
Description |
---|---|---|---|
zone_id |
Yes |
String |
ID of the private zone to be queried |
Request Parameters
Parameter |
Mandatory |
Type |
Description |
---|---|---|---|
X-Auth-Token |
Yes |
String |
User token. It can be obtained by calling an IAM API. The value of X-Subject-Token in the response header is the user token. |
Response Parameters
Status code: 200
Parameter |
Type |
Description |
---|---|---|
nameservers |
Array of PrivateNameServer objects |
Name server list |
Parameter |
Type |
Description |
---|---|---|
priority |
Integer |
Priority. If the value of priority is 1, the DNS server is the first one to resolve domain names. |
address |
String |
Address of the DNS server |
Status code: 400
Parameter |
Type |
Description |
---|---|---|
code |
String |
Error code Minimum: 8 Maximum: 36 |
message |
String |
Description Minimum: 2 Maximum: 512 |
Status code: 404
Parameter |
Type |
Description |
---|---|---|
code |
String |
Error code Minimum: 8 Maximum: 36 |
message |
String |
Description Minimum: 2 Maximum: 512 |
Status code: 500
Parameter |
Type |
Description |
---|---|---|
code |
String |
Error code Minimum: 8 Maximum: 36 |
message |
String |
Description Minimum: 2 Maximum: 512 |
Example Requests
None
Example Responses
Status code: 200
Response to the request for querying the name server in a private zone
{ "nameservers" : [ { "priority" : 1, "address" : "100.125.0.81" }, { "priority" : 2, "address" : "100.125.0.82" } ] }
Status Codes
Status Code |
Description |
---|---|
200 |
Response to the request for querying the name server in a private zone |
400 |
Error response |
404 |
Error response |
500 |
Error response |
Error Codes
See Error Codes.
Feedback
Was this page helpful?
Provide feedbackThank you very much for your feedback. We will continue working to improve the documentation.