Skip to main content

Bind or Unbind Approval Group Resources

Use this API to bind an approval group to specified resources or remove an existing approval group binding. Supported resource types include environments, data sources, and database groups.

Request URL: /openapi/v1/approval/group/bind

Request Method: POST

Request Parameters

ParameterTypeRequiredDescriptionExample
idStringNoApproval group ID. Pass null or an empty string to remove the approval group binding from the resources.30044
resourceTypeStringYesResource type. Valid values: env, datasource, group.env
resourceIdListArrayYesResource ID list. At least one resource ID is required.["env-dev"]

Request Example

{
"id": "30044",
"resourceType": "env",
"resourceIdList": ["env-dev"]
}

Unbind Request Example

{
"id": "",
"resourceType": "env",
"resourceIdList": ["env-dev"]
}

Response Parameters

ParameterTypeDescriptionExample
successBooleanWhether the request is successful.true
requestIdStringRequest ID for troubleshooting and tracing.Aw1s9LIO-kqqrvUEnqojy5TJdmqc1OBK
dataStringExecution result.success
errorCodeStringError code returned when the call fails.None
messageStringError message returned when the call fails.None

Successful Invocation Example

{
"success": true,
"requestId": "Aw1s9LIO-kqqrvUEnqojy5TJdmqc1OBK",
"data": "success"
}

Result

A successful response returns success in data, which means the binding change was saved. Pass an approval group ID to bind resources, or pass null or an empty string for id to remove the approval group binding.