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:
| Capability | Description |
|---|---|
| List Projects | Discover LaunchDarkly projects in your account |
| List Environments | View environment topology (production, staging, test) |
| List Feature Flags | Scan flags with filtering by environment, tag, and state |
| Inspect Flag Details | Deep-dive into targeting rules, variations, and prerequisites |
| Check Flag Status | Determine 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
- Log in to LaunchDarkly
- Go to Organization settings → Authorization → Access tokens
- Click Create token
- Select the Reader role
- Check This is a service token for long-term integration use
- Copy the generated token
2
Add Integration in Autoheal
- Go to Integrations in Autoheal
- Click LaunchDarkly
- 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.
| Permission | Why It's Needed |
|---|---|
| Read projects | Discover project structure |
| Read environments | Understand environment topology |
| Read feature flags | Inspect flag state and targeting rules |
| Read flag statuses | Check 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