secure-mcp-gateway MCP Server
Enkrypt AI Secure MCP Gateway — authentication, guardrails, caching, and observability for Model Context Protocol servers.
secure-mcp-gateway scores 47 (Fair), licensed Apache-2.0 and written in Python. It installs as a local process. It does not declare tools yet. Filed under Monitoring. GitHub shows 60 stars. Package registries report about 39 downloads a week. Install configs are generated for 10 clients. Being listed in the registry is not the same as being vendor-official.
Fair trust
47 of 100 from six public signals. Nobody can buy a point.
- OSI-style license: apache-2.0.
License, quality and maintenance
Where the 47 comes from
0 + 20 + 6 + 10 + 4 + 7 = 47. Each factor is capped, so no single signal can carry a listing.
Active in the official MCP registry, plus a known vendor namespace.
Registry: 0 of 30 points.How recently the repository saw a commit or release.
Maintenance: 20 of 20 points.GitHub stars and weekly downloads, on a log scale.
Popularity: 6 of 20 points.A clear, OSI-style open-source license.
License: 10 of 10 points.Not archived, a secure install path, a pinned version.
Security: 4 of 10 points.A real summary, a README with depth, listed tools.
Docs: 7 of 10 points.Install
Pick your client, copy the config, paste it in.
Needs Cursor or VS Code installed on this device. The button opens the app and asks you to confirm before it adds the server.
{ "mcpServers": { "enkryptai-secure-mcp-gateway": { "command": "uvx", "args": [ "secure-mcp-gateway" ] } }}
Environment variables
This server does not declare environment variables.
Tools
All capabilitiesTools show up when the registry metadata or the repository README lists them. Public READMEs are read directly. A GitHub token is used only when one is already configured.
About
Enkrypt AI Secure MCP Gateway

📖 Featured Blog Post: Learn how the Secure MCP Gateway prevents top attacks and vulnerabilities in our latest blog:
How Enkrypt's Secure MCP Gateway and MCP Scanner Prevent Top Attacks
Discover real-world attack scenarios, security best practices, and how our gateway protects your AI applications.
Overview
This Secure MCP Gateway is built with authentication, automatic tool discovery, caching, and guardrail enforcement.
It sits between your MCP client and MCP servers. So, by it's nature it itself also acts as an MCP server as well as an MCP client :)
When your MCP client connects to the Gateway, it acts as an MCP server. When the Gateway connects to the actual MCP server, it acts as an MCP client.
-
Also see:
- CLI-Commands-Reference.md for the list of commands and their usage
- API-Reference.md for the list of API endpoints and their usage
- MCP Gateway Setup Notebook for a complete walkthrough of all the essential commands
Table of Contents
- 1. Features 🚀
- 2. High level steps of how the MCP Gateway works 🪜
- 3. Prerequisites 🧩
- 4. Gateway Setup 👨💻
- 5. (Optional) OpenTelemetry Setup 📊
- 6. Verify Installation and check the files generated ✅
- 7. Edit the Gateway config as needed ✏️
- 8. CLI Quick Start Guide 🖥️
- 9. (Optional) Add GitHub MCP Server to the Gateway 🤖
- 9.1 (Optional) Connect to MCP Servers with OAuth 🔐
- 10. (Optional) Protect GitHub MCP Server and Test Echo Server 🔒
- 11. Recommendations for using Guardrails 💡
- 12. Other tools available 🔧
- 13. (Optional) Sandbox Isolation 🛡️
- 14. Deployment Patterns 🪂
- 15. Uninstall the Gateway 🗑️
- 16. Troubleshooting 🕵
- 17. Known Issues being worked on 🏗️
- 18. Known Limitations ⚠️
- 19. Contribute 🤝
- 20. Testing 🧪
- 21. License
1. Features

Below are the list of features Enkrypt AI Secure MCP Gateway provides:
-
Authentication: We use Unique Key to authenticate with the Gateway. We also use Enkrypt API Key if you want to protect your MCPs with Enkrypt Guardrails. Additionally, a secure
admin_apikey(256-character random string) is automatically generated at the root of the config for administrative REST API operations. (Whenplugins.auth.providerisenkrypt,admin_apikeyis optional — the Enkrypt cloudapi_keydoubles as the admin credential for most REST endpoints. The cache-flush endpoint specifically uses a stricter org-id-gated policy under cloud auth — see Hot-Reload Auth Policy.) -
Ease of use: You can configure all your MCP servers either locally in
enkrypt_mcp_config.jsonor — better yet for teams and production — in Enkrypt cloud (runsecure-mcp-gateway generate-config --provider enkrypt). The cloud owns the server list, guardrail policies, andcommon_overrides, and the gateway pulls them at request time with a 5-minute TTL. -
Dynamic Tool Discovery: The Gateway discovers tools from the MCP servers dynamically and makes them available to the MCP client
-
Restrict Tool Invocation: If you don't want all tools to be accessible of a an MCP server, you can restrict them by explicitly mentioning the tools in the Gateway config so that only the allowed tools are accessible to the MCP client
-
Caching: We cache the user gateway config and tools discovered from various MCP servers locally or in an external cache server like KeyDB if configured to improve performance
-
Guardrails: You can configure guardrails for each MCP server in Enkrypt both on input side (before sending the request to the MCP server) and output side (after receiving the response from the MCP server)
-
Logging: We log every request and response from the Gateway locally in your MCP logs and also forward them to Enkrypt (Coming soon) for monitoring. This enables you to see all the calls made in your account, servers used, tools invoked, requests blocked, etc.
-
Sandbox Isolation: MCP servers can be launched inside isolated sandbox environments (Docker, Podman, or microVMs) so that a compromised or malicious server cannot access the host filesystem, network, or other resources. Each sandbox is ephemeral — created per session and destroyed when done.
1.1 Guardrails

Input Protection: Topic detection, NSFW filtering, toxicity detection, injection attack prevention, keyword detection, policy violation detection, bias detection, and PII redaction (More coming soon like system prompt protection, copyright protection, etc.)
Output Protection: All input protections plus adherence checking and relevancy validation (More coming soon like hallucination detection, etc.) We also auto unredact the response if it was redacted on input.
1.2 Concepts
-
MCP Config is an array of MCP servers like
mcp_server_1,mcp_server_2,mcp_server_3etc.- Each config has a unique ID
-
User is a user of the gateway with unique email and ID
-
A project is a collection of users that share an MCP Config
- Project has a name and unique ID
- The MCP Config can be updated or can be pointed to a different config by the Admin
- Users can be added to multiple projects
-
An API Key is created for a user and project combination
- A user can have different API Keys for different projects
- This API Key is used to authenticate the user and identify the right project and MCP Config
-
See 6.5 Example config file generated and 7. Edit the Gateway config as needed for schema reference
2. High level steps of how the MCP Gateway works

