Enabling Domain Name Resolution for IP Addresses
Function
This API is used to enable domain name resolution for IP addresses.
Calling Method
For details, see Calling APIs.
URI
POST /v3/{project_id}/elb/loadbalancers/{loadbalancer_id}/dns/ips/batch-enable
|
Parameter |
Mandatory |
Type |
Description |
|---|---|---|---|
|
project_id |
Yes |
String |
Definition: Specifies the project ID. For details about how to obtain a project ID, see Obtaining a Project ID. Constraints: N/A Range: The value can contain a maximum of 32 characters, including digits and lowercase letters. Default value: N/A |
|
loadbalancer_id |
Yes |
String |
Specifies the load balancer ID. |
Request Parameters
|
Parameter |
Mandatory |
Type |
Description |
|---|---|---|---|
|
X-Auth-Token |
Yes |
String |
Definition: Specifies the token used for IAM authentication. Constraints: N/A Range: N/A Default value: N/A |
|
Parameter |
Mandatory |
Type |
Description |
|---|---|---|---|
|
ips |
Yes |
Array of DnsIp objects |
Definition: Specifies the IP addresses you want to enable domain name resolution for. Constraints: N/A Range: N/A Default value: N/A |
Response Parameters
Status code: 200
|
Parameter |
Type |
Description |
|---|---|---|
|
ips |
Array of ListDnsIpResponseBody objects |
Definition: Specifies the domain name resolution information of a load balancer. Constraints: If neither public nor private domain name resolution is enabled for the load balancer, an empty list is returned. Range: N/A Default value: N/A |
|
Parameter |
Type |
Description |
|---|---|---|
|
ips |
Array of DnsIpResponse objects |
Specifies the domain name resolution information of a load balancer. |
|
Parameter |
Type |
Description |
|---|---|---|
|
id |
String |
Specifies the ID of domain name resolution configured for the IP address. |
|
enable |
Boolean |
Definition: Specifies whether domain name resolution is enabled for the IP address. Range:
|
|
ip_address |
String |
Definition: Specifies the IP address. It can be an IPv4 or IPv6 address. Constraints: The IP address must be a private or public IP address of the load balancer. |
|
type |
String |
Definition: Specifies the IP address type. Range:
|
|
domain_name |
String |
Definition: Specifies the domain name that the IP address is mapped to. Constraints:
|
|
created_at |
String |
Specifies the creation time. The value must be a UTC time in the format of yyyy-MM-dd'T'HH:mm:ss'Z'. |
|
updated_at |
String |
Specifies the update time. The value must be a UTC time in the format of yyyy-MM-dd'T'HH:mm:ss'Z'. |
Example Requests
Enabling domain name resolution for IP addresses
POST https://{ELB_Endpoint}/v3/{project_id}/elb/loadbalancers/{loadbalancer_id}/dns/ips/batch-enable
{
"ips" : [ {
"ip_address" : "192.168.20.87"
}, {
"ip_address" : "2001:db8:a583:682::10"
} ]
}
Example Responses
Status code: 200
Successful request.
{
"ips" : [ {
"enable" : true,
"type" : "vip",
"ip_address" : "192.168.20.87",
"domain_name" : "10000000-0000-0000-0000-000000000001-internal.elb.zunei.test.private.com",
"id" : "10000000-0000-0000-0000-000000000001"
}, {
"enable" : true,
"type" : "eip",
"ip_address" : "2001:db8:a583:682::10",
"domain_name" : "10000000-0000-0000-0000-000000000001.elb.zunei.test.public.com",
"id" : "10000000-0000-0000-0000-000000000002"
} ]
}
Status Codes
|
Status Code |
Description |
|---|---|
|
200 |
Successful request. |
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.See the reply and handling status in My Cloud VOC.
For any further questions, feel free to contact us through the chatbot.
Chatbot