Skip to main content
Glama

Preflight brand check

brand_preflight
Read-onlyIdempotent

Validates HTML/CSS against brand rules, catching off-brand colors, wrong fonts, missing logos, and anti-patterns before publishing visual content.

Instructions

Check HTML/CSS against brand rules — catches off-brand colors, wrong fonts, missing logo, and anti-pattern violations (drop shadows, gradients, etc.). Pass an HTML string or file path. Mode 'check' (default) runs all compliance checks and returns pass/warn/fail per rule. Mode 'rules' lists all active preflight rules without checking content. Use after generating any visual content to validate brand compliance. Returns overall status and per-check details. NOT for scoring content copy — use brand_audit_content. NOT for brand directory validation — use brand_audit.

Input Schema

NameRequiredDescriptionDefault
htmlYesHTML to validate: either a full HTML string (with <style> blocks) or a file path ending in .html (e.g. 'output.html')
modeNo'check' (default): validates HTML against all brand rules. 'rules': lists all active rules without running checks.check

Output Schema

NameRequiredDescriptionDefault
_metadataYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv0.17.0
  2. Removedv0.13.4
  3. Changed1 schema field changedv0.11.0
    • changedOutput schema / (root)
      Previous value: -nullNew value: +{
      +  "$schema": "http://json-schema.org/draft-07/schema#",
      +  "additionalProperties": true,
      +  "properties": {
      +    "_metadata": {
      +      "additionalProperties": true,
      +      "properties": {
      +        "next_steps": {
      +          "items": {
      +            "type": "string"
      +          },
      +          "type": "array"
      +        },
      +        "what_happened": {
      +          "type": "string"
      +        }
      +      },
      +      "required": [
      +        "what_happened",
      +        "next_steps"
      +      ],
      +      "type": "object"
      +    }
      +  },
      +  "required": [
      +    "_metadata"
      +  ],
      +  "type": "object"
      +}
  4. First observedv0.5.0

TDQS

A4.5/5.0
Behavior5/5

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

Annotations already declare this as a safe, read-only, idempotent operation, and the description adds meaningful behavioral context: what 'check' returns (pass/warn/fail per rule), what 'rules' does without checking content, and the overall return shape. No contradictions.

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 front-loaded with the core action and scope, then mode behavior, use timing, and exclusions. Every sentence contributes useful routing or behavioral information.

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

Completeness5/5

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

With rich annotations, full parameter schema coverage, and an output schema, the description fills the remaining gaps: mode semantics, when to use it, and which sibling alternatives to use instead. An agent has enough to call it correctly.

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%, and the schema already documents the html string/file-path behavior and the mode enum. The description restates these semantics but adds no additional parameter nuance beyond the schema.

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

Purpose4/5

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

The description gives a specific verb and resource — checking HTML/CSS against brand rules — and lists concrete violation types. It also distinguishes itself from brand_audit_content and brand_audit, but does not explicitly differentiate from the sibling tool brand_check.

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

Usage Guidelines5/5

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

It states exactly when to use the tool (after generating visual content), explains both modes, and explicitly names two non-use cases with alternative tools. The agent has clear routing guidance.

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