Flag import configurations (beta)

Create a flag import configuration

POST
/api/v2/integration-capabilities/flag-import/{projectKey}/{integrationKey}

Create a new flag import configuration. The integrationKey path parameter identifies the feature management system from which the import occurs, for example, split. The config object in the request body schema is described by the global integration settings, as specified by the formVariables in the manifest.json for this integration. It varies slightly based on the integrationKey.

Authorization

ApiKey read, write
Authorization<token>

In: header

Scope: read, write

Path Parameters

projectKey*string

The project key

Formatstring
integrationKey*string

The integration key

Formatstring

Request Body

application/json

config*

The global configuration settings, as specified by the formVariables in the manifest.json for this configuration.

tags?array<string>

Tags to associate with the configuration

name?string

Name to identify the configuration

Response Body

application/json

application/json

application/json

application/json

application/json

application/json

application/json

curl -X POST "https://example.com/api/v2/integration-capabilities/flag-import/string/string" \  -H "Content-Type: application/json" \  -d '{    "config": {      "environmentId": "The ID of the environment in the external system",      "ldApiKey": "An API key with create flag permissions in your LaunchDarkly account",      "ldMaintainer": "The ID of the member who will be the maintainer of the imported flags",      "ldTag": "A tag to apply to all flags imported to LaunchDarkly",      "splitTag": "If provided, imports only the flags from the external system with this tag. Leave blank to import all flags.",      "workspaceApiKey": "An API key with read permissions in the external feature management system",      "workspaceId": "The ID of the workspace in the external system"    },    "name": "Sample configuration",    "tags": [      "example-tag"    ]  }'
{  "_links": {    "self": {      "href": "string",      "type": "string"    },    "parent": {      "href": "string",      "type": "string"    },    "project": {      "href": "string",      "type": "string"    }  },  "_id": "12ab3c4d5ef1a2345bcde67f",  "integrationKey": "split",  "projectKey": "default",  "config": {    "property1": null,    "property2": null  },  "tags": [],  "name": "Development environment configuration",  "version": 1,  "_access": {    "denied": [      {        "action": "string",        "reason": {          "resources": [            "proj/*:env/*;qa_*:/flag/*"          ],          "notResources": [            "string"          ],          "actions": [            "*"          ],          "notActions": [            "string"          ],          "effect": "allow",          "role_name": "string"        }      }    ],    "allowed": [      {        "action": "string",        "reason": {          "resources": [            "proj/*:env/*;qa_*:/flag/*"          ],          "notResources": [            "string"          ],          "actions": [            "*"          ],          "notActions": [            "string"          ],          "effect": "allow",          "role_name": "string"        }      }    ]  },  "_status": {    "status": "pending",    "lastImport": "1717263000000",    "lastError": "1714584600000",    "errors": [      {        "integrationId": "string",        "message": "string",        "statusCode": 0,        "timestamp": 0      }    ]  }}