Skip to content
Source
Sign inSign up
pingdotgg/t3code

fix(server): keep the Claude MCP token out of process arguments #17408

Mergedjuliusmarmingemerged 2 commits intomain fromrefs/pull/17408/headmerged by juliusmarminge View on GitHub

Showing 2 changed files with 35 additions and 6 deletions.

x
0 of 2 viewed, 2 left
16 additions and 3 deletionsapps/server/src/orchestration-v2/Adapters/ClaudeAdapterV2.test.tsModified
View file
@@ -478,11 +478,14 @@
type: "http",
url: "http://127.0.0.1:43123/mcp",
headers: {
- Authorization: "Bearer secret-claude-token",
+ Authorization: "${T3_CODE_MCP_AUTHORIZATION}",
timeout: ClaudeAdapterV2.CLAUDE_T3_MCP_TOOL_TIMEOUT_MS,
} as const;
+ const T3_MCP_ENVIRONMENT = {
+ T3_CODE_MCP_AUTHORIZATION: "Bearer secret-claude-token",
+ } as const;
​
const withMcpSession = (threadId: ThreadId, run: () => void) => {
McpProviderSession.setMcpProviderSession({
@@ -531,6 +534,7 @@
assert.deepEqual(overrides, {
allowedTools: [ClaudeAdapterV2.CLAUDE_T3_MCP_TOOL_WILDCARD],
mcpServers: T3_MCP_SERVERS,
+ mcpEnvironment: T3_MCP_ENVIRONMENT,
});
});
});
@@ -547,6 +551,7 @@
assert.deepEqual(overrides, {
allowedTools: ["Read", "mcp__t3-code__*"],
mcpServers: T3_MCP_SERVERS,