Statsig MCP server for AI agents

Live

API KEY

FEATURE FLAGS

Developer Tools

Statsig gives your agent feature flag and experiment control: create, update, and launch feature gates, run and ship experiments, manage dynamic configs and segments, and read Pulse results, metrics, and audit logs.

  • Per-user credentials: each call uses the actual user's API key, never a shared bot.
  • Encrypted per-tenant vault: AES-256, resolved at request time, never in LLM context.
  • Scoped before every call: pre-call scope check, 90-day SIEM-exportable audit chain.
Statsig
agent · Acme Q3
Run
How is the new-checkout experiment doing on conversion?
S
statsig_get_experiment_pulse_results
146ms
Experimentation agent
The test group shows a 3.2% lift in checkout conversion, statistically significant. Revenue per user is flat.
Sources: 1 experiment, Pulse results
statsig
2 metrics
18:29
Message Claude...

Tools your experimentation agent reaches for on Statsig, scoped per user.

CALL ANY TOOL
96 tools for feature flags and experiments in Statsig: create, update, enable, disable, and launch gates, start, ship, and abandon experiments, manage dynamic configs, segments, layers, and holdouts, and read Pulse results, metrics, and audit logs.
statsig_abandon_experiment
Abandon experiment
Abandon an experiment, stopping it without shipping any group. Returns a confirmation message. Use statsig_abandon_experiment to stop a failed or invalid test. Use statsig_ship_experiment to launch a winning group.
Parameters
Name
Type
Required
Description
decision_reason
string
Required
Reason for abandoning, recorded on the experiment. Example: Logging bug invalidated the results.
experiment_id
string
Required
ID of the experiment, as returned by statsig_list_experiments. Example: checkout_button_color_test.
statsig_add_gate_overrides
Add gate overrides
statsig_archive_dynamic_config
Archive dynamic config
statsig_create_dynamic_config
Create dynamic config
statsig_create_holdout
Create holdout
statsig_delete_dynamic_config
Delete dynamic config
statsig_delete_gate
Delete gate
statsig_disable_dynamic_config
Disable dynamic config
statsig_enable_gate
Enable gate
statsig_get_alert
Get alert
statsig_get_event
Get event
statsig_get_experiment_overrides
Get experiment overrides
statsig_get_gate_checks
Get gate checks
statsig_get_holdout
Get holdout
statsig_get_metric_value
Get metric value
statsig_get_release_pipeline
Get release pipeline
statsig_list_alerts
List alerts
statsig_list_dynamic_config_rules
List dynamic config rules
statsig_list_environments
List environments
statsig_list_experiments
List experiments
statsig_list_gates
List gates
statsig_list_metric_experiments
List metric experiments
statsig_list_metrics
List metrics
statsig_list_segment_ids
List segment ids
statsig_list_target_apps
List target apps
statsig_remove_segment_ids
Remove segment ids
statsig_schedule_experiment_start
Start schedule experiment
statsig_update_dynamic_config
Update dynamic config
statsig_update_experiment_overrides
Update experiment overrides
statsig_update_holdout
Update holdout

For more tools, view docs.

Build your Agent
Same auth pattern across LangChain, OpenAI, Anthropic, and Google ADK.
Python · LlamaIndex
import { ScalekitClient } from "@scalekit-sdk/node";
import { createReactAgent } from "@langchain/langgraph/prebuilt";

const sk = new ScalekitClient(env.SCALEKIT_ENV_URL, env.SCALEKIT_CLIENT_ID, env.SCALEKIT_CLIENT_SECRET);

// Statsig tools scoped to this user
const { tools } = await sk.tools.listScopedTools("user_123", {
  filter: { connectionNames: ["statsig"], toolNames: [
    "statsig_list_gates",
    "statsig_get_experiment_pulse_results",
    "statsig_disable_gate"] },
  pageSize: 100,
});

const agent = createReactAgent({ llm, tools });
await agent.invoke({ messages: [{ role: "user", content: "Show Pulse results for the new-checkout experiment" }] });
import OpenAI from "openai";
import { ScalekitClient } from "@scalekit-sdk/node";

