Detaches an EIP from a cloud resource.

Debug

By using API Explorer, you can easily debug APIs, automatically generate SDK code examples, and quickly search for APIs.

Request parameters

Parameter Type Required? Example value Description
Action String Yes UnassociateEipAddress

The name of this action. Value:

UnassociateEipAddress

AllocationId String Yes eip-2zeerraiwb7uj6i0d0fo3

The ID of the EIP.

InstanceId String  Yes i-12345678

The ID of the cloud resource.

RegionId String Yes cn-hangzhou

The ID of the region to which the EIP belongs.

InstanceType String No EcsInstance

The type of the cloud resource. Valid values:

  • EcsInstance(default): a VPC ECS instance

  • SlbInstance: a VPC SLB instance

  • Nat: NAT Gateway

  • HaVip: HAVIP

Response parameters

Parameter Type Example value Description
RequestId String 220F3179-5238-47F0-A0CA-1272AA2BC41F The ID of the request.

Examples

Request example


https://vpc.aliyuncs.com/?Action=UnassociateEipAddress
&AllocationId=eip-25877c70x
&InstanceId=i-25skktcp4
&<CommonParameters>
Response example
  • XML format

    <UnassociateEipAddressResponse>
      <RequestId>0ED8D006-F706-4D23-88ED-E11ED28DCAC0</RequestId>
    </UnassociateEipAddressResponse>
    
  • JSON format

    {
    	"RequestId":"0ED8D006-F706-4D23-88ED-E11ED28DCAC0"
    }

Error codes

HTTP status code Error code Error message Description
400 IncorrectEipStatus Current elastic IP status does not support this operation. The current status of the specified EIP address does not support this operation.
400 InvalidInstanceId.NotFound Specified instance does not exist. The specified instance does not exist.
400 IncorrectInstanceStatus The current status of instance does not support this operation. The current instance status does not support this operation.
400 InvalidInstanceType.ValueNotSupported The specified value of InstanceType is not supported. The InstanceType value is invalid.
400 IncorrectHaVipStatus This operation is denied because satus of the specified HaVip is neither Available nor InUse. This operation cannot be performed because the HAVIP is in the Available or InUse state.
400 OperationDenied Eip of default vpc not allow this operation The EIP of the default VPC does not support this operation.
404 Forbidden.RegionNotFound Specified region is not found during access authentication. The specified region does not exist.
400 InvalidParameter The specified parameter is not valid. The specified parameter value is invalid.
400 Forbbiden The eip instance owener error You are not authorized to call this EIP.
400 InvalidBindingStatus The eip binding status invalid. The attaching status of the EIP is invalid.

See common error codes