-
Your MCP client connects to the Secure MCP Gateway server with API Key (handled by
src/secure_mcp_gateway/gateway.py). -
Gateway server fetches the gateway config from either the local
enkrypt_mcp_config.jsonfile (plugins.auth.provider = "local_apikey") or the remote Enkrypt cloud athttps://api.enkryptai.com/mcp-gateway/get-gateway-config(plugins.auth.provider = "enkrypt"). See §14.5 Gateway Config Schema for both shapes.- It caches the config locally or in an external cache server like KeyDB if configured to improve performance.
-
If input guardrails are enabled, request is validated before the tool call (handled by
src/secure_mcp_gateway/guardrail.py).- Request is blocked if it violates any of the configured guardrails and the specific detector is configured to block.
-
Requests are forwarded to the Gateway Client (handled by
src/secure_mcp_gateway/client.py). -
The Gateway client forwards the request to the appropriate MCP server (handled by
src/secure_mcp_gateway/client.py). -
The MCP server processes the request and returns the response to the Gateway client.
-
If it was a discover tools call, the Gateway client caches the tools locally or in an external cache server like KeyDB if configured. It then forwards the response to the Gateway server.
-
The Gateway server receives the response from the Gateway client and if output guardrails are enabled, it validates the response against the configured guardrails (handled by
src/secure_mcp_gateway/guardrail.py).- Response is blocked if it violates any of the configured guardrails and the specific detector is configured to block.
-
The Gateway server forwards the response back to the MCP client if everything is fine.
3. Prerequisites
-
Git 2.43or higher -
Python 3.11or higher installed on your system and is accessible from the command line using eitherpythonorpython3command -
pip 25.0.1or higher is installed on your system and is accessible from the command line using eitherpiporpython -m pipcommand -
uv 0.7.9or higher is installed on your system and is accessible from the command line using eitheruvorpython -m uvcommand
-
Check if Python, pip and uv are installed
-
If any of the below commands fail, please refer the respective documentation to install them properly
# ------------------
# Python
# ------------------
python --version
# Example output
Python 3.13.3
# If not, install python from their website and run the version check again
# ------------------
# pip
# ------------------
pip --version
# Example output
pip 25.0.1 from C:\Users\PC\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.13_qbz5n2kfra8p0\LocalCache\local-packages\Python313\site-packages\pip (python 3.13)
# If not, try the following and run the version check again
python -m ensurepip
# ------------------
# uv
# ------------------
uv --version
# Or run with "python -m" if uv is not found directly
# If this works, use "python -m" before all uv commands from now on
python -m uv --version
# Example output
uv 0.7.9 (13a86a23b 2025-05-30)
# If not, try the following and run the version check again
python -m pip install uv
-
Install Claude Desktop as the MCP Client from their website if you haven't already and login to it
- If you are using Linux and cannot run any unofficial version of Claude Desktop, you can use any supported MCP Client to test the Gateway. If it does not support mcp cli
mcp installcommand, then go through the scripts code and run the commands supported manually.
- If you are using Linux and cannot run any unofficial version of Claude Desktop, you can use any supported MCP Client to test the Gateway. If it does not support mcp cli
-
Any other dependencies required for the MCP servers we want to proxy requests to
-
Follow the instructions of the respective MCP server to install its dependencies
-
Like
Node.js,npx,docker, etc.
-
-
(Optional) A cache server like KeyDB installed and running (If you want to cache externally and not locally)
If you want to protect your MCPs with Enkrypt Guardrails, you need to do the following:
-
Create a new account if you don't have one. It's free! 🆓 No credit card required 💳🚫
-
An
ENKRYPT_API_KEYwhich you can get from Enkrypt Dashboard Settings -
To protect your MCPs with Guardrails, you can use the default sample Guardrail
Sample Airline Guardrailto get started or you can create your own custom Guardrail -
To configure custom Guardrails, you need to either login to Enkrypt AI App or use the APIs/SDK
4. Gateway Setup
4.1 Local Installation with pip
4.1.1 Download and Install the Package
-
Activate a virtual environment
python -m venv .secure-mcp-gateway-venv # Activate the virtual environment # On Windows .secure-mcp-gateway-venv\Scripts\activate # On Linux/macOS source .secure-mcp-gateway-venv/bin/activate # Run the below to exit the virtual environment later if needed deactivate -
Install the package. For more info see https://pypi.org/project/secure-mcp-gateway/
pip install secure-mcp-gateway
4.1.2 Run the Generate Command
-
This generates the config file at
~/.enkrypt/enkrypt_mcp_config.jsonon macOS and%USERPROFILE%\.enkrypt\enkrypt_mcp_config.jsonon Windowssecure-mcp-gateway generate-config
⚠️ Re-running on an existing config?
generate-configrefuses to clobber an existing file by default — it exits withINFO: Config file already exists at <path>. ... use --overwrite flag.Add--overwriteto regenerate (a timestamped.bkp.<YYYYMMDD_HHMMSS>backup is written next to the original first). The flag also works with--provider enkryptbelow.secure-mcp-gateway generate-config --overwrite
Choosing an auth provider at generation time
The default command emits the full local-apikey schema — a sample echo server, a default project, a user, and an auto-generated gateway API key — everything you need to boot offline. If you instead want the gateway to source its servers/projects/users from Enkrypt cloud, generate the minimal cloud-backed config:
secure-mcp-gateway generate-config --provider enkrypt
This writes a much shorter file containing only:
enkrypt_config.api_keyandbase_url(you fill in the apikey)plugins.auth.provider = "enkrypt"with agateway_nameplaceholderplugins.guardrails.provider = "enkrypt"plugins.telemetry.provider = "opentelemetry"(OTLP gRPC tolocalhost:4317, matching the local-apikey default and the bundled Prometheus/Grafana/Jaeger/Loki stack — setconfig.enabled: falseif you don't have a collector running)- Two commonly-tweaked entries under
common_mcp_gateway_config(enkrypt_log_level,enkrypt_gateway_cache_expiration_minutes)
No local mcp_configs / projects / users / apikeys blocks — the cloud owns those. After generation, edit the file and set:
enkrypt_config.api_key→ your Enkrypt cloud apikeyplugins.auth.config.gateway_name→ thesaved_nameof the gateway you created in the Enkrypt console
gateway_nameis the one value that can also arrive per request, as theX-Enkrypt-MCP-Gatewayheader from the MCP client, so that a single gateway process can serve several cloud gateways. When it is set in the config the config wins. Full config-key and header reference: §7.1 Enkrypt cloud auth provider and gateway headers.
The shipped reference file is src/secure_mcp_gateway/example_enkrypt_cloud_config.json — same shape the CLI generates. Use it as a template for hand-written configs.
Supported flag values:
--provider | Behavior |
|---|---|
local_apikey (default) | Full local schema with sample echo server, project, user, API key, and a root-level admin_apikey for the REST admin API. Backward-compatible with all pre-2.2 setups. |
enkrypt | Minimal cloud-backed schema. No admin_apikey baked in — the cloud enkrypt_config.api_key doubles as the admin credential (see Admin API Key Authentication). |
Initializing Enkrypt Secure MCP Gateway
Initializing Enkrypt Secure MCP Gateway Common Utilities Module
Initializing Enkrypt Secure MCP Gateway Module
--------------------------------
SYSTEM INFO:
Using Python interpreter: C:\Users\PC\Documents\GitHub\EnkryptAI\secure-mcp-gateway\.secure-mcp-gateway-venv\Scripts\python.exe
Python version: 3.13.3 (tags/v3.13.3:6280bb5, Apr 8 2025, 14:47:33) [MSC v.1943 64 bit (AMD64)]
Current working directory: C:\Users\PC\Documents\GitHub\EnkryptAI\secure-mcp-gateway
PYTHONPATH: Not set
--------------------------------
Installing dependencies...
All dependencies installed successfully.
Initializing Enkrypt Secure MCP Gateway Client Module
Initializing Enkrypt Secure MCP Gateway Guardrail Module
Error: Gateway key is required. Please update your mcp client config and try again.
Getting Enkrypt Common Configuration
config_path: C:\Users\PC\.enkrypt\enkrypt_mcp_config.json
example_config_path: C:\Users\PC\Documents\GitHub\EnkryptAI\secure-mcp-gateway\.secure-mcp-gateway-venv\Lib\site-packages\secure_mcp_gateway\example_enkrypt_mcp_config.json
No enkrypt_mcp_config.json file found. Defaulting to example_enkrypt_mcp_config.json
--------------------------------
ENKRYPT_GATEWAY_KEY: ****NULL
enkrypt_log_level: info
is_debug_log_level: False
enkrypt_base_url: https://api.enkryptai.com
enkrypt_api_key: ****_KEY
enkrypt_tool_cache_expiration: 4
enkrypt_gateway_cache_expiration: 24
enkrypt_mcp_use_external_cache: False
enkrypt_async_input_guardrails_enabled: False
--------------------------------
External Cache is not enabled. Using local cache only.
Initializing Enkrypt Secure MCP Gateway CLI Module
Generated default config at C:\Users\PC\.enkrypt\enkrypt_mcp_config.json
INFO: Initializing Enkrypt Secure MCP Gateway CLI Module v2.2.0
INFO: HOME_DIR: C:\Users\PC
INFO: GATEWAY_PY_PATH: C:\Users\PC\Documents\GitHub\EnkryptAI\secure-mcp-gateway\.secure-mcp-gateway-venv\Lib\site-packages\secure_mcp_gateway\gateway.py
INFO: ECHO_SERVER_PATH: C:\Users\PC\Documents\GitHub\EnkryptAI\secure-mcp-gateway\.secure-mcp-gateway-venv\Lib\site-packages\secure_mcp_gateway\bad_mcps\echo_oauth_mcp.py
INFO: PICKED_CONFIG_PATH: C:\Users\PC\.enkrypt\enkrypt_mcp_config.json
INFO: Generating minimal Enkrypt-cloud configuration (plugins.auth.provider=enkrypt)...
SUCCESS: Generated config at C:\Users\PC\.enkrypt\enkrypt_mcp_config.json
INFO: Before starting the gateway, edit the file and set:
* enkrypt_config.api_key (replace 'YOUR_ENKRYPT_API_KEY' with your Enkrypt cloud apikey)
* plugins.auth.config.gateway_name (replace 'your-gateway-saved-name' with the saved_name of the gateway you created in Enkrypt cloud)
Notice the cloud variant skips the long boot/dependency banner — it's a fast, focused command. The two
INFO: Before starting…lines are the operator-must-edit checklist; the gateway will fail with a 401 from Enkrypt cloud on first boot if you skip them.
4.1.3 Example of the generated config file
Note: The examples below show the full schema emitted by
secure-mcp-gateway generate-config(default--provider local_apikey). Every field is included so you can compare your generated file 1:1. Theoauth_configblock ships disabled ("enabled": false) — its keys are placeholders you only need to fill in if a server uses OAuth. Thetimeout_settingsblock holds the per-operation timeouts the gateway uses internally; defaults are sane and rarely need editing.
- This is an example of the default configuration file generated by the CLI on macOS:
{
"admin_apikey": "AUTO_GENERATED_256_CHAR_KEY",
"enkrypt_config": {
"api_key": "YOUR_ENKRYPT_API_KEY",
"base_url": "https://api.enkryptai.com"
},
"common_mcp_gateway_config": {
"enkrypt_log_level": "INFO",
"enkrypt_mcp_use_external_cache": false,
"enkrypt_cache_host": "localhost",
"enkrypt_cache_port": 6379,
"enkrypt_cache_db": 0,
"enkrypt_cache_password": null,
"enkrypt_tool_cache_expiration": 4,
"enkrypt_gateway_cache_expiration": 24,
"enkrypt_gateway_cache_expiration_minutes": 5,
"enkrypt_config_watcher_poll_seconds": 2.0,
"enkrypt_async_input_guardrails_enabled": false,
"enkrypt_async_output_guardrails_enabled": false,
"timeout_settings": {
"default_timeout": 90,
"guardrail_timeout": 390,
"auth_timeout": 30,
"tool_execution_timeout": 360,
"discovery_timeout": 540,
"cache_timeout": 15,
"connectivity_timeout": 6,
"escalation_policies": {
"warn_threshold": 0.8,
"timeout_threshold": 1.0,
"fail_threshold": 1.2
}
}
},
"plugins": {
"auth": { "provider": "local_apikey", "config": {} },
"guardrails": { "provider": "enkrypt", "config": {} },
"telemetry": {
"provider": "opentelemetry",
"config": {
"enabled": true,
"url": "http://localhost:4317",
"insecure": true
}
}
},
"mcp_configs": {
"fcbd4508-1432-4f13-abb9-c495c946f638": {
"mcp_config_name": "default_config",
"common_overrides": {
"server_tools_guardrails_config": {
"enabled": false,
"guardrail_name": "Sample Airline Guardrail",
"block": [
"policy_violation",
"injection_attack",
"topic_detector",
"nsfw",
"toxicity",
"pii",
"keyword_detector",
"bias",
"sponge_attack"
]
}
},
"mcp_config": [
{
"server_name": "echo_server",
"description": "Simple Echo Server",
"config": {
"command": "python",
"args": [
"/Users/user/enkryptai/secure-mcp-gateway/venv/lib/python3.13/site-packages/secure_mcp_gateway/bad_mcps/echo_mcp.py"
]
},
"oauth_config": {
"enabled": false,
"is_remote": false,
"OAUTH_VERSION": "2.1",
"OAUTH_GRANT_TYPE": "client_credentials",
"OAUTH_CLIENT_ID": "your-client-id",
"OAUTH_CLIENT_SECRET": "your-client-secret",
"OAUTH_TOKEN_URL": "https://auth.example.com/oauth/token",
"OAUTH_AUDIENCE": "https://api.example.com",
"OAUTH_ORGANIZATION": "your-org-id",
"OAUTH_SCOPE": "read write",
"OAUTH_RESOURCE": "https://resource.example.com",
"OAUTH_TOKEN_EXPIRY_BUFFER": 300,
"OAUTH_USE_BASIC_AUTH": true,
"OAUTH_ENFORCE_HTTPS": true,
"OAUTH_TOKEN_IN_HEADER_ONLY": true,
"OAUTH_VALIDATE_SCOPES": true,
"OAUTH_USE_MTLS": false,
"OAUTH_CLIENT_CERT_PATH": null,
"OAUTH_CLIENT_KEY_PATH": null,
"OAUTH_CA_BUNDLE_PATH": null,
"OAUTH_REVOCATION_URL": null,
"OAUTH_ADDITIONAL_PARAMS": {},
"OAUTH_CUSTOM_HEADERS": {}
},
"tools": {},
"denied_tools": [],
"input_guardrails_config": {
"enabled": false,
"guardrail_name": "Sample Airline Guardrail",
"additional_config": {
"pii_redaction": false
},
"block": [
"policy_violation",
"injection_attack",
"topic_detector",
"nsfw",
"toxicity",
"pii",
"keyword_detector",
"bias",
"sponge_attack"
]
},
"output_guardrails_config": {
"enabled": false,
"guardrail_name": "Sample Airline Guardrail",
"additional_config": {
"relevancy": false,
"hallucination": false,
"adherence": false
},
"block": [
"policy_violation",
"injection_attack",
"topic_detector",
"nsfw",
"toxicity",
"pii",
"keyword_detector",
"bias",
"sponge_attack"
]
}
}
]
}
},
"projects": {
"3c09f06c-1f0d-4153-9ac5-366397937641": {
"project_name": "default_project",
"mcp_config_id": "fcbd4508-1432-4f13-abb9-c495c946f638",
"users": [
"6469a670-1d64-4da5-b2b3-790de21ac726"
],
"created_at": "2025-07-16T17:02:00.406877"
}
},
"users": {
"6469a670-1d64-4da5-b2b3-790de21ac726": {
"email": "default@example.com",
"created_at": "2025-07-16T17:02:00.406902"
}
},
"apikeys": {
"2W8UupCkazk4SsOcSu_1hAbiOgPdv0g-nN9NtfZyg-rvYGat": {
"project_id": "3c09f06c-1f0d-4153-9ac5-366397937641",
"user_id": "6469a670-1d64-4da5-b2b3-790de21ac726",
"created_at": "2025-07-16T17:02:00.406905"
}
}
}
- This is an example of the default configuration file generated by the CLI on Windows:
{
"admin_apikey": "AUTO_GENERATED_256_CHAR_KEY",
"enkrypt_config": {
"api_key": "YOUR_ENKRYPT_API_KEY",
"base_url": "https://api.enkryptai.com"
},
"common_mcp_gateway_config": {
"enkrypt_log_level": "INFO",
"enkrypt_mcp_use_external_cache": false,
"enkrypt_cache_host": "localhost",
"enkrypt_cache_port": 6379,
"enkrypt_cache_db": 0,
"enkrypt_cache_password": null,
"enkrypt_tool_cache_expiration": 4,
"enkrypt_gateway_cache_expiration": 24,
"enkrypt_gateway_cache_expiration_minutes": 5,
"enkrypt_config_watcher_poll_seconds": 2.0,
"enkrypt_async_input_guardrails_enabled": false,
"enkrypt_async_output_guardrails_enabled": false,
"timeout_settings": {
"default_timeout": 90,
"guardrail_timeout": 390,
"auth_timeout": 30,
"tool_execution_timeout": 360,
"discovery_timeout": 540,
"cache_timeout": 15,
"connectivity_timeout": 6,
"escalation_policies": {
"warn_threshold": 0.8,
"timeout_threshold": 1.0,
"fail_threshold": 1.2
}
}
},
"plugins": {
"auth": { "provider": "local_apikey", "config": {} },
"guardrails": { "provider": "enkrypt", "config": {} },
"telemetry": {
"provider": "opentelemetry",
"config": {
"enabled": true,
"url": "http://localhost:4317",
"insecure": true
}
}
},
"mcp_configs": {
"fcbd4508-1432-4f13-abb9-c495c946f638": {
"mcp_config_name": "default_config",
"common_overrides": {
"server_tools_guardrails_config": {
"enabled": false,
"guardrail_name": "Sample Airline Guardrail",
"block": [
"policy_violation",
"injection_attack",
"topic_detector",
"nsfw",
"toxicity",
"pii",
"keyword_detector",
"bias",
"sponge_attack"
]
}
},
"mcp_config": [
{
"server_name": "echo_server",
"description": "Simple Echo Server",
"config": {
"command": "python",
"args": [
"C:\\Users\\<User>\\Documents\\GitHub\\EnkryptAI\\secure-mcp-gateway\\.secure-mcp-gateway-venv\\Lib\\site-packages\\secure_mcp_gateway\\bad_mcps\\echo_mcp.py"
]
},
"oauth_config": {
"enabled": false,
"is_remote": false,
"OAUTH_VERSION": "2.1",
"OAUTH_GRANT_TYPE": "client_credentials",
"OAUTH_CLIENT_ID": "your-client-id",
"OAUTH_CLIENT_SECRET": "your-client-secret",
"OAUTH_TOKEN_URL": "https://auth.example.com/oauth/token",
"OAUTH_AUDIENCE": "https://api.example.com",
"OAUTH_ORGANIZATION": "your-org-id",
"OAUTH_SCOPE": "read write",
"OAUTH_RESOURCE": "https://resource.example.com",
"OAUTH_TOKEN_EXPIRY_BUFFER": 300,
"OAUTH_USE_BASIC_AUTH": true,
"OAUTH_ENFORCE_HTTPS": true,
"OAUTH_TOKEN_IN_HEADER_ONLY": true,
"OAUTH_VALIDATE_SCOPES": true,
"OAUTH_USE_MTLS": false,
"OAUTH_CLIENT_CERT_PATH": null,
"OAUTH_CLIENT_KEY_PATH": null,
"OAUTH_CA_BUNDLE_PATH": null,
"OAUTH_REVOCATION_URL": null,
"OAUTH_ADDITIONAL_PARAMS": {},
"OAUTH_CUSTOM_HEADERS": {}
},
"tools": {},
"denied_tools": [],
"input_guardrails_config": {
"enabled": false,
"guardrail_name": "Sample Airline Guardrail",
"additional_config": {
"pii_redaction": false
},
"block": [
"policy_violation",
"injection_attack",
"topic_detector",
"nsfw",
"toxicity",
"pii",
"keyword_detector",
"bias",
"sponge_attack"
]
},
"output_guardrails_config": {
"enabled": false,
"guardrail_name": "Sample Airline Guardrail",
"additional_config": {
"relevancy": false,
"hallucination": false,
"adherence": false
},
"block": [
"policy_violation",
"injection_attack",
"topic_detector",
"nsfw",
"toxicity",
"pii",
"keyword_detector",
"bias",
"sponge_attack"
]
}
}
]
}
},
"projects": {
"3c09f06c-1f0d-4153-9ac5-366397937641": {
"project_name": "default_project",
"mcp_config_id": "fcbd4508-1432-4f13-abb9-c495c946f638",
"users": [
"6469a670-1d64-4da5-b2b3-790de21ac726"
],
"created_at": "2025-07-16T17:02:00.406877"
}
},
"users": {
"6469a670-1d64-4da5-b2b3-790de21ac726": {
"email": "default@example.com",
"created_at": "2025-07-16T17:02:00.406902"
}
},
"apikeys": {
"2W8UupCkazk4SsOcSu_1hAbiOgPdv0g-nN9NtfZyg-rvYGat": {
"project_id": "3c09f06c-1f0d-4153-9ac5-366397937641",
"user_id": "6469a670-1d64-4da5-b2b3-790de21ac726",
"created_at": "2025-07-16T17:02:00.406905"
}
}
}
- This is the complete file emitted by
secure-mcp-gateway generate-config --provider enkrypt. Same shape on macOS, Linux, and Windows — only the on-disk path differs (~/.enkrypt/...vs%USERPROFILE%\.enkrypt\...).
{
"enkrypt_config": {
"api_key": "YOUR_ENKRYPT_API_KEY",
"base_url": "https://api.enkryptai.com",
"org_id": "YOUR_ENKRYPT_ORG_ID"
},
"plugins": {
"auth": {
"provider": "enkrypt",
"config": {
"gateway_name": "your-gateway-saved-name",
"gateway_version": "v1",
"cache_ttl_seconds": 300
}
},
"guardrails": {
"provider": "enkrypt",
"config": {}
},
"telemetry": {
"provider": "opentelemetry",
"config": {
"enabled": true,
"url": "http://localhost:4317",
"insecure": true
}
}
},
"common_mcp_gateway_config": {
"enkrypt_log_level": "INFO",
"enkrypt_gateway_cache_expiration_minutes": 5
}
}
What's intentionally NOT here (cloud owns these):
- No
mcp_configs/projects/users/apikeysblocks — the gateway resolves them from Enkrypt cloud via/mcp-gateway/get-gateway-configon every authenticated request. - No root-level
admin_apikey— the cloudenkrypt_config.api_keydoubles as the admin credential for most REST endpoints (see Admin API Key Authentication). The cache-flush endpoint specifically requiresenkrypt_config.org_idto be set and validates incoming apikeys againstGET /consumer-info.org_id— see Cache-flush authorization policy. If you want a separate admin secret for non-flush endpoints, add"admin_apikey": "<256-char-key>"at the root. - No legacy
enkrypt_use_remote_mcp_config/enkrypt_remote_mcp_gateway_*flags — those only drive the deprecatedlocal_apikeyremote-fetch fallback. Theenkryptprovider has its own cleaner cloud-config flow inEnkryptAuthProvider.
Two operator-must-edit values before first boot:
enkrypt_config.api_key→ your real Enkrypt cloud apikeyplugins.auth.config.gateway_name→ thesaved_nameof the gateway you created in the Enkrypt console
The shipped reference file at src/secure_mcp_gateway/example_enkrypt_cloud_config.json is byte-for-byte identical to this example.
4.1.4 Install the Gateway for Claude Desktop
-
Run the following command to install the gateway for Claude:
secure-mcp-gateway install --client claude-desktop -
This will register Enkrypt Secure MCP Gateway with Claude Desktop.
-
NOTE: Please restart Claude Desktop after installation
Initializing Enkrypt Secure MCP Gateway
Initializing Enkrypt Secure MCP Gateway Common Utilities Module
Initializing Enkrypt Secure MCP Gateway Module
--------------------------------
SYSTEM INFO:
Using Python interpreter: C:\Users\PC\Documents\GitHub\EnkryptAI\secure-mcp-gateway\.secure-mcp-gateway-venv\Scripts\python.exe
Python version: 3.13.3 (tags/v3.13.3:6280bb5, Apr 8 2025, 14:47:33) [MSC v.1943 64 bit (AMD64)]
Current working directory: C:\Users\PC\Documents\GitHub\EnkryptAI\secure-mcp-gateway
PYTHONPATH: Not set
--------------------------------
Installing dependencies...
All dependencies installed successfully.
Initializing Enkrypt Secure MCP Gateway Client Module
Initializing Enkrypt Secure MCP Gateway Guardrail Module
Error: Gateway key is required. Please update your mcp client config and try again.
Getting Enkrypt Common Configuration
config_path: C:\Users\PC\.enkrypt\enkrypt_mcp_config.json
example_config_path: C:\Users\PC\Documents\GitHub\EnkryptAI\secure-mcp-gateway\.secure-mcp-gateway-venv\Lib\site-packages\secure_mcp_gateway\example_enkrypt_mcp_config.json
Loading enkrypt_mcp_config.json file...
--------------------------------
ENKRYPT_GATEWAY_KEY: ****NULL
enkrypt_log_level: info
is_debug_log_level: False
enkrypt_base_url: https://api.enkryptai.com
enkrypt_api_key: ****_KEY
enkrypt_tool_cache_expiration: 4
enkrypt_gateway_cache_expiration: 24
enkrypt_mcp_use_external_cache: False
enkrypt_async_input_guardrails_enabled: False
--------------------------------
External Cache is not enabled. Using local cache only.
Initializing Enkrypt Secure MCP Gateway CLI Module
CONFIG_PATH: C:\Users\PC\.enkrypt\enkrypt_mcp_config.json
GATEWAY_PY_PATH: C:\Users\PC\Documents\GitHub\EnkryptAI\secure-mcp-gateway\.secure-mcp-gateway-venv\Lib\site-packages\secure_mcp_gateway\gateway.py
client name from args: claude-desktop
Successfully installed gateway for claude-desktop
Path to gateway is incorrect. Modifying the path to gateway in claude_desktop_config.json file...
Path to gateway modified in claude_desktop_config.json file
Please restart Claude Desktop to use the gateway.
4.1.5 Example of the Claude Desktop Config after installation
The env-var shape depends on your gateway's
plugins.auth.provider. Same dichotomy as the Cursor section below:
local_apikeyprovider (default) → three env vars:ENKRYPT_GATEWAY_KEY+ENKRYPT_PROJECT_ID+ENKRYPT_USER_IDenkryptcloud provider → single env var:ENKRYPT_APIKEY
-
~/Library/Application Support/Claude/claude_desktop_config.json— local_apikey provider (default){ "mcpServers": { "Enkrypt Secure MCP Gateway": { "command": "mcp", "args": [ "run", "/Users/user/enkryptai/secure-mcp-gateway/venv/lib/python3.13/site-packages/secure_mcp_gateway/gateway.py" ], "env": { "ENKRYPT_GATEWAY_KEY": "2W8UupCkazk4SsOcSu_1hAbiOgPdv0g-nN9NtfZyg-rvYGat", "ENKRYPT_PROJECT_ID": "3c09f06c-1f0d-4153-9ac5-366397937641", "ENKRYPT_USER_ID": "6469a670-1d64-4da5-b2b3-790de21ac726" } } } } -
~/Library/Application Support/Claude/claude_desktop_config.json— enkrypt cloud provider (when generated with--provider enkrypt){ "mcpServers": { "Enkrypt Secure MCP Gateway": { "command": "mcp", "args": [ "run", "/Users/user/enkryptai/secure-mcp-gateway/venv/lib/python3.13/site-packages/secure_mcp_gateway/gateway.py" ], "env": { "ENKRYPT_APIKEY": "your-enkrypt-cloud-apikey" } } } }
-
%USERPROFILE%\AppData\Roaming\Claude\claude_desktop_config.json— local_apikey provider (default){ "mcpServers": { "Enkrypt Secure MCP Gateway": { "command": "mcp", "args": [ "run", "C:\\Users\\<User>\\Documents\\GitHub\\EnkryptAI\\secure-mcp-gateway\\.secure-mcp-gateway-venv\\Lib\\site-packages\\secure_mcp_gateway\\gateway.py" ], "env": { "ENKRYPT_GATEWAY_KEY": "2W8UupCkazk4SsOcSu_1hAbiOgPdv0g-nN9NtfZyg-rvYGat", "ENKRYPT_PROJECT_ID": "3c09f06c-1f0d-4153-9ac5-366397937641", "ENKRYPT_USER_ID": "6469a670-1d64-4da5-b2b3-790de21ac726" } } } } -
%USERPROFILE%\AppData\Roaming\Claude\claude_desktop_config.json— enkrypt cloud provider (when generated with--provider enkrypt){ "mcpServers": { "Enkrypt Secure MCP Gateway": { "command": "mcp", "args": [ "run", "C:\\Users\\<User>\\Documents\\GitHub\\EnkryptAI\\secure-mcp-gateway\\.secure-mcp-gateway-venv\\Lib\\site-packages\\secure_mcp_gateway\\gateway.py" ], "env": { "ENKRYPT_APIKEY": "your-enkrypt-cloud-apikey" } } } }
4.1.6 Install the Gateway for Cursor
-
Run the CLI Install Command for Cursor
secure-mcp-gateway install --client cursor -
This automatically updates your ~/.cursor/mcp.json (on Windows it is at: %USERPROFILE%.cursor\mcp.json) with the correct entry.
-
Although it is not usually required to restart, if you see it in loading state for a long time, please restart Cursor
The env-var shape depends on your gateway's
plugins.auth.provider. The install command writes whichever shape matches:
Provider Env vars written Used for local_apikey(default)ENKRYPT_GATEWAY_KEY+ENKRYPT_PROJECT_ID+ENKRYPT_USER_IDLooking up the local apikey + project + user in your local config enkrypt(cloud)ENKRYPT_APIKEYSingle cloud apikey; project/user come from Enkrypt cloud Both
mcp.jsonshapes below are valid — pick the one matching how you generated your config. See Section 4.1.2 for the--provider enkryptflag.
-
~/.cursor/mcp.json— local_apikey provider (default){ "mcpServers": { "Enkrypt Secure MCP Gateway": { "command": "mcp", "args": [ "run", "/Users/user/enkryptai/secure-mcp-gateway/venv/lib/python3.13/site-packages/secure_mcp_gateway/gateway.py" ], "env": { "ENKRYPT_GATEWAY_KEY": "2W8UupCkazk4SsOcSu_1hAbiOgPdv0g-nN9NtfZyg-rvYGat", "ENKRYPT_PROJECT_ID": "3c09f06c-1f0d-4153-9ac5-366397937641", "ENKRYPT_USER_ID": "6469a670-1d64-4da5-b2b3-790de21ac726" } } } } -
~/.cursor/mcp.json— enkrypt cloud provider (when generated with--provider enkrypt){ "mcpServers": { "Enkrypt Secure MCP Gateway": { "command": "mcp", "args": [ "run", "/Users/user/enkryptai/secure-mcp-gateway/venv/lib/python3.13/site-packages/secure_mcp_gateway/gateway.py" ], "env": { "ENKRYPT_APIKEY": "your-enkrypt-cloud-apikey" } } } }
-
%USERPROFILE%\.cursor\mcp.json— local_apikey provider (default){ "mcpServers": { "Enkrypt Secure MCP Gateway": { "command": "mcp", "args": [ "run", "C:\\Users\\<User>\\Documents\\GitHub\\EnkryptAI\\secure-mcp-gateway\\.secure-mcp-gateway-venv\\Lib\\site-packages\\secure_mcp_gateway\\gateway.py" ], "env": { "ENKRYPT_GATEWAY_KEY": "2W8UupCkazk4SsOcSu_1hAbiOgPdv0g-nN9NtfZyg-rvYGat", "ENKRYPT_PROJECT_ID": "3c09f06c-1f0d-4153-9ac5-366397937641", "ENKRYPT_USER_ID": "6469a670-1d64-4da5-b2b3-790de21ac726" } } } }If
mcpis not on your PATH (e.g. you didn't activate the venv), you can wrap it throughuvinstead:"command": "uv", "args": ["run", "--with", "mcp[cli]", "mcp", "run", "<full path to gateway.py>"]The
secure-mcp-gateway install --client cursorcommand always emits the bare"mcp"form above — switch to theuvwrapper only if you hit amcp: command not founderror. -
%USERPROFILE%\.cursor\mcp.json— enkrypt cloud provider (when generated with--provider enkrypt){ "mcpServers": { "Enkrypt Secure MCP Gateway": { "command": "mcp", "args": [ "run", "C:\\Users\\<User>\\Documents\\GitHub\\EnkryptAI\\secure-mcp-gateway\\.secure-mcp-gateway-venv\\Lib\\site-packages\\secure_mcp_gateway\\gateway.py" ], "env": { "ENKRYPT_APIKEY": "your-enkrypt-cloud-apikey" } } } }
4.1.7 Install the Gateway for Claude Code
Claude Code is Anthropic's CLI-based coding agent. It uses claude mcp add commands to configure MCP servers. Unlike Claude Desktop and Cursor which use JSON config files, Claude Code manages MCP servers through its own CLI.
Prerequisite: The
claudeCLI must be installed on your system. See Claude Code docs for installation.
Step 1: Install the gateway
secure-mcp-gateway install --client claude-code
This automatically:
- Reads the gateway credentials from your generated config (provider-aware):
local_apikeyprovider (default) → emits three--envflags:ENKRYPT_GATEWAY_KEY,ENKRYPT_PROJECT_ID,ENKRYPT_USER_IDenkryptcloud provider → emits a single--envflag:ENKRYPT_APIKEY(sourced fromenkrypt_config.api_key, or--apikey <key>if you pass it on the CLI)
- Runs
claude mcp addwith--transport stdioand the correct credentials and gateway path - Registers the server as
Enkrypt-Secure-MCP-Gatewaywith--scope user(available across all Claude Code projects)
Step 2: Verify the server was added
claude mcp list
You should see Enkrypt-Secure-MCP-Gateway in the list.
Step 3: Use the gateway in Claude Code
Launch Claude Code and try:
list all servers, get all tools available
Get your credentials from the generated enkrypt_mcp_config.json and the gateway path:
python -c "import secure_mcp_gateway.gateway; print(secure_mcp_gateway.gateway.__file__)"
Then add the gateway manually. The exact command depends on your gateway's plugins.auth.provider (see §4.1.2):
For local_apikey provider (default):
claude mcp add --transport stdio --env ENKRYPT_GATEWAY_KEY=YOUR_GATEWAY_KEY --env ENKRYPT_PROJECT_ID=YOUR_PROJECT_ID --env ENKRYPT_USER_ID=YOUR_USER_ID --scope user Enkrypt-Secure-MCP-Gateway -- mcp run /path/to/secure_mcp_gateway/gateway.py
For enkrypt cloud provider (when generated with --provider enkrypt):
claude mcp add --transport stdio --env ENKRYPT_APIKEY=YOUR_ENKRYPT_CLOUD_APIKEY --scope user Enkrypt-Secure-MCP-Gateway -- mcp run /path/to/secure_mcp_gateway/gateway.py
Note: The server name must use hyphens or underscores — Claude Code does not allow spaces in names.
4.2 Local Installation with git clone
4.2.1 Clone the repo, setup virtual environment and install dependencies
- Clone the repository:
git clone https://github.com/enkryptai/secure-mcp-gateway
cd secure-mcp-gateway
# ------------------
# Create a virtual environment
# ------------------
uv venv
# Example output
Using CPython 3.13.3 interpreter at: C:\Users\PC\AppData\Local\Microsoft\WindowsApps\PythonSoftwareFoundation.Python.3.13_qbz5n2kfra8p0\python.exe
Creating virtual environment at: .venv
Activate with: .venv\Scripts\activate
# ------------------
# Activate the virtual environment
# ------------------
# For 🍎 Linux/macOS, run the following
source ./.venv/Scripts/activate
# For 🪟 Windows, run the following
.\.venv\Scripts\activate
# After activating, you should see (enkrypt-secure-mcp-gateway) before the file path in the terminal
# Example:
# (enkrypt-secure-mcp-gateway) %USERPROFILE%\Documents\GitHub\EnkryptAI\secure-mcp-gateway>
# ------------------
# Install pip in the virtual environment
# ------------------
python -m ensurepip
# ------------------
# Install uv in the virtual environment
# ------------------
python -m pip install uv
- Synchronize Python dependencies for the checked-out project:
uv sync --frozen
uv sync installs and runs this repository checkout. It does not install the published PyPI package.
When CONDA_PREFIX is set, run uv sync --active --frozen. Conda owns the interpreter and Conda-only packages. pyproject.toml and uv.lock own PyPI dependencies.
- Verify mcp cli got installed successfully:
mcp version
# Example output
MCP version 1.9.2
4.2.2 Run the setup script
-
This script creates the config file at
~/.enkrypt/enkrypt_mcp_config.jsonon macOS and%USERPROFILE%\.enkrypt\enkrypt_mcp_config.jsonon Windows based onsrc/secure_mcp_gateway/example_enkrypt_mcp_config.jsonfile -
It replaces
UNIQUE_GATEWAY_KEYand otherUUIDswith auto generated values and also replacesDUMMY_MCP_FILE_PATHwith the actual path to the test MCP filebad_mcps/echo_mcp.py -
It also installs the MCP client in Claude Desktop
-
NOTE: Please restart Claude Desktop after running the setup script to see the Gateway running in Claude Desktop
# On 🍎 Linux/macOS run the below
cd scripts
chmod +x *.sh
./setup.sh
# On 🪟 Windows run the below
cd scripts
setup.bat
# Now restart Claude Desktop to see the Gateway running
-------------------------------
Setting up Enkrypt Secure MCP Gateway enkrypt_mcp_config.json config file
-------------------------------
1 file(s) copied.
Generated unique gateway key: WTZOpoU1mXJz8b_ZJQ42DuSXlQCSCtWOn3FX0jG8sO_FKYNJetjYEgSluvhtBN8_
Generated unique uuid: 7920749a-228e-47fe-a6a9-cd2d64a2283b
DUMMY_MCP_FILE_PATH: C:\Users\PC\Documents\GitHub\EnkryptAI\secure-mcp-gateway\src\secure_mcp_gateway\bad_mcps\echo_mcp.py
-------------------------------
Setup complete. Please check the enkrypt_mcp_config.json file in the ~\.enkrypt directory and update with your MCP server configs as needed.
-------------------------------
-------------------------------
Installing Enkrypt Secure MCP Gateway with gateway key and dependencies
-------------------------------
mcp is installed. Proceeding with installation...
ENKRYPT_GATEWAY_KEY: WTZOpoU1mXJz8b_ZJQ42DuSXlQCSCtWOn3FX0jG8sO_FKYNJetjYEgSluvhtBN8_
The system cannot find the path specified.
Package names only:
Dependencies string for the cli install command:
Running the cli install command: mcp install gateway.py --env-var ENKRYPT_GATEWAY_KEY=WTZOpoU1mXJz8b_ZJQ42DuSXlQCSCtWOn3FX0jG8sO_FKYNJetjYEgSluvhtBN8_
Initializing Enkrypt Secure MCP Gateway
Initializing Enkrypt Secure MCP Gateway Common Utilities Module
Initializing Enkrypt Secure MCP Gateway Module
--------------------------------
SYSTEM INFO:
Using Python interpreter: C:\Users\PC\Documents\GitHub\EnkryptAI\secure-mcp-gateway\.secure-mcp-gateway-venv\Scripts\python.exe
Python version: 3.13.3 (tags/v3.13.3:6280bb5, Apr 8 2025, 14:47:33) [MSC v.1943 64 bit (AMD64)]
Current working directory: C:\Users\PC\Documents\GitHub\EnkryptAI\secure-mcp-gateway\src\secure_mcp_gateway
PYTHONPATH: Not set
--------------------------------
Installing dependencies...
All dependencies installed successfully.
Initializing Enkrypt Secure MCP Gateway Client Module
Initializing Enkrypt Secure MCP Gateway Guardrail Module
Getting Enkrypt Common Configuration
config_path: C:\Users\PC\.enkrypt\enkrypt_mcp_config.json
example_config_path: C:\Users\PC\Documents\GitHub\EnkryptAI\secure-mcp-gateway\.secure-mcp-gateway-venv\Lib\site-packages\secure_mcp_gateway\example_enkrypt_mcp_config.json
Loading enkrypt_mcp_config.json file...
--------------------------------
ENKRYPT_GATEWAY_KEY: ****BN8_
enkrypt_log_level: info
is_debug_log_level: False
enkrypt_base_url: https://api.enkryptai.com
enkrypt_api_key: ****_KEY
enkrypt_tool_cache_expiration: 4
enkrypt_gateway_cache_expiration: 24
enkrypt_mcp_use_external_cache: False
enkrypt_async_input_guardrails_enabled: False
--------------------------------
External Cache is not enabled. Using local cache only.
Initializing Enkrypt Secure MCP Gateway Module
--------------------------------
SYSTEM INFO:
Using Python interpreter: C:\Users\PC\Documents\GitHub\EnkryptAI\secure-mcp-gateway\.secure-mcp-gateway-venv\Scripts\python.exe
Python version: 3.13.3 (tags/v3.13.3:6280bb5, Apr 8 2025, 14:47:33) [MSC v.1943 64 bit (AMD64)]
Current working directory: C:\Users\PC\Documents\GitHub\EnkryptAI\secure-mcp-gateway\src\secure_mcp_gateway
PYTHONPATH: Not set
--------------------------------
Installing dependencies...
All dependencies installed successfully.
Getting Enkrypt Common Configuration
config_path: C:\Users\PC\.enkrypt\enkrypt_mcp_config.json
example_config_path: C:\Users\PC\Documents\GitHub\EnkryptAI\secure-mcp-gateway\.secure-mcp-gateway-venv\Lib\site-packages\secure_mcp_gateway\example_enkrypt_mcp_config.json
Loading enkrypt_mcp_config.json file...
--------------------------------
ENKRYPT_GATEWAY_KEY: ****BN8_
enkrypt_log_level: info
is_debug_log_level: False
enkrypt_base_url: https://api.enkryptai.com
enkrypt_api_key: ****_KEY
enkrypt_tool_cache_expiration: 4
enkrypt_gateway_cache_expiration: 24
enkrypt_mcp_use_external_cache: False
enkrypt_async_input_guardrails_enabled: False
--------------------------------
External Cache is not enabled. Using local cache only.
[06/15/25 13:14:10] INFO Added server 'Enkrypt Secure MCP Gateway' to Claude config claude.py:137
INFO Successfully installed Enkrypt Secure MCP Gateway in Claude app cli.py:486
-------------------------------
Installation complete. Check the claude_desktop_config.json file as per the readme instructions and restart Claude Desktop.
-------------------------------
4.2.3 Setup Other MCP Clients
-
You can navigate to cursor's Global MCP file at
~/.cursor/mcp.jsonon Linux/macOS or%USERPROFILE%\.cursor\mcp.jsonon Windows- If you would like to use at a Project level place it inside your project. For details see Cursor's docs
-
You can also navigate to the file Via cursor's UI by clicking on
settingsgear icon on the top right
-
Click on
MCPand then click onAdd new global MCP serverwhich takes you to themcp.jsonfile
-
Example
mcp.jsonfile opened in the editor
-
Once the file is opened at Global or Project level, you can copy paste the same config we used in
Claude Desktop. For reference, you can refer to Installation - 6.2 Example MCP config file generated 📄- Be sure to use your own file that was generated by the
setupscript in Installation - 4.2.2 Run the setup script 📥. Please do not copy paste the example config file in this repo.
- Be sure to use your own file that was generated by the
-
See Verify Cursor section to verify the MCP server is running in Cursor
-
Claude Code uses its own CLI to manage MCP servers instead of JSON config files
-
Get your credentials from the generated
enkrypt_mcp_config.json(gateway key, project ID, user ID) -
Find the gateway.py path:
python -c "import secure_mcp_gateway.gateway; print(secure_mcp_gateway.gateway.__file__)" -
Add the gateway to Claude Code. The env vars differ by auth provider:
# For local_apikey provider (default) claude mcp add --transport stdio --env ENKRYPT_GATEWAY_KEY=YOUR_GATEWAY_KEY --env ENKRYPT_PROJECT_ID=YOUR_PROJECT_ID --env ENKRYPT_USER_ID=YOUR_USER_ID --scope user Enkrypt-Secure-MCP-Gateway -- mcp run /path/to/secure_mcp_gateway/gateway.py # For enkrypt cloud provider (generated with --provider enkrypt) claude mcp add --transport stdio --env ENKRYPT_APIKEY=YOUR_ENKRYPT_CLOUD_APIKEY --scope user Enkrypt-Secure-MCP-Gateway -- mcp run /path/to/secure_mcp_gateway/gateway.py -
Verify:
claude mcp list -
For detailed setup, see 4.1.7 Install the Gateway for Claude Code
4.3 Docker Installation
4.3.1 Build the Docker Image
docker build -t secure-mcp-gateway .
Tag your build so the
--dockerwrapper finds it. Starting in v2.2.0 thesecure-mcp-gateway --docker ...wrapper pullsenkryptai/secure-mcp-gateway:<your-host-CLI-version>by default (e.g.enkryptai/secure-mcp-gateway:2.2.0). Until that exact tag is published on Docker Hub, every--dockercommand fails withUnable to find image ... not found. Fix it once by tagging your local build to match (find your version withsecure-mcp-gateway --version):# Replace 2.2.0 with the output of `secure-mcp-gateway --version` docker tag secure-mcp-gateway:latest enkryptai/secure-mcp-gateway:2.2.0After this one command, every
secure-mcp-gateway --docker generate-config,--docker install --client X,--docker config list, etc. in the rest of §4.3 works without needing--docker-imageoverrides.
Truncated for readability. The image synchronizes dependencies from
uv.lock. First-time builds typically take 3–5 minutes depending on network and CPU. Subsequent rebuilds are mostly cached and complete in under 30s.
Verify the image landed:
docker images secure-mcp-gateway
# REPOSITORY TAG IMAGE ID CREATED SIZE
# secure-mcp-gateway latest 92d8c6b5714d 2 seconds ago 1.81GB
4.3.2 Generate the config file
- This creates a config file in the
~/.enkrypt/docker/enkrypt_mcp_config.jsonfile on macOS/Linux and%USERPROFILE%\.enkrypt\docker\enkrypt_mcp_config.jsonfile on Windows.
Quick shorthand — If you have the CLI installed locally via pip, you can use the
--dockerflag on any command and skip the verbose Docker syntax:secure-mcp-gateway --docker generate-config
Choosing an auth provider at generation time
Identical to the local install — see §4.1.2 → "Choosing an auth provider at generation time" for the full explanation. In short:
- Default (omit
--provider) → fulllocal_apikeyschema with a sample echo server, project, user, gateway API key, and root-leveladmin_apikey. Boots offline, no cloud dependency. --provider enkrypt→ minimal cloud-backed schema. After generating, edit the file and setenkrypt_config.api_key(your Enkrypt cloud apikey) andplugins.auth.config.gateway_name(the saved name of the gateway you created in the Enkrypt console). The cloud owns servers/projects/users/apikeys, so those blocks are absent.
Copy-paste commands (all OSes, using the --docker shorthand — works in bash, zsh, CMD, and PowerShell since the wrapper handles per-OS quoting internally):
# 1. Default — local_apikey (offline, no cloud dependency)
secure-mcp-gateway --docker generate-config
# 2. Cloud-backed — enkrypt provider (requires container CLI >= v2.2.0; see warning below)
secure-mcp-gateway --docker generate-config --provider enkrypt
# 3. Re-generate over an existing file (adds timestamped .bkp.YYYYMMDD_HHMMSS next to the original)
secure-mcp-gateway --docker generate-config --overwrite
secure-mcp-gateway --docker generate-config --provider enkrypt --overwrite
# 4. If the default image tag isn't on Docker Hub yet, point at a locally-built image:
# docker build -t secure-mcp-gateway . # one-time, from this repo root
secure-mcp-gateway --docker --docker-image secure-mcp-gateway generate-config --provider enkrypt --overwrite
After the command succeeds, the file lands at:
- macOS/Linux:
~/.enkrypt/docker/enkrypt_mcp_config.json - Windows:
%USERPROFILE%\.enkrypt\docker\enkrypt_mcp_config.json
If you don't have the CLI installed locally via pip, the equivalent raw docker run ... invocations for each OS shell are in the "Verbose Docker run commands" details block below.
⚠️ Re-running on an existing config?
generate-configrefuses to clobber an existing file by default — it exits withINFO: Config file already exists at <path>. ... use --overwrite flag.Add--overwriteat the end of the command to regenerate (a timestamped.bkp.<YYYYMMDD_HHMMSS>backup is written next to the original first). The flag works the same for--provider enkryptand the--dockershorthand.
⚠️ "unrecognized arguments: --provider enkrypt" when using
--docker? This means the in-container CLI is older than your host CLI (--providerwas added in v2.2.0). The--dockerwrapper now defaults toenkryptai/secure-mcp-gateway:<host-version>, but if that tag isn't on Docker Hub yet you'll seeUnable to find image ... not found. Build the image from source:docker build -t secure-mcp-gateway . && secure-mcp-gateway --docker --docker-image secure-mcp-gateway generate-config --provider enkrypt --overwrite. See Docker command pattern → Image tag is pinned to your host CLI version for the full workaround table.
Default — local_apikey provider:
# On 🍎 Linux/macOS run the below
docker run --rm -e HOST_OS=macos -e HOST_ENKRYPT_HOME=$HOME/.enkrypt -v ~/.enkrypt/docker:/app/.enkrypt/docker --entrypoint python secure-mcp-gateway -m secure_mcp_gateway.cli generate-config
# On 🪟 Windows (CMD) run the below
docker run --rm -e HOST_OS=windows -e HOST_ENKRYPT_HOME=%USERPROFILE%\.enkrypt -v %USERPROFILE%\.enkrypt\docker:/app/.enkrypt/docker --entrypoint python secure-mcp-gateway -m secure_mcp_gateway.cli generate-config
# On 🪟 Windows (📟 PowerShell) run the below
docker run --rm -e HOST_OS=windows -e "HOST_ENKRYPT_HOME=$env:USERPROFILE\.enkrypt" -v "$env:USERPROFILE\.enkrypt\docker:/app/.enkrypt/docker" --entrypoint python secure-mcp-gateway -m secure_mcp_gateway.cli generate-config
Cloud-backed — --provider enkrypt:
# On 🍎 Linux/macOS
docker run --rm -e HOST_OS=macos -e HOST_ENKRYPT_HOME=$HOME/.enkrypt -v ~/.enkrypt/docker:/app/.enkrypt/docker --entrypoint python secure-mcp-gateway -m secure_mcp_gateway.cli generate-config --provider enkrypt
# On 🪟 Windows (CMD)
docker run --rm -e HOST_OS=windows -e HOST_ENKRYPT_HOME=%USERPROFILE%\.enkrypt -v %USERPROFILE%\.enkrypt\docker:/app/.enkrypt/docker --entrypoint python secure-mcp-gateway -m secure_mcp_gateway.cli generate-config --provider enkrypt
# On 🪟 Windows (📟 PowerShell)
docker run --rm -e HOST_OS=windows -e "HOST_ENKRYPT_HOME=$env:USERPROFILE\.enkrypt" -v "$env:USERPROFILE\.enkrypt\docker:/app/.enkrypt/docker" --entrypoint python secure-mcp-gateway -m secure_mcp_gateway.cli generate-config --provider enkrypt
Re-generate over an existing file — append --overwrite to either command above. Example (PowerShell):
docker run --rm -e HOST_OS=windows -e "HOST_ENKRYPT_HOME=$env:USERPROFILE\.enkrypt" -v "$env:USERPROFILE\.enkrypt\docker:/app/.enkrypt/docker" --entrypoint python secure-mcp-gateway -m secure_mcp_gateway.cli generate-config --overwrite
Identical schema to the local-install config in §4.1.3. The only material differences from a local-install file are:
- Path of
mcp_configs.<id>.mcp_config[0].config.args[0]points at the container's site-packages:/usr/local/lib/python3.12/dist-packages/secure_mcp_gateway/bad_mcps/echo_oauth_mcp.py(vs. the host's venv path locally).PICKED_CONFIG_PATHthe gateway reads is/app/.enkrypt/docker/enkrypt_mcp_config.json(mounted from~/.enkrypt/docker/on the host), not/app/.enkrypt/enkrypt_mcp_config.json.Everything else (admin_apikey, common_mcp_gateway_config including
timeout_settings, plugins, mcp_configs.common_overrides, oauth_config, denied_tools, full block lists for input/output guardrails) is byte-for-byte the same shape — the samegenerate_default_config()code path produces both.
{
"admin_apikey": "AUTO_GENERATED_256_CHAR_KEY",
"enkrypt_config": {
"api_key": "YOUR_ENKRYPT_API_KEY",
"base_url": "https://api.enkryptai.com"
},
"common_mcp_gateway_config": {
"enkrypt_log_level": "INFO",
"enkrypt_mcp_use_external_cache": false,
"enkrypt_cache_host": "localhost",
"enkrypt_cache_port": 6379,
"enkrypt_cache_db": 0,
"enkrypt_cache_password": null,
"enkrypt_tool_cache_expiration": 4,
"enkrypt_gateway_cache_expiration": 24,
"enkrypt_gateway_cache_expiration_minutes": 5,
"enkrypt_config_watcher_poll_seconds": 2.0,
"enkrypt_async_input_guardrails_enabled": false,
"enkrypt_async_output_guardrails_enabled": false,
"timeout_settings": {
"default_timeout": 90,
"guardrail_timeout": 390,
"auth_timeout": 30,
"tool_execution_timeout": 360,
"discovery_timeout": 540,
"cache_timeout": 15,
"connectivity_timeout": 6,
"escalation_policies": {
"warn_threshold": 0.8,
"timeout_threshold": 1.0,
"fail_threshold": 1.2
}
}
},
"plugins": {
"auth": { "provider": "local_apikey", "config": {} },
"guardrails": { "provider": "enkrypt", "config": {} },
"telemetry": {
"provider": "opentelemetry",
"config": {
"enabled": true,
"url": "http://localhost:4317",
"insecure": true
}
}
},
"mcp_configs": {
"31491c1c-7258-4617-93aa-0bd81800d318": {
"mcp_config_name": "default_config",
"common_overrides": {
"server_tools_guardrails_config": {
"enabled": false,
"guardrail_name": "Sample Airline Guardrail",
"block": [
"policy_violation",
"injection_attack",
"topic_detector",
"nsfw",
"toxicity",
"pii",
"keyword_detector",
"bias",
"sponge_attack"
]
}
},
"mcp_config": [
{
"server_name": "echo_server",
"description": "Simple Echo Server",
"config": {
"command": "python",
"args": [
"/usr/local/lib/python3.12/dist-packages/secure_mcp_gateway/bad_mcps/echo_oauth_mcp.py"
]
},
"oauth_config": {
"enabled": false,
"is_remote": false,
"OAUTH_VERSION": "2.1",
"OAUTH_GRANT_TYPE": "client_credentials",
"OAUTH_CLIENT_ID": "your-client-id",
"OAUTH_CLIENT_SECRET": "your-client-secret",
"OAUTH_TOKEN_URL": "https://auth.example.com/oauth/token",
"OAUTH_AUDIENCE": "https://api.example.com",
"OAUTH_ORGANIZATION": "your-org-id",
"OAUTH_SCOPE": "read write",
"OAUTH_RESOURCE": "https://resource.example.com",
"OAUTH_TOKEN_EXPIRY_BUFFER": 300,
"OAUTH_USE_BASIC_AUTH": true,
"OAUTH_ENFORCE_HTTPS": true,
"OAUTH_TOKEN_IN_HEADER_ONLY": true,
"OAUTH_VALIDATE_SCOPES": true,
"OAUTH_USE_MTLS": false,
"OAUTH_CLIENT_CERT_PATH": null,
"OAUTH_CLIENT_KEY_PATH": null,
"OAUTH_CA_BUNDLE_PATH": null,
"OAUTH_REVOCATION_URL": null,
"OAUTH_ADDITIONAL_PARAMS": {},
"OAUTH_CUSTOM_HEADERS": {}
},
"tools": {},
"denied_tools": [],
"input_guardrails_config": {
"enabled": false,
"guardrail_name": "Sample Airline Guardrail",
"additional_config": {
"pii_redaction": false
},
"block": [
"policy_violation",
"injection_attack",
"topic_detector",
"nsfw",
"toxicity",
"pii",
"keyword_detector",
"bias",
"sponge_attack"
]
},
"output_guardrails_config": {
"enabled": false,
"guardrail_name": "Sample Airline Guardrail",
"additional_config": {
"relevancy": false,
"hallucination": false,
"adherence": false
},
"block": [
"policy_violation",
"injection_attack",
"topic_detector",
"nsfw",
"toxicity",
"pii",
"keyword_detector",
"bias",
"sponge_attack"
]
}
}
]
}
},
"projects": {
"48a1e676-5b4b-41a9-8c50-ef04be4c9173": {
"project_name": "default_project",
"mcp_config_id": "31491c1c-7258-4617-93aa-0bd81800d318",
"users": [
"dbaf0d74-a312-4469-bb92-ba4f8af7eb18"
],
"created_at": "2026-01-01T00:00:00.000000"
}
},
"users": {
"dbaf0d74-a312-4469-bb92-ba4f8af7eb18": {
"email": "default@example.com",
"created_at": "2026-01-01T00:00:00.000000"
}
},
"apikeys": {
"Xy2RXGMu_2ZmLP9d7heVb5cj4WYeosldWvDd6hi9opW7ekRL": {
"project_id": "48a1e676-5b4b-41a9-8c50-ef04be4c9173",
"user_id": "dbaf0d74-a312-4469-bb92-ba4f8af7eb18",
"created_at": "2026-01-01T00:00:00.000000"
}
}
}
Identical to the local-install cloud config in §4.1.3 (specifically the "☁️ Example file with
--provider enkrypt" block) — samegenerate_default_enkrypt_cloud_config()code path runs in both modes, so the on-disk JSON is byte-for-byte the same. Only the file path differs (/app/.enkrypt/docker/...inside the container, mounted from~/.enkrypt/docker/on the host).
Run the appropriate --provider enkrypt command from the "Verbose Docker run commands" block above (Linux/macOS, Windows CMD, or Windows PowerShell). The exact file written:
{
"enkrypt_config": {
"api_key": "YOUR_ENKRYPT_API_KEY",
"base_url": "https://api.enkryptai.com",
"org_id": "YOUR_ENKRYPT_ORG_ID"
},
"plugins": {
"auth": {
"provider": "enkrypt",
"config": {
"gateway_name": "your-gateway-saved-name",
"gateway_version": "v1",
"cache_ttl_seconds": 300
}
},
"guardrails": {
"provider": "enkrypt",
"config": {}
},
"telemetry": {
"provider": "opentelemetry",
"config": {
"enabled": true,
"url": "http://localhost:4317",
"insecure": true
}
}
},
"common_mcp_gateway_config": {
"enkrypt_log_level": "INFO",
"enkrypt_gateway_cache_expiration_minutes": 5
}
}
What's intentionally NOT here (see §4.1.3 cloud-variant block for the full rationale):
- No
mcp_configs/projects/users/apikeys— the cloud owns those and the gateway resolves them per-request via/mcp-gateway/get-gateway-config. - No root-level
admin_apikey—enkrypt_config.api_keydoubles as the admin credential for most REST endpoints. Cache-flush requiresenkrypt_config.org_idto be set (cloud-org-gated; see Cache-flush authorization policy). - No verbose
common_mcp_gateway_configblock (cache hosts/ports, async guardrails, timeout_settings, etc.) — the cloud variant ships a deliberately minimal common block; the two values you see (enkrypt_log_level,enkrypt_gateway_cache_expiration_minutes) are the only ones operators commonly tweak. Add any othercommon_mcp_gateway_configkeys by hand if you need them.
Two operator-must-edit values before first boot:
enkrypt_config.api_key→ your real Enkrypt cloud apikeyplugins.auth.config.gateway_name→ thesaved_nameof the gateway you created in the Enkrypt console
The shipped reference file at src/secure_mcp_gateway/example_enkrypt_cloud_config.json is byte-for-byte identical to this example.
4.3.3 Install the Gateway in Claude Desktop
- You can find the Claude config location at the below locations in your system. For reference see Claude docs.
- macOS:
~/Library/Application Support/Claude - Windows:
%APPDATA%\Claude
- macOS:
Note: The generated config includes
MCP_TRANSPORT=stdiofor stdio mode communication with Claude Desktop. The command is provider-aware — it readsplugins.auth.providerfrom your gateway config and emits the correctenv/-eshape (ENKRYPT_GATEWAY_KEY/ENKRYPT_PROJECT_ID/ENKRYPT_USER_IDforlocal_apikey, singleENKRYPT_APIKEYforenkrypt).
Copy-paste command (all OSes — the --docker wrapper auto-mounts your Claude config directory):
secure-mcp-gateway --docker install --client claude-desktop
Hit
Unable to find image 'enkryptai/secure-mcp-gateway:<version>' ... not found? You skipped the one-timedocker tagstep at the end of §4.3.1. Run it once and re-try.
After it runs, restart Claude Desktop to pick up the new config.
# On 🍎 Linux/macOS run the below
docker run --rm -i -e HOST_OS=macos -e HOST_ENKRYPT_HOME=$HOME/.enkrypt -v ~/.enkrypt/docker:/app/.enkrypt/docker -v ~/Library/Application\ Support/Claude:/app/.claude --entrypoint python secure-mcp-gateway -m secure_mcp_gateway.cli install --client claude-desktop
# On 🪟 Windows (CMD) run the below
docker run --rm -i -e HOST_OS=windows -e HOST_ENKRYPT_HOME=%USERPROFILE%\.enkrypt -v %USERPROFILE%\.enkrypt\docker:/app/.enkrypt/docker -v %APPDATA%\Claude:/app/.claude --entrypoint python secure-mcp-gateway -m secure_mcp_gateway.cli install --client claude-desktop
# On 🪟 Windows (📟 PowerShell) run the below
docker run --rm -i -e HOST_OS=windows -e "HOST_ENKRYPT_HOME=$env:USERPROFILE\.enkrypt" -v "$env:USERPROFILE\.enkrypt\docker:/app/.enkrypt/docker" -v "$env:APPDATA\Claude:/app/.claude" --entrypoint python secure-mcp-gateway -m secure_mcp_gateway.cli install --client claude-desktop
4.3.4 Example Claude Desktop config file
The
envblock depends on your gateway'splugins.auth.provider(see §4.1.2). Both shapes are shown below.
Why one
-eper env var? MCP clients set theenvblock on the spawneddockerprocess, but Docker only forwards env vars across the container boundary if you list them with-e VAR_NAMEin the args. Each key inenvneeds a matching-eflag — the install command (secure-mcp-gateway install --client claude-desktop) generates this pairing for you. Hand-rolled JSON should mirror the pattern exactly or the gateway inside the container will seeos.environ[VAR]as unset.
{
"mcpServers": {
"Enkrypt Secure MCP Gateway": {
"command": "docker",
"args": [
"run",
"--rm",
"-i",
"-e",
"MCP_TRANSPORT=stdio",
"-v",
"C:\\Users\\<user>\\.enkrypt\\docker:/app/.enkrypt/docker",
"-e",
"ENKRYPT_GATEWAY_KEY",
"-e",
"ENKRYPT_PROJECT_ID",
"-e",
"ENKRYPT_USER_ID",
"secure-mcp-gateway"
],
"env": {
"ENKRYPT_GATEWAY_KEY": "2W8UupCkazk4SsOcSu_1hAbiOgPdv0g-nN9NtfZyg-rvYGat",
"ENKRYPT_PROJECT_ID": "3c09f06c-1f0d-4153-9ac5-366397937641",
"ENKRYPT_USER_ID": "6469a670-1d64-4da5-b2b3-790de21ac726"
}
}
}
}
{
"mcpServers": {
"Enkrypt Secure MCP Gateway": {
"command": "docker",
"args": [
"run",
"--rm",
"-i",
"-e",
"MCP_TRANSPORT=stdio",
"-v",
"C:\\Users\\<user>\\.enkrypt\\docker:/app/.enkrypt/docker",
"-e",
"ENKRYPT_APIKEY",
"secure-mcp-gateway"
],
"env": {
"ENKRYPT_APIKEY": "your-enkrypt-cloud-apikey"
}
}
}
}
4.3.5 Install the Gateway in Cursor
- You can find the Cursor config location at the below locations. For reference see Cursor docs.
- macOS:
~/.cursor - Windows:
%USERPROFILE%\.cursor
- macOS:
Note: The generated config includes
MCP_TRANSPORT=stdiofor stdio mode communication with Cursor. The command is provider-aware — it readsplugins.auth.providerfrom your gateway config and emits the correctenv/-eshape (ENKRYPT_GATEWAY_KEY/ENKRYPT_PROJECT_ID/ENKRYPT_USER_IDforlocal_apikey, singleENKRYPT_APIKEYforenkrypt).
Copy-paste command (all OSes — the --docker wrapper auto-mounts ~/.cursor so the in-container install can write back to it):
secure-mcp-gateway --docker install --client cursor
Hit
Unable to find image 'enkryptai/secure-mcp-gateway:<version>' ... not found? You skipped the one-timedocker tagstep at the end of §4.3.1. Run it once and re-try.
After it runs, restart Cursor to pick up the new server. The entry lands at ~/.cursor/mcp.json on macOS/Linux or %USERPROFILE%\.cursor\mcp.json on Windows.
# On 🍎 Linux/macOS run the below
docker run --rm -i -e HOST_OS=macos -e HOST_ENKRYPT_HOME=$HOME/.enkrypt -v ~/.enkrypt/docker:/app/.enkrypt/docker -v ~/.cursor:/app/.cursor --entrypoint python secure-mcp-gateway -m secure_mcp_gateway.cli install --client cursor
# On 🪟 Windows (CMD) run the below
docker run --rm -i -e HOST_OS=windows -e HOST_ENKRYPT_HOME=%USERPROFILE%\.enkrypt -v %USERPROFILE%\.enkrypt\docker:/app/.enkrypt/docker -v %USERPROFILE%\.cursor:/app/.cursor --entrypoint python secure-mcp-gateway -m secure_mcp_gateway.cli install --client cursor
# On 🪟 Windows (📟 PowerShell) run the below
docker run --rm -i -e HOST_OS=windows -e "HOST_ENKRYPT_HOME=$env:USERPROFILE\.enkrypt" -v "$env:USERPROFILE\.enkrypt\docker:/app/.enkrypt/docker" -v "$env:USERPROFILE\.cursor:/app/.cursor" --entrypoint python secure-mcp-gateway -m secure_mcp_gateway.cli install --client cursor
4.3.6 Install the Gateway in Claude Code
Claude Code uses its own CLI (claude mcp add) to manage MCP servers. When running the gateway in Docker, Claude Code connects via npx mcp-remote to the gateway's Streamable HTTP endpoint.
Prerequisites: Node.js and npm must be installed on your machine (
node -vandnpm -vto verify).
Step 1: Run the gateway container
Start the gateway as a background Docker container with the Streamable HTTP endpoint exposed:
# On 🍎 Linux/macOS
docker run -d --name enkrypt-gateway -p 8000:8000 -v ~/.enkrypt/docker:/app/.enkrypt/docker secure-mcp-gateway
# On 🪟 Windows (PowerShell)
docker run -d --name enkrypt-gateway -p 8000:8000 -v "$env:USERPROFILE\.enkrypt\docker:/app/.enkrypt/docker" secure-mcp-gateway
Step 2: Add the gateway to Claude Code
The HTTP headers differ by auth provider:
# For local_apikey provider (default)
claude mcp add --transport http --header "apikey:YOUR_GATEWAY_KEY" --
Frequently asked questions
What is secure-mcp-gateway MCP Server?
Enkrypt AI Secure MCP Gateway — authentication, guardrails, caching, and observability for Model Context Protocol servers.
How do I install secure-mcp-gateway MCP Server in Claude Desktop, Cursor, or VS Code?
Pick your client in the Install section on this page and copy the generated config into the client's config file. Step-by-step guides: Claude Desktop, Cursor, and VS Code. secure-mcp-gateway MCP Server runs locally from the PyPI package secure-mcp-gateway with the command uvx secure-mcp-gateway.
Is secure-mcp-gateway MCP Server free and open source?
Yes. secure-mcp-gateway MCP Server is released under the Apache-2.0 license, an OSI-approved open-source license, so you can use, modify, and self-host it under those terms.
Does secure-mcp-gateway MCP Server support remote (HTTP) connections?
No remote endpoint is listed for secure-mcp-gateway MCP Server. It runs locally on your machine over stdio, started by your MCP client.
How is secure-mcp-gateway MCP Server's trust score calculated?
secure-mcp-gateway MCP Server scores 47 out of 100 (Fair). The score adds six capped public signals: registry status, maintenance, popularity, license, documentation, and security. Nobody can pay for points. Read the methodology for the full formula.
Reviews
No reviews yet—Be the first to review
No published reviews yet. Used it? Tell the next person how it went.
Sign inA verified email is required to review this server.
Add badge to your README
Paste either snippet into the repository README. The image links to this listing.
