Skip to main content
Glama

00Widget

Publish a card

upsert_card
DestructiveIdempotent

Create or replace one dashboard card, for standing state the operator checks on — a balance, a queue depth, today's total. For work with a start and an end that you will report on while it runs, start_live_activity is the better surface: it reaches the Lock Screen and Dynamic Island, where a card only reaches a Home Screen widget on a rationed refresh budget. The id is the identity of the thing being shown, so reuse it on every publish — never embed a timestamp or run id, or each update becomes a new card. Publishing several cards from one snapshot? Use upsert_cards_batch instead.

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": {
      "id": "<id>",
      "template": "<template>",
      "title": "<title>"
    },
    "name": "upsert_card"
  }
}

Input Schema

NameRequiredDescriptionDefault
idYesStable identity of the thing being shown, reused on every publish so the card updates rather than duplicating. Never embed a timestamp or run id. Letters, digits and . _ : - only, because it is also a URL path segment.
iconNoSF Symbol name for the card: sun.max, bolt.car, flame, washer, creditcard.
unitNoSuffix shown after `value`: kW, %, jobs. Prefixes such as currency symbols belong in the formatted `value` instead; use `value: "$338.99"` and omit `unit`, not `value: "338.99"` with `unit: "$"`.
chartNoThe series behind a `chart` card. Republish the whole window every time — nothing is appended and no history is kept.
itemsNoRows. A `list` shows them as rows, ranked as bars when they carry an `amount`; a `history` draws their `status` as pips, oldest first; a `breakdown` splits one bar by their `amount`.
titleYesThe name of the thing. It renders on one line at caption size, so keep it short and stable — a value that moves belongs in `value`.
valueNoThe headline, as a display string already formatted for a person: "3.2", "$338.99", "4m 12s", "Healthy". It is never parsed back into a number.
statusNoDrives the card's tint and badge on every surface. `good`/`warning`/`critical` for health, `running`/`finished`/`paused`/`offline` for lifecycle.unknown
actionsNoButtons. They are not tied to `template: action` — any template can carry them, so a `chart` card can plot a series and offer a Retry button. `action` is simply the template whose whole point is the buttons, with no visual of its own. How many are drawn depends on the surface: a small widget shows 1, medium 2, large and extra-large 4, and the iOS app and Apple TV show all of them; the Lock Screen accessories show none, and a widget the operator has set to Compact density shows one fewer (none at all on a small one). Order them most useful first, because the tail is what gets cut. Only `role: normal` with `confirm: false` can run straight from a widget; anything else routes through the iOS app for confirmation. A press is delivered to the action's private `webhookId`, or to the account's `default` webhook when none is set. The destination must already be registered under `/v1/integrations/` or the press fails with a 409. Registration needs the `webhook:manage` scope, which an MCP credential does not have — the operator registers webhooks with an API token, from whatever runs each endpoint.
briefingNoOrdered prose behind a `briefing` card. Keep `value` as the compact conclusion and `subtitle` as its first explanation: old clients render the unknown template as a summary and still show both.
deadlineNoWhen the thing this card is about is due, drawn as a countdown the device ticks locally. Publish a date here rather than writing the remaining time into `value`: a widget reloads at most twice an hour, so a republished string is wrong for most of the time it is on screen.
deepLinkNoHTTPS URL opened when the card is tapped. Point it at the dashboard or detail page this card summarises.
priorityNoWhere this card sits among the tenant's cards. Higher comes first; absent counts as 0 and ties break by `id`, which is the order everything had before. It decides the order of `GET /v1/cards`, the app's dashboard, and which cards fill a Home Screen grid widget that has not been configured with specific ones.
producerNoWho published this card. Use the operator's own agent or automation name, not a provider logo; compact surfaces omit this attribution to preserve space.
progressNoHow full the thing is, 0-1, drawn as a bar. Required in practice by `template: progress`, ignored where there is nowhere to draw it. Keep `value` as the label, so the card can show both: "184 of 240".
subtitleNoA short, single-line label under the title or value. It truncates rather than wraps on widgets, so aim for about 40 characters, put essential numbers and qualifiers first, and do not repeat the title. For a chart whose `reference` matters, lead with its formatted meaning and value: "$300 baseline · Mar–Aug 2026".
templateYesHow the card is drawn. Pick by the shape of the data, not the domain: `summary` for one headline number or short state; `progress` for something filling up; `list` for 2-6 things with their own values; `action` for buttons; `chart` for one number moving over time; `history` for a run of pass/fail outcomes; `breakdown` for a whole split into parts; `briefing` for a conclusion followed by ordered prose; `timeline` for irregular timestamped events and duration spans. When unsure, `summary` degrades best at every widget size.
timelineNoTimestamped events and spans behind a `timeline` card. Republish the complete fixed window; the server sorts entries and does not append history.
updatedAtNoWhen this state was true, as an ISO-8601 instant with seconds and an offset (2026-04-26T18:45:00Z). Omit it and the server stamps the time the publish arrived.
comparisonNoA concise interpretation beside the headline, for example +18 vs Monday. This is distinct from chart style `delta`, which controls bar geometry.
staleAfterNoAfter this the widget dims the card into a 'stale' state so the reading is visibly old. A hint only: nothing hides or deletes the card.
statusIconNoA second SF Symbol for a runtime state that changes independently of what the card is — bolt.fill while boosting, arrow.up while charging. Drawn at every widget size, including grid cells.

Output Schema

NameRequiredDescriptionDefault
cardYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.3/5.0
Behavior4/5

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

Annotations declare idempotentHint=true and destructiveHint=true, and the description reinforces idempotency concretely: reusing `id` means 'the card updates rather than duplicating', while embedding a timestamp makes 'each update a new card'. It also adds real behavioral context not in annotations — the Home Screen 'rationed refresh budget' — but never explains the destructive side of replace (that a publish overwrites prior content and keeps no history), which is only implied by 'replace'.

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?

Purpose is front-loaded in the first clause, followed by the discriminating alternative and then the identity rule, with the batch pointer closing it out. The middle sentence about Lock Screen and Dynamic Island vs a rationed-refresh widget is the longest but carries genuine decision value.

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?

For a 22-parameter, deeply nested mutation with a published output schema and full schema coverage, the description covers the decisions the schema cannot: which tool, and the identity rule behind `id`. It omits operational prerequisites such as the webhook registration and `webhook:manage` scope requirement, but those are documented in the schema's `actions` property.

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 the schema already documents all 22 parameters in depth. The description's `id` guidance ('identity of the thing being shown, so reuse it on every publish — never embed a timestamp or run id') restates the schema's own wording rather than adding new meaning, so the baseline 3 applies.

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

Purpose5/5

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

States a specific verb and resource ('Create or replace one dashboard card') plus the domain it is for ('standing state the operator checks on — a balance, a queue depth, today's total'). It explicitly distinguishes itself from two siblings, start_live_activity and upsert_cards_batch, so an agent can route without opening a schema.

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?

Gives an explicit when-not case with the alternative named ('work with a start and an end that you will report on while it runs, start_live_activity is the better surface') and a fan-out case ('Publishing several cards from one snapshot? Use upsert_cards_batch instead'). Both selections are stated, not inferred.

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.