Skip to main content
Glama

get_logos

Retrieves logo variants with usage guidelines, minimum sizes, clear space rules, and forbidden uses. Optionally returns base64-encoded image data.

Instructions

Get logo variants (primary, mark, wordmark, monochrome) with usage guidelines, minimum sizes, clear space rules, and forbidden uses. Optionally returns base64-encoded image data.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
variantNoFilter by variant name (e.g., 'primary', 'mark', 'wordmark')
formatNoWhether to include base64 datametadata

Implementation Reference

  • The tool name is exported as 'get_logos', used to register this tool with the MCP server.
    export const TOOL_NAME = 'get_logos';
  • The tool description, shown in the MCP ListTools response.
    export const TOOL_DESCRIPTION =
      'Get logo variants (primary, mark, wordmark, monochrome) with usage guidelines, minimum sizes, clear space rules, and forbidden uses. Optionally returns base64-encoded image data.';
  • Input schema for get_logos: accepts optional 'variant' (string filter) and 'format' (metadata or base64).
    export const INPUT_SCHEMA = {
      type: 'object' as const,
      properties: {
        variant: { type: 'string', description: "Filter by variant name (e.g., 'primary', 'mark', 'wordmark')" },
        format: { type: 'string', enum: ['metadata', 'base64'], default: 'metadata', description: 'Whether to include base64 data' },
      },
    };
  • Main handler function. Retrieves logo variants from the design system index, optionally filters by variant name, and optionally includes base64-encoded image data. Returns JSON with variants, usage guidelines, clear space, minimum size, and forbidden usage.
    export async function handler(index: DesignSystemIndex, args: GetLogosArgs) {
      const logos = index.resolved.all.logos;
      const format = args?.format ?? 'metadata';
    
      let variants = logos.variants;
      if (args.variant) {
        variants = variants.filter((v) => v.name.toLowerCase().includes(args.variant!.toLowerCase()));
      }
    
      if (variants.length === 0) {
        return [{ type: 'text' as const, text: 'No logo variants found matching the criteria.' }];
      }
    
      // Build variant data, optionally including base64 data URIs
      const variantData = await Promise.all(
        variants.map(async (v) => {
          const entry: Record<string, unknown> = {
            name: v.name,
            format: v.format,
            width: v.width,
            height: v.height,
            filePath: v.filePath,
          };
    
          if (format === 'base64') {
            const abs = v.source
              ?? (v.filePath && isAbsolute(v.filePath) ? v.filePath : null)
              ?? (v.filePath ? resolve(process.cwd(), v.filePath) : null);
            if (abs && existsSync(abs)) {
              try {
                entry.dataUri = await generateBase64DataURI(abs);
              } catch {
                entry.dataUriError = 'Could not encode logo as base64';
              }
            } else {
              entry.dataUriError = 'Logo source file not found';
            }
          }
    
          return entry;
        }),
      );
    
      const result: Record<string, unknown> = {
        variants: variantData,
        usageGuidelines: logos.usageGuidelines,
        clearSpace: logos.clearSpace,
        minimumSize: logos.minimumSize,
        forbiddenUsage: logos.forbiddenUsage,
      };
    
      return [{ type: 'text' as const, text: JSON.stringify(result, null, 2) }];
    }
  • Registers the get_logos handler in the CallToolRequestSchema switch statement, routing 'get_logos' calls to logos.handler().
    case logos.TOOL_NAME:
      return { content: await logos.handler(index, args as never) };
Behavior3/5

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

No annotations are provided, so the description must cover behavioral aspects. It discloses optional base64 data return but omits details on rate limits, authentication requirements, or whether the data is cached. The description is adequate but not rich.

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

Conciseness5/5

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

The description is a single, well-structured sentence that quickly conveys the tool's purpose and key features. Every part is relevant and front-loaded.

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

Completeness4/5

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

Given the absence of annotations and output schema, the description covers the main functionality well. It specifies what is returned (variants, guidelines, base64). A small gap is that it doesn't describe the output format for metadata, but it is relatively complete.

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%, so baseline is 3. The description adds minimal value beyond the schema: it repeats the variant filtering and format options. It mentions usage guidelines but these are not parameters. No significant extra semantics.

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

Purpose5/5

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

The description clearly states the tool retrieves logo variants with specific features like usage guidelines and minimum sizes. It distinguishes itself from sibling tools such as get_colors and get_typography by focusing on logos.

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

Usage Guidelines3/5

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

The description implies usage for obtaining logos but lacks explicit guidance on when to use it versus alternatives like search_brand or get_brand_overview. No when-not or exclusion criteria are mentioned.

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

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/ejwhite7/brandkit-mcp'

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