Skip to main content
Glama
MarySuneela

Visa Design System MCP Server

by MarySuneela

get-guidelines

Retrieve design guidelines from Visa's Product Design System with optional category filtering to access component specifications and usage resources.

Instructions

Get design guidelines with optional category filtering

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
categoryNoFilter guidelines by category

Implementation Reference

  • MCP tool handler that delegates to GuidelinesService.getGuidelines and formats the result as JSON response with count and applied filters.
    private async handleGetGuidelines(args: Record<string, any>): Promise<CallToolResult> { const guidelines = await this.guidelinesService.getGuidelines(args); return { content: [ { type: 'text', text: JSON.stringify({ guidelines, count: guidelines.length, filters: args }, null, 2) } ] }; }
  • Core service method that retrieves guidelines from data cache, applies category/other filters via filterGuidelines, with circuit breaker and comprehensive error handling.
    @handleErrors async getGuidelines(options?: GuidelineSearchOptions): Promise<Guideline[]> { return this.circuitBreaker.execute(async () => { const cachedData = this.dataManager.getCachedData(); if (!cachedData) { throw new DataError('No guidelines data available', [ 'Ensure data files are loaded', 'Check data directory configuration' ], { service: 'GuidelinesService', method: 'getGuidelines' }); } let guidelines = cachedData.guidelines; // Apply filters if provided if (options) { guidelines = this.filterGuidelines(guidelines, options); } return guidelines; }, { service: 'GuidelinesService', method: 'getGuidelines', options }); }
  • Tool registration definition in getToolDefinitions(): includes name, description, and input schema for category filtering.
    { name: 'get-guidelines', description: 'Get design guidelines with optional category filtering', inputSchema: { type: 'object', properties: { category: { type: 'string', description: 'Filter guidelines by category' } } } },
  • Input schema definition for the get-guidelines tool, allowing optional category filter.
    inputSchema: { type: 'object', properties: { category: { type: 'string', description: 'Filter guidelines by category' } }
  • Switch case routing get-guidelines tool calls to the specific handler function.
    case 'get-guidelines': return await this.handleGetGuidelines(args);

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/MarySuneela/mcp-vpds'

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