# notes

> Every coline notes command, with its flags and the action it runs.

Source: https://docs.coline.app/cli/reference/notes

{/* Generated by apps/docs/scripts/cli-reference.ts from coline's command tree and the cli action catalog. Don't edit it: run `pnpm --filter @colineapp/docs cli:reference`. */}

Notes: cat, edit and every notes action. Every `coline notes` command, 22 in all.

## notes cat

Print a note as markdown: its title as a # heading, then its text. Name it by its link or its id.

```text
coline notes cat <note> [flags]
```

**Built into coline.** · **Calls** `notes.get` · **Effect** read, changes nothing · **Can wait for your approval** no

```bash
coline notes cat https://coline.app/acme/notes/3b1f…
coline notes cat 3b1f… > note.md
coline notes cat 3b1f… --json --fields title,body
```

## notes edit

Open a note in your editor as markdown: the first line `# Title` is its title, the rest its text. Save and close to save it in Coline; leave it unchanged or empty to cancel. --from takes the text from a file or stdin instead.

Only what you changed is saved. Blocks you didn't touch stay exactly as they are, with their colors, callouts, embeds, files and anything else markdown can't show. If it changed in Coline since you opened it and the two can't be put together, nothing is saved and it says to open it again.

When a block you changed had something markdown can't keep (a color, a callout, an embed), it says what and saves only with --confirm.

The editor is the one set with `coline config set editor`, else $VISUAL, then $EDITOR, then vi.

```text
coline notes edit <note> [flags]
```

**Built into coline.** · **Calls** `notes.get`, `notes.update` · **Effect** write · **Can wait for your approval** no

| Flag            | What it does                                     |
| --------------- | ------------------------------------------------ |
| `--from <file>` | Take the new text from this file; - reads stdin. |

```bash
coline notes edit https://coline.app/acme/notes/3b1f…
coline notes edit 3b1f… --from note.md
coline notes cat 3b1f… | sed 's/Q3/Q4/g' | coline notes edit 3b1f… --from -
```

## notes generate

The note editor's "write this for me", streamed to stdout. Nothing is written into the note: pipe the text where you want it, like coline notes edit. The note is its link or id; you need to be able to edit it. Text piped in is what to work on.

```text
coline notes generate <note> <what to write…> [flags]
```

**Built into coline.** · **Calls** `POST /api/v1/notes/ai/generate` · **Effect** write · **Can wait for your approval** no

| Flag                      | What it does                                                                     |
| ------------------------- | -------------------------------------------------------------------------------- |
| `--selection-file <file>` | The note's text to work on, from a file; - reads stdin (piped stdin is read too) |
| `--title <text>`          | The note's title, for context.                                                   |

```bash
coline notes generate https://coline.app/acme/notes/3b1f… "An intro for the launch plan"
coline notes cat 3b1f… | coline notes generate 3b1f… "Summarize this in three bullets"
coline notes generate 3b1f… "A closing paragraph" --json
```

## notes assist

Answers a question from a page (and up to 12 other pages the person can read), rewrites it, or lists the tasks in it. It never changes the page.

It changes nothing.

```text
coline notes assist [flags]
```

**Action** `notes.assist` · **Effect** read, changes nothing · **Can wait for your approval** no · **Scope** `files.read` · **Workspace** yes, `-w`

| Flag                       | What it does                                          |
| -------------------------- | ----------------------------------------------------- |
| `--note-id <id>`           | Note id from search, fetch or create\_note. Required. |
| `--mode <text>`            | Required. One of `answer`, `rewrite`, `tasks`.        |
| `--prompt <text>`          | Required.                                             |
| `--source-note-ids <list>` |                                                       |
| `--input <file>`           | Read the input as JSON from a file; - reads stdin.    |

```bash
coline notes assist -w acme --note-id <note-id> --mode answer --prompt "…"
coline notes assist -w acme --json '{"noteId":"<note-id>","mode":"answer","prompt":"…"}' --fields id
```

## notes create

Creates a note: plans, drafts, summaries, meeting notes, working notes. Write the body in markdown; the person sees the page take shape inside the chat and can edit it there.

Set blocks with --json '\{…}' or --input.

```text
coline notes create [flags]
```

**Action** `notes.create` · **Effect** write · **Can wait for your approval** no · **Scope** `files.write` · **Workspace** yes, `-w`

| Flag               | What it does                                                      |
| ------------------ | ----------------------------------------------------------------- |
| `--title <text>`   |                                                                   |
| `--body <text>`    | Markdown: headings, lists, checklists, quotes, code. Default .    |
| `--drive-id <id>`  | Drive to put it in; default: the person's default writable drive. |
| `--parent-id <id>` | Folder to put it in, in that drive.                               |
| `--input <file>`   | Read the input as JSON from a file; - reads stdin.                |

