For AI agents: a documentation index is available at the root level at /llms.txt. Append /llms.txt to any URL for a page-level index, or .md for the markdown version of any page.
Updates an existing holdout, and returns the updated holdout. Updating holdouts uses the semantic patch format.
To make a semantic patch request, you must append `domain-model=launchdarkly.semanticpatch` to your `Content-Type` header. To learn more, read [Updates using semantic patch](https://launchdarkly.com/docs/api#updates-using-semantic-patch).
### Instructions
Semantic patch requests support the following `kind` instructions for updating holdouts.
<details>
<summary>Click to expand instructions for <strong>updating holdouts</strong></summary>
#### endHoldout
Ends a holdout.
##### Parameters
None.
Here's an example:
```json
{
"comment": "Optional comment describing why the holdout is ending",
"instructions": [{
"kind": "endHoldout"
}]
}
```
#### removeExperiment
Removes an experiment from a holdout.
##### Parameters
- `value`: The key of the experiment to remove
Here's an example:
```json
{
"comment": "Optional comment describing the change",
"instructions": [{
"kind": "removeExperiment",
"value": "experiment-key"
}]
}
```
#### updateDescription
Updates the description of the holdout.
##### Parameters
- `value`: The new description.
Here's an example:
```json
{
"comment": "Optional comment describing the update",
"instructions": [{
"kind": "updateDescription",
"value": "Updated holdout description"
}]
}
```
#### updateName
Updates the name of the holdout.
##### Parameters
- `value`: The new name.
Here's an example:
```json
{
"comment": "Optional comment describing the update",
"instructions": [{
"kind": "updateName",
"value": "Updated holdout name"
}]
}
```
</details>
Authentication
Authorizationstring
API Key authentication via header
Path parameters
projectKeystringRequiredformat: "string"
The project key
environmentKeystringRequiredformat: "string"
The environment key
holdoutKeystringRequiredformat: "string"
The holdout key
Request
This endpoint expects an object.
instructionslist of maps from strings to anyRequired
The instructions to perform when updating. This should be an array with objects that look like <code>{“kind”: “update_action”}</code>. Some instructions also require a <code>value</code> field in the array element.
commentstringOptional
Optional comment describing the update
Response
Holdout response
_idstring
statusenum
Allowed values:
holdoutAmountstring
The percentage of traffic allocated to this holdout.
createdAtlong
updatedAtlong
baseExperimentobject
descriptionstringOptional
experimentslist of objectsOptional
Errors
400
Bad Request Error
401
Unauthorized Error
403
Forbidden Error
404
Not Found Error
429
Too Many Requests Error
Updates an existing holdout, and returns the updated holdout. Updating holdouts uses the semantic patch format.
To make a semantic patch request, you must append domain-model=launchdarkly.semanticpatch to your Content-Type header. To learn more, read Updates using semantic patch.
Instructions
Semantic patch requests support the following kind instructions for updating holdouts.
Click to expand instructions for updating holdouts
endHoldout
Ends a holdout.
Parameters
None.
Here’s an example:
{
"comment": "Optional comment describing why the holdout is ending",
"instructions": [{
"kind": "endHoldout"
}]
}
removeExperiment
Removes an experiment from a holdout.
Parameters
value: The key of the experiment to remove
Here’s an example:
{
"comment": "Optional comment describing the change",
"instructions": [{
"kind": "removeExperiment",
"value": "experiment-key"
}]
}
updateDescription
Updates the description of the holdout.
Parameters
value: The new description.
Here’s an example:
{
"comment": "Optional comment describing the update",
"instructions": [{
"kind": "updateDescription",
"value": "Updated holdout description"
}]
}
updateName
Updates the name of the holdout.
Parameters
value: The new name.
Here’s an example:
{
"comment": "Optional comment describing the update",