---
title: "Change a note"
description: "Changes only the fields sent. Needs the `videos:create` permission."
---

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

Path: Mosio REST API › Notes

`PATCH /v1/notes/{id}`

Changes only the fields sent. Needs the `videos:create` permission.

## Authentication

- `apiKey`, apiKey, in header, header `x-api-key`

## Path parameters

- `id` (`updateNote.path.id`; string, required)

## Request body

_Required._

- `kind` (`updateNote.kind`; string, optional)
  - one of `"idea"`, `"research"`, `"data"`, `"reference"`, `"brief"`, `"note"`
- `title` (`updateNote.title`; string, optional)
  - minLength 1; maxLength 120
- `body` (`updateNote.body`; string, optional)
  - maxLength 10000
- `research` (`updateNote.research`; any of, optional)
  - any of: `object`, `null`
- `links` (`updateNote.links`; array<string>, optional)
  - format `uri`; maxLength 2000
- `tags` (`updateNote.tags`; array<string>, optional)
  - minLength 1; maxLength 40
- `color` (`updateNote.color`; string, optional)
  - one of `"yellow"`, `"blue"`, `"green"`, `"pink"`, `"purple"`, `"gray"`
- `x` (`updateNote.x`; integer, optional)
  - min -20000; max 20000
- `y` (`updateNote.y`; integer, optional)
  - min -20000; max 20000

## Example request

```json
{
  "kind": "idea",
  "title": "string",
  "body": "string",
  "research": {
    "question": "string",
    "sources": [
      {
        "url": "http://example.com",
        "title": "string",
        "accessed_at": "2019-08-24T14:15:22Z",
        "findings": [
          "string"
        ]
      }
    ],
    "user_facts": [],
    "open_questions": []
  },
  "links": [
    "http://example.com"
  ],
  "tags": [
    "string"
  ],
  "color": "yellow",
  "x": -20000,
  "y": -20000
}
```

## Code samples

### cURL

```bash
curl --request PATCH \
  --url 'https://app.mosio.me/v1/notes/<id>' \
  --header 'Content-Type: application/json' \
  --header 'x-api-key: <x-api-key>' \
  --data '
{
  "kind": "idea",
  "title": "string",
  "body": "string",
  "research": {
    "question": "string",
    "sources": [
      {
        "url": "http://example.com",
        "title": "string",
        "accessed_at": "2019-08-24T14:15:22Z",
        "findings": [
          "string"
        ]
      }
    ],
    "user_facts": [],
    "open_questions": []
  },
  "links": [
    "http://example.com"
  ],
  "tags": [
    "string"
  ],
  "color": "yellow",
  "x": -20000,
  "y": -20000
}
'
```

### TypeScript

```typescript
const url = 'https://app.mosio.me/v1/notes/<id>';
const options = {
  method: 'PATCH',
  headers: {'Content-Type': 'application/json', 'x-api-key': '<x-api-key>'},
  body: JSON.stringify({
    kind: 'idea',
    title: 'string',
    body: 'string',
    research: {
      question: 'string',
      sources: [
        {
          url: 'http://example.com',
          title: 'string',
          accessed_at: '2019-08-24T14:15:22Z',
          findings: ['string']
        }
      ],
      user_facts: [],
      open_questions: []
    },
    links: ['http://example.com'],
    tags: ['string'],
    color: 'yellow',
    x: -20000,
    y: -20000
  })
};

fetch(url, options)
  .then(res => res.json())
  .then(json => console.log(json))
  .catch(err => console.error(err));
```

### Python

```python
import requests

url = "https://app.mosio.me/v1/notes/<id>"

payload = {
    "kind": "idea",
    "title": "string",
    "body": "string",
    "research": {
        "question": "string",
        "sources": [
            {
                "url": "http://example.com",
                "title": "string",
                "accessed_at": "2019-08-24T14:15:22Z",
                "findings": ["string"]
            }
        ],
        "user_facts": [],
        "open_questions": []
    },
    "links": ["http://example.com"],
    "tags": ["string"],
    "color": "yellow",
    "x": -20000,
    "y": -20000
}
headers = {
    "Content-Type": "application/json",
    "x-api-key": "<x-api-key>"
}

response = requests.patch(url, json=payload, headers=headers)

print(response.text)
```

## Responses

### 200

The note.

