Choose an output format
anyr space list --table
anyr space list --pretty
anyr space list --json
Compact JSON is the default. Diagnostics go to stderr.
anyr quick reference
Recall common Anytype automation commands. Quoted words such as
"Work"
are resolver-backed names; shell variables ending in
_ID
are exact IDs returned by anyr. Every
SPACE
operand shown accepts a space name or ID, and chat operands paired with a space accept a
chat name, title, or ID. Type examples use lowercase keys.
anyr space list --table
anyr space list --pretty
anyr space list --json
Compact JSON is the default. Diagnostics go to stderr.
anyr space list --pretty --output spaces.json
anyr object list "Work" --all --json
anyr --help
anyr chat messages send --help
jqanyr space list | jq '.items[] | {id, name}'
anyr --url http://127.0.0.1:31012 \
--grpc http://127.0.0.1:31010 \
--keystore file space list
HTTP and gRPC authenticate separately. See Connections and gRPC for headless-server installation and authentication.
ANYTYPE_URL=http://127.0.0.1:31012 anyr space list
anyr --url http://127.0.0.1:31012 space list
Without either selector, anyr uses
http://127.0.0.1:31012 when the selected keystore contains gRPC
credentials; otherwise it uses
http://127.0.0.1:31009.
ANYTYPE_GRPC_ENDPOINT=http://127.0.0.1:31010 anyr auth status
anyr --grpc http://127.0.0.1:31010 auth status
The default is http://127.0.0.1:31010.
ANYTYPE_KEYSTORE=file anyr auth status
anyr --keystore file auth status
The selector is optional. See the keystore reference for platform stores, file encryption, and environment credentials.
anyr init-cli
anyr auth status --pretty
CLI + gRPC means a running Anytype CLI server and a healthy authenticated gRPC ping.
anyr auth status --pretty
anyr auth login
anyr init-cli
ANYTYPE_KEYSTORE=env anyr init-cli --save-env ./anytype.env
source ./anytype.env
The file contains plaintext credentials and is created with owner-only permissions on Unix.
anyr init-cli --join "$INVITE_LINK"
printf '%s\n' "$HTTP_TOKEN" | anyr auth set-http
printf '%s\n' "$ACCOUNT_KEY" | anyr auth set-grpc --account-key
Both commands read the secret from standard input. The gRPC account key comes from the Anytype CLI server account.
anyr auth logout
anyr space list --table
anyr space get "Work" --pretty
anyr space create "Work" --description "Team documents"
anyr space create "Team Chat" --chat
--chat:
CLI + gRPC required.
anyr space update "Work" --name "Projects"
anyr space count-archived "Work"
anyr space delete-archived "Work" --confirm
anyr space delete "Old Work" \
--archive ./old-work.zip --confirm
CLI + gRPC required for the backup and permanent deletion.
anyr space delete "Old Work"
The prompt offers a backup, then requires the exact space name. CLI + gRPC required.
anyr search --space "Work" --type task --all --table
anyr search --space "Work" --type task \
--text "customer" --table
anyr object create "Work" task \
--name "Review proposal" status=Open
anyr object update "Work" "$TASK_ID" status=Done
anyr search --space "Work" --type task \
--sort last_modified_date --desc --table
anyr search --space "Work" --type task --all \
| jq -r '.[] | .id'
anyr object list "Work" --type page --table
anyr object get "Work" "$OBJECT_ID" --pretty
anyr object create "Work" page \
--name "Meeting notes" --body-file notes.md
anyr object update "Work" "$OBJECT_ID" \
--name "New title" priority=2
anyr search --text "meeting notes" --table
anyr search --space "Work" --text "meeting notes" --table
anyr object link "Work" "$OBJECT_ID"
anyr object delete "Work" "$OBJECT_ID"
CLI + gRPC required. Attached-discussion operations also use HTTP preflight. Object and block operands are exact IDs.
anyr object discussion get "Work" "$OBJECT_ID" --pretty
anyr object discussion attach "Work" "$OBJECT_ID" --pretty
get returns an absent or attached
state. attach creates the derived discussion when absent and returns
the verified discussion ID.
anyr body list "Work" "$OBJECT_ID" --table
anyr body show "Work" "$OBJECT_ID" "$BLOCK_ID" --pretty
List output preserves document order and reports each block's parent and sibling position.
anyr body create "Work" "$OBJECT_ID" "$ROOT_BLOCK_ID" \
last-child --block @- <<'JSON'
{"content":{"kind":"callout","text":"Check this","icon":{"type":"emoji","content":"💡"}},"background_color":"grey"}
JSON
--block accepts literal JSON, @FILE,
@-, or - for standard input.
anyr body update "Work" "$OBJECT_ID" "$BLOCK_ID" --change \
'{"kind":"text","text":"Checked","marks":[]}'
Changes cover text and marks, style, checkbox state, colors, callout icons, embeds, link appearance, and alignment.
anyr body move "Work" "$OBJECT_ID" "$BLOCK_ID" \
"$TARGET_BLOCK_ID" before
Positions are before, after,
first-child, and last-child.
anyr body delete "Work" "$OBJECT_ID" "$BLOCK_ID" \
--expected-subtree-blocks 1 --confirm
The command rereads the body and refuses deletion when the current subtree size differs from the supplied count.
anyr md get "Work" "$OBJECT_ID" --output page.md
$EDITORanyr md edit "Work" "$OBJECT_ID"
anyr md edit --doc "$ANYTYPE_LINK"
anyr md update --input page.md
The exported file carries the object coordinates used by
update.
A chat name operand requires the Anytype CLI server and gRPC credentials for name resolution, even when the command itself can use REST. Pass an exact chat ID to keep a REST-backed operation HTTP-only.
anyr chat list --space "Work" --table
anyr chat create "Work" "Ops"
anyr chat messages send "Work" "Ops" \
--text "Deployment complete"
anyr chat messages send "Work" "Ops" \
--text "Release ready" --style header2 --mark bold:0:13
The mark range selects the complete 13-byte ASCII message.
anyr chat messages list "Work" "Ops" --limit 1000 --json \
| jq '.messages[] | select(.created_at >= "2026-08-01T00:00:00Z")'
This filters one bounded window. Use order-ID continuation to inspect older windows. CLI + gRPC required.
anyr chat messages search "Work" "Ops" \
"deployment" --table
anyr chat messages edit "Work" "Ops" "$MESSAGE_ID" \
--text "Updated status"
anyr chat messages react "Work" "Ops" "$MESSAGE_ID" "👍"
anyr chat listen --space "Work" --chat "Ops" \
--initial-limit 20 --heartbeat 15
anyr chat read-all "Work" "Ops"
anyr chat list
anyr chat get "Work" "Ops"
anyr chat messages get "Work" "Ops" "$MESSAGE_ID"
anyr chat messages delete "Work" "Ops" "$MESSAGE_ID"
anyr chat unread "Work" "Ops" --after "$ORDER_ID"
CLI + gRPC required.
Cross-space or text-filtered chat lists, message list/get/delete,
unread, --blocks-json, and multi-chat or preview
listeners also select gRPC.
anyr file list "Personal" --file-type image \
--size-gte 1048576 --name-contains report --table
CLI + gRPC required.
file search and file get use the same backend.
anyr file upload "Personal" --file ./report.pdf \
--mime application/pdf
anyr file upload "Personal" --stdin --name report.pdf \
< ./report.pdf
anyr file upload "Personal" --url https://example.com/logo.png \
--file-type image --style embed
CLI + gRPC required. On
file upload, --url, --file-type,
--style, --details, and creation-context options select
gRPC. File preload and discard-preload also require it.
anyr file download "Personal" "$FILE_ID" --dir /tmp
anyr file metadata "Personal" "$FILE_ID" --width 128
--width
selects the image variant whose headers are returned.
anyr file update "Personal" "$FILE_ID" --name report-final.pdf
anyr file delete "Personal" "$FILE_ID" --permanent
anyr file preload "Personal" --file ./draft.png --file-type image
anyr file discard-preload "Personal" "$PRELOAD_ID"
anyr type list "Work" --table
anyr property list "Work" --table
anyr type create "Work" decision "Decision" \
--plural "Decisions" --layout basic
anyr property create "Work" "Priority" number \
--key priority
anyr property create "Work" "Status" select \
--key status --tag Open:blue --tag Done:lime
anyr tag create "Work" "$PROPERTY_ID" Blocked red \
--key blocked
anyr template list "Work" task --table
anyr type update "Work" task --add-property status
--add-property:
CLI + gRPC required.
--set-property and --clear-properties remain
REST-backed.
anyr search --space "Work" --type collection --table
anyr search --space "Work" --type set --table
anyr list views "Work" "$LIST_ID" --table
anyr view objects "Work" "$TYPE_ID" --view "$VIEW_ID" \
--columns name,creator,status --table
anyr list add "Work" "$LIST_ID" "$OBJECT_ID"
anyr list remove "Work" "$LIST_ID" "$OBJECT_ID"
anyr member list "Work" --status active --table
anyr space invite show "Work"
anyr space invite revoke "Work"
anyr space enable-sharing "Work"
anyr space disable-sharing "Work"
anyr backup create --space "Work" --dir ./backups
Add --include-files to embed file objects and binaries.
CLI + gRPC required.
anyr backup create --space "Work" \
--dest ./backups/work.zip --include-files
anyr backup list ./backups/work.zip --files --table
anyr backup manifest ./backups/work.zip --pretty
anyr backup restore ./backups/work.zip \
--space "Restored Work" --dry-run
The dry run reads the archive locally and resolves the destination over HTTP.
anyr backup restore ./backups/work.zip \
--space "Restored Work" --log restore.json
anyr backup diff ./backups/old.zip ./backups/new.zip \
--table
anyr backup inspect ./backups/work.zip
The inspector owns the terminal and rejects output-format flags.
anyr mcp
The compact base catalog is HTTP-complete. The standard read-write catalog and some optional toolsets require a running Anytype CLI server and gRPC credentials.
anyr mcp init
anyr mcp check
source <(anyr completions zsh)
source <(anyr completions bash)
anyr completions fish | source
anyr --version