Scheduled flag changes is an Enterprise feature
Scheduled flag changes is available to customers on an Enterprise plan. To learn more, read about our pricing. To upgrade your plan, contact Sales.
Schedule the specified flag targeting changes to take effect at the selected time. You may schedule multiple changes for a flag each with a different ExecutionDate
. To learn more, read Scheduled flag changes.
Several of the endpoints in the scheduled changes API require a scheduled change ID. The scheduled change ID is returned as part of the Create scheduled changes workflow and List scheduled changes responses. It is the _id
field, or the _id
field of each element in the items
array.
Get a list of scheduled changes that will be applied to the feature flag.
Scheduled changes collection response
Invalid request
Invalid access token
Forbidden
Invalid resource identifier
{- "items": [
- {
- "_id": "string",
- "_creationDate": 0,
- "_maintainerId": "12ab3c45de678910abc12345",
- "_version": 1,
- "executionDate": 0,
- "instructions": [
- {
- "property1": null,
- "property2": null
}
], - "conflicts": null,
- "_links": {
- "property1": {
- "href": "string",
- "type": "string"
}, - "property2": {
- "href": "string",
- "type": "string"
}
}
}
], - "_links": {
- "property1": {
- "href": "string",
- "type": "string"
}, - "property2": {
- "href": "string",
- "type": "string"
}
}
}
Create scheduled changes for a feature flag. If the ignoreConficts
query parameter is false and there are conflicts between these instructions and existing scheduled changes, the request will fail. If the parameter is true and there are conflicts, the request will succeed.
Scheduled changes response
Invalid request
Invalid access token
Forbidden
Invalid resource identifier
Method not allowed
Status conflict
Rate limited
{- "comment": "Optional comment describing the scheduled changes",
- "executionDate": 1718467200000,
- "instructions": [
- {
- "kind": "turnFlagOn"
}
]
}
{- "_id": "string",
- "_creationDate": 0,
- "_maintainerId": "12ab3c45de678910abc12345",
- "_version": 1,
- "executionDate": 0,
- "instructions": [
- {
- "property1": null,
- "property2": null
}
], - "conflicts": null,
- "_links": {
- "property1": {
- "href": "string",
- "type": "string"
}, - "property2": {
- "href": "string",
- "type": "string"
}
}
}
Get a scheduled change that will be applied to the feature flag by ID.
Scheduled changes response
Invalid access token
Invalid resource identifier
Rate limited
{- "_id": "string",
- "_creationDate": 0,
- "_maintainerId": "12ab3c45de678910abc12345",
- "_version": 1,
- "executionDate": 0,
- "instructions": [
- {
- "property1": null,
- "property2": null
}
], - "conflicts": null,
- "_links": {
- "property1": {
- "href": "string",
- "type": "string"
}, - "property2": {
- "href": "string",
- "type": "string"
}
}
}
Update a scheduled change, overriding existing instructions with the new ones. Updating a scheduled change 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.
Semantic patch requests support the following kind
instructions for updating scheduled changes.
Removes the scheduled change.
Here's an example:
{
"instructions": [{ "kind": "deleteScheduledChange" }]
}
Removes the existing scheduled changes and replaces them with the new instructions.
value
: An array of the new actions to perform when the execution date for these scheduled changes arrives. Supported scheduled actions are turnFlagOn
and turnFlagOff
.Here's an example that replaces the scheduled changes with new instructions to turn flag targeting off:
{
"instructions": [
{
"kind": "replaceScheduledChangesInstructions",
"value": [ {"kind": "turnFlagOff"} ]
}
]
}
Updates the execution date for the scheduled changes.
value
: the new execution date, in Unix milliseconds.Here's an example:
{
"instructions": [
{
"kind": "updateScheduledChangesExecutionDate",
"value": 1754092860000
}
]
}
Scheduled changes response
Invalid request
Invalid access token
Forbidden
Invalid resource identifier
Method not allowed
Status conflict
Rate limited
{- "comment": "Optional comment describing the update to the scheduled changes",
- "instructions": [
- {
- "kind": "replaceScheduledChangesInstructions",
- "value": [
- {
- "kind": "turnFlagOff"
}
]
}
]
}
{- "_id": "string",
- "_creationDate": 0,
- "_maintainerId": "12ab3c45de678910abc12345",
- "_version": 1,
- "executionDate": 0,
- "instructions": [
- {
- "property1": null,
- "property2": null
}
], - "conflicts": null,
- "_links": {
- "property1": {
- "href": "string",
- "type": "string"
}, - "property2": {
- "href": "string",
- "type": "string"
}
}
}
Delete a scheduled changes workflow.
Action succeeded
Invalid access token
Forbidden
Invalid resource identifier
Method not allowed
Status conflict
Rate limited
{- "code": "unauthorized",
- "message": "Invalid access token"
}