Modifying the Extended Information About a Microservice Instance
Function
This API is used to add or update the extended information about a registered microservice instance based on the instance ID.
Constraints
None
URI
PUT /v4/{project_id}/registry/microservices/{service_id}/instances/{instance_id}/properties
| Parameter | Mandatory | Type | Description |
|---|---|---|---|
| project_id | Yes | String | Unique ID of a tenant sub-project. Length: 1–64 characters. |
| service_id | Yes | String | Microservice ID, which must be unique. Length: 1–64 characters. Regular expression: ^.*$ |
| instance_id | Yes | String | ID of a microservice instance, which must be unique. Length: 1–64 characters. Regular expression: ^[A-Za-z0-9_.-]*$ |
Request Parameters
| Parameter | Mandatory | Type | Description |
|---|---|---|---|
| x-domain-name | Yes | String | Tenant account name. |
| X-consumer_id | Yes | String | Microservice consumer ID, which must be unique. |
| Parameter | Mandatory | Type | Description |
|---|---|---|---|
| properties | No | Object | Extended attribute. You can customize a key and value. The value contains at least 1 byte. |
Response Parameters
Status code: 400
| Parameter | Type | Description |
|---|---|---|
| errorCode | String | Error code. |
| errorMessage | String | Error information. |
| detail | String | Location details. |
Status code: 500
| Parameter | Type | Description |
|---|---|---|
| errorCode | String | Error code. |
| errorMessage | String | Error information. |
| detail | String | Location details. |
Example Requests
PUT https://{endpoint}/v4/{project_id}/registry/microservices/{service_id}/instances/{instance_id}/properties
{
"properties" : {
"attr1" : "b"
}
} Example Responses
None
Status Codes
| Status Code | Description |
|---|---|
| 200 | OK |
| 400 | Bad Request |
| 500 | Internal Server Error |
Error Codes
See Error Codes.
Last Article: Querying Details About a Microservice Instance
Next Article: Changing the Status of a Microservice Instance
Did this article solve your problem?
Thank you for your score!Your feedback would help us improve the website.