Skip to main content
Glama
huseyindol

User Info MCP Server

by huseyindol

add_user

Add new users to the User Info MCP Server by providing name, email, and phone number for user information management.

Instructions

Yeni kullanıcı ekle

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
nameYesKullanıcının tam adı
emailYesE-posta adresi
phoneYesTelefon numarası

Implementation Reference

  • The handler function that executes the add_user tool logic. It calls userService.createUser and returns a formatted MCP response.
    static async handleAddUser({ name, email, phone }: { name: string; email: string; phone: string }): Promise<ToolResponse> { try { const result = await userService.createUser({ name, email, phone }); return { content: [ { type: "text", text: result.success ? `${result.message}\n${JSON.stringify(result.data, null, 2)}` : result.error || "Kullanıcı oluşturulamadı", }, ], }; } catch (error) { return { content: [ { type: "text", text: "Kullanıcı oluşturma işleminde hata oluştu", }, ], }; } }
  • Zod schema defining the input parameters for the add_user tool: name, email, phone.
    export const AddUserInputSchema = { name: z.string().min(2).max(100).describe("Kullanıcının tam adı"), email: z.string().email().describe("E-posta adresi"), phone: z.string().min(10).max(20).describe("Telefon numarası") };
  • Registers the 'add_user' tool with the MCP server, specifying name, metadata, input schema, and handler.
    server.registerTool( "add_user", { title: "Kullanıcı Ekle", description: "Yeni kullanıcı ekle", inputSchema: AddUserInputSchema, }, UserController.handleAddUser );

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/huseyindol/McpProjectScaffold'

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