@wirecat/max-cli 0.62.0 → 0.64.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (72) hide show
  1. package/README.md +8 -5
  2. package/dist/adapter/max-adapter.js +1 -1
  3. package/dist/adapter/max-adapter.js.map +1 -1
  4. package/dist/client/chat-writes.js +1 -1
  5. package/dist/client/chat-writes.js.map +1 -1
  6. package/dist/client/live.js +2 -2
  7. package/dist/client/live.js.map +1 -1
  8. package/dist/client/people.js +3 -3
  9. package/dist/client/people.js.map +1 -1
  10. package/dist/client/values.js +1 -1
  11. package/dist/client/values.js.map +1 -1
  12. package/dist/commands/contacts.js +2 -2
  13. package/dist/commands/contacts.js.map +1 -1
  14. package/dist/commands/doctor.js +1 -1
  15. package/dist/commands/doctor.js.map +1 -1
  16. package/dist/commands/messages.js +1 -1
  17. package/dist/commands/messages.js.map +1 -1
  18. package/dist/commands/serve-members.d.ts.map +1 -1
  19. package/dist/commands/serve-members.js +2 -2
  20. package/dist/commands/serve-members.js.map +1 -1
  21. package/dist/commands/session.d.ts +1 -1
  22. package/dist/commands/session.d.ts.map +1 -1
  23. package/dist/commands/session.js +36 -29
  24. package/dist/commands/session.js.map +1 -1
  25. package/dist/commands/setup.d.ts.map +1 -1
  26. package/dist/commands/setup.js +15 -6
  27. package/dist/commands/setup.js.map +1 -1
  28. package/dist/commands/watch.js +1 -1
  29. package/dist/commands/watch.js.map +1 -1
  30. package/dist/install/postinstall.d.ts.map +1 -1
  31. package/dist/install/postinstall.js +4 -3
  32. package/dist/install/postinstall.js.map +1 -1
  33. package/dist/messenger.js +1 -1
  34. package/dist/messenger.js.map +1 -1
  35. package/dist/permissions.d.ts.map +1 -1
  36. package/dist/permissions.js +2 -1
  37. package/dist/permissions.js.map +1 -1
  38. package/dist/program.d.ts.map +1 -1
  39. package/dist/program.js +22 -13
  40. package/dist/program.js.map +1 -1
  41. package/dist/server/server-connection.js +1 -1
  42. package/dist/server/server-connection.js.map +1 -1
  43. package/dist/server/server.js +2 -2
  44. package/dist/server/server.js.map +1 -1
  45. package/dist/session/browser.d.ts +0 -11
  46. package/dist/session/browser.d.ts.map +1 -1
  47. package/dist/session/browser.js +0 -63
  48. package/dist/session/browser.js.map +1 -1
  49. package/dist/session/store.d.ts +5 -0
  50. package/dist/session/store.d.ts.map +1 -1
  51. package/dist/session/store.js +16 -3
  52. package/dist/session/store.js.map +1 -1
  53. package/dist/spec/operations/assets.js +1 -1
  54. package/dist/spec/operations/assets.js.map +1 -1
  55. package/dist/spec/operations/banners.js +1 -1
  56. package/dist/spec/operations/banners.js.map +1 -1
  57. package/dist/spec/operations/calls.js +1 -1
  58. package/dist/spec/operations/calls.js.map +1 -1
  59. package/dist/spec/operations/contacts.js +1 -1
  60. package/dist/spec/operations/contacts.js.map +1 -1
  61. package/dist/version.d.ts +1 -1
  62. package/dist/version.js +1 -1
  63. package/package.json +4 -4
  64. package/scenarios/agent-on-a-timer.md +17 -0
  65. package/scenarios/catch-up.md +17 -0
  66. package/scenarios/find-what-was-said.md +17 -0
  67. package/scenarios/post-as-a-bot.md +17 -0
  68. package/skills/max-cli/SKILL.md +7 -5
  69. package/dist/session/qr-terminal.d.ts +0 -9
  70. package/dist/session/qr-terminal.d.ts.map +0 -1
  71. package/dist/session/qr-terminal.js +0 -34
  72. package/dist/session/qr-terminal.js.map +0 -1
