Skip to content

Instantly share code, notes, and snippets.

@Forever-Young
Created March 18, 2026 14:37
Show Gist options
  • Select an option

  • Save Forever-Young/a21a4149ba57b329318a260d99b725e1 to your computer and use it in GitHub Desktop.

Select an option

Save Forever-Young/a21a4149ba57b329318a260d99b725e1 to your computer and use it in GitHub Desktop.
name description homepage metadata
apple-notes
Manage Apple Notes via the `memo notes api` CLI on macOS (create, view, edit, delete, search, move, and export notes). Non-interactive, machine-friendly API for scripts and AI agents.
openclaw
emoji os requires install
📝
darwin
bins
memo
id kind formula bins label
brew
brew
forever-young/tap/memo
memo
Install memo via Homebrew

Apple Notes API

Use memo notes api to manage Apple Notes from the terminal. Non-interactive, machine-friendly commands for scripts and AI agents. Output is plain text, well-parsable (TSV, lines, JSON).

Setup

  • Install (Homebrew): brew tap forever-young/tap && brew install forever-young/tap/memo
  • Manual (pip): pip install . (after cloning the repo)
  • macOS-only; if prompted, grant Automation access to Notes.app.

List Notes

  • List all notes: memo notes api list
  • Filter by folder: memo notes api list -f "Folder Name"
  • Output formats: --format tsv (default), lines, json

Create Notes

  • Add note from stdin: echo "# Title\nBody" | memo notes api add -f "Folder Name"

View Notes

  • Show note body as Markdown: memo notes api show <note-id>

Edit Notes

  • Replace note body from stdin: memo notes api edit <note-id> (pipe or redirect)

Delete Notes

  • Delete a note: memo notes api delete <note-id>

Move Notes

  • Move note to folder: memo notes api move <note-id> <target-folder>

Search Notes

  • Search by title: memo notes api search "query"
  • Search in body too: memo notes api search "query" --body
  • Filter by folder: memo notes api search "query" -f "Folder"

Folders

  • List folders: memo notes api folders
  • Delete folder: memo notes api remove <folder-path> --force

Export

  • Export all notes: memo notes api export --path /path/to/dir
  • With Markdown conversion: memo notes api export --path /path/to/dir --markdown

Limitations

  • macOS-only. Requires Apple Notes.app.
  • For automation, grant permissions in System Settings > Privacy & Security > Automation.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment