Help Center/ ServiceStage/ API Reference (ME-Abu Dhabi Region)/ CSE API/ Deleting Static Information About Microservices in Batches
Updated on 2023-06-25 GMT+08:00

Deleting Static Information About Microservices in Batches

Function

This API is used to delete the definitions and related information about microservices in batches, and deregister all instances of the microservices.

URI

DELETE /v4/{project_id}/registry/microservices

Table 1 Path parameters

Parameter

Type

Mandatory

Description

project_id

String

Yes

Fixed value: default.

Request

Request parameters

Table 2 Request body parameters

Parameter

Type

Mandatory

Description

serviceIds

Array of strings

Yes

Microservice ID list.

force

Boolean

No

Whether to forcibly delete static information about microservices. Options:
  • false: Do not forcibly delete such information.
  • true: Forcibly delete such information.

Default value: false.

If the value is true, all service instances are automatically deregistered and related service dependencies are deleted. If the value is not specified and a microservice is the dependent service of other microservices or has instances, the microservice cannot be deleted.

Response

Response parameters

Table 3 describes the parameters.

Table 3 Parameter

Parameter

Type

Description

services

Array of objects

See DelServicesResponse.

Example

Example request

{
  "serviceIds": [
    "string"
  ],
  "force": boolean
}

Example response

{
  "services": [
    {
      "serviceId": "string"
    }
  ]
}

Status Code

See Status Codes.

Error Code

See CSE Error Codes.