pcbdog

API and AI agents

Everything the site does is available as plain HTTP, without an API key: USD quotes, Gerber pre-checks, orders, and saving a quote with an e-mail. Prices are computed from the same tables as the site.

Quote

A USD price per tier (usd) with a door-to-door delivery_by date and its transit_days range. US and EU shipments are DDP: duties are prepaid, the price is final.

curl 'https://pcb.dog/api/quote?layers=4&width_mm=100&height_mm=100&qty=5'

Gerber pre-check

One .zip (Gerber RS-274X + Excellon, up to 25 MB) returns detected layers, board size, hole count, DFM findings and an id. Agents with a shell upload this way and pass the id to the MCP tools as file_id, which costs far less than putting the zip into a tool call as base64.

curl -F [email protected] https://pcb.dog/api/analyze

How an order works

  1. Pre-check the Gerber .zip: POST /api/analyze or analyze_gerbers. You get an id, the layer count and board size read from the file, and any DFM findings.
  2. Create the order: POST /api/orders or create_order with the id, a tier, the quantity, the shipping address and the person's e-mail. The reply is a summary with the USD total, the delivery date, a preview of the board and an order_id. Nothing is charged; the draft is kept for 24 hours.
  3. Show the summary and the preview to the person and get their approval.
  4. Confirm: POST /api/orders/{order_id}/confirm or confirm_order. The reply says whether the order was accepted. A repeated confirm returns the same answer and never places a second order.
curl -X POST https://pcb.dog/api/orders \
  -H 'content-type: application/json' \
  -d '{"file_id":"<id from the pre-check>","tier":"economy","qty":5,
       "email":"[email protected]",
       "ship_to":{"name":"Your Name","line1":"1 Main St","city":"Austin",
                  "postal_code":"78701","country":"US"}}'

curl -X POST https://pcb.dog/api/orders/<order_id>/confirm

Payment

The person pays, not the agent. An accepted order's reply carries a payment link for the person to open. The agent never sees card details and needs no API key, account or crypto wallet. Prices are in USD and final; US and EU shipments include duties.

Save a quote

Send the spec, a tier and an e-mail; the price is computed server-side. The e-mail is used only to follow up on that quote.

curl -X POST https://pcb.dog/api/leads \
  -H 'content-type: application/json' \
  -d '{"kind":"quote","spec":{"layers":4,"qty":5,"widthMm":100,"heightMm":100},
       "tier":"economy","email":"[email protected]"}'

MCP

A Model Context Protocol server (Streamable HTTP, no auth): quoting, Gerber analysis from a URL, cost reductions, capability limits, ordering and quote saving. Prices are computed server-side from the same tables as the site.

Endpoint:    https://pcb.dog/mcp
Server card: https://pcb.dog/.well-known/mcp/server-card.json

Machine-readable descriptions

Capability limits are on the capabilities page. Questions: [email protected].