```bash
coline notes create -w acme
coline notes create -w acme --json '{}' --fields id
```

## notes daily

Opens today's daily note, making it if it isn't there yet.

```text
coline notes daily [flags]
```

**Action** `notes.daily` · **Effect** write · **Can wait for your approval** no · **Scope** `files.write` · **Workspace** yes, `-w`

| Flag             | What it does                                       |
| ---------------- | -------------------------------------------------- |
| `--input <file>` | Read the input as JSON from a file; - reads stdin. |

```bash
coline notes daily -w acme
coline notes daily -w acme --json '{}' --fields id
```

## notes delete

Moves a note to trash in Coline, where it can be restored.

It removes or overwrites something, so it runs only with --confirm.

```text
coline notes delete [flags]
```

**Action** `notes.delete` · **Effect** destructive, runs only with `--confirm` · **Can wait for your approval** no · **Scope** `files.write` · **Workspace** yes, `-w`

| Flag             | What it does                                          |
| ---------------- | ----------------------------------------------------- |
| `--note-id <id>` | Note id from search, fetch or create\_note. Required. |
| `--input <file>` | Read the input as JSON from a file; - reads stdin.    |

```bash
coline notes delete -w acme --note-id <note-id> --confirm
coline notes delete -w acme --json '{"noteId":"<note-id>"}' --fields id --confirm
```

## notes details change

Restores a past revision, changes the page's properties and layout, or adds, edits, resolves or deletes a comment.

Set change with --json '\{…}' or --input.

```text
coline notes details change [flags]
```

**Action** `notes.details.change` · **Effect** write · **Can wait for your approval** no · **Scope** `files.write` · **Workspace** yes, `-w`

| Flag             | What it does                                          |
| ---------------- | ----------------------------------------------------- |
| `--note-id <id>` | Note id from search, fetch or create\_note. Required. |
| `--input <file>` | Read the input as JSON from a file; - reads stdin.    |

```bash
coline notes details change -w acme --note-id <note-id>
coline notes details change -w acme --json '{"noteId":"<note-id>","change":"…"}' --fields id
```

## notes details get

A page's comments, child pages and backlinks (paged), its history, or one past revision.

It changes nothing.

```text
coline notes details get [flags]
```

**Action** `notes.details.get` · **Effect** read, changes nothing · **Can wait for your approval** no · **Scope** `files.read` · **Workspace** yes, `-w`

| Flag                       | What it does                                          |
| -------------------------- | ----------------------------------------------------- |
| `--note-id <id>`           | Note id from search, fetch or create\_note. Required. |
| `--revision <number>`      | One past revision.                                    |
| `--history`                | The page's history instead.                           |
| `--before <number>`        |                                                       |
| `--comments-after <text>`  |                                                       |
| `--children-after <text>`  |                                                       |
| `--backlinks-after <text>` |                                                       |
| `--input <file>`           | Read the input as JSON from a file; - reads stdin.    |

```bash
coline notes details get -w acme --note-id <note-id>
coline notes details get -w acme --json '{"noteId":"<note-id>"}' --fields id
```

## notes folders create

Makes a folder for notes, in a drive and folder the person can write to.

```text
coline notes folders create [flags]
```

**Action** `notes.folders.create` · **Effect** write · **Can wait for your approval** no · **Scope** `files.write` · **Workspace** yes, `-w`

| Flag               | What it does                                       |
| ------------------ | -------------------------------------------------- |
| `--name <text>`    | Required.                                          |
| `--parent-id <id>` |                                                    |
| `--drive-id <id>`  |                                                    |
| `--input <file>`   | Read the input as JSON from a file; - reads stdin. |

```bash
coline notes folders create -w acme --name "…"
coline notes folders create -w acme --json '{"name":"…"}' --fields id
```

## notes folders list

The notes folders under a folder (or at the top), or the whole nested tree.

It changes nothing.

```text
coline notes folders list [flags]
```

**Action** `notes.folders.list` · **Effect** read, changes nothing · **Can wait for your approval** no · **Scope** `files.read` · **Workspace** yes, `-w`

| Flag               | What it does                                       |
| ------------------ | -------------------------------------------------- |
| `--parent-id <id>` |                                                    |
| `--tree`           |                                                    |
| `--input <file>`   | Read the input as JSON from a file; - reads stdin. |

```bash
coline notes folders list -w acme
coline notes folders list -w acme --json '{}' --fields id
```

## notes get

Reads a note's title and text (markdown) with its revision.

