@flutchai/flutch-sdk 0.7.5 → 0.7.6

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.
package/dist/index.js CHANGED
@@ -6814,6 +6814,7 @@ ${paramDescriptions.join("\n")}`;
6814
6814
  }
6815
6815
  }
6816
6816
  };
6817
+ var MCP_RUNTIME_TIMEOUT_MS = Number(process.env.MCP_RUNTIME_TIMEOUT_MS) || 2e4;
6817
6818
  var McpToolFilter = class _McpToolFilter {
6818
6819
  static {
6819
6820
  __name(this, "McpToolFilter");
@@ -6847,7 +6848,7 @@ var McpToolFilter = class _McpToolFilter {
6847
6848
  if (context) requestBody.context = context;
6848
6849
  this.logger.debug(`[DEBUG] Request body: ${JSON.stringify(requestBody)}`);
6849
6850
  const response = await axios2.post(`${this.mcpRuntimeUrl}/tools/schemas`, requestBody, {
6850
- timeout: 5e3,
6851
+ timeout: MCP_RUNTIME_TIMEOUT_MS,
6851
6852
  headers: {
6852
6853
  "Content-Type": "application/json"
6853
6854
  }
@@ -6890,7 +6891,7 @@ var McpToolFilter = class _McpToolFilter {
6890
6891
  async getAllTools() {
6891
6892
  try {
6892
6893
  const response = await axios2.get(`${this.mcpRuntimeUrl}/tools/list`, {
6893
- timeout: 5e3
6894
+ timeout: MCP_RUNTIME_TIMEOUT_MS
6894
6895
  });
6895
6896
  const allTools = Array.isArray(response.data) ? response.data : [];
6896
6897
  this.logger.debug(`Retrieved ${allTools.length} total MCP tools`);
@@ -6937,7 +6938,7 @@ var McpToolFilter = class _McpToolFilter {
6937
6938
  async getAvailableToolNames() {
6938
6939
  try {
6939
6940
  const response = await axios2.get(`${this.mcpRuntimeUrl}/tools/list`, {
6940
- timeout: 5e3
6941
+ timeout: MCP_RUNTIME_TIMEOUT_MS
6941
6942
  });
6942
6943
  const tools = Array.isArray(response.data) ? response.data : [];
6943
6944
  return tools.map((tool) => tool.name);