Skip to main content
Glama
usegranthq

UseGrant MCP Server

Official
by usegranthq

get_tenant_provider_policy

Retrieve access policies for tenant providers by specifying tenant ID, provider ID, and policy ID. Facilitates managed access control in the UseGrant MCP Server platform.

Instructions

Get a policy for a tenant provider

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
policyIdYesThe ID of the tenant provider policy
providerIdYesThe ID of the tenant provider
tenantIdYesThe ID of the tenant

Implementation Reference

  • Handler function that retrieves the tenant provider policy using the UseGrant SDK and returns it as JSON.
    async ({ tenantId, providerId, policyId }) => {
      const policy = await usegrant.getTenantProviderPolicy(tenantId, providerId, policyId);
      return {
        content: [{ type: 'text', text: JSON.stringify(policy, null, 2) }],
      };
    },
  • Input schema for the tool, defining tenantId, providerId, and policyId using schemas from @usegrant/sdk/schema.
    {
      tenantId: UgSchema.TenantIdSchema,
      providerId: UgSchema.TenantProviderIdSchema,
      policyId: UgSchema.TenantProviderPolicyIdSchema,
    },
  • src/index.ts:350-364 (registration)
    Registration of the 'get_tenant_provider_policy' tool with the MCP server, including description, input schema, and handler.
    server.tool(
      'get_tenant_provider_policy',
      'Get a policy for a tenant provider',
      {
        tenantId: UgSchema.TenantIdSchema,
        providerId: UgSchema.TenantProviderIdSchema,
        policyId: UgSchema.TenantProviderPolicyIdSchema,
      },
      async ({ tenantId, providerId, policyId }) => {
        const policy = await usegrant.getTenantProviderPolicy(tenantId, providerId, policyId);
        return {
          content: [{ type: 'text', text: JSON.stringify(policy, null, 2) }],
        };
      },
    );
Behavior2/5

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

With no annotations provided, the description carries the full burden of behavioral disclosure. It states 'Get a policy' which implies a read-only operation, but it doesn't clarify if this requires authentication, returns specific data formats, handles errors, or has any side effects. For a tool with three required parameters and no annotation coverage, this leaves significant behavioral gaps.

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

Conciseness4/5

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

The description is a single, straightforward sentence that efficiently conveys the core action without unnecessary words. It's front-loaded with the key verb 'Get,' making it easy to parse. However, it could be slightly more informative without losing conciseness, such as by hinting at the policy type or usage context.

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

Completeness2/5

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

Given the complexity of a tool with three required parameters, no annotations, and no output schema, the description is incomplete. It doesn't explain what the policy entails, the return format, error conditions, or how it fits into the broader context of tenant provider management. This leaves the agent with insufficient information to use the tool effectively beyond basic parameter passing.

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?

The schema description coverage is 100%, with clear descriptions for each parameter (policyId, providerId, tenantId) in the input schema. The description adds no additional parameter semantics beyond what's already documented in the schema, such as format examples or relationships between IDs. This meets the baseline score of 3 since the schema adequately covers parameter details.

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 'Get a policy for a tenant provider' clearly states the action (get) and resource (policy for a tenant provider), making the purpose understandable. However, it doesn't distinguish this tool from its sibling 'list_tenant_provider_policies' or specify what type of policy it retrieves (e.g., security, access), leaving it somewhat vague compared to more specific alternatives.

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?

The description provides no guidance on when to use this tool versus alternatives like 'list_tenant_provider_policies' for listing multiple policies or other 'get_' tools for different resources. It lacks context about prerequisites, such as needing existing tenant, provider, and policy IDs, or when this retrieval is appropriate over other operations.

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

Install Server

Other Tools

Related Tools

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/usegranthq/mcp-server'

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