@@ -0,0 +1,17 @@
1
+ ---
2
+ title: Find what someone said
3
+ goal: Get back a message, a file or a voice note when you remember only a word or the person.
4
+ steps:
5
+ - run: max search all "invoice"
6
+ why: messages, notes, the text of files and voice transcripts in one search, best match first
7
+ - run: max contacts timeline Anna
8
+ why: everything one person wrote or was mentioned in, newest first, from the store
9
+ - run: max messages context Team 1234
10
+ why: the message a hit points to, with what came either side of it
11
+ look:
12
+ - the chat and the time of each hit
13
+ - the msg locator, to cite it or to open the message
14
+ ---
15
+
16
+ A search finds only what the store holds. Run `max messages sync --all` once, or `max schedule command` on a timer,
17
+ so older history is there to find.
@@ -0,0 +1,17 @@
1
+ ---
2
+ title: Post as your bot
3
+ goal: Send a message to a group as your bot, through MAX's official Bot API, not from your own account.
4
+ steps:
5
+ - run: max bot auth set
6
+ why: checks the bot's token with MAX and keeps it; type it at the hidden prompt or pipe it on stdin
7
+ - run: max bot chats list
8
+ why: the chats this bot has seen on this machine, to pick the one to write to
9
+ - run: max bot messages send Team "the release is out"
10
+ why: sends the message as the bot; without the text it is read from stdin
11
+ look:
12
+ - which bot `bot auth set` names, before anything is sent
13
+ - the message id the send returns, to edit or pin it later
14
+ ---
15
+
16
+ A bot needs its own token from MAX; your personal login is not used. `max bot recipients add` limits which chats the
17
+ bot may write to.
@@ -47,6 +47,8 @@ MCP: сначала `max_tools_search`, затем `max_read` или `max_write`
47
47
  Предупредите: настройка может занять около пяти минут. QR сканирует владелец приложением MAX;
48
48
  `--method qr-chrome` и `sms` используют web.max.ru в браузере, `--method token` — скрытый ввод
49
49
  или stdin. Токен и пароль не запрашивайте в чате и не передавайте аргументами команды.
50
+ Без терминала: `max personal setup --qr-file login.png --agent codex --json` пишет QR-код в PNG;
51
+ покажите картинку владельцу. Файл удаляется после входа; облачный пароль MAX так не ввести.
50
52
  Повторный setup проверяет существующую сессию без нового входа. Если ключница недоступна,
51
53
  исправьте окружение по подсказке, не создавайте новую сессию. При истёкшем токене владелец
52
54
  явно запускает `max personal session start qr`.
@@ -121,7 +123,7 @@ remove|admins|update|link reset|requests accept|requests decline` видят д
121
123
  2. **Первое слово — профиль, если это не команда.** `max work chats list` — профиль `work`.
122
124
  Флага `--profile` нет; то же делает переменная `MAX_PROFILE`.
123
125
  **Профиль не подразумевается, даже единственный:** без имени команда завершается с кодом `2`
124
- и перечисляет профили (`error.profiles`) — спросите владельца, какой нужен, не берите первый.
126
+ и перечисляет профили (`error.details.profiles`) — спросите владельца, какой нужен, не берите первый.
125
127
  Без профиля работают `--help`, `commands`, `skill show`, `account list`, `config show`. Имя профиля — латиница, цифры,
126
128
  точка, дефис и подчёркивание: оно становится именем файла и записью в ключнице. Имя в другом
127
129
  алфавите отвергается **как имя** (код `2`), и это не то же самое, что профиль, в который никто
@@ -171,7 +173,7 @@ remove|admins|update|link reset|requests accept|requests decline` видят д
171
173
  5d. **Ошибку, которую не удаётся объяснить, — в отчёт автору.** Предложите владельцу
172
174
  `max personal doctor report create`: команда пишет файл без текстов сообщений и печатает ссылку на новую
173
175
  задачу на GitHub. Задачу создаёт владелец сам: она видна всем.
174
- 5e. **`max` не находится — `npx @wirecat/max-cli doctor`.** Он скажет, куда поставлена команда и
176
+ 5e. **`max` не находится — `npx @wirecat/max-cli personal doctor`.** Вместо `personal` подставьте имя профиля владельца. Он скажет, куда поставлена команда и
175
177
  почему терминал её не видит, и напечатает команду исправления. Клиенту MCP без терминала (Claude
176
178
  Desktop, Cursor) готовую запись с полными путями печатает `max personal mcp config`.
177
179
  6. **`messages show` и `messages context` требуют чат и id сообщения** — или одну ссылку `msg:…` из
@@ -190,7 +192,7 @@ remove|admins|update|link reset|requests accept|requests decline` видят д
190
192
  Отправка с `--offline` — всегда отказ.
191
193
  10. **Многострочный текст передаётся только через stdin.** Аргумент командной строки перевод
192
194
  строки не несёт вовсе, а тело в аргументе видно в `ps` и остаётся в истории оболочки. Последний
193
- аргумент опускается, и тело читается со входа: `printf 'первая\n\nтретья' | max messages send
195
+ аргумент опускается, и тело читается со входа: `printf 'первая\n\nтретья' | max personal messages send
194
196
  -1000`. Один перевод строки в самом конце отбрасывается, остальные сохраняются.
195
197
  11. **Номер страницы на живом списке может повторить или пропустить строку.** Сверху самое свежее,
196
198
  поэтому сообщение, пришедшее между первой страницей и второй, сдвигает кого-то через границу.