const sk = new ScalekitClient(env.SCALEKIT_ENV_URL, env.SCALEKIT_CLIENT_ID, env.SCALEKIT_CLIENT_SECRET);
const openai = new OpenAI();

const { tools } = await sk.tools.listScopedTools("user_123", {
  filter: { connectionNames: ["statsig"] }, pageSize: 100,
});

const res = await openai.chat.completions.create({
  model: "gpt-5",
  messages: [{ role: "user", content: "Show Pulse results for the new-checkout experiment" }],
  tools,
});

// Execute the tool call with the user's vaulted Statsig API key
await sk.tools.executeTool(res.choices[0].message.tool_calls[0], "user_123");
import Anthropic from "@anthropic-ai/sdk";
import { ScalekitClient } from "@scalekit-sdk/node";

const sk = new ScalekitClient(env.SCALEKIT_ENV_URL, env.SCALEKIT_CLIENT_ID, env.SCALEKIT_CLIENT_SECRET);
const anthropic = new Anthropic();

const { tools } = await sk.tools.listScopedTools("user_123", {
  filter: { connectionNames: ["statsig"] }, pageSize: 100,
});

const msg = await anthropic.messages.create({
  model: "claude-sonnet-5",
  max_tokens: 1024,
  messages: [{ role: "user", content: "Show Pulse results for the new-checkout experiment" }],
  tools,
});

// Tool call runs with the user's vaulted Statsig API key
await sk.tools.executeTool(msg.content, "user_123");
import { Agent } from "@google/adk/agents";
import { ScalekitClient } from "@scalekit-sdk/node";

const sk = new ScalekitClient(env.SCALEKIT_ENV_URL, env.SCALEKIT_CLIENT_ID, env.SCALEKIT_CLIENT_SECRET);

const { tools } = await sk.tools.listScopedTools("user_123", {
  filter: { connectionNames: ["statsig"] }, pageSize: 100,
});

const agent = new Agent({
  name: "experimentation_agent",
  model: "gemini-2.5-pro",
  instruction: "Statsig tools scoped to this user",
  tools,
});

await agent.run("Show Pulse results for the new-checkout experiment");
Try these prompts
Copy any prompt into your agent. Each maps directly to a Statsig tool. Click to copy, paste into your agent, done.
Feature gates
Copy the prompt
Copied
Create a feature gate called new_onboarding for 10% of users.
Copy the prompt
Copied
Disable the checkout_v2 gate now.
Copy the prompt
Copied
Has the legacy_search gate been checked in production in the last 7 days?
Experiments
Copy the prompt
Copied
Show Pulse results for the new-checkout experiment.
Copy the prompt
Copied
Ship the test group of the pricing-page experiment.
Copy the prompt
Copied
List experiments that are currently active.
Configs and audit
Copy the prompt
Copied
Update the default value of the rate_limits dynamic config.
Copy the prompt
Copied
Add these 20 user IDs to the beta-testers segment.
Copy the prompt
Copied
Show audit log entries for gate changes made yesterday.
SEE HOW AUTH WORKS
Each user connects their own Statsig API key once, and Scalekit sends it with every call. Keys stay vaulted, every call is scope checked, and every action is logged.
1
Authorize
Your user connects
Statsig
once. We tie it to their identity and the meetings they approved — no shared bot account, no org-wide access
Who:
user ‘A’
when:
Once per user
access:
Limited to user
2
Store
Their
Statsig
token lives in a vault scoped to them. User A's meetings are never reachable by an agent acting for user B, even on the same connection
vault:
encrypted
scope:
per-user
tokens:
auto-refreshed
3
Resolve
When your agent calls a
Statsig
tool, we fetch the right token server-side. It never touches your agent, never appears in the LLM context, never shows up in your logs
speed:
~40ms
check:
before every call
seen by:
nobody
4
Audit
Every
Statsig
tool call is logged — who triggered it, which meeting was fetched, what came back. 90 days of history, tied to the user who authorized it
history:
90 days
export:
SIEM-ready
logged:
every call
Test other agents
See the same per-user auth pattern across other developer tools and analytics connectors.
Engineering Teams
DevOps assistant agent
Polls GitHub for failing checks and stale PRs, opens Linear issues for the ones that need work, and posts a daily digest to Slack. It acts as the engineer, not a shared service account.
Engineering Teams
Engineering standup agent
Pulls commits from GitHub and GitLab, tracks issue movement in Jira, and posts a per-engineer standup brief to Slack. Each engineer's activity is read on their own delegated OAuth.
Test other agents
See the same per-user auth pattern across other developer tools and analytics connectors.
ENGINEERING
DevOps assistant agent
Poll GitHub for failing checks and stale pull requests, open Linear issues for the ones that need work, and digest to Slack.
ENGINEERING
Engineering standup agent
Pull commits from GitHub and GitLab, track Jira issue movement, and post a per-engineer standup brief to Slack.
Why Scalekit
Secure your agent's access. Connectors ship in minutes
01.
Shared tokens break per-user analytics
A shared Statsig API key looks fine in a demo. In production every gate change looks like one service account, and you cannot tell which user triggered it. Scalekit resolves the credential of the actual user who triggered the agent, never a shared bot.
// shared key
audit → bot_service_account

