Skip to main content
Glama

get_user

Retrieve detailed user information by specifying a user ID and optional realm within the Keycloak identity management system.

Instructions

Get a specific user by ID. Args: user_id: The user's ID realm: Target realm (uses default if not specified) Returns: User object

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
realmNo
user_idYes

Implementation Reference

  • The handler function for the 'get_user' MCP tool. It is decorated with @mcp.tool() which registers it, retrieves user details from Keycloak API using the provided user_id and optional realm.
    @mcp.tool() async def get_user(user_id: str, realm: Optional[str] = None) -> Dict[str, Any]: """ Get a specific user by ID. Args: user_id: The user's ID realm: Target realm (uses default if not specified) Returns: User object """ return await client._make_request("GET", f"/users/{user_id}", realm=realm)

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/idoyudha/mcp-keycloak'

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