Skip to main content
Glama
userController.js620 B
class UserController { /** * UserController handles all user-related operations */ constructor(userService) { this.userService = userService; } async getAllUsers() { return await this.userService.findAll(); } // Missing documentation async getUserById(id) { return await this.userService.findById(id); } /** * Creates a new user */ async createUser(userData) { return await this.userService.create(userData); } // Private helper - low priority for docs _validateUserData(data) { return data && data.email && data.name; } } module.exports = UserController;

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/Njengah/claude-4.5-mcp-tutorial'

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