# RevCent MCP Guide: `EditProjectNote`

AI/MCP-focused guide for editing a RevCent Project Note.

---

## Related Documentation

| Guide | Link | Why It Matters |
|---|---|---|
| Project Overview | `https://revcent.com/documentation/markdown/mcp/operation/OverviewProject.md` | Explains how Projects work as pseudo repositories / durable AI context containers. |
| GetProject | `https://revcent.com/documentation/markdown/mcp/operation/GetProject.md` | Retrieve Project details and associated entities before editing context-sensitive notes. |
| GetProjectNotes | `https://revcent.com/documentation/markdown/mcp/operation/GetProjectNotes.md` | Retrieve Project Note titles and metadata; content is not returned by this list operation. |
| GetProjectNote | `https://revcent.com/documentation/markdown/mcp/operation/GetProjectNote.md` | Retrieve the full content of one Project Note before editing it. |
| CreateProjectNote | `https://revcent.com/documentation/markdown/mcp/operation/CreateProjectNote.md` | Create a new note when a new Project event occurs. |

---

## Operation Summary

Operation:

```text
EditProjectNote
```

Purpose:

```text
Edit an existing Project Note using the Project Note ID.
```

A Project is a pseudo repository for a business, objective, workflow, report, external-agent source of truth, or other durable AI/MCP context. Project Notes preserve the Project's history and reduce the need to keep all historical context active.

Use `EditProjectNote` to correct or clarify an existing note. Use `CreateProjectNote` when a new event, decision, warning, or follow-up should be added to the Project history.

Important schema behavior:

```text
Only provide the fields that should be edited.
```

---

## Title, Content, and Metadata Caveat

Project Notes have three important editable context fields:

```text
title
content
metadata
```

`title` is the short, list-visible summary returned by `GetProjectNotes`. Edit the title when the existing title is vague, incorrect, or no longer represents the note clearly.

`content` is the full note body. It is not returned by `GetProjectNotes`; it must be retrieved with `GetProjectNote`. Before editing content, retrieve the existing note so important context is not accidentally overwritten.

`metadata` is an optional array of structured name/value pairs. Edit metadata when the note needs better structured labels for filtering, such as entity type, entity ID, workflow, status, report period, decision category, or risk level.

Important:

```text
GetProjectNotes returns titles and list metadata only.
GetProjectNote returns the full title, content, and metadata for one note.
EditProjectNote should update only the fields that need to change.
Providing metadata when editing overwrites the existing metadata array; it does not append to it.
```

---

## When to Use

Use `EditProjectNote` when:

- a note title is unclear or inaccurate,
- note content contains an error,
- missing context should be added to an existing note,
- a note was associated with the wrong Project and must be moved with `project_id`,
- an existing note needs clarification without creating a new Project event.

---

## Metadata Property

Project Notes can include optional structured metadata as an array of name/value pairs.

Metadata item shape:

```json
{
  "name": "entity_type",
  "value": "payment_profile"
}
```

Metadata constraints:

| Field | Type | Required | Description |
|---|---:|---:|---|
| `name` | string | Yes | Metadata name. Minimum 1 character, maximum 100 characters. |
| `value` | string | Yes | Metadata value. Minimum 1 character, maximum 255 characters. |

Use metadata for compact, filterable context such as entity type, entity ID, workflow name, decision category, report period, agent purpose, risk level, or follow-up status. Metadata should not replace the `title` or `content`; it should add structured labels that make Project Notes easier to filter and retrieve later.

---

## Input Schema

| Field | Type | Required | Description |
|---|---:|---:|---|
| `project_note_id` | string | Yes | 20-character Project Note ID. |
| `project_id` | string | No | 20-character Project ID associated with the note. Include only when changing the associated Project. |
| `title` | string | No | Short Project Note title. Minimum 1 character, maximum 100 characters. Returned by `GetProjectNotes`; should be useful as a quick index entry. |
| `content` | string | No | Full Project Note content. Minimum 1 character, maximum 5000 characters. Retrieved through `GetProjectNote`, not through `GetProjectNotes`. |
| `metadata` | array | No | Optional array of metadata name/value pair objects. Providing metadata when editing overwrites the existing metadata array; it does not append to it. |


Example updating metadata:

```json
{
  "project_note_id": "XXXXXXXXXXXXXXXXXXXX",
  "metadata": [
    {
      "name": "entity_type",
      "value": "payment_profile"
    },
    {
      "name": "follow_up_status",
      "value": "completed"
    }
  ]
}
```

Important:

```text
When editing metadata, send the complete metadata array that should remain on the note.
The provided metadata array replaces existing metadata.
It is not merged with or appended to existing metadata.
```

---

## Output Schema

Successful output can include:

| Field | Description |
|---|---|
| `api_call_id` | 20-character API call ID. |
| `api_call_unix` | Unix timestamp when the API call was initiated. |
| `code` | API response code. `1` indicates success. |
| `project_note_id` | 20-character Project Note ID. |
| `result` | Result message. |

---

## Recommended Workflow

```text
1. Use GetProjectNotes to find the relevant Project Note by title and metadata.
2. Use GetProjectNote to retrieve the full note content and existing metadata.
3. Decide whether the existing note should be edited or a new note should be created.
4. Run EditProjectNote with only the fields that should change. If changing metadata, provide the full replacement metadata array.
5. Use GetProjectNote again if verification is needed.
```

---

## Best Practices

- Retrieve the full note with `GetProjectNote` before editing content or metadata.
- Edit the title if it does not clearly summarize the note for future retrieval.
- Preserve important historical context.
- Use `CreateProjectNote` instead of editing when documenting a new event.
- Only include fields that should change.
- When changing metadata, preserve any existing metadata pairs that should remain because metadata edits overwrite the metadata array.

---

## Common Mistakes to Avoid

Do not:

- assume `GetProjectNotes` returned the full note body,
- overwrite content or metadata without first retrieving the current note,
- use `EditProjectNote` to hide important history,
- create vague titles that make future retrieval harder,
- send unchanged fields unless intended,
- send partial metadata when existing metadata should be preserved,
- edit an old note when a new note would better preserve chronology.

---

## Final AI/MCP Instruction

Use `EditProjectNote` only to correct, clarify, retitle, move, or relabel an existing Project Note. Treat the title as the list-visible retrieval clue, the content as the full durable context body retrieved through `GetProjectNote`, and metadata as structured labels that can be replaced when better filtering context is needed.


---
Document Parent Directory
* [Operations](https://revcent.com/documentation/markdown/mcp/operation/index.md) - AI/MCP details and overviews for operations available within the RevCent MCP.