remove_workspace_team_member
Remove a workspace team member by specifying their member ID. This tool deletes the user and revokes their access.
Instructions
Remove a team member from the workspace.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| member_id | Yes | Team member ID to remove |
Implementation Reference
- server/index.js:205-208 (handler)The async handler function that executes the remove_workspace_team_member tool logic. It calls apiCall to DELETE /v1/workspace/team/{member_id}.
async ({ member_id }) => { const data = await apiCall(`/v1/workspace/team/${member_id}`, "DELETE"); return { content: [{ type: "text", text: JSON.stringify(data, null, 2) }] }; } - server/index.js:201-203 (schema)Zod schema defining the input parameter: member_id (string) - the team member ID to remove.
{ member_id: z.string().describe("Team member ID to remove"), }, - server/index.js:198-209 (registration)Registration of the remove_workspace_team_member tool on the MCP server, including its title, description, and metadata (destructiveHint: true).
server.tool( "remove_workspace_team_member", "Remove a team member from the workspace.", { member_id: z.string().describe("Team member ID to remove"), }, { title: "Remove Team Member", readOnlyHint: false, destructiveHint: true, openWorldHint: false }, async ({ member_id }) => { const data = await apiCall(`/v1/workspace/team/${member_id}`, "DELETE"); return { content: [{ type: "text", text: JSON.stringify(data, null, 2) }] }; } ); - server/index.js:112-123 (helper)The apiCall helper function used by the handler to make authenticated HTTP requests to the Lindo AI API.
async function apiCall(path, method, body) { const url = `${BASE_URL}${path}`; const res = await fetch(url, { method, headers: { Authorization: `Bearer ${API_KEY}`, "Content-Type": "application/json", }, ...(body ? { body: JSON.stringify(body) } : {}), }); return res.json(); }