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
      • PUTCreate or update flag defaults for project
      • POSTCreate project
      • DELDelete project
      • GETGet flag defaults for project
      • GETGet project
      • GETList projects
      • PATCHUpdate flag default for project
      • PATCHUpdate project
    • Relay Proxy Configurations
    • Release Pipelines Beta
    • Releases Beta
    • Scheduled Changes
    • Segments
    • Tags
    • Teams
    • Teams Beta
    • Users
    • Users Beta
    • User Settings
    • Views Beta
    • Webhooks
    • Workflows
    • Workflow Templates
    • Other
Sign inTry it free
LogoLogo
REST API overviewProjects

Update project

PATCH
/api/v2/projects/:projectKey
PATCH
/api/v2/projects/:projectKey
$curl -X PATCH https://app.launchdarkly.com/api/v2/projects/projectKey \
> -H "Authorization: <apiKey>" \
> -H "Content-Type: application/json" \
> -d '[
> {
> "op": "add",
> "path": "/tags/0",
> "value": null
> }
>]'
1{
2 "_links": {
3 "environments": {
4 "href": "/api/v2/projects/my-project/environments",
5 "type": "application/json"
6 },
7 "self": {
8 "href": "/api/v2/projects/my-project",
9 "type": "application/json"
10 }
11 },
12 "_id": "57be1db38b75bf0772d11383",
13 "key": "project-key-123abc",
14 "includeInSnippetByDefault": true,
15 "name": "My Project",
16 "tags": [
17 "ops"
18 ],
19 "environments": [
20 {
21 "_links": {
22 "self": {
23 "href": "/api/v2/projects/my-project/environments/my-environment",
24 "type": "application/json"
25 }
26 },
27 "_id": "57be1db38b75bf0772d11384",
28 "key": "environment-key-123abc",
29 "name": "My Environment",
30 "apiKey": "sdk-xxx",
31 "mobileKey": "mob-xxx",
32 "color": "F5A623",
33 "defaultTtl": 5,
34 "secureMode": true,
35 "defaultTrackEvents": false,
36 "requireComments": true,
37 "confirmChanges": true,
38 "tags": [
39 "ops"
40 ],
41 "critical": true,
42 "_access": {
43 "denied": [
44 {
45 "action": "string",
46 "reason": {
47 "effect": "allow",
48 "resources": [
49 "proj/*:env/*;qa_*:/flag/*"
50 ],
51 "notResources": [
52 "string"
53 ],
54 "actions": [
55 "*"
56 ],
57 "notActions": [
58 "string"
59 ],
60 "role_name": "string"
61 }
62 }
63 ],
64 "allowed": [
65 {
66 "action": "string",
67 "reason": {
68 "effect": "allow",
69 "resources": [
70 "proj/*:env/*;qa_*:/flag/*"
71 ],
72 "notResources": [
73 "string"
74 ],
75 "actions": [
76 "*"
77 ],
78 "notActions": [
79 "string"
80 ],
81 "role_name": "string"
82 }
83 }
84 ]
85 },
86 "approvalSettings": {
87 "required": true,
88 "bypassApprovalsForPendingChanges": false,
89 "minNumApprovals": 1,
90 "canReviewOwnRequest": false,
91 "canApplyDeclinedChanges": true,
92 "serviceKind": "launchdarkly",
93 "serviceConfig": {},
94 "requiredApprovalTags": [
95 "require-approval"
96 ],
97 "autoApplyApprovedChanges": true,
98 "serviceKindConfigurationId": "1ef45a85-218f-4428-a8b2-a97e5f56c258"
99 },
100 "resourceApprovalSettings": {}
101 }
102 ],
103 "defaultClientSideAvailability": {
104 "usingMobileKey": true,
105 "usingEnvironmentId": true
106 },
107 "_access": {
108 "denied": [
109 {
110 "action": "string",
111 "reason": {
112 "effect": "allow",
113 "resources": [
114 "proj/*:env/*;qa_*:/flag/*"
115 ],
116 "notResources": [
117 "string"
118 ],
119 "actions": [
120 "*"
121 ],
122 "notActions": [
123 "string"
124 ],
125 "role_name": "string"
126 }
127 }
128 ],
129 "allowed": [
130 {
131 "action": "string",
132 "reason": {
133 "effect": "allow",
134 "resources": [
135 "proj/*:env/*;qa_*:/flag/*"
136 ],
137 "notResources": [
138 "string"
139 ],
140 "actions": [
141 "*"
142 ],
143 "notActions": [
144 "string"
145 ],
146 "role_name": "string"
147 }
148 }
149 ]
150 },
151 "defaultReleasePipelineKey": "string"
152}
Update a project. Updating a project uses a [JSON patch](https://datatracker.ietf.org/doc/html/rfc6902) representation of the desired changes. To learn more, read [Updates](https://launchdarkly.com/docs/api#updates).<br/><br/>To add an element to the project fields that are arrays, set the `path` to the name of the field and then append `/<array index>`. Use `/0` to add to the beginning of the array. Use `/-` to add to the end of the array. For example, `"path": "/tags/0"` adds a tag.<br/><br/>Note that `tags` are always deduplicated and returned in alphabetical order, regardless of the array index used in the patch path.
Was this page helpful?
Previous

Relay Proxy Configurations

Next
Built with

Update a project. Updating a project uses a JSON patch representation of the desired changes. To learn more, read Updates.

To add an element to the project fields that are arrays, set the path to the name of the field and then append /<array index>. Use /0 to add to the beginning of the array. Use /- to add to the end of the array. For example, "path": "/tags/0" adds a tag.

Note that tags are always deduplicated and returned in alphabetical order, regardless of the array index used in the patch path.

Authentication

Authorizationstring
API Key authentication via header

Path parameters

projectKeystringRequiredformat: "string"
The project key

Request

This endpoint expects a list of objects.
opstringRequired
The type of operation to perform
pathstringRequired
A JSON Pointer string specifying the part of the document to operate on
valueanyOptional
A JSON value used in "add", "replace", and "test" operations

Response

Project response
_linksmap from strings to objects
The location and content type of related resources
_idstring
The ID of this project
keystring
The key of this project
includeInSnippetByDefaultboolean

Whether or not flags created in this project are made available to the client-side JavaScript SDK by default

namestring

A human-friendly name for the project

tagslist of strings
A list of tags for the project
environmentslist of objects
A list of environments for the project
defaultClientSideAvailabilityobject

Describes which client-side SDKs can use new flags by default

_accessobject
Details on the allowed and denied actions for this project
defaultReleasePipelineKeystring
The key of the default release pipeline for this project

Errors

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