@optimizeoverseas/lacrm-enforcement-wrapper 1.0.2 → 1.0.3

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.
Files changed (2) hide show
  1. package/build/index.js +5 -5
  2. package/package.json +1 -1
package/build/index.js CHANGED
@@ -5,8 +5,8 @@ import { Client } from '@modelcontextprotocol/sdk/client/index.js';
5
5
  import { StdioClientTransport } from '@modelcontextprotocol/sdk/client/stdio.js';
6
6
  import { CallToolRequestSchema, ListToolsRequestSchema, } from '@modelcontextprotocol/sdk/types.js';
7
7
  // --- Configuration ---
8
- const MAX_UNIQUE_CONTACTS = 10;
9
- const MAX_TOTAL_OPERATIONS = 50;
8
+ const MAX_UNIQUE_CONTACTS = 20;
9
+ const MAX_TOTAL_OPERATIONS = 80;
10
10
  const INACTIVITY_TIMEOUT_MS = 10 * 60 * 1000; // 10 minutes
11
11
  const DOWNSTREAM_COMMAND = 'node';
12
12
  const DOWNSTREAM_ARGS = ['/usr/local/lib/node_modules/@optimizeoverseas/lacrm-mcp/build/index.js'];
@@ -46,17 +46,17 @@ function extractContactId(toolName, args) {
46
46
  }
47
47
  function checkBudgets(toolName, args) {
48
48
  if (totalOperations >= MAX_TOTAL_OPERATIONS) {
49
- return `Session operation limit reached (${MAX_TOTAL_OPERATIONS}). No more operations can be performed in this session.`;
49
+ return `CRM operation limit reached (${MAX_TOTAL_OPERATIONS} operations). To continue, please start a new request.`;
50
50
  }
51
51
  if (CONTACT_MUTATING_TOOLS.has(toolName)) {
52
52
  const contactId = extractContactId(toolName, args);
53
53
  // For edit_contact, check if adding this contact would exceed the limit
54
54
  if (contactId && !modifiedContacts.has(contactId) && modifiedContacts.size >= MAX_UNIQUE_CONTACTS) {
55
- return `Unique contact modification limit reached (${MAX_UNIQUE_CONTACTS}). You have already modified ${MAX_UNIQUE_CONTACTS} distinct contacts in this session. You may still edit contacts you have already modified: ${[...modifiedContacts].join(', ')}`;
55
+ return `Contact limit reached (${MAX_UNIQUE_CONTACTS} unique contacts). You can still edit contacts you've already modified: ${[...modifiedContacts].join(', ')}. To modify additional contacts, please start a new request.`;
56
56
  }
57
57
  // For create_contact (no contactId yet), check if there's room for one more
58
58
  if (!contactId && modifiedContacts.size >= MAX_UNIQUE_CONTACTS) {
59
- return `Unique contact modification limit reached (${MAX_UNIQUE_CONTACTS}). Cannot create new contacts you have already modified ${MAX_UNIQUE_CONTACTS} distinct contacts in this session.`;
59
+ return `Contact limit reached (${MAX_UNIQUE_CONTACTS} unique contacts). No additional contacts can be created or modified in this request. Please start a new request to continue.`;
60
60
  }
61
61
  }
62
62
  return null;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@optimizeoverseas/lacrm-enforcement-wrapper",
3
- "version": "1.0.2",
3
+ "version": "1.0.3",
4
4
  "description": "MCP proxy wrapper enforcing session limits on LACRM MCP",
5
5
  "type": "module",
6
6
  "main": "build/index.js",