It changes nothing.

```text
coline notes get [flags]
```

**Action** `notes.get` · **Effect** read, changes nothing · **Can wait for your approval** no · **Scope** `files.read` · **Workspace** yes, `-w`

| Flag             | What it does                                          |
| ---------------- | ----------------------------------------------------- |
| `--note-id <id>` | Note id from search, fetch or create\_note. Required. |
| `--input <file>` | Read the input as JSON from a file; - reads stdin.    |

```bash
coline notes get -w acme --note-id <note-id>
coline notes get -w acme --json '{"noteId":"<note-id>"}' --fields id
```

## notes import

Brings Markdown or a Notion export into your notes, from ZIPs you already uploaded with the migration upload. To see what would arrive first, use notes.importPreview.

Set visibility, userMappings with --json '\{…}' or --input.

```text
coline notes import [flags]
```

**Action** `notes.import` · **Effect** write · **Can wait for your approval** no · **Scope** `files.write` · **Workspace** yes, `-w`

| Flag                   | What it does                                                                                                                        |
| ---------------------- | ----------------------------------------------------------------------------------------------------------------------------------- |
| `--upload-ids <list>`  | The uploaded export ZIPs, in order. Required.                                                                                       |
| `--request-id <id>`    | A new id for this import. Sending the same id again returns the same import instead of starting another. One is made when left out. |
| `--connection-id <id>` | A Notion connection that also brings formulas, relations, people and comments.                                                      |
| `--input <file>`       | Read the input as JSON from a file; - reads stdin.                                                                                  |

```bash
coline notes import -w acme --upload-ids "…"
coline notes import -w acme --json '{"uploadIds":"…"}' --fields id
```

## notes import-preview

Reads Markdown or a Notion export you already uploaded with the migration upload and says what an import would bring into your notes: its people, top-level sections and counts. Nothing is imported; notes.import does that.

It changes nothing.

```text
coline notes import-preview [flags]
```

**Action** `notes.importPreview` · **Effect** read, changes nothing · **Can wait for your approval** no · **Scope** `files.read` · **Workspace** yes, `-w`

| Flag                   | What it does                                                                   |
| ---------------------- | ------------------------------------------------------------------------------ |
| `--upload-ids <list>`  | The uploaded export ZIPs, in order. Required.                                  |
| `--connection-id <id>` | A Notion connection that also brings formulas, relations, people and comments. |
| `--input <file>`       | Read the input as JSON from a file; - reads stdin.                             |

```bash
coline notes import-preview -w acme --upload-ids "…"
coline notes import-preview -w acme --json '{"uploadIds":"…"}' --fields id
```

## notes list

Lists the notes the caller can open, most recently edited first, optionally matching a title.

It changes nothing.

```text
coline notes list [flags]
```

**Action** `notes.list` · **Effect** read, changes nothing · **Can wait for your approval** no · **Scope** `files.read` · **Workspace** yes, `-w`

| Flag               | What it does                                       |
| ------------------ | -------------------------------------------------- |
| `--q <text>`       | Part of a note's title.                            |
| `--limit <number>` | Default 20.                                        |
| `--cursor <text>`  | nextCursor from the previous page.                 |
| `--input <file>`   | Read the input as JSON from a file; - reads stdin. |

```bash
coline notes list -w acme
coline notes list -w acme --json '{}' --fields id
```

## notes record-page

Opens the page for a sheet record, making it on first open.

```text
coline notes record-page [flags]
```

**Action** `notes.recordPage` · **Effect** write · **Can wait for your approval** no · **Scope** `files.write` · **Workspace** yes, `-w`

| Flag                   | What it does                                       |
| ---------------------- | -------------------------------------------------- |
| `--sheet-file-id <id>` | Required.                                          |
| `--table-id <id>`      | Required.                                          |
| `--row-id <id>`        | Required.                                          |
| `--create`             | Default true.                                      |
| `--input <file>`       | Read the input as JSON from a file; - reads stdin. |

```bash
coline notes record-page -w acme --sheet-file-id <sheet-file-id> --table-id <table-id> --row-id <row-id>
coline notes record-page -w acme --json '{"sheetFileId":"<sheet-file-id>","tableId":"<table-id>","rowId":"<row-id>"}' --fields id
```

## notes templates create

Saves a page as a template for the workspace.

Set blocks with --json '\{…}' or --input.

```text
coline notes templates create [flags]
```

**Action** `notes.templates.create` · **Effect** write · **Can wait for your approval** no · **Scope** `files.write` · **Workspace** yes, `-w`

