Skip to main content
Glama

create-users

Add one or multiple users to your MCP- N8N instance by specifying email and role. Simplify user management with structured input for client ID and user details.

Instructions

Create one or more users in your instance.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
clientIdYes
usersYes

Implementation Reference

  • Executes the create-users tool by retrieving the N8nClient instance using clientId and calling its createUsers method with the users array.
    case "create-users": { const { clientId, users } = args as { clientId: string; users: Array<{ email: string; role?: 'global:admin' | 'global:member' }> }; const client = clients.get(clientId); if (!client) { return { content: [{ type: "text", text: "Client not initialized. Please run init-n8n first.", }], isError: true }; } try { const result = await client.createUsers(users); return { content: [{ type: "text", text: JSON.stringify(result, null, 2), }] }; } catch (error) { return { content: [{ type: "text", text: error instanceof Error ? error.message : "Unknown error occurred", }], isError: true }; } }
  • Input schema definition for the create-users tool, specifying clientId and users array with email (required) and optional role.
    inputSchema: { type: "object", properties: { clientId: { type: "string" }, users: { type: "array", items: { type: "object", properties: { email: { type: "string" }, role: { type: "string", enum: ["global:admin", "global:member"] } }, required: ["email"] } } }, required: ["clientId", "users"] }
  • src/index.ts:566-589 (registration)
    Registration of the create-users tool in the ListToolsRequestSchema handler's tools array, including name, description, and input schema.
    { name: "create-users", description: "Create one or more users in your instance.", inputSchema: { type: "object", properties: { clientId: { type: "string" }, users: { type: "array", items: { type: "object", properties: { email: { type: "string" }, role: { type: "string", enum: ["global:admin", "global:member"] } }, required: ["email"] } } }, required: ["clientId", "users"] }
  • N8nClient helper method that performs the POST request to the /users endpoint to create the users.
    async createUsers(users: Array<{ email: string; role?: 'global:admin' | 'global:member' }>): Promise<any> { return this.makeRequest('/users', { method: 'POST', body: JSON.stringify(users), }); }

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/fellipesaraiva88/n8n-mcp-server'

If you have feedback or need assistance with the MCP directory API, please join our Discord server