card_new
Fill a template's slots to create a card, write its SVG and render PNG into assets/cards, ready for cues to point at.
Instructions
Make a card from a template: fill its slots, write the SVG, render it.
name is the <name> in card:<name> — the key a cue points at. Both
the SVG source and the PNG are written under the project's
assets/cards/, so the card can be re-edited later and re-rendered with
card_render rather than redrawn.
A slot value is text. A newline inside one is a line break wherever the template accepts multiple lines; nothing wraps automatically, because a guessed wrap overflows the frame without saying so. Ratings are numbers out of five, to the nearest half.
Leave width/height unset unless you mean something other than this
film. They default to the project's own canvas, which is what stops a
card from pillarboxing inside the frame it was made for; naming a size
that is not the project's is how a card loses a quarter of its width to
black bar. Given at all, both must be.
Refused if a card of this name exists, unless overwrite — a cue may
already point at it. Read font_warnings in the result: a template
naming a face this machine lacks still renders, in a substitute, with
nothing else to say so.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| name | Yes | The `<name>` in `card:<name>` — the key a cue points at. The SVG and the PNG are both written under `assets/cards/`. | |
| path | No | The project directory to act on. Omit it — the usual case — when this server is bound to a project (started as `proofcut -C DIR mcp`, or inside a project; `ping` says which): it then resolves to that one bound project, a relative path resolves against it, and a path outside it is refused by name. Unbound, `path` is the whole address and omitting it refuses rather than guessing. | |
| slots | Yes | The template's slots filled in, as text. A newline is a line break where the template takes several lines; ratings are numbers out of five, to the nearest half. | |
| width | No | Render width. **Leave it unset unless you mean something other than this film** — it defaults to the project's canvas, which is what stops a card pillarboxing inside the frame it was made for. Given at all, `height` must be too. | |
| height | No | Render height, given together with `width` or not at all. | |
| template | Yes | Which template to fill; `card_templates` lists them with their slots. A per-aspect variant file is resolved from the canvas, never named here. | |
| overwrite | No | Redraw a card of this name that already exists. Refused without it, since a cue may already point at that card. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||