get_user
Retrieve detailed user information by specifying a user ID using the MCP Server’s API integration with SD Elements security platform.
Instructions
Get detailed information about a specific user
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| user_id | Yes | The ID of the user to retrieve |
Implementation Reference
- src/sde_mcp_server/tools/users.py:25-32 (handler)The primary handler function for the 'get_user' tool. It initializes the API client if necessary, calls api_client.get_user(user_id), and returns the result as formatted JSON. The @mcp.tool() decorator handles registration and schema inference from signature and docstring.@mcp.tool() async def get_user(ctx: Context, user_id: int) -> str: """Get details of a specific user""" global api_client if api_client is None: api_client = init_api_client() result = api_client.get_user(user_id) return json.dumps(result, indent=2)
- src/sde_mcp_server/tools/__init__.py:7-7 (registration)Import statement in tools/__init__.py that loads the users module, executing the @mcp.tool() decorators to register the get_user tool.from .users import *
- src/sde_mcp_server/server.py:296-296 (registration)Import in server.py that loads the tools package, transitively importing users.py and completing tool registration before running the MCP server.from . import tools # noqa: F401