Updated on 2025-05-06 GMT+08:00

Updating an Endpoint

Function

This API is used to update an endpoint.

URI

PUT /v1/{project_id}/endpoints/{endpoint_id}

Table 1 Path Parameters

Parameter

Mandatory

Type

Description

project_id

Yes

String

Tenant resource space ID.

endpoint_id

Yes

String

ID of the endpoint.

Request Parameters

Table 2 Request header parameters

Parameter

Mandatory

Type

Description

X-Auth-Token

Yes

String

User token. The token can be obtained by calling the IAM API used to obtain a user token. The value of X-Subject-Token in the response header is the user token.

Table 3 Request body parameters

Parameter

Mandatory

Type

Description

description

No

String

Description.

Response Parameters

Status code: 200

Table 4 Response body parameters

Parameter

Type

Description

id

String

ID of the endpoint.

name

String

Name of the endpoint.

vpc_id

String

ID of the VPC to which the endpoint belongs.

subnet_id

String

ID of the subnet to which the endpoint belongs.

domain

String

Access domain name.

description

String

Description.

status

String

Status of the endpoint.

error_info

ErrorInfo object

Error message.

type

String

Type of the endpoint.

scalable

Boolean

Whether the endpoint is accessible.

created_time

String

UTC time when the endpoint is created.

updated_time

String

UTC time when the endpoint is updated.

endpoints

Array of EndpointConnection objects

List of endpoints.

Table 5 ErrorInfo

Parameter

Type

Description

error_code

String

Error code.

error_detail

String

Error details.

error_msg

String

Error message.

Table 6 EndpointConnection

Parameter

Type

Description

endpoint_service_id

String

Service ID of the endpoint.

endpoint_service_name

String

Service name of the endpoint.

marker_id

String

Packet ID of the endpoint.

id

String

Node ID of the endpoint.

ip

String

Node IP address of the endpoint.

created_time

String

Time when the endpoint is created.

Example Requests

Update an endpoint.

PUT https://{eg_endpoint}/v1/{project_id}/endpoints/{endpoint_id}

{
  "description" : "string"
}

Example Responses

Status code: 200

Operation successful.

{
  "id" : "23709d68-54d5-423b-a6be-03302e893152",
  "name" : "endpoint",
  "vpc_id" : "68bfbcc1-dff2-47e4-a9d4-332b9bc1b8de",
  "subnet_id" : "84758cf5-9c62-43ae-a778-3dbd8370c0a4",
  "domain" : "events.cn-north-4.myhuaweicloud.com",
  "description" : "Endpoint.",
  "status" : "CREATED",
  "error_info" : { },
  "type" : "PRIVATE",
  "scalable" : false,
  "created_time" : "2021-12-09 09:00:00",
  "updated_time" : "2021-12-09 09:00:00",
  "endpoints" : [ { } ]
}

Status Codes

Status Code

Description

200

Operation successful.

Error Codes

See Error Codes.