Manage categories
manage_categoriesCreate, update, or delete areas (categories / groups / colour-coded labels), activity types (tags / fill patterns) and projects (named goals under an area) — one or many in a single call. Pass areas, activityTypes and/or projects, each an array of ops: {op:"create", name, color?} / {op:"update", id, name?, color?} / {op:"delete", id, reassignTo?} for areas; pattern instead of color for activity types (valid patterns: solid, hatch_r, hatch_l, cross, horizontal, vertical, grid, dots, waves, chevron). Projects: {op:"create", name, areaId?} / {op:"update", id, name?, areaId?, order?, archived?} / {op:"delete", id} / {op:"split", id, linkId}. A split moves one task list or Linear project (linkId) that feeds the project to a new project of its own, "{name} ({Provider})" in the same area (" 2" on a taken name), with its Inbox items; later syncs keep it there. {op:"relink", id, linkId} points one Linear project (linkId) at the live project id, with its Inbox items. A project is your own (no shared defaults, no fork). areaId links it to an area; when a write moves an Inbox item to the project and sets no area, the item takes that area, also over an area set by hand. archived: true marks it archived in the lookups and refuses new links; its links stay; archived: false restores it. A delete clears the project link on its items and events (one undo restores them). A delete of a project that a synced task list or Linear project feeds fails with conflict: link it to another project first, or archive it. A project name is unique among the live projects of the user, in any area: a duplicate fails with conflict ("A project named Launch exists in Work."). Results come back in a projects array. Colours are lowercase "#rrggbb"; omit color or pattern to auto-pick. Editing a shared global default forks it into your own copy, so the returned id may differ — each result reports the effective id (and forkedFrom). A delete removes your own entry, or hides a shared default (and your copy of it) for you only. When events, Inbox items, trackers or calendar defaults use it, a delete without reassignTo is refused with validation; the error details give usage (the counts) and reassignTargets (the categories that can take them). Ask the user, then send the delete again with reassignTo (another id, to move them) or reassignTo: null (to clear their link). A project name is unique among all live projects of the user, so a moved project keeps its name. Names are deduplicated case-, accent- and whitespace-insensitively: a create or a rename into the name of an existing area/type fails with conflict (reuse the existing id instead). A create or update result is the created/updated row; a delete result lists deletedIds (plus movedEvents after a reassign). Every call that writes returns one undoToken + expiresAt (a UTC instant); pass it to undo_changes to reverse the whole call. Atomic by default: if any op is invalid nothing is written; pass partial: true for best-effort. Create areas/types here first, then reference the returned ids in write_events (and a project id in manage_inbox projectId).
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| areas | No | ||
| partial | No | Best-effort mode instead of the default all-or-nothing. | |
| projects | No | ||
| activityTypes | No |