> ## Documentation Index
> Fetch the complete documentation index at: https://docs.cassidyai.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Update Knowledge Base document

> Update an existing document in your Knowledge Base from within a Workflow.

Update an existing document in your [Knowledge Base](https://docs.cassidyai.com/knowledge-base/overview.md) from within a [Workflow](https://docs.cassidyai.com/workflows/overview.md). Use this to keep documentation current automatically — for example, appending meeting notes to a running document or updating a FAQ page.

**1. Add the action**

In the Workflow builder, click **+** between blocks and select **Update Knowledge Base Document** from the action library.

![Action library with Update Knowledge Base Document selected](https://mintcdn.com/cassidy/S3C8nlCeFAZnY2mJ/images/reference/update-knowledge-base-document-img-0.png?fit=max\&auto=format\&n=S3C8nlCeFAZnY2mJ\&q=85\&s=1108043b97edc8dcc40a5035967cff82)

![Update Knowledge Base Document action added to the Workflow](https://mintcdn.com/cassidy/S3C8nlCeFAZnY2mJ/images/reference/update-knowledge-base-document-img-1.png?fit=max\&auto=format\&n=S3C8nlCeFAZnY2mJ\&q=85\&s=300c72626ad3207bd62f56b8bc21f6df)

**2. Select the document to update**

Choose how to reference the document using one of three options:

* **Static Document** — Select a specific document directly from your Knowledge Base. Best for keeping a running document like a feedback log.

![Static Document selection from Knowledge Base](https://mintcdn.com/cassidy/S3C8nlCeFAZnY2mJ/images/reference/update-knowledge-base-document-img-3.png?fit=max\&auto=format\&n=S3C8nlCeFAZnY2mJ\&q=85\&s=9ae5929be8cfd70129199785dbc7e074)

* **Knowledge Base Item Reference** — Use a variable that references a Knowledge Base item. Useful when the document to update is a trigger input — for example, augmenting an existing document with a generated summary or FAQ.

![Knowledge Base Item Reference variable selector](https://mintcdn.com/cassidy/S3C8nlCeFAZnY2mJ/images/reference/update-knowledge-base-document-img-4.png?fit=max\&auto=format\&n=S3C8nlCeFAZnY2mJ\&q=85\&s=5fc52a3a0a42916c479e1f27ab6495d2)

* **Dynamic Path** — Specify a document path using variables or naming conventions. Select the **Knowledge Base Collection**, enter the **Document Path** separated by forward slashes, and toggle **Create if Not Found** to create the document and any missing folders if they don't exist.

![Dynamic Path with Collection, Document Path, and Create if Not Found toggle](https://mintcdn.com/cassidy/S3C8nlCeFAZnY2mJ/images/reference/update-knowledge-base-document-img-5.png?fit=max\&auto=format\&n=S3C8nlCeFAZnY2mJ\&q=85\&s=37930da0e71aea835137a25f629f657c)

**3. Select the update method**

Choose how the new content should be applied to the existing document:

* **Replace entire document** — Completely replaces the existing content with new content
* **Append to end** — Adds new content after the existing content
* **Prepend to beginning** — Adds new content before the existing content

![Update method dropdown with Replace, Append, and Prepend options](https://mintcdn.com/cassidy/S3C8nlCeFAZnY2mJ/images/reference/update-knowledge-base-document-img-6.png?fit=max\&auto=format\&n=S3C8nlCeFAZnY2mJ\&q=85\&s=76790cfaa6153f4844a335efb5425ab9)

**4. Enter the document content**

Specify the text to update the document with. Use **#** to [insert variables](https://docs.cassidyai.com/guides/prompt-engineering.md#workflow-prompts) from previous steps or the trigger to dynamically generate the content.

![Document Content field with variable reference](https://mintcdn.com/cassidy/S3C8nlCeFAZnY2mJ/images/reference/update-knowledge-base-document-img-7.png?fit=max\&auto=format\&n=S3C8nlCeFAZnY2mJ\&q=85\&s=0f7c1f62bc2f464fc8984aa72b780fbd)

## Related

* [Create Knowledge Base Document](https://docs.cassidyai.com/reference/actions/create-knowledge-base-document.md)
* [Knowledge Base overview](https://docs.cassidyai.com/knowledge-base/overview.md)


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.