Skip to main content
PATCH
/
api
/
v2
/
flags
/
{projectKey}
/
{flagKey}
/
release
Patch release for flag
curl --request PATCH \
  --url https://app.launchdarkly.com/api/v2/flags/{projectKey}/{flagKey}/release \
  --header 'Authorization: <api-key>' \
  --header 'Content-Type: application/json' \
  --data '
[
  {
    "op": "replace",
    "path": "/phases/0/complete",
    "value": true
  }
]
'
{
  "name": "Example release pipeline",
  "releasePipelineKey": "example-release-pipeline",
  "releasePipelineDescription": "Our release pipeline for typical testing and deployment",
  "phases": [
    {
      "_id": "1234a56b7c89d012345e678f",
      "_name": "Phase 1 - Testing",
      "complete": true,
      "_creationDate": "1684262711507",
      "_audiences": [
        {
          "_id": "1234a56b7c89d012345e678g",
          "name": "Phase 1 - Testing",
          "_links": {},
          "environment": {
            "_links": {
              "self": {
                "href": "/api/v2/projects/my-project/environments/my-environment",
                "type": "application/json"
              }
            },
            "key": "environment-key-123abc",
            "name": "My Environment",
            "color": "F5A623"
          },
          "configuration": {
            "releaseStrategy": "monitoredRelease",
            "requireApproval": true,
            "notifyMemberIds": [
              "1234a56b7c89d012345e678f"
            ],
            "notifyTeamKeys": [
              "example-reviewer-team"
            ],
            "releaseGuardianConfiguration": {
              "monitoringWindowMilliseconds": 60000,
              "rolloutWeight": 50,
              "rollbackOnRegression": true,
              "randomizationUnit": "user"
            }
          },
          "segmentKeys": [
            "segment-key-123abc"
          ],
          "status": "active",
          "_ruleIds": [
            "<string>"
          ]
        }
      ],
      "_completionDate": "1684262711509",
      "_completedBy": {
        "member": {
          "_links": {
            "self": {
              "href": "/api/v2/members/569f183514f4432160000007",
              "type": "application/json"
            }
          },
          "_id": "569f183514f4432160000007",
          "role": "admin",
          "email": "ariel@acme.com",
          "firstName": "Ariel",
          "lastName": "Flores"
        },
        "token": {
          "_links": {},
          "_id": "<string>",
          "name": "DevOps token",
          "ending": "2345",
          "serviceToken": false
        }
      },
      "status": "Started",
      "started": true,
      "_startedDate": 123,
      "configuration": {}
    }
  ],
  "_version": 1,
  "_links": {},
  "_releaseVariationId": "<string>",
  "_canceledAt": "1684262711507"
}

Documentation Index

Fetch the complete documentation index at: https://launchdarkly-preview.mintlify.app/llms.txt

Use this file to discover all available pages before exploring further.

Authorizations

Authorization
string
header
required

Path Parameters

projectKey
string<string>
required

The project key

flagKey
string<string>
required

The flag key

Body

application/json
op
string
required

The type of operation to perform

Example:

"replace"

path
string
required

A JSON Pointer string specifying the part of the document to operate on

Example:

"/exampleField"

value
any

A JSON value used in "add", "replace", and "test" operations

Example:

"new example value"

Response

Release response

name
string
required

The release pipeline name

Example:

"Example release pipeline"

releasePipelineKey
string
required

The release pipeline key

Example:

"example-release-pipeline"

releasePipelineDescription
string
required

The release pipeline description

Example:

"Our release pipeline for typical testing and deployment"

phases
object[]
required

An ordered list of the release pipeline phases

_version
integer
required

The release version

Example:

1

The location and content type of related resources

_releaseVariationId
string

The chosen release variation ID to use across all phases of a release

_canceledAt
integer<int64>

Timestamp of when the release was canceled

Example:

"1684262711507"