# Statsig MCP for AI Agents AI Agent Connect

> Statsig MCP lets you manage feature flags, dynamic configurations, and product experiments directly through your AI agent. You can create gates, fetch config values, and log events without switching tabs. It turns your AI into a hands-on operator for your Statsig project, making it easier to control app behavior and roll out new features on the fly.

## Overview
- **Category:** developer-tools
- **Price:** Free
- **Endpoint:** https://edge.vinkius.com/vk_preview_ZEX4bsyQXMNxXPnw9oDygkK22SmvaLyaVC4MgykQ/ai-agent-connect
- **Tags:** feature-flags, ab-testing, product-experimentation, dynamic-config, statsig

## Description

This Connector connects your Statsig project to your AI agent so you can handle feature rollouts and product experiments through a simple conversation. Instead of hunting through a dashboard to toggle flags or check configuration values, you just tell your agent what to do. You can verify if a feature is active for a specific user, create new dynamic configurations, or log custom events for your analytics in seconds. It removes the friction of context switching between your workspace and your product management tools. By using this with the Vinkius catalog, you're putting the power of real-time configuration directly into your agent's hands. You can manage your entire product lifecycle without leaving your current environment. Whether you're adjusting a rollout percentage for a new release or checking the status of a complex experiment, your agent handles the heavy lifting. It's about getting things done faster, maintaining your focus, and making your product updates feel like a natural part of your conversation. No more tab-switching, no more manual entry errors, just direct control over your application's behavior. For a product manager, this means checking a gate status in the middle of a meeting without having to share your screen and navigate a complex UI. For a developer, it means verifying that a specific configuration is being served to a test user without having to manually run curl commands or check logs. It turns your AI into a functional operator that understands your project's specific rules and goals.

## Tools

### list_gates
Lists all feature gates in your project. Use this to get a bird's eye view of your active gates.

### get_config
Fetches configuration values for a specific config or experiment. This helps you see the exact JSON being served.

### get_dynamic_config
Reads a specific dynamic config. Use this to inspect the details of a single configuration.

### get_gate
Reads a specific feature gate. This lets you see the current rules and settings for a single gate.

### get_layer
Fetches parameter values from a layer. This is useful for seeing how layers affect your evaluations.

### log_event
Logs custom events for analytics. This sends real-time data to your Statsig dashboard for tracking.

### list_dynamic_configs
Shows all dynamic configs in your project. Use this to see what configurations are currently active.

### check_gate
Evaluates feature gates for a specific user. This tells you if a user can see a specific feature right now.

### create_dynamic_config
Creates a new dynamic config. Use this to set up new app behaviors without deploying code.

### create_gate
Creates a new feature gate. This lets you start a new rollout or experiment immediately.

### delete_gate
Deletes a feature gate. Use this to clean up old gates once a feature is fully launched.

### update_gate
Updates an existing feature gate. Use this to change rollout percentages or target rules on the fly.

## Prompt Examples

**Prompt:** 
```
Is the 'new_ui_beta' gate active for user_442?
```

**Response:** 
```
| Gate Name | Status | User ID |
| :--- | :--- | :--- |
| new_ui_beta | **Open** (True) | user_442 |

I've checked the gate for you. The user has access to the beta UI.
```

**Prompt:** 
```
List all our active gates.
```

**Response:** 
```
I've retrieved the current gates for your project:

* **ai_beta_access**
* **dark_mode_v2**
* **new_checkout_flow**
```

**Prompt:** 
```
Create a new gate for 'summer_sale' with a description of 'Testing 20% off' for 10% of users.
```

**Response:** 
```
The feature gate **summer_sale** has been successfully created.

* **Description**: Testing 20% off
* **Rollout**: 10% of users
* **Status**: Active
```

## Capabilities

### Toggle feature gates
Check if a specific feature is active for a user.

### Create new configs
Add dynamic configurations to your project via chat.

### Fetch configuration values
Get the current JSON for a specific config or experiment.

### Log custom events
Send real-time data to your dashboard for analytics.

### List all project gates
See every active gate in your project at once.

### Update existing gates
Modify the rules of a feature gate on the fly.

### Delete old gates
Remove gates from your project once you are finished with them.

## Use Cases

### Quick Rollout Check
A PM wants to know if a new checkout flow is live for a specific VIP user. They ask the agent to check_gate for that user ID.

### Emergency Config Update
A dev notices a bug in a dynamic config and needs to change a JSON value. They use create_dynamic_config to push a fix immediately.

### Data Validation
A data scientist needs to confirm that a specific event is being captured. They ask the agent to log_event for a test action.

### Cleanup Task
An engineer is cleaning up a project and needs to remove 10 old gates. They ask the agent to delete_gate for each one.

## Benefits

- Stop context switching by managing feature gates and dynamic configs directly in your chat or IDE.
- Speed up rollouts with create_gate and update_gate to change user access rules instantly.
- Verify your production logic using check_gate to see exactly what a user sees without manual testing.
- Keep your analytics accurate by using log_event to send custom data points to your dashboard from your tools.
- Simplify config management with list_dynamic_configs to see every active setup in your project at a glance.
- Reduce deployment risk by using get_config to inspect JSON values before they hit your production environment.

## How It Works

The bottom line is you get a natural language interface for your entire product rollout strategy.

1. Connect your Statsig project to Vinkius and grab your keys.
2. Input your Server Secret Key and Console API Key into your AI client.
3. Ask your agent to list gates, check statuses, or create new configs.

## Frequently Asked Questions

**What can I do with the Statsig MCP?**
You can manage feature flags, dynamic configurations, and product experiments through a natural conversation. It lets your AI agent perform actions like creating gates, updating rollout rules, and fetching configuration values.

**Can I create new feature gates using this?**
Yes, you can use your AI agent to create new gates immediately. Just describe the gate name and rollout rules in your chat.

**How do I check if a user sees a feature?**
You can ask your agent to check a specific gate for any user ID. It will return a clear status of whether that user has access to the feature.

**Does this help with A/B testing?**
Yes, it helps you manage the configurations and experiments that drive your A/B tests. You can inspect and update these parameters without leaving your chat.

**Does the Statsig MCP work with Claude or Cursor?**
Yes, it works with any MCP-compatible client, including Claude, Cursor, Windsurf, and VS Code.

**Can I log events for my analytics?**
Yes, you can ask your agent to log custom events. This sends real-time data to your analytics dashboard for tracking and metric calculation.

**What is the difference between the Server Secret Key and the Console API Key?**
The Server Secret Key is used for evaluation tools like `check_gate` and `get_config`. The Console API Key is required for management actions like `list_gates` or `create_gate`.

**How do I evaluate a gate for a specific user?**
Use the `check_gate` tool. You must provide the `gateName` and a `user` JSON object containing at least a `userID` (e.g., `{"userID": "123"}`).

**Can I log custom events for analytics?**
Yes, use the `log_event` tool to send an array of event objects including name, value, and user metadata to Statsig for real-time metric calculation.