get_tenant_provider
Retrieve provider details for a specific tenant on the UseGrant MCP Server by submitting tenantId and providerId to ensure accurate tenant-provider association and access management.
Instructions
Get a provider for a tenant
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| providerId | Yes | The ID of the tenant provider | |
| tenantId | Yes | The ID of the tenant |
Implementation Reference
- src/index.ts:296-301 (handler)The handler function that executes the tool logic: fetches the tenant provider via UseGrant SDK and returns JSON response.async ({ tenantId, providerId }) => { const provider = await usegrant.getTenantProvider(tenantId, providerId); return { content: [{ type: 'text', text: JSON.stringify(provider, null, 2) }], }; },
- src/index.ts:292-295 (schema)Input parameters schema using Zod schemas from UseGrant SDK for tenantId and providerId.{ tenantId: UgSchema.TenantIdSchema, providerId: UgSchema.TenantProviderIdSchema, },
- src/index.ts:289-302 (registration)MCP server tool registration including name, description, schema, and inline handler.server.tool( 'get_tenant_provider', 'Get a provider for a tenant', { tenantId: UgSchema.TenantIdSchema, providerId: UgSchema.TenantProviderIdSchema, }, async ({ tenantId, providerId }) => { const provider = await usegrant.getTenantProvider(tenantId, providerId); return { content: [{ type: 'text', text: JSON.stringify(provider, null, 2) }], }; }, );