| Flag                   | What it does                                               |
| ---------------------- | ---------------------------------------------------------- |
| `--name <text>`        | Required.                                                  |
| `--description <text>` | Default .                                                  |
| `--icon <text>`        | Default IconNote.                                          |
| `--category <text>`    | Required. One of `work`, `personal`, `planning`, `custom`. |
| `--title <text>`       | Required.                                                  |
| `--input <file>`       | Read the input as JSON from a file; - reads stdin.         |

```bash
coline notes templates create -w acme --name "…" --category work --title "…"
coline notes templates create -w acme --json '{"name":"…","category":"work","title":"…","blocks":"…"}' --fields id
```

## notes templates delete

Deletes a note template.

It removes or overwrites something, so it runs only with --confirm.

```text
coline notes templates delete [flags]
```

**Action** `notes.templates.delete` · **Effect** destructive, runs only with `--confirm` · **Can wait for your approval** no · **Scope** `files.write` · **Workspace** yes, `-w`

| Flag                 | What it does                                       |
| -------------------- | -------------------------------------------------- |
| `--template-id <id>` | Required.                                          |
| `--input <file>`     | Read the input as JSON from a file; - reads stdin. |

```bash
coline notes templates delete -w acme --template-id <template-id> --confirm
coline notes templates delete -w acme --json '{"templateId":"<template-id>"}' --fields id --confirm
```

## notes templates list

The workspace's note templates.

It changes nothing.

```text
coline notes templates list [flags]
```

**Action** `notes.templates.list` · **Effect** read, changes nothing · **Can wait for your approval** no · **Scope** `files.read` · **Workspace** yes, `-w`

| Flag             | What it does                                       |
| ---------------- | -------------------------------------------------- |
| `--input <file>` | Read the input as JSON from a file; - reads stdin. |

```bash
coline notes templates list -w acme
coline notes templates list -w acme --json '{}' --fields id
```

## notes templates update

Changes a template's name, description, icon, category, title or blocks.

Set blocks with --json '\{…}' or --input.

```text
coline notes templates update [flags]
```

**Action** `notes.templates.update` · **Effect** write · **Can wait for your approval** no · **Scope** `files.write` · **Workspace** yes, `-w`

| Flag                   | What it does                                       |
| ---------------------- | -------------------------------------------------- |
| `--template-id <id>`   | Required.                                          |
| `--name <text>`        |                                                    |
| `--description <text>` |                                                    |
| `--icon <text>`        |                                                    |
| `--category <text>`    | One of `work`, `personal`, `planning`, `custom`.   |
| `--title <text>`       |                                                    |
| `--input <file>`       | Read the input as JSON from a file; - reads stdin. |

```bash
coline notes templates update -w acme --template-id <template-id>
coline notes templates update -w acme --json '{"templateId":"<template-id>"}' --fields id
```

## notes update

Rewrites a note: a new title, a new whole body (markdown), or both. Read it first and pass its revision so the person's newer edits are kept.

Set blocks with --json '\{…}' or --input.

```text
coline notes update [flags]
```

**Action** `notes.update` · **Effect** write · **Can wait for your approval** no · **Scope** `files.write` · **Workspace** yes, `-w`

| Flag                       | What it does                                                       |
| -------------------------- | ------------------------------------------------------------------ |
| `--note-id <id>`           | Note id from search, fetch or create\_note. Required.              |
| `--title <text>`           |                                                                    |
| `--body <text>`            | The whole new body in markdown.                                    |
| `--base-revision <number>` | The revision you read; edits made since then are merged, not lost. |
| `--mutation-id <id>`       |                                                                    |
| `--input <file>`           | Read the input as JSON from a file; - reads stdin.                 |

```bash
coline notes update -w acme --note-id <note-id>
coline notes update -w acme --json '{"noteId":"<note-id>"}' --fields id
```

## notes workflows create

Makes a set of linked pages for a course, lecture, project, meeting series or research; retrying with the same request id never duplicates them.

```text
coline notes workflows create [flags]
```

**Action** `notes.workflows.create` · **Effect** write · **Can wait for your approval** no · **Scope** `files.write` · **Workspace** yes, `-w`

| Flag                | What it does                                                            |
| ------------------- | ----------------------------------------------------------------------- |
| `--request-id <id>` | Required.                                                               |
| `--kind <text>`     | Required. One of `course`, `lecture`, `project`, `meeting`, `research`. |
| `--title <text>`    |                                                                         |
| `--input <file>`    | Read the input as JSON from a file; - reads stdin.                      |

```bash
coline notes workflows create -w acme --request-id <request-id> --kind course
coline notes workflows create -w acme --json '{"requestId":"<request-id>","kind":"course"}' --fields id
```