#### Example

```json
{
  "id": "string",
  "kind": "idea",
  "title": "string",
  "body": "string",
  "research": {
    "question": "string",
    "sources": [
      {
        "url": "http://example.com",
        "title": "string",
        "accessed_at": "2019-08-24T14:15:22Z",
        "findings": [
          "string"
        ]
      }
    ],
    "user_facts": [],
    "open_questions": []
  },
  "links": [
    "string"
  ],
  "tags": [
    "string"
  ],
  "color": "yellow",
  "x": 0,
  "y": 0,
  "source": "string",
  "plan_id": "string",
  "created_at": "string",
  "updated_at": "string"
}
```

- `id` (`updateNote.response.200.id`; string, required)
- `kind` (`updateNote.response.200.kind`; string, required)
  - one of `"idea"`, `"research"`, `"data"`, `"reference"`, `"brief"`, `"note"`
- `title` (`updateNote.response.200.title`; string, required)
- `body` (`updateNote.response.200.body`; string, required)
- `research` (`updateNote.response.200.research`; any of, required)
  - any of: `object`, `null`
- `links` (`updateNote.response.200.links`; array<string>, required)
- `tags` (`updateNote.response.200.tags`; array<string>, required)
- `color` (`updateNote.response.200.color`; string, required)
  - one of `"yellow"`, `"blue"`, `"green"`, `"pink"`, `"purple"`, `"gray"`
- `x` (`updateNote.response.200.x`; number, required)
- `y` (`updateNote.response.200.y`; number, required)
- `source` (`updateNote.response.200.source`; string | null, required)
- `plan_id` (`updateNote.response.200.plan_id`; string | null, required)
- `created_at` (`updateNote.response.200.created_at`; string, required)
- `updated_at` (`updateNote.response.200.updated_at`; string, required)

### 400

The request body is not valid JSON or does not match the schema.

#### Example

```json
{
  "error": "unauthorized",
  "message": "string",
  "details": null
}
```

- `error` (`updateNote.response.400.error`; string, required) — A stable error code.
  - one of `"unauthorized"`, `"invalid_api_key"`, `"insufficient_scope"`, `"forbidden"`, `"invalid_input"`, `"invalid_composition"`, `"idempotency_conflict"`, `"project_edited"`, `"quota_exceeded"`, `"insufficient_credits"`, `"too_many_active_renders"`, `"duration_too_long"`, `"not_found"`, `"internal_error"`
- `message` (`updateNote.response.400.message`; string, required) — A message for people, in Indonesian.
- `details` (`updateNote.response.400.details`; unknown, optional) — More about the error, such as the fields to fix.

### 401

The API key is missing or not valid.

#### Example

```json
{
  "error": "unauthorized",
  "message": "Kirim API key di header x-api-key."
}
```

- `error` (`updateNote.response.401.error`; string, required) — A stable error code.
  - one of `"unauthorized"`, `"invalid_api_key"`, `"insufficient_scope"`, `"forbidden"`, `"invalid_input"`, `"invalid_composition"`, `"idempotency_conflict"`, `"project_edited"`, `"quota_exceeded"`, `"insufficient_credits"`, `"too_many_active_renders"`, `"duration_too_long"`, `"not_found"`, `"internal_error"`
- `message` (`updateNote.response.401.message`; string, required) — A message for people, in Indonesian.
- `details` (`updateNote.response.401.details`; unknown, optional) — More about the error, such as the fields to fix.

### 404

No such video or file in this workspace.

#### Example

```json
{
  "error": "unauthorized",
  "message": "string",
  "details": null
}
```

- `error` (`updateNote.response.404.error`; string, required) — A stable error code.
  - one of `"unauthorized"`, `"invalid_api_key"`, `"insufficient_scope"`, `"forbidden"`, `"invalid_input"`, `"invalid_composition"`, `"idempotency_conflict"`, `"project_edited"`, `"quota_exceeded"`, `"insufficient_credits"`, `"too_many_active_renders"`, `"duration_too_long"`, `"not_found"`, `"internal_error"`
- `message` (`updateNote.response.404.message`; string, required) — A message for people, in Indonesian.
- `details` (`updateNote.response.404.details`; unknown, optional) — More about the error, such as the fields to fix.


Source: https://docs.mosio.me/api/notes/update/index.md
