Skip to main content
Glama

Extract KiCad PCB footprint (.kicad_mod)

datasheetvend_extract_kicad_footprint
Read-onlyIdempotent

Write a KiCad PCB footprint (.kicad_mod) from a datasheet's package mechanical drawing: pad geometry, pitch, thermal tabs and courtyard, using the datasheet's own recommended land pattern when it prints one, otherwise simplified IPC-7351B fillet math. Emitted files are loaded with kicad-cli (sym/fp upgrade) where it is installed, which is a file-format check, not a DRC or ERC. Only bundle_status "completed" (with final_readiness.physical_truth_approved true) means the placement was independently proven against this document; "needs_review" covers everything else that still produced a file, including one built from the KiCad library or JEDEC/IPC-7351B math instead of this document (see footprint_provenance).

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "documentPath": "<documentPath>"
    },
    "name": "datasheetvend_extract_kicad_footprint"
  }
}

Input Schema

NameRequiredDescriptionDefault
partNameNoOptional part number / MPN to disambiguate package variants.
documentPathYeshttps:// URL to the datasheet PDF. The remote /api/mcp endpoint accepts ONLY https:// URLs (it downloads them); a local filesystem path works solely in local stdio mode (npm run mcp:serve)..
packageSelectionNoOptional package/variant (e.g. 'LQFP48', 'SOIC8', 'QFN32').

Output Schema

NameRequiredDescriptionDefault
inputsYes
reviewYes
statusYesThe pipeline's own run status. FAILED means nothing usable was produced and the credits for this call are refunded automatically.
contractYesContract schema identifier: kicad_evidence_v1
warningsYesEngineering warnings emitted during generation
kicad_modYesComplete KiCad PCB footprint (.kicad_mod) file content, or null if withheld/not produced.
requestedYesExactly what the caller sent, kept distinct from the resolved identity above.
validationYeskicad-cli file-load result (sym/fp upgrade — a format check, not a DRC).
user_reportYesWhat the engineer must check, in the same words as the dashboard, README.txt and API v1: a status line that matches the files (Proven only when the readiness verdict proves the run), per-file state, and one to_check entry per code. review.reasons lists the same to_check lines. technical_details_count counts the other notes, none of which needs action.
bundle_statusYescompleted = both requested files were proven against this document. needs_review = a run finished (or a fallback file was attached) without that proof. cannot_extract = nothing usable. null = the pipeline never reached a stage that could compute this.
status_detailYes
human_warningsYes
final_readinessYesThe emit gate's full verdict. null when the pipeline never reached this stage.
package_variantYesResolved package code.
symbol_provenanceYesSet only when this file did NOT come from this document's own extraction (a KiCad-library match or JEDEC/IPC-7351B math instead). null means the file was built from this document.
footprint_provenanceYesSet only when this file did NOT come from this document's own extraction (a KiCad-library match or JEDEC/IPC-7351B math instead). null means the file was built from this document.
manufacturer_part_numberYesResolved by the pipeline's identity resolution — not an echo of the input. See requested.part_name for what was sent.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed2 schema fields changed
    • addedOutput schema / properties / user_report
      Added value: +{
      +  "anyOf": [
      +    {
      +      "additionalProperties": false,
      +      "properties": {
      +        "files": {
      +          "additionalProperties": false,
      +          "properties": {
      +            "footprint": {
      +              "type": "string"
      +            },
      +            "symbol": {
      +              "type": "string"
      +            }
      +          },
      +          "required": [
      +            "symbol",
      +            "footprint"
      +          ],
      +          "type": "object"
      +        },
      +        "human_review_required": {
      +          "type": "boolean"
      +        },
      +        "status_line": {
      +          "type": "string"
      +        },
      +        "technical_details_count": {
      +          "type": "number"
      +        },
      +        "to_check": {
      +          "items": {
      +            "additionalProperties": false,
      +            "properties": {
      +              "action": {
      +                "type": "string"
      +              },
      +              "code": {
      +                "type": "string"
      +              },
      +              "file": {
      +                "enum": [
      +                  "symbol",
      +                  "footprint",
      +                  "package",
      +                  "bundle"
      +                ],
      +                "type": "string"
      +              },
      +              "level": {
      +                "enum": [
      +                  "blocking",
      +                  "review"
      +                ],
      +                "type": "string"
      +              },
      +              "line": {
      +                "type": "string"
      +              },
      +              "pages": {
      +                "items": {
      +                  "type": "number"
      +                },
      +                "type": "array"
      +              },
      +              "title": {
      +                "type": "string"
      +              },
      +              "why": {
      +                "type": "string"
      +              }
      +            },
      +            "required": [
      +              "code",
      +              "file",
      +              "level",
      +              "title",
      +              "why",
      +              "action",
      +              "pages",
      +              "line"
      +            ],
      +            "type": "object"
      +          },
      +          "type": "array"
      +        },
      +        "verdict": {
      +          "enum": [
      +            "proven",
      +            "checks_passed",
      +            "draft",
      +            "no_files"
      +          ],
      +          "type": "string"
      +        }
      +      },
      +      "required": [
      +        "status_line",
      +        "verdict",
      +        "files",
      +        "to_check",
      +        "technical_details_count",
      +        "human_review_required"
      +      ],
      +      "type": "object"
      +    },
      +    {
      +      "type": "null"
      +    }
      +  ],
      +  "description": "What the engineer must check, in the same words as the dashboard, README.txt and API v1: a status line that matches the files (Proven only when the readiness verdict proves the run), per-file state, and one to_check entry per code. review.reasons lists the same to_check lines. technical_details_count counts the other notes, none of which needs action."
      +}
    • changedOutput schema / required
      Previous value: -[
      -  "contract",
      -  "manufacturer_part_number",
      -  "package_variant",
      -  "kicad_mod",
      -  "validation",
      -  "review",
      -  "warnings",
      -  "status",
      -  "bundle_status",
      -  "requested",
      -  "inputs",
      -  "status_detail",
      -  "human_warnings",
      -  "footprint_provenance",
      -  "symbol_provenance",
      -  "final_readiness"
      -]New value: +[
      +  "contract",
      +  "manufacturer_part_number",
      +  "package_variant",
      +  "kicad_mod",
      +  "validation",
      +  "review",
      +  "warnings",
      +  "status",
      +  "bundle_status",
      +  "requested",
      +  "inputs",
      +  "status_detail",
      +  "human_warnings",
      +  "footprint_provenance",
      +  "symbol_provenance",
      +  "final_readiness",
      +  "user_report"
      +]
  2. Added

