Modify ENIs

Last updated: 2017-12-26 15:46:27

PDF

1. API Description

This API (ModifyNetworkInterface) is used to modify ENIs.
Domain for API request: vpc.api.qcloud.com

2. Input Parameters

The following request parameter list only provides API request parameters. Common request parameters need to be added when the API is called. For more information, refer to Common Request Parameters. The Action field for this API is ModifyNetworkInterface.

Parameter Name Required Type Description
vpcId Yes String Virtual private cloud ID of ENI, for example: vpc-7t9nf3pu.
networkInterfaceId Yes String ENI ID assigned by the system, for example: eni-m6dyj72l.
eniName No String ENI name; up to 60 characters; unique within the same VPC.
eniDescription No String ENI description, up to 60 characters.

3. Output Parameters

Parameter Name Type Description
code Int Error code, 0: Succeeded, other values: Failed.
message String Error message.

4. Error Codes

The following error code list only provides the business logic error codes for this API. For additional common error codes, refer to VPC Error Codes.

Error Code Description
InvalidVpc.NotFound VPC does not exist. Please check the information you entered. You can query the VPC by using the DescribeVpcEx API
InvalidNetworkInterface.NotFound ENI does not exist. Please check the information you entered. You can query the ENI via the DescribeNetworkInterfaces API.
InvalidEniName.InUse The ENI name has already been used.

5. Example

Input


https://vpc.api.qcloud.com/v2/index.php?Action=ModifyNetworkInterface
&<Common request parameters>
&vpcId=vpc-7t9nf3pu
&networkInterfaceId=eni-m6dyj72l
&eniName=barrytest

Output

{
    "code": 0,
    "message": "",
    "codeDesc": "Success",
}