Skip to main content

LaunchDarkly Integration

Connect LaunchDarkly to give the AI agent visibility into feature flag state, targeting rules, and flag status across environments — answering "did someone flip a flag?" during incident triage.

Capabilities

Once connected, the AI agent can:

CapabilityDescription
List ProjectsDiscover LaunchDarkly projects in your account
List EnvironmentsView environment topology (production, staging, test)
List Feature FlagsScan flags with filtering by environment, tag, and state
Inspect Flag DetailsDeep-dive into targeting rules, variations, and prerequisites
Check Flag StatusDetermine if a flag is active, inactive, launched, or new

Prerequisites

  • A LaunchDarkly account
  • An API access token with Reader role permissions
  • Read access to the projects you want to monitor

Setup

1
Create an API Access Token
  1. Log in to LaunchDarkly
  2. Go to Organization settingsAuthorizationAccess tokens
  3. Click Create token
  4. Select the Reader role
  5. Check This is a service token for long-term integration use
  6. Copy the generated token
2
Add Integration in Autoheal
  1. Go to Integrations in Autoheal
  2. Click LaunchDarkly
  3. Enter a name (e.g., "Production LaunchDarkly")
3
Configure Credentials

Enter the following:

  • API Access Token: Your LaunchDarkly access token
4
Test and Save

Click Test Connection to verify, then Save.

Token Permissions

The Reader built-in role is sufficient for all investigation capabilities. This grants read-only access to projects, environments, flags, and flag statuses.

PermissionWhy It's Needed
Read projectsDiscover project structure
Read environmentsUnderstand environment topology
Read feature flagsInspect flag state and targeting rules
Read flag statusesCheck if flags are active or inactive
info

We recommend using a service token rather than a personal token. Service tokens are not tied to a user account and won't break if the user leaves the organization.

Example Queries

Once connected, you can ask the AI agent:

What feature flags are currently active in the production environment?
Show me the targeting rules for the enable-new-checkout flag
Are there any flags that are ON in production but OFF in staging?
What's the rollout percentage for the rate-limit-increase flag?
Which flags were recently launched in the default project?

Troubleshooting

401 Unauthorized
  • Verify the access token is correct and hasn't expired
  • Ensure the token hasn't been revoked in LaunchDarkly settings
  • Check that the token was copied completely (tokens start with api-)
403 Forbidden
  • Verify the token has the Reader role or equivalent permissions
  • Check that custom role restrictions aren't blocking project access
Project or Flag Not Found
  • Verify the project key is correct (keys are case-sensitive)
  • Ensure the flag exists in the specified project
  • Check that the token has access to the project
Rate Limiting
  • LaunchDarkly allows 160 requests per 15 minutes
  • The read-only tools are unlikely to hit this limit during normal investigation
  • If rate limited, wait a few minutes and retry