diff --git a/package-lock.json b/package-lock.json index f008ed8..60defee 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,15 +1,15 @@ { "name": "@linkedapi/mcp", - "version": "2.1.3", + "version": "2.2.1", "lockfileVersion": 3, "requires": true, "packages": { "": { "name": "@linkedapi/mcp", - "version": "2.1.3", + "version": "2.2.1", "license": "MIT", "dependencies": { - "@linkedapi/node": "^2.2.0", + "@linkedapi/node": "^2.2.1", "@modelcontextprotocol/sdk": "^1.17.4", "zod": "^4.1.1" }, @@ -921,10 +921,9 @@ } }, "node_modules/@linkedapi/node": { - "version": "2.2.0", - "resolved": "https://registry.npmjs.org/@linkedapi/node/-/node-2.2.0.tgz", - "integrity": "sha512-VA8SnZYyfVeaKxkN7OlJb2uwgYoyhBlhXrdqV4+6LZ2NJ7as9QknhHizVJqdGeyapgM+4yqCgO2t9kIlw+pItg==", - "license": "MIT" + "version": "2.2.1", + "resolved": "https://registry.npmjs.org/@linkedapi/node/-/node-2.2.1.tgz", + "integrity": "sha512-4Qdcsog5S/1UxFfYAGNlb63NMh2aCg9o3+CCGfKC4XJrosDwqykhXSa/2fT7OG3UwVkSqM7s2kl/BB7sF8um5Q==" }, "node_modules/@modelcontextprotocol/sdk": { "version": "1.26.0", diff --git a/package.json b/package.json index 0cdb1f1..9bde905 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@linkedapi/mcp", - "version": "2.2.0", + "version": "2.2.1", "description": "MCP server that lets AI assistants control LinkedIn accounts and retrieve real-time data.", "main": "dist/index.js", "bin": { @@ -30,7 +30,7 @@ "author": "Linked API", "license": "MIT", "dependencies": { - "@linkedapi/node": "^2.2.0", + "@linkedapi/node": "^2.2.1", "@modelcontextprotocol/sdk": "^1.17.4", "zod": "^4.1.1" }, diff --git a/src/tools/send-message.ts b/src/tools/send-message.ts index 852a4e1..8832b35 100644 --- a/src/tools/send-message.ts +++ b/src/tools/send-message.ts @@ -11,13 +11,18 @@ export class SendMessageTool extends OperationTool personUrl: z.string().optional(), text: z.string().min(1), threadId: z.string().optional(), + manageConversation: z + .object({ + operation: z.enum(['archive', 'unarchive', 'star', 'unstar', 'mute', 'unmute']), + }) + .optional(), }); public override getTool(): Tool { return { name: this.name, description: - 'Allows you to send a message to a person (st.sendMessage action). Provide either personUrl or threadId (threadId replies into an existing conversation thread and takes precedence). If this workflow is still running, do not retry this tool; retrying can send duplicate messages to the same person.', + 'Allows you to send a message to a person (st.sendMessage action). Provide either personUrl or threadId (threadId replies into an existing conversation thread and takes precedence). Optionally pass manageConversation to archive, star, or mute the conversation right after the message is sent (chained st.manageConversation child, acting on the same thread). If this workflow is still running, do not retry this tool; retrying can send duplicate messages to the same person.', inputSchema: { type: 'object', properties: { @@ -35,6 +40,19 @@ export class SendMessageTool extends OperationTool description: 'Optional conversation thread identifier to reply into, as returned by get_inbox. Provide this instead of personUrl to reply directly into a known thread.', }, + manageConversation: { + type: 'object', + description: + 'Optional. Manage the conversation right after the message is sent. Acts on the same thread, so no threadId is needed.', + properties: { + operation: { + type: 'string', + enum: ['archive', 'unarchive', 'star', 'unstar', 'mute', 'unmute'], + description: 'Operation to apply to the conversation after sending the message.', + }, + }, + required: ['operation'], + }, }, required: ['text'], },