TDQS

A3.9/5.0
Behavior5/5

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

Beyond the annotations, the description discloses material behavior: kicad-cli loading is a file-format check only, not DRC/ERC, and the bundle_status semantics are spelled out precisely — only 'completed' with physical_truth_approved true means placement was independently proven, while 'needs_review' covers files built from the KiCad library or JEDEC/IPC math instead of the document. The pointer to footprint_provenance tells the agent where to verify origin. This is exactly the kind of provenance and validation caveat annotations cannot carry.

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?

Two sentences, no filler, and the core action plus artifact type are front-loaded. The second sentence is long and packs three distinct ideas (validation scope, bundle_status meaning, provenance fallback), which is dense but each clause carries real information.

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?

With an output schema present, return values need no explanation, and the description still covers validation limits and status semantics that the schema cannot. What remains unaddressed is the input prerequisite (a legible package mechanical drawing) and whether package-dimension extraction should precede this call.

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 documentPath, partName and packageSelection are already well documented, and the description only gestures at 'this document' without adding format, URL, or disambiguation detail beyond the schema. The baseline of 3 applies because the schema does the parameter-level work.

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 opens with a specific verb and artifact: 'Write a KiCad PCB footprint (.kicad_mod) from a datasheet's package mechanical drawing', and enumerates what goes into it (pad geometry, pitch, thermal tabs, courtyard). It does not explicitly differentiate itself from close siblings such as datasheetvend_match_kicad_footprint or datasheetvend_extract_kicad_symbol, so an agent must infer the distinction from the artifact extension alone.

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?

Usage context is implied rather than stated: it is clear you call this when you need a .kicad_mod, and the description explains which land-pattern source will be used (datasheet-recommended pattern first, IPC-7351B fillet math otherwise). However, there is no explicit when-to-use-this-vs-alternatives guidance against siblings like match_kicad_footprint or calculate_land_pattern, and no stated prerequisites (e.g. that the document must contain a mechanical drawing).

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources