get_group
Retrieve a specific group by ID from Keycloak's identity management system, optionally specifying a target realm. Returns the group object for accurate access control.
Instructions
Get a specific group by ID.
Args:
group_id: Group ID
realm: Target realm (uses default if not specified)
Returns:
Group object
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| group_id | Yes | ||
| realm | No |
Implementation Reference
- src/tools/group_tools.py:39-52 (handler)The get_group tool handler: fetches a specific group by ID using KeycloakClient, registered via @mcp.tool() decorator.@mcp.tool() async def get_group(group_id: str, realm: Optional[str] = None) -> Dict[str, Any]: """ Get a specific group by ID. Args: group_id: Group ID realm: Target realm (uses default if not specified) Returns: Group object """ return await client._make_request("GET", f"/groups/{group_id}", realm=realm)