Updates change request configuration for an environment in the project
PUT <your-unleash-url>/api/admin/projects/:projectId/environments/:environment/change-requests/config
Authorization
name: Authorizationtype: apiKeyin: header
This endpoint will change the change request configuration for a given environment, set it to either on/off and optionally configure the number of approvals needed. The minimum number of approvals is 1 and the maximum number is 10. If you provide a number higher than 10 or lower than 1, Unleash will clamp it to the allowed range.
Request
Path Parameters
- projectId string required
- environment string required
- application/json
Body
required
updateChangeRequestEnvironmentConfigSchema
- changeRequestsEnabled boolean required
true
if change requests should be enabled, otherwisefalse
. - requiredApprovals integer
The number of approvals required before a change request can be applied in this environment.
Responses
- 200
This response has no body.
Authorization
name: Authorizationtype: apiKeyin: header
Request
Request
curl / cURL
curl -L -X PUT '<your-unleash-url>/api/admin/projects/:projectId/environments/:environment/change-requests/config' \
-H 'Content-Type: application/json' \
-H 'Authorization: <API_KEY_VALUE>' \
--data-raw '{
"changeRequestsEnabled": true,
"requiredApprovals": 3
}'
python / requests
curl -L -X PUT '<your-unleash-url>/api/admin/projects/:projectId/environments/:environment/change-requests/config' \
-H 'Content-Type: application/json' \
-H 'Authorization: <API_KEY_VALUE>' \
--data-raw '{
"changeRequestsEnabled": true,
"requiredApprovals": 3
}'
go / native
curl -L -X PUT '<your-unleash-url>/api/admin/projects/:projectId/environments/:environment/change-requests/config' \
-H 'Content-Type: application/json' \
-H 'Authorization: <API_KEY_VALUE>' \
--data-raw '{
"changeRequestsEnabled": true,
"requiredApprovals": 3
}'
nodejs / axios
curl -L -X PUT '<your-unleash-url>/api/admin/projects/:projectId/environments/:environment/change-requests/config' \
-H 'Content-Type: application/json' \
-H 'Authorization: <API_KEY_VALUE>' \
--data-raw '{
"changeRequestsEnabled": true,
"requiredApprovals": 3
}'
ruby / Net::HTTP
curl -L -X PUT '<your-unleash-url>/api/admin/projects/:projectId/environments/:environment/change-requests/config' \
-H 'Content-Type: application/json' \
-H 'Authorization: <API_KEY_VALUE>' \
--data-raw '{
"changeRequestsEnabled": true,
"requiredApprovals": 3
}'
csharp / RestSharp
curl -L -X PUT '<your-unleash-url>/api/admin/projects/:projectId/environments/:environment/change-requests/config' \
-H 'Content-Type: application/json' \
-H 'Authorization: <API_KEY_VALUE>' \
--data-raw '{
"changeRequestsEnabled": true,
"requiredApprovals": 3
}'
php / cURL
curl -L -X PUT '<your-unleash-url>/api/admin/projects/:projectId/environments/:environment/change-requests/config' \
-H 'Content-Type: application/json' \
-H 'Authorization: <API_KEY_VALUE>' \
--data-raw '{
"changeRequestsEnabled": true,
"requiredApprovals": 3
}'
java / OkHttp
curl -L -X PUT '<your-unleash-url>/api/admin/projects/:projectId/environments/:environment/change-requests/config' \
-H 'Content-Type: application/json' \
-H 'Authorization: <API_KEY_VALUE>' \
--data-raw '{
"changeRequestsEnabled": true,
"requiredApprovals": 3
}'
powershell / RestMethod
curl -L -X PUT '<your-unleash-url>/api/admin/projects/:projectId/environments/:environment/change-requests/config' \
-H 'Content-Type: application/json' \
-H 'Authorization: <API_KEY_VALUE>' \
--data-raw '{
"changeRequestsEnabled": true,
"requiredApprovals": 3
}'