For agents

Docs for agents

Written for the agent that calls Whet, then for you. Give a coding agent one address and it gets the endpoint, the fields, every error code and the rules for telling a customer what Whet found.

View as Markdown

Paste into your agent

prompt.txttext
Read https://whet.design/llms.txt, then add font identification to this project with Whet's API.
The key is in the env var WHET_API_KEY. Follow the relay rules in that file:
only call a font "the font" when decision is "same".

Three files, one truth

FileWhat it holds
/llms.txtEvery API on one Markdown page: base URL, authentication, endpoints, decisions, errors and limits.
/api/v1/openapi.jsonOpenAPI 3.1. Descriptions say when to retry and what each decision allows, so a generated client or a tool definition carries the rules with it.
<page>.mdEvery docs page as Markdown at its own address plus .md, such as /docs/fonts/identify.md.

Relay rules

What an agent may tell a customer about a font identification.

  1. Only when decision is same may you say “this is the font”.
  2. For closest, say “closest open font” and offer the shortlist. The original is likely a commercial font.
  3. For none, first check the text you sent: a misread word fits no font. Then hand it to a person.
  4. Never round a closest up to same, whatever the iou.
  5. Name the licence with the font. Every font Whet returns is open.

Calling Whet from an agent

  • One word per call. Split a logo into its words and send each with its box. Two typefaces in one call fit neither.
  • Read the text yourself. Whet checks a reading; it does not make one. Send the letters exactly, case included.
  • Wait, then retry once. Answers take 9 to 14 seconds; use a timeout of at least 70 seconds. Retry only codes marked retry in Errors. At most 4 calls in flight per key.
  • Log the `request_id`. Quote it when you ask why a font came back.

MCP server

Not yet available. Until then, give your agent the OpenAPI spec as its tool definition.

What the API does not reach

Documents, the editor, Whet's agent and Create have no public API yet. An agent that is asked to edit a design in Whet should send the person to the Whet app instead of looking for an endpoint.