@@ -198,8 +200,8 @@ remove|admins|update|link reset|requests accept|requests decline` видят д
198
200
  12. **`max personal inbox --new` сдвигает место, где владелец остановился.** После него следующий
199
201
  `--new` владельца не покажет того, что уже увидел агент. Без сдвига: просто `max personal inbox`
200
202
  (непрочитанное) или `max personal inbox 'date>2h'`.
201
- 13. **`--at-time` ставит сообщение в очередь MAX, а не отправляет.** Ответ — `{item: {operation_id, operation_id,
202
- message, scheduled_for}}`; ушедшее сообщение получит другой id. Очередь: `max messages scheduled <чат>`.
203
+ 13. **`--at-time` ставит сообщение в очередь MAX, а не отправляет.** Ответ — `{item: {operation_id,
204
+ message, scheduled_for}}`; ушедшее сообщение получит другой id. Очередь: `max personal messages scheduled <чат>`.
203
205
  Через MCP — параметр `at_time` у `max_write` (`command: "messages send"`) и инструмент `max_read` (`command: "messages scheduled"`).
204
206
  Отменить можно только в приложении MAX.
205
207
 
@@ -1,9 +0,0 @@
1
- /**
2
- * A QR code as text, two modules per character cell with half blocks, so it fits a terminal
3
- * without being twice as tall as it is wide. `width` is in columns, for deciding whether it fits.
4
- */
5
- export declare const terminalQr: (link: string) => {
6
- text: string;
7
- width: number;
8
- };
9
- //# sourceMappingURL=qr-terminal.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"qr-terminal.d.ts","sourceRoot":"","sources":["../../src/session/qr-terminal.ts"],"names":[],"mappings":"AAQA;;;GAGG;AACH,eAAO,MAAM,UAAU,SAAU,MAAM,KAAG;IAAE,IAAI,EAAE,MAAM,CAAC;IAAC,KAAK,EAAE,MAAM,CAAA;CAwBtE,CAAA"}
@@ -1,34 +0,0 @@
1
- import qrcode from "qrcode-generator";
2
- const QUIET_ZONE = 4;
3
- // Dark modules on a light ground whatever the terminal's theme: a phone camera reads an inverted
4
- // code unreliably, so the colours are forced even under NO_COLOR.
5
- const BLACK_ON_WHITE = "\x1b[30;107m";
6
- const RESET = "\x1b[0m";
7
- /**
8
- * A QR code as text, two modules per character cell with half blocks, so it fits a terminal
9
- * without being twice as tall as it is wide. `width` is in columns, for deciding whether it fits.
10
- */
11
- export const terminalQr = (link) => {
12
- const code = qrcode(0, "M");
13
- code.addData(link);
14
- code.make();
15
- const count = code.getModuleCount();
16
- const size = count + QUIET_ZONE * 2;
17
- const dark = (row, col) => {
18
- const r = row - QUIET_ZONE;
19
- const c = col - QUIET_ZONE;
20
- return r >= 0 && c >= 0 && r < count && c < count && code.isDark(r, c);
21
- };
22
- const lines = [];
23
- for (let row = 0; row < size; row += 2) {
24
- let line = "";
25
- for (let col = 0; col < size; col++) {
26
- const top = dark(row, col);
27
- const bottom = row + 1 < size && dark(row + 1, col);
28
- line += top && bottom ? "█" : top ? "▀" : bottom ? "▄" : " ";
29
- }
30
- lines.push(`${BLACK_ON_WHITE}${line}${RESET}`);
31
- }
32
- return { text: lines.join("\n"), width: size };
33
- };
34
- //# sourceMappingURL=qr-terminal.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"qr-terminal.js","sourceRoot":"","sources":["../../src/session/qr-terminal.ts"],"names":[],"mappings":"AAAA,OAAO,MAAM,MAAM,kBAAkB,CAAA;AAErC,MAAM,UAAU,GAAG,CAAC,CAAA;AACpB,iGAAiG;AACjG,kEAAkE;AAClE,MAAM,cAAc,GAAG,cAAc,CAAA;AACrC,MAAM,KAAK,GAAG,SAAS,CAAA;AAEvB;;;GAGG;AACH,MAAM,CAAC,MAAM,UAAU,GAAG,CAAC,IAAY,EAAmC,EAAE;IAC1E,MAAM,IAAI,GAAG,MAAM,CAAC,CAAC,EAAE,GAAG,CAAC,CAAA;IAC3B,IAAI,CAAC,OAAO,CAAC,IAAI,CAAC,CAAA;IAClB,IAAI,CAAC,IAAI,EAAE,CAAA;IAEX,MAAM,KAAK,GAAG,IAAI,CAAC,cAAc,EAAE,CAAA;IACnC,MAAM,IAAI,GAAG,KAAK,GAAG,UAAU,GAAG,CAAC,CAAA;IACnC,MAAM,IAAI,GAAG,CAAC,GAAW,EAAE,GAAW,EAAE,EAAE;QACxC,MAAM,CAAC,GAAG,GAAG,GAAG,UAAU,CAAA;QAC1B,MAAM,CAAC,GAAG,GAAG,GAAG,UAAU,CAAA;QAC1B,OAAO,CAAC,IAAI,CAAC,IAAI,CAAC,IAAI,CAAC,IAAI,CAAC,GAAG,KAAK,IAAI,CAAC,GAAG,KAAK,IAAI,IAAI,C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