For AI agents: a documentation index is available at the root level at /llms.txt and /llms-full.txt. Append /llms.txt to any URL for a page-level index, or .md for the markdown version of any page.
Sign inTry it free
DocsGuidesSDKsIntegrationsAPI docsTutorialsFlagship blog
DocsGuidesSDKsIntegrationsAPI docsTutorialsFlagship blog
  • REST API overview
    • Access Tokens
    • Account Members
    • Account Usage Beta
    • AI Configs
    • Announcements
    • Applications Beta
    • Approvals
    • Approvals Beta
    • Audit Log
    • Code References
    • Contexts
    • Context Settings
    • Custom Roles
    • Data Export Destinations
    • Environments
    • Experiments
    • Feature Flags
    • Feature Flags Beta
    • Flag Import Configurations Beta
    • Flag Links Beta
    • Flag Triggers
    • Follow Flags
    • Holdouts Beta
    • Insights Charts Beta
    • Insights Deployments Beta
    • Insights Flag Events Beta
    • Insights Pull Requests Beta
    • Insights Repositories Beta
    • Insights Scores Beta
    • Integration Audit Log Subscriptions
    • Integration Delivery Configurations Beta
    • Integrations Beta
    • Layers
    • Metrics
    • Metrics Beta
    • OAuth2 Clients
    • Persistent Store Integrations Beta
    • Projects
    • Relay Proxy Configurations
    • Release Pipelines Beta
    • Releases Beta
    • Scheduled Changes
      • POSTCreate scheduled changes workflow
      • DELDelete scheduled changes workflow
      • GETGet a scheduled change
      • GETList scheduled changes
      • PATCHUpdate scheduled changes workflow
    • Segments
    • Tags
    • Teams
    • Teams Beta
    • Users
    • Users Beta
    • User Settings
    • Views Beta
    • Webhooks
    • Workflows
    • Workflow Templates
    • Other
Sign inTry it free
LogoLogo
REST API overviewScheduled Changes

Create scheduled changes workflow

POST
/api/v2/projects/:projectKey/flags/:featureFlagKey/environments/:environmentKey/scheduled-changes
POST
/api/v2/projects/:projectKey/flags/:featureFlagKey/environments/:environmentKey/scheduled-changes
$curl -X POST https://app.launchdarkly.com/api/v2/projects/projectKey/flags/featureFlagKey/environments/environmentKey/scheduled-changes \
> -H "Authorization: <apiKey>" \
> -H "Content-Type: application/json" \
> -d '{
> "executionDate": 1718467200000,
> "instructions": [
> {
> "kind": "turnFlagOn"
> }
> ],
> "comment": "Optional comment describing the scheduled changes"
>}'
1{
2 "_id": "12ab3c45de678910abc12345",
3 "_creationDate": 1654123897062,
4 "_maintainerId": "12ab3c45de678910abc12345",
5 "_version": 1,
6 "executionDate": 1636558831870,
7 "instructions": [
8 "[ { \"kind\": \"turnFlagOn\" }]"
9 ],
10 "_maintainerServiceTokenId": "string",
11 "conflicts": null,
12 "_links": {}
13}
Create scheduled changes for a feature flag. The changes you schedule may include any semantic patch instructions available when [updating a feature flag](https://launchdarkly.com/docs/api/feature-flags/patch-feature-flag#using-semantic-patches-on-a-feature-flag). If the `ignoreConflicts` 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.
Was this page helpful?
Previous

Delete scheduled changes workflow

Next
Built with

Create scheduled changes for a feature flag. The changes you schedule may include any semantic patch instructions available when updating a feature flag. If the ignoreConflicts 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.

Authentication

Authorizationstring
API Key authentication via header

Path parameters

projectKeystringRequiredformat: "string"
The project key
featureFlagKeystringRequiredformat: "string"
The feature flag key
environmentKeystringRequiredformat: "string"
The environment key

Query parameters

ignoreConflictsbooleanOptional

Whether to succeed (true) or fail (false) when these instructions conflict with existing scheduled changes

Request

This endpoint expects an object.
executionDatelongRequired
When the scheduled changes should be executed
instructionslist of maps from strings to anyRequired

The actions to perform on the execution date for these scheduled changes. This should be an array with a single object that looks like <code>{“kind”: “scheduled_action”}</code>. Supported scheduled actions include any semantic patch instructions available when updating a feature flag.

commentstringOptional
Optional comment describing the scheduled changes

Response

Scheduled changes response
_idstring
The ID of this scheduled change
_creationDatelong
Timestamp of when the scheduled change was created
_maintainerIdstring
The ID of the scheduled change maintainer
_versioninteger
Version of the scheduled change
executionDatelong
When the scheduled changes should be executed
instructionslist of maps from strings to any
The actions to perform on the execution date for these scheduled changes
_maintainerServiceTokenIdstring
The ID of the service token that created or updated this scheduled change
conflictsany
Details on any conflicting scheduled changes
_linksmap from strings to objects
The location and content type of related resources

Errors

400
Bad Request Error
401
Unauthorized Error
403
Forbidden Error
404
Not Found Error
405
Method Not Allowed Error
409
Conflict Error
429
Too Many Requests Error