Skip to main content
Glama
Keycloak MCP Server

Keycloak MCP Server

by Cayetano97

get_effective_client_template_realm_scope_mappings

Retrieves effective realm-level roles for a client scope, recursively including roles inherited through composite roles.

Instructions

Get effective realm-level roles associated with the client’s scope What this does is recurse any composite roles associated with the client’s scope and adds the roles to this lists.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "realm": "<realm>",
      "client_scope_id": "<client_scope_id>"
    },
    "name": "get_effective_client_template_realm_scope_mappings"
  }
}

Input Schema

NameRequiredDescriptionDefault
realmYesRealm name
client_scope_idYesClient scope ID
briefRepresentationNoif false, return roles with their attributes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv2.0.0

TDQS

C2.8/5.0
Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations at all, the description carries the full burden, and it does disclose one genuinely useful trait: composite roles are recursively expanded and folded into the result, so 'effective' means inherited plus direct roles. It says nothing about required permissions, whether the call is read-only, pagination, or result ordering, which is a meaningful gap for a no-annotation tool.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness3/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The purpose is front-loaded, which is good, but the second sentence is a run-on with rough grammar ("What this does is recurse...", "adds the roles to this lists") and a stray encoding artifact in the text. The recursion point could be one clean clause instead of a whole sentence.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a three-parameter read tool with full schema coverage and no output schema, the essentials are mostly present, including the composite-role behavior that defines 'effective'. What is missing is the return shape (list of role representations?), the effect of briefRepresentation on that shape, and any disambiguation from the many sibling mapping tools.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 100%, with realm, client_scope_id, and briefRepresentation each documented, so the schema already does the parameter work. The description adds no meaning beyond it — notably it never explains that briefRepresentation=false returns role attributes, which is the only non-obvious parameter behavior.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose3/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description gives a verb and a resource ("Get effective realm-level roles associated with the client's scope") and even explains the recursion semantics, which is more than a bare restatement. However, it never mentions "client template" even though the tool name and the sibling catalog are full of near-identical variants (get_effective_client_realm_scope_mappings, get_effective_client_scope_realm_scope_mappings, get_effective_client_template_client_scope_mappings). It also conflates "client's scope" with the template the tool actually targets, so an agent cannot cleanly separate it from its siblings.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

There is no when-to-use guidance, no statement of when-not-to-use, and no named alternative among the many parallel 'effective vs available vs assigned' mapping tools. The only contextual hint is the recursion clause, which describes behavior rather than selection criteria.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Deploy Server

Other Tools