@devries-cameron20 / composio-1 / commits / 11c4bca81
Fork 0

Composio powers 1000+ toolkits, tool search, context management, authentication, and a sandboxed workbench to help you build AI agents that turn intent into action.

Fix review issues: image Frame, rename SDK to Code, fix JSON, remove redundant section

Anshu Garg committed Jan 5, 2026 at 12:51 UTC 11c4bca812033d5fad7f75b1a31539938bb10048
1 file changed +11 -19
fern/pages/src/changelog/12-29-25-mcp-api-key-enforcement.md
+11 -19
@@ -29,20 +29,19 @@ When the setting is **enabled**:
29
30 **Without API key (when enforcement is enabled):**
31 ```bash
32 -curl -X POST "https://mcp.composio.dev/{mcp_url}" \
32 +curl -X POST "https://mcp.composio.dev/{your_mcp_server_url}" \
33 -H "Content-Type: application/json" \
34 - -d '{"jsonrpc":"2.0","id":1,"method":"initialize",...}'
34 + -d '{"jsonrpc":"2.0","id":1,"method":"initialize"}'
35
36 # Response: 401 Unauthorized
37 -# {"error": "API key is required in headers for security reasons"}
37 ```
38
39 **With API key:**
40 ```bash
42 -curl -X POST "https://mcp.composio.dev/{mcp_url}" \
41 +curl -X POST "https://mcp.composio.dev/{your_mcp_server_url}" \
42 -H "Content-Type: application/json" \
43 -H "x-api-key: ak_your_api_key" \
45 - -d '{"jsonrpc":"2.0","id":1,"method":"initialize",...}'
44 + -d '{"jsonrpc":"2.0","id":1,"method":"initialize"}'
45
46 # Response: 200 OK
47 ```
@@ -56,7 +55,9 @@ curl -X POST "https://mcp.composio.dev/{mcp_url}" \
55 3. Find the **"Require API Key for MCP"** toggle
56 4. Enable the toggle
57
59 -![MCP API Key Toggle in Project Settings](/assets/images/mcp-api-key-toggle.png)
58 +<Frame>
59 + <img src="/assets/images/mcp-api-key-toggle.png" alt="MCP API Key Toggle in Project Settings" />
60 +</Frame>
61
62 ### Via API
63
@@ -79,11 +80,10 @@ curl -X PATCH "https://backend.composio.dev/api/v3/org/project/config" \
80 }
81 ```
82
82 -### Via SDK
83 +### Via Code
84
85 <CodeGroup>
86 ```python title="Python"
86 -# Update project config to require MCP API key
87 import requests
88
89 response = requests.patch(
@@ -98,7 +98,6 @@ response = requests.patch(
98 print(response.json())
99 ```
100 ```typescript title="TypeScript"
101 -// Update project config to require MCP API key
101 const response = await fetch(
102 "https://backend.composio.dev/api/v3/org/project/config",
103 {
@@ -124,15 +123,6 @@ Enable API key enforcement when you need to:
123 - **Add an extra security layer** for production deployments
124 - **Audit and track** MCP server usage through API key attribution
125
127 -## Backward Compatibility
128 -
129 -This is a **fully opt-in feature** with no impact on existing integrations:
130 -
131 -- Default value is `false` — no changes to current behavior
132 -- Existing MCP servers continue to work without modification
133 -- You can enable/disable the setting at any time
134 -- The setting applies project-wide to all MCP servers in that project
135 -
126 ## API Reference
127
128 ### Get Current Setting
@@ -145,8 +135,10 @@ GET /api/v3/org/project/config
135
136 ```http
137 PATCH /api/v3/org/project/config
138 +```
139
140 +```json
141 {
150 - "require_mcp_api_key": true | false
142 + "require_mcp_api_key": true
143 }
144 ```