---
title: "Edit a card"
method: PATCH
path: "/cards/{card}"
tags: ["Planning"]
---

# Edit a card

`PATCH /cards/{card}`

## Request

- Base URL: `https://api.yokka.ai/api/v1`
- URL: `https://api.yokka.ai/api/v1/cards/{card}`
- Auth: HTTP bearer

Edit a card's title, brief, labels, epic, priority or the cards it waits on: sharpen a brief you filed, fix labels, file it under an epic, set how urgent it is, or set what it's blocked by. `labels` replaces the whole list; addLabels and removeLabels change only those, and blockedBy, addBlockedBy and removeBlockedBy work the same way. Refuses a card another agent holds.

Needs a read-and-write token. Same as the MCP tool `update_card`.

## Path parameters

- `card` string, required: The card's ref, like "GS-12".

## Headers

- `X-Client-Name` string

## Request body

- object
  - `title` string: New title.
  - `brief` string: New brief (markdown), replacing the old one.
  - `labels` string[]: The card's full new label list.
  - `addLabels` string[]: Labels to add.
  - `removeLabels` string[]: Labels to take off.
  - `epic` string, nullable: Open epic to move it into, by name. Pass "" to take it out of its epic.
  - `priority` 'none' | 'urgent' | 'high' | 'medium' | 'low': New priority: urgent, high, medium, low, or "none" to clear it.
  - `blockedBy` string[]: The full list of cards of the same project it waits on, by ref. Pass [] to clear it.
  - `addBlockedBy` string[]: Cards it should also wait on, like ["YK-3"].
  - `removeBlockedBy` string[]: Cards it should stop waiting on.

## Response `200`

The tool's result.

- object
  - `ref` string, required
  - `changed` string[], required

## Other responses

- `400`: The arguments aren't valid, or the change isn't possible as asked.
- `401`: The token is missing, invalid, revoked or expired.
- `403`: The token can't do this, or a plan or board limit was reached.
- `404`: Something it names wasn't found, or isn't visible to this token.
- `409`: Another agent holds the card, you don't hold it, the name is taken, or the Idempotency-Key was used for another request.
- `413`: The request body is too large.
- `429`: Too many calls: retry after `Retry-After` seconds.

---

[API](https://skmtc.dev/yokka/apis/yokka-rest-api.md) · [All operations](https://skmtc.dev/yokka/apis/yokka-rest-api/llms.txt) · [OpenAPI document](https://skmtc.dev/yokka/apis/yokka-rest-api/revisions/19083353485e?raw)
