
Custom Metrics
This walks you through the full lifecycle of custom business metrics in LaunchDarkly: creating metric definitions via API, tracking events through the SDK, and querying results. It's built for measuring things like conversion rates, task success, user satisfaction, or revenue impact from your configs. The skill includes API key auto-detection from Claude's MCP config or environment variables, handles required fields like successCriteria and unit for numeric metrics, and gives you concrete tracking patterns for common scenarios. You'll need a LaunchDarkly API token with writer permissions. It's experimental but covers the practical stuff you'd actually need to instrument custom metrics beyond LaunchDarkly's built-in ones.
- skills.sh installs
- 1.3K
- GitHub stars
- 19
- last updated
- Jul 14, 2026
Install
$ npx -y skills add launchdarkly/agent-skills --skill custom-metrics --agent claude-codeInstalls into .claude/skills of the current project.
Files
Custom Metrics for Configs
Full lifecycle management of custom business metrics: create metric definitions with the MCP server, track events via SDK, retrieve metric data, and manage metrics programmatically.
Prerequisites
- LaunchDarkly AI SDK initialized (see
sdk-install). The SDK readsLD_SDK_KEYfrom the environment. - The remotely hosted LaunchDarkly MCP server configured in your environment
- A LaunchDarkly API token with the
writerrole, only to update or delete metrics, or for scripts that can't use MCP - Understanding of built-in agent metrics (see
built-in-metrics)
API Access
Use the LaunchDarkly MCP server tools wherever one exists: they authenticate via OAuth and need no token. Create metrics with create-metric, check that events are arriving with get-metric-events, read definitions with get-metrics, and change or remove them with update-metric and delete-metric. For scripts that can't use MCP, ask the user to paste an API access token for this session and substitute it for {api_token} in the examples below. Do not search environment variables, .env files, or agent/MCP config files for credentials.
Metrics Lifecycle Overview
Sponsors
Details
- Repository
- github.com/launchdarkly/agent-skills
- Category
- AI & Agent Building
- First seen
- Jul 14, 2026
More from launchdarkly/agent-skills
All 41- Migrate1.3K
- Online Evals1.3K
- Projects1.3K
- Snippets1.3K
- Tools1.3K
- Launchdarkly Flag Command1K
- Onboarding3.3K
- Launchdarkly Flag Cleanup2.5K
- Launchdarkly Flag Create2.5K
- Launchdarkly Flag Discovery2.5K
- Launchdarkly Flag Targeting2.5K
- Aiconfig Create2.3K
- Aiconfig Projects2.3K
- Aiconfig Tools2.3K
- Aiconfig Update2.3K
- Aiconfig Variations2.3K
- Launchdarkly Metric Choose2.3K
- Launchdarkly Metric Create2.3K
- Launchdarkly Metric Instrument2.3K
- Aiconfig Online Evals2.2K
- Aiconfig Targeting2.2K
- Aiconfig Ai Metrics2K
- Aiconfig Custom Metrics2K
- Aiconfig Migrate2K