integrate-sdk 0.9.14-dev.0 → 0.9.15-dev.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -3674,6 +3674,7 @@ init_tool_builder();
3674
3674
  var SERVER_LOG_CONTEXT3 = "server";
3675
3675
  var logger31 = createLogger("MCPServer", SERVER_LOG_CONTEXT3);
3676
3676
  var codeVerifierStorage = new Map;
3677
+ var unauthenticatedCodeModeWarnings = new Set;
3677
3678
  function toSolidStartHandler(clientOrHandlerOrOptions, _redirectOptions) {
3678
3679
  if (clientOrHandlerOrOptions && clientOrHandlerOrOptions.handler && typeof clientOrHandlerOrOptions.handler === "function") {
3679
3680
  const baseHandler = clientOrHandlerOrOptions.handler;
@@ -3674,6 +3674,7 @@ init_tool_builder();
3674
3674
  var SERVER_LOG_CONTEXT3 = "server";
3675
3675
  var logger31 = createLogger("MCPServer", SERVER_LOG_CONTEXT3);
3676
3676
  var codeVerifierStorage = new Map;
3677
+ var unauthenticatedCodeModeWarnings = new Set;
3677
3678
  function toSolidStartHandler(clientOrHandlerOrOptions, _redirectOptions) {
3678
3679
  if (clientOrHandlerOrOptions && clientOrHandlerOrOptions.handler && typeof clientOrHandlerOrOptions.handler === "function") {
3679
3680
  const baseHandler = clientOrHandlerOrOptions.handler;
@@ -3674,6 +3674,7 @@ init_tool_builder();
3674
3674
  var SERVER_LOG_CONTEXT3 = "server";
3675
3675
  var logger31 = createLogger("MCPServer", SERVER_LOG_CONTEXT3);
3676
3676
  var codeVerifierStorage = new Map;
3677
+ var unauthenticatedCodeModeWarnings = new Set;
3677
3678
  function toSolidStartHandler(clientOrHandlerOrOptions, _redirectOptions) {
3678
3679
  if (clientOrHandlerOrOptions && clientOrHandlerOrOptions.handler && typeof clientOrHandlerOrOptions.handler === "function") {
3679
3680
  const baseHandler = clientOrHandlerOrOptions.handler;
@@ -4677,7 +4677,14 @@ async function callTool(toolName, args) {
4677
4677
  }
4678
4678
 
4679
4679
  if (!res.ok) {
4680
- const message = (payload && (payload.error || payload.message)) || 'Tool call failed: HTTP ' + res.status;
4680
+ let message = (payload && (payload.error || payload.message)) || 'Tool call failed: HTTP ' + res.status;
4681
+ if ((res.status === 401 || res.status === 403) && typeof text === 'string' && text.indexOf('Authorization header') !== -1) {
4682
+ message =
4683
+ 'Code Mode callback was rejected by the MCP server (HTTP ' + res.status + '). ' +
4684
+ 'The SDK route could not synthesize an Authorization header. Check the host-side ' +
4685
+ 'createMCPServer config (apiKey, getProviderToken) or pass providerTokens to the ' +
4686
+ 'AI helper. Original upstream message: ' + text;
4687
+ }
4681
4688
  const err = new Error(message);
4682
4689
  err.status = res.status;
4683
4690
  err.toolName = toolName;
package/dist/ai/google.js CHANGED
@@ -4677,7 +4677,14 @@ async function callTool(toolName, args) {
4677
4677
  }
4678
4678
 
4679
4679
  if (!res.ok) {
4680
- const message = (payload && (payload.error || payload.message)) || 'Tool call failed: HTTP ' + res.status;
4680
+ let message = (payload && (payload.error || payload.message)) || 'Tool call failed: HTTP ' + res.status;
4681
+ if ((res.status === 401 || res.status === 403) && typeof text === 'string' && text.indexOf('Authorization header') !== -1) {
4682
+ message =
4683
+ 'Code Mode callback was rejected by the MCP server (HTTP ' + res.status + '). ' +
4684
+ 'The SDK route could not synthesize an Authorization header. Check the host-side ' +
4685
+ 'createMCPServer config (apiKey, getProviderToken) or pass providerTokens to the ' +
4686
+ 'AI helper. Original upstream message: ' + text;
4687
+ }
4681
4688
  const err = new Error(message);
4682
4689
  err.status = res.status;
4683
4690
  err.toolName = toolName;
package/dist/ai/index.js CHANGED
@@ -4677,7 +4677,14 @@ async function callTool(toolName, args) {
4677
4677
  }
4678
4678
 
4679
4679
  if (!res.ok) {
4680
- const message = (payload && (payload.error || payload.message)) || 'Tool call failed: HTTP ' + res.status;
4680
+ let message = (payload && (payload.error || payload.message)) || 'Tool call failed: HTTP ' + res.status;
4681
+ if ((res.status === 401 || res.status === 403) && typeof text === 'string' && text.indexOf('Authorization header') !== -1) {
4682
+ message =
4683
+ 'Code Mode callback was rejected by the MCP server (HTTP ' + res.status + '). ' +
4684
+ 'The SDK route could not synthesize an Authorization header. Check the host-side ' +
4685
+ 'createMCPServer config (apiKey, getProviderToken) or pass providerTokens to the ' +
4686
+ 'AI helper. Original upstream message: ' + text;
4687
+ }
4681
4688
  const err = new Error(message);
4682
4689
  err.status = res.status;
4683
4690
  err.toolName = toolName;
package/dist/ai/openai.js CHANGED
@@ -4677,7 +4677,14 @@ async function callTool(toolName, args) {
4677
4677
  }
4678
4678
 
4679
4679
  if (!res.ok) {
4680
- const message = (payload && (payload.error || payload.message)) || 'Tool call failed: HTTP ' + res.status;
4680
+ let message = (payload && (payload.error || payload.message)) || 'Tool call failed: HTTP ' + res.status;
4681
+ if ((res.status === 401 || res.status === 403) && typeof text === 'string' && text.indexOf('Authorization header') !== -1) {
4682
+ message =
4683
+ 'Code Mode callback was rejected by the MCP server (HTTP ' + res.status + '). ' +
4684
+ 'The SDK route could not synthesize an Authorization header. Check the host-side ' +
4685
+ 'createMCPServer config (apiKey, getProviderToken) or pass providerTokens to the ' +
4686
+ 'AI helper. Original upstream message: ' + text;
4687
+ }
4681
4688
  const err = new Error(message);
4682
4689
  err.status = res.status;
4683
4690
  err.toolName = toolName;
@@ -4677,7 +4677,14 @@ async function callTool(toolName, args) {
4677
4677
  }
4678
4678
 
4679
4679
  if (!res.ok) {
4680
- const message = (payload && (payload.error || payload.message)) || 'Tool call failed: HTTP ' + res.status;
4680
+ let message = (payload && (payload.error || payload.message)) || 'Tool call failed: HTTP ' + res.status;
4681
+ if ((res.status === 401 || res.status === 403) && typeof text === 'string' && text.indexOf('Authorization header') !== -1) {
4682
+ message =
4683
+ 'Code Mode callback was rejected by the MCP server (HTTP ' + res.status + '). ' +
4684
+ 'The SDK route could not synthesize an Authorization header. Check the host-side ' +
4685
+ 'createMCPServer config (apiKey, getProviderToken) or pass providerTokens to the ' +
4686
+ 'AI helper. Original upstream message: ' + text;
4687
+ }
4681
4688
  const err = new Error(message);
4682
4689
  err.status = res.status;
4683
4690
  err.toolName = toolName;
@@ -60,7 +60,14 @@ async function callTool(toolName, args) {
60
60
  }
61
61
 
62
62
  if (!res.ok) {
63
- const message = (payload && (payload.error || payload.message)) || 'Tool call failed: HTTP ' + res.status;
63
+ let message = (payload && (payload.error || payload.message)) || 'Tool call failed: HTTP ' + res.status;
64
+ if ((res.status === 401 || res.status === 403) && typeof text === 'string' && text.indexOf('Authorization header') !== -1) {
65
+ message =
66
+ 'Code Mode callback was rejected by the MCP server (HTTP ' + res.status + '). ' +
67
+ 'The SDK route could not synthesize an Authorization header. Check the host-side ' +
68
+ 'createMCPServer config (apiKey, getProviderToken) or pass providerTokens to the ' +
69
+ 'AI helper. Original upstream message: ' + text;
70
+ }
64
71
  const err = new Error(message);
65
72
  err.status = res.status;
66
73
  err.toolName = toolName;
@@ -275,7 +275,14 @@ async function callTool(toolName, args) {
275
275
  }
276
276
 
277
277
  if (!res.ok) {
278
- const message = (payload && (payload.error || payload.message)) || 'Tool call failed: HTTP ' + res.status;
278
+ let message = (payload && (payload.error || payload.message)) || 'Tool call failed: HTTP ' + res.status;
279
+ if ((res.status === 401 || res.status === 403) && typeof text === 'string' && text.indexOf('Authorization header') !== -1) {
280
+ message =
281
+ 'Code Mode callback was rejected by the MCP server (HTTP ' + res.status + '). ' +
282
+ 'The SDK route could not synthesize an Authorization header. Check the host-side ' +
283
+ 'createMCPServer config (apiKey, getProviderToken) or pass providerTokens to the ' +
284
+ 'AI helper. Original upstream message: ' + text;
285
+ }
279
286
  const err = new Error(message);
280
287
  err.status = res.status;
281
288
  err.toolName = toolName;
@@ -12,5 +12,5 @@
12
12
  * dependencies. It is NOT imported by the host SDK — it only ships as a
13
13
  * literal payload to the sandbox.
14
14
  */
15
- export declare const RUNTIME_STUB_SOURCE = "// runtime.mjs \u2014 generated by integrate-sdk code mode\nconst MCP_URL = process.env.INTEGRATE_MCP_URL;\nconst SESSION_TOKEN = process.env.INTEGRATE_SESSION_TOKEN;\nconst API_KEY = process.env.INTEGRATE_API_KEY || '';\nconst PROVIDER_TOKENS = process.env.INTEGRATE_PROVIDER_TOKENS || '';\nconst INTEGRATIONS_HEADER = process.env.INTEGRATE_INTEGRATIONS || '';\nconst CONTEXT_JSON = process.env.INTEGRATE_CONTEXT || '';\n\nif (!MCP_URL) {\n throw new Error('INTEGRATE_MCP_URL is not set \u2014 the sandbox cannot reach the MCP route.');\n}\n\nfunction camelToSnake(str) {\n return str.replace(/[A-Z]/g, (letter) => '_' + letter.toLowerCase());\n}\n\nasync function callTool(toolName, args) {\n const headers = {\n 'Content-Type': 'application/json',\n 'x-integrate-code-mode': '1',\n };\n if (SESSION_TOKEN) headers['Authorization'] = 'Bearer ' + SESSION_TOKEN;\n if (API_KEY) headers['x-integrate-api-key'] = API_KEY;\n if (PROVIDER_TOKENS) headers['x-integrate-tokens'] = PROVIDER_TOKENS;\n if (INTEGRATIONS_HEADER) headers['x-integrations'] = INTEGRATIONS_HEADER;\n if (CONTEXT_JSON) headers['x-integrate-context'] = CONTEXT_JSON;\n\n const res = await fetch(MCP_URL, {\n method: 'POST',\n headers,\n body: JSON.stringify({ name: toolName, arguments: args || {} }),\n });\n\n const text = await res.text();\n let payload;\n try {\n payload = text ? JSON.parse(text) : null;\n } catch {\n payload = { content: [{ type: 'text', text }] };\n }\n\n if (!res.ok) {\n const message = (payload && (payload.error || payload.message)) || 'Tool call failed: HTTP ' + res.status;\n const err = new Error(message);\n err.status = res.status;\n err.toolName = toolName;\n throw err;\n }\n\n return payload;\n}\n\nfunction createIntegrationProxy(integrationId) {\n return new Proxy({}, {\n get(_target, methodName) {\n if (typeof methodName !== 'string') return undefined;\n return (args) => callTool(integrationId + '_' + camelToSnake(methodName), args);\n },\n });\n}\n\nexport const client = new Proxy({}, {\n get(_target, integrationId) {\n if (typeof integrationId !== 'string') return undefined;\n return createIntegrationProxy(integrationId);\n },\n});\n\nexport { callTool };\n";
15
+ export declare const RUNTIME_STUB_SOURCE = "// runtime.mjs \u2014 generated by integrate-sdk code mode\nconst MCP_URL = process.env.INTEGRATE_MCP_URL;\nconst SESSION_TOKEN = process.env.INTEGRATE_SESSION_TOKEN;\nconst API_KEY = process.env.INTEGRATE_API_KEY || '';\nconst PROVIDER_TOKENS = process.env.INTEGRATE_PROVIDER_TOKENS || '';\nconst INTEGRATIONS_HEADER = process.env.INTEGRATE_INTEGRATIONS || '';\nconst CONTEXT_JSON = process.env.INTEGRATE_CONTEXT || '';\n\nif (!MCP_URL) {\n throw new Error('INTEGRATE_MCP_URL is not set \u2014 the sandbox cannot reach the MCP route.');\n}\n\nfunction camelToSnake(str) {\n return str.replace(/[A-Z]/g, (letter) => '_' + letter.toLowerCase());\n}\n\nasync function callTool(toolName, args) {\n const headers = {\n 'Content-Type': 'application/json',\n 'x-integrate-code-mode': '1',\n };\n if (SESSION_TOKEN) headers['Authorization'] = 'Bearer ' + SESSION_TOKEN;\n if (API_KEY) headers['x-integrate-api-key'] = API_KEY;\n if (PROVIDER_TOKENS) headers['x-integrate-tokens'] = PROVIDER_TOKENS;\n if (INTEGRATIONS_HEADER) headers['x-integrations'] = INTEGRATIONS_HEADER;\n if (CONTEXT_JSON) headers['x-integrate-context'] = CONTEXT_JSON;\n\n const res = await fetch(MCP_URL, {\n method: 'POST',\n headers,\n body: JSON.stringify({ name: toolName, arguments: args || {} }),\n });\n\n const text = await res.text();\n let payload;\n try {\n payload = text ? JSON.parse(text) : null;\n } catch {\n payload = { content: [{ type: 'text', text }] };\n }\n\n if (!res.ok) {\n let message = (payload && (payload.error || payload.message)) || 'Tool call failed: HTTP ' + res.status;\n if ((res.status === 401 || res.status === 403) && typeof text === 'string' && text.indexOf('Authorization header') !== -1) {\n message =\n 'Code Mode callback was rejected by the MCP server (HTTP ' + res.status + '). ' +\n 'The SDK route could not synthesize an Authorization header. Check the host-side ' +\n 'createMCPServer config (apiKey, getProviderToken) or pass providerTokens to the ' +\n 'AI helper. Original upstream message: ' + text;\n }\n const err = new Error(message);\n err.status = res.status;\n err.toolName = toolName;\n throw err;\n }\n\n return payload;\n}\n\nfunction createIntegrationProxy(integrationId) {\n return new Proxy({}, {\n get(_target, methodName) {\n if (typeof methodName !== 'string') return undefined;\n return (args) => callTool(integrationId + '_' + camelToSnake(methodName), args);\n },\n });\n}\n\nexport const client = new Proxy({}, {\n get(_target, integrationId) {\n if (typeof integrationId !== 'string') return undefined;\n return createIntegrationProxy(integrationId);\n },\n});\n\nexport { callTool };\n";
16
16
  //# sourceMappingURL=runtime-stub.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"runtime-stub.d.ts","sourceRoot":"","sources":["../../../src/code-mode/runtime-stub.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;GAaG;AAEH,eAAO,MAAM,mBAAmB,qtEAqE/B,CAAC"}
1
+ {"version":3,"file":"runtime-stub.d.ts","sourceRoot":"","sources":["../../../src/code-mode/runtime-stub.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;GAaG;AAEH,eAAO,MAAM,mBAAmB,8rFA4E/B,CAAC"}
@@ -60,7 +60,14 @@ async function callTool(toolName, args) {
60
60
  }
61
61
 
62
62
  if (!res.ok) {
63
- const message = (payload && (payload.error || payload.message)) || 'Tool call failed: HTTP ' + res.status;
63
+ let message = (payload && (payload.error || payload.message)) || 'Tool call failed: HTTP ' + res.status;
64
+ if ((res.status === 401 || res.status === 403) && typeof text === 'string' && text.indexOf('Authorization header') !== -1) {
65
+ message =
66
+ 'Code Mode callback was rejected by the MCP server (HTTP ' + res.status + '). ' +
67
+ 'The SDK route could not synthesize an Authorization header. Check the host-side ' +
68
+ 'createMCPServer config (apiKey, getProviderToken) or pass providerTokens to the ' +
69
+ 'AI helper. Original upstream message: ' + text;
70
+ }
64
71
  const err = new Error(message);
65
72
  err.status = res.status;
66
73
  err.toolName = toolName;
@@ -275,7 +275,14 @@ async function callTool(toolName, args) {
275
275
  }
276
276
 
277
277
  if (!res.ok) {
278
- const message = (payload && (payload.error || payload.message)) || 'Tool call failed: HTTP ' + res.status;
278
+ let message = (payload && (payload.error || payload.message)) || 'Tool call failed: HTTP ' + res.status;
279
+ if ((res.status === 401 || res.status === 403) && typeof text === 'string' && text.indexOf('Authorization header') !== -1) {
280
+ message =
281
+ 'Code Mode callback was rejected by the MCP server (HTTP ' + res.status + '). ' +
282
+ 'The SDK route could not synthesize an Authorization header. Check the host-side ' +
283
+ 'createMCPServer config (apiKey, getProviderToken) or pass providerTokens to the ' +
284
+ 'AI helper. Original upstream message: ' + text;
285
+ }
279
286
  const err = new Error(message);
280
287
  err.status = res.status;
281
288
  err.toolName = toolName;
package/dist/server.js CHANGED
@@ -1481,7 +1481,14 @@ async function callTool(toolName, args) {
1481
1481
  }
1482
1482
 
1483
1483
  if (!res.ok) {
1484
- const message = (payload && (payload.error || payload.message)) || 'Tool call failed: HTTP ' + res.status;
1484
+ let message = (payload && (payload.error || payload.message)) || 'Tool call failed: HTTP ' + res.status;
1485
+ if ((res.status === 401 || res.status === 403) && typeof text === 'string' && text.indexOf('Authorization header') !== -1) {
1486
+ message =
1487
+ 'Code Mode callback was rejected by the MCP server (HTTP ' + res.status + '). ' +
1488
+ 'The SDK route could not synthesize an Authorization header. Check the host-side ' +
1489
+ 'createMCPServer config (apiKey, getProviderToken) or pass providerTokens to the ' +
1490
+ 'AI helper. Original upstream message: ' + text;
1491
+ }
1485
1492
  const err = new Error(message);
1486
1493
  err.status = res.status;
1487
1494
  err.toolName = toolName;
@@ -11784,6 +11791,33 @@ var logger33 = createLogger("MCPServer", SERVER_LOG_CONTEXT3);
11784
11791
  var globalServerConfig = null;
11785
11792
  var globalMCPHandler = null;
11786
11793
  var codeVerifierStorage = new Map;
11794
+ function resolveProviderFromToolName(toolName, candidates) {
11795
+ let best = null;
11796
+ for (const candidate of candidates) {
11797
+ if (!candidate)
11798
+ continue;
11799
+ if (toolName === candidate || toolName.startsWith(candidate + "_")) {
11800
+ if (!best || candidate.length > best.length)
11801
+ best = candidate;
11802
+ }
11803
+ }
11804
+ return best;
11805
+ }
11806
+ var unauthenticatedCodeModeWarnings = new Set;
11807
+ function warnUnauthenticatedCodeModeCallback(details) {
11808
+ if (unauthenticatedCodeModeWarnings.has(details.toolName))
11809
+ return;
11810
+ unauthenticatedCodeModeWarnings.add(details.toolName);
11811
+ console.warn(`[integrate-sdk] Code Mode callback for tool "${details.toolName}" has no Authorization header.
11812
+ ` + ` x-integrate-tokens present: ${details.tokensPresent} (resolved provider: ${details.tokensResolvedProvider ?? "none"})
11813
+ ` + ` x-integrate-context present: ${details.contextPresent}
11814
+ ` + ` x-integrate-api-key matches server apiKey: ${details.apiKeyMatches}
11815
+ ` + ` getProviderToken configured: ${details.getProviderTokenConfigured}
11816
+ ` + ` Fix by either (a) passing providerTokens to the AI helper, or (b) configuring getProviderToken + apiKey on createMCPServer and passing context.`);
11817
+ }
11818
+ function __resetUnauthenticatedCodeModeWarnings() {
11819
+ unauthenticatedCodeModeWarnings.clear();
11820
+ }
11787
11821
  function cleanupExpiredCodeVerifiers() {
11788
11822
  const now = Date.now();
11789
11823
  for (const [state, entry] of codeVerifierStorage.entries()) {
@@ -11950,36 +11984,44 @@ function createMCPServer(config) {
11950
11984
  const body = await webRequest.json();
11951
11985
  let authHeader = webRequest.headers.get("authorization");
11952
11986
  const integrationsHeader = webRequest.headers.get("x-integrations");
11953
- if (!authHeader) {
11954
- const tokensHeader = webRequest.headers.get("x-integrate-tokens");
11955
- const toolName = typeof body?.name === "string" ? body.name : "";
11956
- if (tokensHeader && toolName) {
11957
- try {
11958
- const tokens = JSON.parse(tokensHeader);
11959
- const provider = toolName.split("_")[0];
11960
- if (provider && tokens[provider]) {
11961
- authHeader = `Bearer ${tokens[provider]}`;
11962
- }
11963
- } catch {}
11964
- }
11987
+ const codeModeHeader = webRequest.headers.get("x-integrate-code-mode");
11988
+ const contextHeader = webRequest.headers.get("x-integrate-context");
11989
+ const callbackApiKey = webRequest.headers.get("x-integrate-api-key");
11990
+ const tokensHeader = webRequest.headers.get("x-integrate-tokens");
11991
+ const toolName = typeof body?.name === "string" ? body.name : "";
11992
+ let tokensResolvedProvider = null;
11993
+ if (!authHeader && tokensHeader && toolName) {
11994
+ try {
11995
+ const tokens = JSON.parse(tokensHeader);
11996
+ const provider = resolveProviderFromToolName(toolName, Object.keys(tokens));
11997
+ if (provider && tokens[provider]) {
11998
+ tokensResolvedProvider = provider;
11999
+ authHeader = `Bearer ${tokens[provider]}`;
12000
+ }
12001
+ } catch {}
11965
12002
  }
11966
- if (!authHeader && config.getProviderToken) {
11967
- const codeModeHeader = webRequest.headers.get("x-integrate-code-mode");
11968
- const contextHeader = webRequest.headers.get("x-integrate-context");
11969
- const callbackApiKey = webRequest.headers.get("x-integrate-api-key");
11970
- const toolName = typeof body?.name === "string" ? body.name : "";
11971
- if (codeModeHeader === "1" && contextHeader && toolName && config.apiKey && callbackApiKey === config.apiKey) {
11972
- try {
11973
- const context2 = JSON.parse(contextHeader);
11974
- const provider = toolName.split("_")[0];
11975
- if (provider) {
11976
- const tokenData = await config.getProviderToken(provider, undefined, context2);
11977
- if (tokenData?.accessToken) {
11978
- authHeader = `Bearer ${tokenData.accessToken}`;
11979
- }
12003
+ if (!authHeader && config.getProviderToken && codeModeHeader === "1" && contextHeader && toolName && config.apiKey && callbackApiKey === config.apiKey) {
12004
+ try {
12005
+ const context2 = JSON.parse(contextHeader);
12006
+ const candidates = integrationsHeader ? integrationsHeader.split(",").map((s) => s.trim()).filter(Boolean) : (config.integrations ?? []).map((i) => i.id).filter(Boolean);
12007
+ const provider = resolveProviderFromToolName(toolName, candidates);
12008
+ if (provider) {
12009
+ const tokenData = await config.getProviderToken(provider, undefined, context2);
12010
+ if (tokenData?.accessToken) {
12011
+ authHeader = `Bearer ${tokenData.accessToken}`;
11980
12012
  }
11981
- } catch {}
11982
- }
12013
+ }
12014
+ } catch {}
12015
+ }
12016
+ if (!authHeader && codeModeHeader === "1") {
12017
+ warnUnauthenticatedCodeModeCallback({
12018
+ toolName,
12019
+ tokensPresent: !!tokensHeader,
12020
+ tokensResolvedProvider,
12021
+ contextPresent: !!contextHeader,
12022
+ apiKeyMatches: !!(config.apiKey && callbackApiKey === config.apiKey),
12023
+ getProviderTokenConfigured: !!config.getProviderToken
12024
+ });
11983
12025
  }
11984
12026
  const { OAuthHandler: OAuthHandler2 } = await Promise.resolve().then(() => (init_base_handler(), exports_base_handler));
11985
12027
  const oauthHandler = new OAuthHandler2({
@@ -12765,6 +12807,7 @@ export {
12765
12807
  calcomIntegration,
12766
12808
  buildCodeModeTool,
12767
12809
  airtableIntegration,
12810
+ __resetUnauthenticatedCodeModeWarnings,
12768
12811
  RUNTIME_STUB_SOURCE,
12769
12812
  POST,
12770
12813
  OAuthHandler,
@@ -12,5 +12,5 @@
12
12
  * dependencies. It is NOT imported by the host SDK — it only ships as a
13
13
  * literal payload to the sandbox.
14
14
  */
15
- export declare const RUNTIME_STUB_SOURCE = "// runtime.mjs \u2014 generated by integrate-sdk code mode\nconst MCP_URL = process.env.INTEGRATE_MCP_URL;\nconst SESSION_TOKEN = process.env.INTEGRATE_SESSION_TOKEN;\nconst API_KEY = process.env.INTEGRATE_API_KEY || '';\nconst PROVIDER_TOKENS = process.env.INTEGRATE_PROVIDER_TOKENS || '';\nconst INTEGRATIONS_HEADER = process.env.INTEGRATE_INTEGRATIONS || '';\nconst CONTEXT_JSON = process.env.INTEGRATE_CONTEXT || '';\n\nif (!MCP_URL) {\n throw new Error('INTEGRATE_MCP_URL is not set \u2014 the sandbox cannot reach the MCP route.');\n}\n\nfunction camelToSnake(str) {\n return str.replace(/[A-Z]/g, (letter) => '_' + letter.toLowerCase());\n}\n\nasync function callTool(toolName, args) {\n const headers = {\n 'Content-Type': 'application/json',\n 'x-integrate-code-mode': '1',\n };\n if (SESSION_TOKEN) headers['Authorization'] = 'Bearer ' + SESSION_TOKEN;\n if (API_KEY) headers['x-integrate-api-key'] = API_KEY;\n if (PROVIDER_TOKENS) headers['x-integrate-tokens'] = PROVIDER_TOKENS;\n if (INTEGRATIONS_HEADER) headers['x-integrations'] = INTEGRATIONS_HEADER;\n if (CONTEXT_JSON) headers['x-integrate-context'] = CONTEXT_JSON;\n\n const res = await fetch(MCP_URL, {\n method: 'POST',\n headers,\n body: JSON.stringify({ name: toolName, arguments: args || {} }),\n });\n\n const text = await res.text();\n let payload;\n try {\n payload = text ? JSON.parse(text) : null;\n } catch {\n payload = { content: [{ type: 'text', text }] };\n }\n\n if (!res.ok) {\n const message = (payload && (payload.error || payload.message)) || 'Tool call failed: HTTP ' + res.status;\n const err = new Error(message);\n err.status = res.status;\n err.toolName = toolName;\n throw err;\n }\n\n return payload;\n}\n\nfunction createIntegrationProxy(integrationId) {\n return new Proxy({}, {\n get(_target, methodName) {\n if (typeof methodName !== 'string') return undefined;\n return (args) => callTool(integrationId + '_' + camelToSnake(methodName), args);\n },\n });\n}\n\nexport const client = new Proxy({}, {\n get(_target, integrationId) {\n if (typeof integrationId !== 'string') return undefined;\n return createIntegrationProxy(integrationId);\n },\n});\n\nexport { callTool };\n";
15
+ export declare const RUNTIME_STUB_SOURCE = "// runtime.mjs \u2014 generated by integrate-sdk code mode\nconst MCP_URL = process.env.INTEGRATE_MCP_URL;\nconst SESSION_TOKEN = process.env.INTEGRATE_SESSION_TOKEN;\nconst API_KEY = process.env.INTEGRATE_API_KEY || '';\nconst PROVIDER_TOKENS = process.env.INTEGRATE_PROVIDER_TOKENS || '';\nconst INTEGRATIONS_HEADER = process.env.INTEGRATE_INTEGRATIONS || '';\nconst CONTEXT_JSON = process.env.INTEGRATE_CONTEXT || '';\n\nif (!MCP_URL) {\n throw new Error('INTEGRATE_MCP_URL is not set \u2014 the sandbox cannot reach the MCP route.');\n}\n\nfunction camelToSnake(str) {\n return str.replace(/[A-Z]/g, (letter) => '_' + letter.toLowerCase());\n}\n\nasync function callTool(toolName, args) {\n const headers = {\n 'Content-Type': 'application/json',\n 'x-integrate-code-mode': '1',\n };\n if (SESSION_TOKEN) headers['Authorization'] = 'Bearer ' + SESSION_TOKEN;\n if (API_KEY) headers['x-integrate-api-key'] = API_KEY;\n if (PROVIDER_TOKENS) headers['x-integrate-tokens'] = PROVIDER_TOKENS;\n if (INTEGRATIONS_HEADER) headers['x-integrations'] = INTEGRATIONS_HEADER;\n if (CONTEXT_JSON) headers['x-integrate-context'] = CONTEXT_JSON;\n\n const res = await fetch(MCP_URL, {\n method: 'POST',\n headers,\n body: JSON.stringify({ name: toolName, arguments: args || {} }),\n });\n\n const text = await res.text();\n let payload;\n try {\n payload = text ? JSON.parse(text) : null;\n } catch {\n payload = { content: [{ type: 'text', text }] };\n }\n\n if (!res.ok) {\n let message = (payload && (payload.error || payload.message)) || 'Tool call failed: HTTP ' + res.status;\n if ((res.status === 401 || res.status === 403) && typeof text === 'string' && text.indexOf('Authorization header') !== -1) {\n message =\n 'Code Mode callback was rejected by the MCP server (HTTP ' + res.status + '). ' +\n 'The SDK route could not synthesize an Authorization header. Check the host-side ' +\n 'createMCPServer config (apiKey, getProviderToken) or pass providerTokens to the ' +\n 'AI helper. Original upstream message: ' + text;\n }\n const err = new Error(message);\n err.status = res.status;\n err.toolName = toolName;\n throw err;\n }\n\n return payload;\n}\n\nfunction createIntegrationProxy(integrationId) {\n return new Proxy({}, {\n get(_target, methodName) {\n if (typeof methodName !== 'string') return undefined;\n return (args) => callTool(integrationId + '_' + camelToSnake(methodName), args);\n },\n });\n}\n\nexport const client = new Proxy({}, {\n get(_target, integrationId) {\n if (typeof integrationId !== 'string') return undefined;\n return createIntegrationProxy(integrationId);\n },\n});\n\nexport { callTool };\n";
16
16
  //# sourceMappingURL=runtime-stub.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"runtime-stub.d.ts","sourceRoot":"","sources":["../../../src/code-mode/runtime-stub.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;GAaG;AAEH,eAAO,MAAM,mBAAmB,qtEAqE/B,CAAC"}
1
+ {"version":3,"file":"runtime-stub.d.ts","sourceRoot":"","sources":["../../../src/code-mode/runtime-stub.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;GAaG;AAEH,eAAO,MAAM,mBAAmB,8rFA4E/B,CAAC"}
@@ -40,6 +40,8 @@ export type MCPServerClient<TIntegrations extends readonly MCPIntegration[]> = M
40
40
  }>;
41
41
  }) => Promise<Response>;
42
42
  };
43
+ /** @internal — used by unit tests to reset the warn-once throttle. */
44
+ export declare function __resetUnauthenticatedCodeModeWarnings(): void;
43
45
  /**
44
46
  * Store codeVerifier temporarily for backend redirect flow
45
47
  * @param state - OAuth state parameter
@@ -1 +1 @@
1
- {"version":3,"file":"server.d.ts","sourceRoot":"","sources":["../../src/server.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC;AAExC,OAAO,KAAK,EAAc,eAAe,EAAE,MAAM,mBAAmB,CAAC;AACrE,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,yBAAyB,CAAC;AAU9D,OAAO,KAAK,EAAE,eAAe,EAAE,cAAc,EAAE,MAAM,MAAM,CAAC;AAO5D;;GAEG;AACH,MAAM,MAAM,eAAe,CAAC,aAAa,SAAS,SAAS,cAAc,EAAE,IAAI,SAAS,CAAC,aAAa,CAAC,GAAG;IACxG;+HAC2H;IAC3H,OAAO,EAAE,CAAC,OAAO,EAAE,OAAO,GAAG,eAAe,EAAE,YAAY,CAAC,EAAE;QAAE,MAAM,CAAC,EAAE;YAAE,MAAM,CAAC,EAAE,MAAM,CAAC;YAAC,GAAG,CAAC,EAAE,MAAM,GAAG,MAAM,EAAE,CAAA;SAAE,CAAA;KAAE,GAAG,cAAc,EAAE,OAAO,CAAC,EAAE;QAAE,MAAM,CAAC,EAAE;YAAE,MAAM,CAAC,EAAE,MAAM,CAAC;YAAC,GAAG,CAAC,EAAE,MAAM,GAAG,MAAM,EAAE,CAAA;SAAE,CAAA;KAAE,KAAK,OAAO,CAAC,QAAQ,GAAG,IAAI,CAAC,CAAC;IAC1O,qDAAqD;IACrD,IA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AC,GAC9B,CAAC,CAAC,OAAO,EAAE,OAAO,EAAE,OAAO,CAAC,EAAE;IAAE,MAAM,CAAC,EAAE;QAAE,MAAM,CAAC,EAAE,MAAM,CAAC;QAAC,GAAG,CAAC,EAAE,MAAM,GAAG,MAAM,EAAE,CAAA;KAAE,CAAA;CAAE,KAAK,OAAO,CAAC,QAAQ,CAAC,CAAC,GAC9G;IACA,oCAAoC;IACpC,SAAS,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE;QACzB,QAAQ,EAAE,MAAM,CAAC;QACjB,YAAY,EAAE,MAAM,CAAC;QACrB,WAAW,CAAC,EAAE,MAAM,CAAC;KACtB,CAAC,CAAC;IACH,gCAAgC;IAChC,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,iCAAiC;IACjC,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,wEAAwE;IACxE,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,iEAAiE;IACjE,gBAAgB,CAAC,EAAE,MAAM,CAAC;CAC3B,EACH,gBAAgB,CAAC,EAAE;IACjB,wEAAwE;IACxE,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,iEAAiE;IACjE,gBAAgB,CAAC,EAAE,MAAM,CAAC;CAC3B,WAOsB,GAAG,KAAG,OAAO,CAAC,QAAQ,CAAC,CAgE/C"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "integrate-sdk",
3
- "version": "0.9.14-dev.0",
3
+ "version": "0.9.15-dev.0",
4
4
  "description": "Type-safe 3rd party integration SDK for the Integrate MCP server",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",