update_context
Update an existing context item: change its name, body, collection, or project, or re-pull a tracked web page's content. Collection and project use full-replace semantics, so always pass both.
Parameters
| Name | Type | Required | Default | Description |
|---|---|---|---|---|
context_item_id | string (uuid) | Yes | — | The context item to update |
refresh_webpage | boolean | No | — | Set `true` to re-pull a `webpage` item's content from its stored URL. Ignores `name` / `content` / `import_url`. Errors on non-webpage items. Admin/editor only |
name | string | No | — | If provided, updates the name. Omit to leave unchanged. Ignored when `refresh_webpage` is true |
content | string | No | — | New markdown body. Omit to leave unchanged. Triggers RAG re-embedding. Mutually exclusive with `import_url`. Ignored when `refresh_webpage` is true |
import_url | string | No | — | Public URL — backend fetches and converts to clean markdown server-side, then stores it as a fresh one-off snapshot body. Mutually exclusive with `content`. Ignored when `refresh_webpage` is true |
collection_id | integer | null | Yes | — | Full replace. Pass the current ID to keep the item in its collection, pass a different ID to move it, or pass `null` (`0` works too) to move it back to the top level of the Reference Library |
project_id | string (uuid) | null | Yes | — | Full replace. Pass the current ID to keep the project association, pass a different ID to move it, or pass `null` to disassociate it |
Input Schema
{
"type": "object",
"required": [
"context_item_id",
"collection_id",
"project_id"
],
"properties": {
"name": {
"type": "string",
"description": "If provided, updates the name. Omit to leave unchanged. Ignored when refresh_webpage is true."
},
"content": {
"type": "string",
"description": "New markdown body. Omit to leave unchanged. Triggers RAG re-embedding. Mutually exclusive with import_url. Ignored when refresh_webpage is true."
},
"import_url": {
"type": "string",
"description": "Public URL — backend fetches and converts to clean markdown server-side, then stores it as a fresh one-off snapshot body. Mutually exclusive with content. Ignored when refresh_webpage is true."
},
"project_id": {
"type": [
"string",
"null"
],
"format": "uuid",
"description": "Full replace. Pass the current ID to keep the project association, pass a different ID to move it, or pass null to disassociate it."
},
"collection_id": {
"type": [
"integer",
"null"
],
"description": "Full replace. Pass the current ID to keep the item in its collection, pass a different ID to move it, or pass null (0 works too) to move it back to the top level of the Reference Library."
},
"context_item_id": {
"type": "string",
"format": "uuid",
"description": "The context item to update."
},
"refresh_webpage": {
"type": "boolean",
"description": "Set true to re-pull a webpage item's content from its stored URL. Ignores name / content / import_url. Errors on non-webpage items. Admin/editor only."
}
}
}Output Schema
{
"type": "object",
"properties": {
"id": {
"type": "string",
"description": "Context item ID."
},
"name": {
"type": "string",
"description": "Updated context item name."
},
"content": {
"type": "string",
"description": "Updated reference content."
},
"link_url": {
"type": "string",
"description": "Direct URL to view this context item in the Marcora app."
},
"project_id": {
"type": [
"string",
"null"
],
"description": "Project this item is associated with (null if none)."
},
"updated_at": {
"type": "integer",
"description": "Unix timestamp of last update."
},
"word_count": {
"type": "integer",
"description": "Word count of updated content."
},
"collection_id": {
"type": [
"integer",
"null"
],
"description": "Collection this item belongs to (null if none)."
},
"content_intro": {
"type": "string",
"description": "Truncated content intro used in listings."
},
"relevancy_processed_status": {
"type": "string",
"description": "RAG re-processing status (unprocessed, provisional, complete). Flips to unprocessed whenever name or content changes."
}
}
}Instructions
Use this tool to update an existing context item in your reference library.
What you can update:
name: rename the context item (omit to leave unchanged)content: replace the stored reference content (omit to leave unchanged; triggers RAG re-embedding)import_url: replace the body with a fresh one-off snapshot fetched from a public URL (omit to leave unchanged; mutually exclusive withcontent)collection_id: move to a different collection, or passnullto move it back to the top level of the Reference Libraryproject_id: change the project association, or passnullto disassociaterefresh_webpage: settrueto re-pull a trackedwebpageitem from its stored URL (admin/editor only; ignoresname/content/import_url)
Important — full-replace semantics for collection_id and project_id:
Unlike name and content, you MUST pass collection_id and project_id on every call. Omitting them is NOT the same as keeping them unchanged — include the current values to preserve them. If you do not know the current values, call get_context_item first or use the web app to check before updating. (Even with refresh_webpage, pass the item's current values; the refresh does not change them.)
The two behave differently when omitted, so pass both explicitly: omitting collection_id returns a Missing param error, while omitting project_id silently detaches the item from its project.
Passing null:
Both fields accept a JSON null — the tool's input schema types them as ["integer","null"] / ["string","null"], so strict MCP clients can send null directly. Use it to move an item out of a collection and back to the top level of the Reference Library, or to detach it from a project. For collection_id, 0 is accepted as an alias for null.
Workflow:
- Get the
context_item_id(UUID) — uselist_context_items,list_context_collections,get_project, orget_relevant_contextto find IDs. - Pass
collection_idandproject_id(required, nullable) — include current values to preserve, ornullto clear. - Optionally pass
nameand/or a new body (contentorimport_url) to update those fields, orrefresh_webpage: trueto re-pull a tracked web page.
Errors
400—Provide either content or import_url, not both.(both were supplied)400—Failed to extract markdown from import_url(the URL could not be fetched or parsed)400—refresh_webpageused on a non-webpage item403—refresh_webpagerequires admin or editor role
Example prompts
- "Rename that brand voice context item to 'Brand Voice v2'"
- "Move the competitive analysis out of the 'Archive' collection"
- "Update our pricing context with the new Enterprise tier info"
- "I updated our pricing page — refresh that web-page context item"
- "Re-import the Acme snapshot from https://example.com/competitor-pricing"