// scalekit
audit → user_abc ✓
02.
Authentication is not authorization
03.
Multi-tenancy is architectural
04.
Statsig today. Ten connectors tomorrow.
“Our agents act across Salesforce, Gong, Google Drive, and more, on behalf of every customer. Scalekit behind the scenes meant we can keep adding tools without ever rebuilding how credentials or tool calling work.”
Venu Madhav Kattagoni
Head of Engineering / Von
FAQs
Frequently Asked Questions
Does the agent access Statsig as the user or through a shared API key?
As the user. Each user connects their own Statsig API key once, and Scalekit sends it with every call. Gate changes, experiment launches, and config edits the agent makes are attributed to that user in your audit trail, not a shared service account.
Where is the Statsig API key stored?
In Scalekit's managed AES-256 token vault, namespaced per tenant. To rotate it, the user reconnects with a new API key. Revocation is a single dashboard action. Credentials never appear in prompts, logs, or LLM context.
Can I limit what the agent does in Statsig?
Yes. Filter by tool name in listScopedTools to expose only what you want, for example read and Pulse tools without statsig_delete_gate and statsig_delete_experiment, which permanently remove a gate or experiment. Archive tools retire them while keeping history. Scalekit also enforces scope checks before every API call.
What happens when a user revokes Statsig access?
The connection is invalidated on the next tool call. Subsequent requests for that user fail closed with a clear error. Other users in the tenant remain unaffected. The event is logged for audit.
Which Statsig project does the agent work in?
The project the user's Statsig API key belongs to. statsig_get_project returns that project's ID and name, and gate, experiment, config, and metric tools act inside it. Team tools such as statsig_list_teams need Statsig Enterprise.
Start in your coding agent
Up and running in one command
Install the Scalekit skill in your editor of choice. Connector, auth, tools, prompt, all wired up
Claude Code REPL
/plugin marketplace add scalekit-inc/claude-code-authstack
/plugin install agentkit@scalekit-auth-stack
Cursor Code REPL
# ~/.cursor/mcp.json
{
""mcpServers"": {
""statsig"": {
""url"": ""https://mcp.scalekit.com/statsig"",
""headers"": { ""Authorization"": ""Bearer $SCALEKIT_TOKEN"" }
}
}
}
Codex Code REPL
# ~/.codex/config.toml
[mcp_servers.statsig]
url = ""https://mcp.scalekit.com/statsig""
auth_env = ""SCALEKIT_TOKEN""
Copilot Code REPL
# .vscode/mcp.json
{
""servers"": {
""statsig"": {
""url"": ""https://mcp.scalekit.com/statsig"",
""type"": ""http""
}
}
}