Updated on 2023-08-02 GMT+08:00

Deleting an Agent

Function

This API is used to delete an Agent.

URI

POST /v1/apm2/openapi/apm-service/agent-mgr/delete-agent

Request Parameters

Table 1 Request header parameters

Parameter

Mandatory

Type

Description

X-Auth-Token

Yes

String

User token obtained from IAM.

x-business-id

Yes

Long

Application ID.

Table 2 Request body parameters

Parameter

Mandatory

Type

Description

instance_list

Yes

Array of integers

Instance list.

region

Yes

String

Region name.

business_id

Yes

Long

Application ID.

Response Parameters

Status code: 200

Table 3 Response body parameters

Parameter

Type

Description

delete_status

Integer

Deleted or not.

Example Requests

Delete the offline Agent 1096 of application 1.

/v1/apm2/openapi/apm-service/agent-mgr/delete-agent

{
  "instance_list" : [ 1096 ],
  "region" : "xx-xxxx-xx",
  "business_id" : 1
}

Example Responses

Status code: 200

OK: The request is successful.

{
  "delete_status" : 0
}

Status Codes

Status Code

Description

200

OK: The request is successful.

401

Unauthorized: No permissions.

403

Forbidden: Access forbidden.

404

Not Found: The requested resource is not found.

Error Codes

See Error Codes.