Janee API Security
MCP server that sits between AI agents and APIs. Agents request access, Janee makes the call with the real credentials, agents never see the secrets.
Janee ๐
Secrets management for AI agents via MCP
The Problem
AI agents need API access to be useful. The current approach is to give them your keys and hope they behave.
- ๐ Agents have full access to Stripe, Gmail, databases
- ๐ No audit trail of what was accessed or why
- ๐ซ No kill switch when things go wrong
- ๐ One prompt injection away from disaster
The Solution
Janee is an MCP server that manages API secrets for AI agents:
- Store your API keys โ encrypted locally in
~/.janee/ - Run
janee serveโ starts MCP server - Agent requests access โ via
executeMCP tool - Janee injects the real key โ agent never sees it
- Everything is logged โ full audit trail
Your keys stay on your machine. Agents never see them. You stay in control.
Configure Once, Use Everywhere
Set up your APIs in Janee once:
services:
stripe:
baseUrl: https://api.stripe.com
auth: { type: bearer, key: sk_live_xxx }
github:
baseUrl: https://api.github.com
auth: { type: bearer, key: ghp_xxx }
openai:
baseUrl: https://api.openai.com
auth: { type: bearer, key: sk-xxx }
Now every agent that connects to Janee can use them:
- Claude Desktop โ access your APIs
- Cursor โ access your APIs
- OpenClaw โ access your APIs
- Any MCP client โ access your APIs
No more copying keys between tools. No more "which agent has which API configured?" Add a new agent? It already has access to everything. Revoke a key? Update it once in Janee.
One config. Every agent. Full audit trail.
Quick Start
Install
npm install -g @true-and-useful/janee
Initialize
janee init
This creates ~/.janee/config.yaml with example services.
Add Services
Option 1: Interactive (recommended for first-time users)
janee add
Janee will guide you through adding a service:
Service name: stripe
Base URL: https://api.stripe.com
Auth type (bearer/hmac/headers): bearer
API key: sk_live_xxx
โ Added service "stripe"
Create a capability for this service? (Y/n): y
Capability name (default: stripe):
TTL (e.g., 1h, 30m): 1h
Auto-approve? (Y/n): y
โ Added capability "stripe"
Done! Run 'janee serve' to start.
Option 2: Edit config directly
Edit ~/.janee/config.yaml:
services:
stripe:
baseUrl: https://api.stripe.com
auth:
type: bearer
key: sk_live_xxx
capabilities:
stripe:
service: stripe
ttl: 1h
autoApprove: true
Start the MCP server
janee serve
Use with your agent
Agents that support MCP (Claude Desktop, Cursor, OpenClaw) can now call the execute tool to make API requests through Janee:
// Agent calls the execute tool
execute({
service: "stripe",
method: "GET",
path: "/v1/balance",
reason: "User asked for account balance"
})
Janee decrypts the key, makes the request, logs everything, and returns the response.
OpenClaw Integration
If you're using OpenClaw, install the plugin for native tool support:
npm install -g @true-and-useful/janee
janee init
# Edit ~/.janee/config.yaml with your services
# Install the OpenClaw plugin
openclaw plugins install @true-and-useful/janee-openclaw
Enable in your agent config:
{
agents: {
list: [{
id: "main",
tools: { allow: ["janee"] }
}]
}
}
Your agent now has these tools:
janee_list_servicesโ Discover available APIsjanee_executeโ Make API requests through Janee
The plugin spawns janee serve automatically. All requests are logged to ~/.janee/logs/.
See docs/OPENCLAW.md for full integration guide.
MCP Tools
Janee exposes two MCP tools:
| Tool | Description |
|---|---|
list_services | Discover available APIs and their policies |
execute | Make an API request through Janee |
Agents discover what's available, then call APIs through Janee. Same audit trail, same protection.
Configuration
Config lives in ~/.janee/config.yaml:
server:
host: localhost
services:
stripe:
baseUrl: https://api.stripe.com
auth:
type: bearer
key: sk_live_xxx # encrypted at rest
github:
baseUrl: https://api.github.com
auth:
type: bearer
key: ghp_xxx
capabilities:
stripe:
service: stripe
ttl: 1h
autoApprove: true
stripe_sensitive:
service: stripe
ttl: 5m
requiresReason: true
Services = Real APIs with real keys
Capabilities = What agents can request, with policies
Request Policies
Control exactly what requests each capability can make using rules:
capabilities:
stripe_readonly:
service: stripe
ttl: 1h
rules:
allow:
- GET *
deny:
- POST *
- PUT *
- DELETE *
stripe_billing:
service: stripe
ttl: 15m
requiresReason: true
rules:
allow:
- GET *
- POST /v1/refunds/*
- POST /v1/invoices/*
deny:
- POST /v1/charges/* # Can't charge cards
- DELETE *
How rules work:
denypatterns are checked first โ explicit deny always wins- Then
allowpatterns are checked โ must match to proceed - No rules defined โ allow all (backward compatible)
- Rules defined but no match โ denied by default
Pattern format: METHOD PATH
GET *โ any GET requestPOST /v1/charges/*โ POST to /v1/charges/ and subpaths* /v1/customersโ any method to /v1/customersDELETE /v1/customers/*โ DELETE any customer
This makes security real: Even if an agent lies about its "reason", it can only access the endpoints the policy allows. Enforcement happens server-side.
CLI Reference
janee init # Set up ~/.janee/ with example config
janee add # Add a service (interactive)
janee add stripe -u https://api.stripe.com -k sk_xxx # Add with args
janee remove <service> # Remove a service
janee list # List configured services
janee serve # Start MCP server
janee logs # View audit log
janee logs -f # Tail audit log
janee sessions # List active sessions
janee revoke <id> # Kill a session
Non-interactive Setup (for AI agents)
AI agents can't respond to interactive prompts. Use --*-from-env flags to read credentials from environment variables โ this keeps secrets out of the agent's context window:
# Bearer auth (Stripe, OpenAI, etc.)
janee add stripe -u https://api.stripe.com --auth-type bearer --key-from-env STRIPE_KEY
# HMAC auth (Bybit)
janee add bybit --auth-type hmac-bybit --key-from-env BYBIT_KEY --secret-from-env BYBIT_SECRET
# HMAC auth with passphrase (OKX)
janee add okx --auth-type hmac-okx --key-from-env OKX_KEY --secret-from-env OKX_SECRET --passphrase-from-env OKX_PASS
When all required credentials are provided via flags, Janee:
- Never opens readline (no hanging on stdin)
- Auto-creates a capability with sensible defaults (1h TTL, auto-approve)
You can also edit ~/.janee/config.yaml directly if you prefer.
How It Works
โโโโโโโโโโโโโโโ โโโโโโโโโโโโ โโโโโโโโโโโ
โ AI Agent โโโโโโโถโ Janee โโโโโโโถโ Stripe โ
โ โ MCP โ MCP โ HTTP โ API โ
โโโโโโโโโโโโโโโ โโโโโโโโโโโโ โโโโโโโโโโโ
โ โ
No key Injects key
+ logs request
- Agent calls
executeMCP tool with service, method, path - Janee looks up service config, decrypts the real key
- Makes HTTP request to real API with key
- Logs: timestamp, service, method, path, status
- Returns response to agent
Agent never touches the real key.
Security
- Encryption: Keys stored with AES-256-GCM
- Local only: MCP server over stdio (no network exposure)
- Audit log: Every request logged to
~/.janee/logs/ - Sessions: Time-limited, revocable
- Kill switch:
janee revokeor delete config
Integrations
Works with any agent that speaks MCP:
- OpenClaw โ Native plugin (
@true-and-useful/janee-openclaw) - Cursor โ Setup guide
- Claude Code โ Setup guide
- Codex CLI โ Setup guide
- Any MCP client โ just point at
janee serve
Contributing
We welcome contributions! See CONTRIBUTING.md for guidelines.
License
MIT โ Built by True and Useful LLC
Stop giving AI agents your keys. Start controlling access. ๐
Related Servers
NWC MCP Server
Control a Lightning wallet using Nostr Wallet Connect (NWC).
norikae-mcp
๐ ไนๆๆกๅ MCP - ไนใๆใๆค็ดข / Norikae MCP - Japanese train route search using Yahoo! Transit
TestDino
TestDino MCP enhances your AI assistant with advanced tooling and diagnostic insights. It enables your AI assistant perform test-run analysis, see root-cause detection, and identify recurring failure patterns.
MCP Claude Spotify
An integration for Claude Desktop to interact with Spotify using the Model Context Protocol (MCP).
IzmirMCP
Access real-time public transit data for ฤฐzmir, including vehicle positions, arrivals, and schedules from ฤฐZBAN and ESHOT.
Uber
Book Uber rides directly through your AI assistant.
APOLOGY-AS-A-SERVICE
A live Model Context Protocol (MCP) server that provides context-aware crisis communication for AI agents
Wordle MCP
Fetches daily Wordle solutions for a specific date via the Wordle API.
Bitnovo Pay
MCP server for Bitnovo Pay integration with AI agents. Provides cryptocurrency payment capabilities through Bitnovo Pay API. Features include payment creation, status checking, QR code generation, and webhook management with support for multiple tunnel providers (ngrok, zrok, manual).
Currency And Oil
Zenrus MCP Server ๆฏไธไธชๆไพๅฎๆถ่ดงๅธๆฑ็ๅ็ณๆฒนไปทๆ ผ็ๆๅกๅจ๏ผๆฏๆๅค็ง่ฎก็ฎๅ่ฝ๏ผ้็จไบ้่ๅๆๅ่ชๅจๅๅทฅๅ ท้ๆใ