Настройка и обслуживание
Вход, профили, настройки, фоновый сервер, локальное хранилище, диагностика, подключение агента и обновления.
Здесь собраны команды настройки и обслуживания. Вы найдёте параметры входа, профилей, настроек, фонового сервера, локального хранилища, диагностики и подключения агента.
Вход, профили, настройки, фоновый сервер, локальное хранилище, диагностика, подключение агента и обновления.
Общие опции
Действуют на любую команду.
Команды
max session
the stored MAX session for this profile
max session start
log this profile in to MAX
max session start [method]| Аргумент | Обязательность | Что это |
|---|---|---|
method | необязательный | token (pasted or piped), qr, qr-chrome or sms. Одно из: token, qr, qr-chrome, sms. По умолчанию: token. |
max session end
выйти из этого профиля на стороне MAX и удалить сохранённую здесь сессию
Меняет что-то в MAX.
max session endmax setup
set up your personal MAX account and connect your agent
Меняет что-то в MAX.
max setup [options]| Опция | Что делает |
|---|---|
--agent <agent> | install the skill for this agent; asks at a terminal, otherwise none. Одно из: none, codex, cursor, claude, gemini, all. |
--method <method> | how to log in when there is no session. Одно из: token, qr, qr-chrome, sms. По умолчанию: qr. |
max account
the logged-in account
max account list
все профили на этом компьютере и аккаунт каждого; не обращается к мессенджеру
max account listmax account show
who this profile is logged in as; the phone number shows its last four digits
max account show [options]| Опция | Что делает |
|---|---|
--show-phone | показать номер телефона целиком. |
max account update
change the name, the description or the photo everyone sees on your profile
Меняет что-то в MAX.
max account update [options]| Опция | Что делает |
|---|---|
--first-name <name> | your first name. |
--last-name <name> | your last name. |
--description <text> | about you. |
--photo <file> | a new profile photo — an image file. |
max account sessions
where else this account is logged in — not max session, which is this tool's own login
max account sessions list
every device and app logged in to this account; nothing is ended
max account sessions listmax account sessions end
log out every other device, your phone included; this one stays
Меняет что-то в MAX.
max account sessions end [options]| Опция | Что делает |
|---|---|
--others | every session but this one. |
max account privacy
кто может найти аккаунт, позвонить или добавить его
max account privacy show
настройки приватности аккаунта; чтение ничего не меняет
max account privacy showmax account privacy set
изменить, кто может найти аккаунт, позвонить или добавить его; остальные настройки сохраняются
Меняет что-то в MAX.
max account privacy set [options]| Опция | Что делает |
|---|---|
--find-by-phone <who> | кто находит аккаунт по номеру: everyone, contacts или nobody; MAX принимает everyone и contacts. |
--phone-number <who> | кто видит номер: everyone, contacts или nobody. |
--calls <who> | кто может звонить: everyone, contacts или nobody. |
--chat-invites <who> | кто добавляет аккаунт в группы и каналы: everyone, contacts или nobody. |
--hide-online <on|off> | скрыть статус онлайн и время последнего входа. |
max store
the local store of messages
max store status
per chat: messages stored, the oldest and newest, and the stretches held completely
max store status [chat]| Аргумент | Обязательность | Что это |
|---|---|---|
chat | необязательный | чат: его ID или часть названия. |
max store gaps
проверить записанные внутренние пробелы охвата и явно загрузить данные для них
max store gaps plan
локальный план охвата; отсутствие идентификаторов сообщений само по себе не означает нехватку истории
max store gaps plan <chat>| Аргумент | Обязательность | Что это |
|---|---|---|
chat | обязательный | чат: его ID или часть названия. |
max store gaps repair
загрузить данные внутренних пробелов с ограничениями и перепроверить охват; никогда не удалять сообщения, которые не встретились при загрузке
max store gaps repair <chat> [options]| Аргумент | Обязательность | Что это |
|---|---|---|
chat | обязательный | чат: его ID или часть названия. |
| Опция | Что делает |
|---|---|
--limit <n> | общее число сообщений при этом устранении пробелов, по умолчанию 500. |
--max-gaps <n> | не более указанного числа пробелов, по умолчанию 5. |
--repair-time <duration> | время, отведённое на восстановление, по умолчанию 30s. По умолчанию: 30s. |
--page-size <n> | число сообщений на страницу провайдера. |
--pause <duration> | пауза между страницами провайдера. По умолчанию: 5s. |
--fingerprint <hash> | отказать, если этот ранее проверенный план охвата изменился. |
--catch-up | подготовить локальный поиск после устранения пробелов; переопределяет searchCatchUp. |
--no-catch-up | пропустить подготовку локального поиска после устранения пробелов. |
--catch-up-chunks <n> | максимальное число подготавливаемых локальных фрагментов. |
--catch-up-messages <n> | максимальное число сохранённых сообщений, читаемых для подготовки. |
--catch-up-time <duration> | время подготовки в пределах оставшегося лимита устранения пробелов. |
--background | устранять пробелы через существующий механизм заданий хранилища; проверять через store jobs show. |
max store jobs
фоновые задания синхронизации
max store jobs list
фоновые задания синхронизации, новые сверху
max store jobs list [options]| Опция | Что делает |
|---|---|
--state <state> | Только задачи в состоянии running, done, failed, cancelled или died. |
max store jobs show
one background job — the newest when none is named — and what the store now holds of its chat
max store jobs show [job]| Аргумент | Обязательность | Что это |
|---|---|---|
job | необязательный | ID задания, который напечатала messages sync --background. |
max store jobs cancel
остановить идущее фоновое задание после текущей страницы; следующая синхронизация продолжит с того же места
max store jobs cancel <job>| Аргумент | Обязательность | Что это |
|---|---|---|
job | обязательный | the job id. |
max store jobs retry
запустить частичное, неудавшееся или умершее задание заново, новым заданием; синхронизация продолжится с того места, где остановилось хранилище
max store jobs retry [job] [options]| Аргумент | Обязательность | Что это |
|---|---|---|
job | необязательный | ID задания. |
| Опция | Что делает |
|---|---|
--failed | каждый чат, чьё последнее задание осталось частичным, завершилось ошибкой или умерло. |
max store jobs clear
забыть завершённые задания и удалить их логи; работающее задание остаётся
Меняет что-то только на этом компьютере.
max store jobs clearmax store export
сохранённые сообщения чата, от старых к новым: --jsonl — одно сообщение на строку, --json — один объект { items, page, limit, hasMore }; к мессенджеру не обращается
max store export [chats] [options]| Аргумент | Обязательность | Что это |
|---|---|---|
chats | необязательный | a chat: its id, or part of its title; several with --to. |
| Опция | Что делает |
|---|---|
--format <format> | jsonl: одно сообщение на строку, по умолчанию с --output; markdown: стенограмма с заголовком на каждый день, ответы и пересылки цитируются. |
--since-time <time> | only from this ISO 8601 time, or 30m / 2h / 1d ago, on. |
--output <file> | write JSON lines, or the transcript, to this new file, readable only by you. |
--to <dir> | write into this folder, a file per chat and a manifest; run again on it for only what changed since. |
--kind <kinds> | with --to: every stored chat of these kinds, comma-separated: dialog, group, channel, saved. |
--all | with --to: every stored chat of this account. |
--encrypt | compress and encrypt with a password, typed at a hidden prompt or piped on stdin; it is never kept — lose it and the file cannot be opened. |
max store clear
delete from the store the chats this account has left, with their messages
max store clear [options]| Опция | Что делает |
|---|---|
--left | the chats this account has left — the only thing this clears. |
--allow-dangerous | yes, delete — it cannot be undone, and a chat you left cannot be fetched again. |
max store info
the store file: where it is, its size, its schema and how many rows it holds; changes nothing
max store infomax store check
whether the store is healthy — integrity, search indexes, disk, and which chats are behind
max store checkmax store migrate
обновить схему архива, нормализовать сообщения и заметки, построить индексы слов и основ
max store migratemax store reindex
перестроить индексы слов, опечаток, основ, файлов и заметок без удаления данных
max store reindexmax store backup
copy the store into a new file, while it is in use; never overwrites a file
max store backup <file> [options]| Аргумент | Обязательность | Что это |
|---|---|---|
file | обязательный | the new file. |
| Опция | Что делает |
|---|---|
--encrypt | compress and encrypt with a password, typed at a hidden prompt or piped on stdin; it is never kept — lose it and the file cannot be opened. |
max store restore
put a backup in place of the store; the store it replaces is kept beside it, never deleted
max store restore <file>| Аргумент | Обязательность | Что это |
|---|---|---|
file | обязательный | a file store backup wrote; one written with --encrypt asks for its password. |
max store decrypt
open a file written with --encrypt into a new file; asks for its password
max store decrypt <file> [options]| Аргумент | Обязательность | Что это |
|---|---|---|
file | обязательный | a file store backup --encrypt or store export --encrypt wrote. |
| Опция | Что делает |
|---|---|
--output <file> | the new file, readable only by you. |
max store repair
bring every table to this build's shape, deleting nothing: a table of the wrong shape is kept as a copy beside a new one
max store repair [options]| Опция | Что делает |
|---|---|
--dry-run | say what it would do, and change nothing. |
max store reset
back the store up beside itself, then delete it and start an empty one at this build's schema; asks first, or --yes
max store reset [options]| Опция | Что делает |
|---|---|
--no-backup | delete the store without backing it up first. |
max store copies
the tables store repair kept as copies
max store copies delete
delete one copy store repair kept, named exactly; refuses any other table
max store copies delete <name>max flood
the waits MAX asked this profile to keep, and a hold on its writes
max flood clear
забыть их, снять приостановку и ограничение темпа профиля, когда MAX больше не ограничивает аккаунт; на стороне MAX ничего не меняется
max flood clearmax models
models that run on this machine
max models audio
speech models for transcribing voice messages
max models audio list
the speech models, most suitable first, which are downloaded, and which one is the default
max models audio listmax models audio download
download a speech model once, checked against the sha256 this version expects
max models audio download <model>max models text
embedding models for searching conversations by meaning
max models text list
the embedding models, most suitable first, which are downloaded, and which one is the default
max models text listmax models text download
download an embedding model once, checked against the sha256 this version expects
max models text download <model> [options]| Опция | Что делает |
|---|---|
--accept-terms | accept the model's licence terms, for a model that has its own. |
max models text key
API keys for embedding and analysis providers
max models text key set
store a key, typed at a hidden prompt or piped on stdin — never as an argument
max models text key set <provider>| Аргумент | Обязательность | Что это |
|---|---|---|
provider | обязательный | openai, anthropic, or the host of a --base-url server that wants a key. |
max models text key remove
forget a stored key
max models text key remove <provider>| Аргумент | Обязательность | Что это |
|---|---|---|
provider | обязательный | openai, anthropic, or a server's host. |
max serve
stay connected to MAX and stream new messages to max watch, until Ctrl-C
max serve [options]| Опция | Что делает |
|---|---|
--idle <duration> | stop after this long with nobody using it — 15m, 1h is 60m. |
max server
max serve in the background: start, stop, restart, status, logs; install adds a systemd or launchd unit
max server start
start serve in the background — through the unit if one is installed — and answer once it connects
max server start [options]| Опция | Что делает |
|---|---|
--idle <duration> | остановиться, если им никто не пользуется столько времени — 15m, 1h. |
max server stop
stop this profile's serve — through the unit if it runs under one
max server stopmax server restart
stop it and start it again
max server restart [options]| Опция | Что делает |
|---|---|
--idle <duration> | остановиться, если им никто не пользуется столько времени — 15m, 1h. |
max server status
whether serve runs for this profile, since when, who started it, and the unit if there is one
max server statusmax server logs
serve's latest log lines — from the journal under systemd, else its log file
max server logs [options]| Опция | Что делает |
|---|---|
-n, --lines <n> | how many lines. По умолчанию: 50. |
max server install
write a systemd user unit or a launchd agent for this profile; starts nothing
max server installmax server uninstall
remove this profile's unit; stop it first
max server uninstallmax watch
print new messages as they arrive, from a running max serve
max watch [options]| Опция | Что делает |
|---|---|
--events | также выводить правки, удаления, реакции, прочтения и изменения чатов; каждая строка содержит вид события. |
max config
the settings in force, and where each one came from
max config show
the profile, the profiles that exist, and each setting with where it came from
max config show [options]| Опция | Что делает |
|---|---|
--bot | the settings a bot command on this profile gets, rather than the personal account's. |
max config migrate
replace legacy access settings with permissions, preserving effective levels
Меняет что-то только на этом компьютере.
max config migrate [options]| Опция | Что делает |
|---|---|
--dry-run | show the migration without writing the file. |
max config set
save a setting to the configuration file
Меняет что-то только на этом компьютере.
max config set <setting> <value> [options]| Аргумент | Обязательность | Что это |
|---|---|---|
setting | обязательный | одно из: limit, timeoutMs, color, record, keepRunsForDays, readOnly, allow, permissions, sendsPerHour, requestsPerMinute, embeddingProvider, embeddingModel, embeddingBaseUrl, embeddingDims, analysisProvider, analysisModel, analysisBaseUrl, models, senderColors, catchUpMarksRead, searchCatchUp, serve, mcpTools, readOtherBots, updateCheck, skillHint, transcribeModel, defaultProfile, searchStemmers.cyrillic, searchStemmers.latin. |
value | обязательный | a number, true or false, or for allow a list like send,reaction. |
| Опция | Что делает |
|---|---|
--defaults | изменить значение для всех профилей, а не только для этого. |
--personal | только для личных аккаунтов — раздел personal в файле. |
--bot | только для ботов — раздел bot в файле. |
max config unset
remove a setting from the configuration file
Меняет что-то только на этом компьютере.
max config unset <setting> [options]| Аргумент | Обязательность | Что это |
|---|---|---|
setting | обязательный | одно из: limit, timeoutMs, color, record, keepRunsForDays, readOnly, allow, permissions, sendsPerHour, requestsPerMinute, embeddingProvider, embeddingModel, embeddingBaseUrl, embeddingDims, analysisProvider, analysisModel, analysisBaseUrl, models, senderColors, catchUpMarksRead, searchCatchUp, serve, mcpTools, readOtherBots, updateCheck, skillHint, transcribeModel, defaultProfile, searchStemmers.cyrillic, searchStemmers.latin. |
| Опция | Что делает |
|---|---|
--defaults | изменить значение для всех профилей, а не только для этого. |
--personal | только для личных аккаунтов — раздел personal в файле. |
--bot | только для ботов — раздел bot в файле. |
max doctor
the state this installation is in, without contacting MAX unless --online
max doctor [options]| Опция | Что делает |
|---|---|
--online | also log in once, read one chat and start the MCP server; sends nothing. |
max doctor report
what a problem report holds and where it goes; writes nothing
max doctor report create
write a problem report to a file, and print how to send it
max doctor report create [options]| Опция | Что делает |
|---|---|
--run <id> | the run the report is about; the newest failed one if not given. |
--output <file> | where to write it; a new file in this directory if not given. |
max runs
recorded runs — what this tool did, and when
max runs list
recorded runs, newest first
max runs list [options]| Опция | Что делает |
|---|---|
--limit <n> | how many to show. По умолчанию: 20. |
max runs show
один запуск: что это было, чем закончилось и что пошло не так; -v — все события
max runs show <run-id>max runs search
search recorded diagnostic metadata and events; no message contents
max runs search [query] [options]| Аргумент | Обязательность | Что это |
|---|---|---|
query | необязательный | case-insensitive literal diagnostic text. |
| Опция | Что делает |
|---|---|
--status <status> | run outcome. Одно из: success, failed, partial, running. |
--error-code <code> | one stable error code. |
--operation <name> | one operation, such as messages.download. |
--profile <name> | one recorded profile. |
--since-time <time> | runs starting on or after an ISO time or 2h / 1d ago. |
--limit <n> | matches per page, at most 100. По умолчанию: 20. |
--page <n> | result page. По умолчанию: 1. |
max runs path
the directory holding one run
max runs path <run-id>max skill
the instructions an agent is given for this tool
max skill show
print SKILL.md — max skill install puts it where Claude Code, Codex and Gemini CLI look for it
max skill show [name]| Аргумент | Обязательность | Что это |
|---|---|---|
name | необязательный | один из навыков для задачи, которые идут в комплекте: follow-ups, link-conversations. |
max skill install
write SKILL.md to ~/.claude/skills/max-cli/ (Claude Code) and ~/.agents/skills/max-cli/ (Codex, Gemini CLI)
max skill install [options]| Опция | Что делает |
|---|---|
--for <agents> | which agents to install for. Одно из: claude, agents, all. По умолчанию: all. |
max commands
commands, options and exit codes as JSON — inspect one command path per call
max commands schema
argv и схемы результатов одной команды, эффекты, разрешения и указания по повторным попыткам
max commands schema <path>| Аргумент | Обязательность | Что это |
|---|---|---|
path | обязательный | один путь команды, например: stats messages show. |
max upgrade
upgrade max with the package manager that installed it; --check only looks
max upgrade [options]| Опция | Что делает |
|---|---|
--check | say whether a newer version exists, and install nothing. |
max complete
shell completion: max complete zsh prints the script to source
max complete [words]| Аргумент | Обязательность | Что это |
|---|---|---|
words | необязательный |
max mcp
serve this profile to an agent over MCP, on stdin and stdout — claude mcp add max -- max mcp
max mcp [options]| Опция | Что делает |
|---|---|
--permission <key=level> | переопределить разрешение только для этого сервера; повторите для нескольких ключей. |
--allow-dangerous | больше не используется — операции записи не показывают форму; решение определяют разрешения профиля. |
--allow-send | устарело: используйте permissions.messages.send в настройках; доступа не даёт. |
--confirm-send | больше не используется — операции записи не показывают форму; решение определяют разрешения профиля. |
--allow-mark-read | устарело: используйте permissions.chats.mark-read в настройках; доступа не даёт. |
--allow-delete | устарело: используйте permissions.messages.delete в настройках; доступа не даёт. |
--allow-moderate | устарело: используйте permissions.chats.moderate и правила группы; доступа не даёт. |
--http | предоставлять HTTP-сервер на 127.0.0.1 для ChatGPT и Claude в браузере через ваш туннель; действуют права профиля. |
--http-confirmation <mode> | больше не используется — операции записи не показывают форму; решение определяют разрешения профиля. |
--port <port> | the local port for --http (default 8765). |
--public-url <url> | the tunnel's https address the browser apps use, e.g. https://.ts.net. |
--revoke | forget every login given to a browser app; each must log in again. |
max mcp config
print the mcpServers entry for Claude Desktop, Cursor and others, with full paths; writes nothing
max mcp config [options]| Опция | Что делает |
|---|---|
--permission <key=level> | переопределить разрешение только для этого сервера; повторите для нескольких ключей. |
--allow-dangerous | больше не используется — операции записи не показывают форму; решение определяют разрешения профиля. |
--allow-send | устарело: используйте permissions.messages.send в настройках; доступа не даёт. |
--confirm-send | больше не используется — операции записи не показывают форму; решение определяют разрешения профиля. |
--allow-mark-read | устарело: используйте permissions.chats.mark-read в настройках; доступа не даёт. |
--allow-delete | устарело: используйте permissions.messages.delete в настройках; доступа не даёт. |
--allow-moderate | устарело: используйте permissions.chats.moderate и правила группы; доступа не даёт. |
max mcp setup
add this profile's local MCP server to Codex or Claude Code
Меняет что-то только на этом компьютере.
max mcp setup <client> [options]| Аргумент | Обязательность | Что это |
|---|---|---|
client | обязательный | codex or claude-code. |
| Опция | Что делает |
|---|---|
--allow-writes | acknowledge that this profile offers writing tools. |
--permission <key=level> | переопределить разрешение только для этого сервера; повторите для нескольких ключей. |
--allow-dangerous | больше не используется — операции записи не показывают форму; решение определяют разрешения профиля. |
--allow-send | устарело: используйте permissions.messages.send в настройках; доступа не даёт. |
--confirm-send | больше не используется — операции записи не показывают форму; решение определяют разрешения профиля. |
--allow-mark-read | устарело: используйте permissions.chats.mark-read в настройках; доступа не даёт. |
--allow-delete | устарело: используйте permissions.messages.delete в настройках; доступа не даёт. |
--allow-moderate | устарело: используйте permissions.chats.moderate и правила группы; доступа не даёт. |
max mcp doctor
check this profile's local MCP handshake and tool list
max mcp doctor [options]| Опция | Что делает |
|---|---|
--permission <key=level> | переопределить разрешение только для этого сервера; повторите для нескольких ключей. |
--allow-dangerous | больше не используется — операции записи не показывают форму; решение определяют разрешения профиля. |
--allow-send | устарело: используйте permissions.messages.send в настройках; доступа не даёт. |
--confirm-send | больше не используется — операции записи не показывают форму; решение определяют разрешения профиля. |
--allow-mark-read | устарело: используйте permissions.chats.mark-read в настройках; доступа не даёт. |
--allow-delete | устарело: используйте permissions.messages.delete в настройках; доступа не даёт. |
--allow-moderate | устарело: используйте permissions.chats.moderate и правила группы; доступа не даёт. |
Коды возврата
Скрипт ветвится по коду, а не по тексту: текст меняется, код — нет.
| Код | Когда |
|---|---|
0 | получилось |
2 | validation_error |
3 | configuration_error |
4 | authentication_error |
5 | permission_error |
6 | not_found |
7 | confirmation_required |
8 | rate_limited |
9 | timeout |
10 | network_error |
11 | provider_error |
12 | provider_unavailable |
13 | invalid_response |
14 | outcome_unknown |
130 | cancelled |
1 | всё остальное |
0 и только 0 означает, что операция выполнена. 14 — outcome_unknown — означает, что
сообщение могло уйти: не отправлено и не провалено, и повторять его можно только с тем же
--send-id.