LaunchDarkly's Model Context Protocol (MCP) Server

LaunchDarkly's Model Context Protocol (MCP) Server
  • typescript

19

GitHub Stars

typescript

Language

6 months ago

First Indexed

2 months ago

Catalog Refreshed

Documentation & install

Readme and setup notes from the catalogue, plus a client-ready config you can copy for your MCP host.

Installation

Add the following to your MCP client configuration file.

Configuration

View docs
{
  "mcpServers": {
    "launchdarkly-mcp-server": {
      "command": "npx",
      "args": [
        "-y",
        "--package",
        "@launchdarkly/mcp-server",
        "--",
        "mcp",
        "start",
        "--api-key",
        "api-xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
      ],
      "env": {
        "LD_ACCESS_TOKEN": "MCP_LD_TOKEN"
      }
    }
  }
}

LaunchDarkly's MCP Server provides a dedicated gateway that lets model clients access LaunchDarkly feature flags using the MCP protocol. It enables dynamic flag evaluation and targeting within AI-driven workflows and experiments, making it easy to incorporate feature flag data into your models and tooling.

How to use

You run the MCP server in your environment and point your MCP-compatible client at it. The server accepts requests from your client and renders real-time flag data from LaunchDarkly. You will typically provide an API key for authentication and use your MCP client to query AI configs, environments, feature flags, and related resources to build decision logic around feature rollouts.

How to install

Prerequisites: you need Node.js and npm installed on your system. Ensure you have network access to download packages from the npm registry.

Step by step, choose one of the following installation methods that matches your environment.

Configuration examples and setup

{
  "mcpServers": {
    "LaunchDarkly": {
      "command": "npx",
      "args": [
        "-y", "--package", "@launchdarkly/mcp-server", "--", "mcp", "start",
        "--api-key", "api-xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
      ]
    }
  }
}

Additional environment configuration

If your setup requires reading the API key from an environment variable, you can configure the MCP server to reference that value. For example, you can pass the token via an environment variable like LD_ACCESS_TOKEN and map it in the MCP configuration as shown.

Environment variables and startup details

You may use an environment variable to supply the access token. Example configuration shows how to reference an environment variable in the MCP server setup and provide a placeholder for the actual token value.

Notes on using the Docker or standalone binary options

The MCP server can also be run as a standalone binary or via a Docker container, with the API key supplied as part of the startup arguments or environment. Ensure the chosen method includes the correct API key value.

Available resources and operations

You can manage and query several resource types through the MCP server, including AI configurations, repositories, environments, and feature flags.

Available environments

Different LaunchDarkly environments can be targeted, with server URLs used to connect to the appropriate environment when needed.

Available tools

getTargeting

Retrieve the targeting rules for a specific AI configuration to understand which users or contexts will see the feature flags.

updateTargeting

Update the targeting rules for an AI configuration to adjust exposure of feature flags.

list

List all AI configurations available in the current environment.

create

Create a new AI configuration for managing feature flag targeting and evaluation within MCP.

delete

Delete an existing AI configuration.

get

Get details of a specific AI configuration by its identifier.

update

Update the properties of an existing AI configuration.

createVariation

Create a variation for an AI configuration to manage multiple targeting scenarios.

deleteVariation

Delete a variation from an AI configuration.

getVariation

Retrieve a specific variation of an AI configuration.

updateVariation

Update a variation of an AI configuration.

listRepositories

List repositories associated with code references that the MCP server can access for integration.

listByProject

List environments linked to a project within the LaunchDarkly context.

getStatus

Get the status of a feature flag across all environments to understand rollout progress.

patch

Patch updates to a feature flag to modify its configuration or rules.

delete

Delete a feature flag from the MCP server.

Built by
VeilStrat
AI signals for GTM teams
© 2026 VeilStrat. All rights reserved.All systems operational