@wirecat/cli-core 0.404.0 → 0.406.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 (124) hide show
  1. package/CHANGELOG.md +45 -1
  2. package/dist/botcheck/reasons.d.ts +1 -1
  3. package/dist/cli/analysis-choice.js +1 -1
  4. package/dist/cli/answer-entity.d.ts +5 -0
  5. package/dist/cli/answer-entity.js +25 -0
  6. package/dist/cli/command-contract.js +2 -5
  7. package/dist/cli/commands-command.js +4 -1
  8. package/dist/cli/effects.js +1 -1
  9. package/dist/cli/embedding-choice.d.ts +1 -1
  10. package/dist/cli/embedding-choice.js +2 -2
  11. package/dist/cli/first-run.js +3 -3
  12. package/dist/cli/help/command-help.js +2 -2
  13. package/dist/cli/index.d.ts +1 -0
  14. package/dist/cli/index.js +1 -0
  15. package/dist/cli/json-fields.js +2 -2
  16. package/dist/cli/meeting-project-candidates-command.js +0 -1
  17. package/dist/cli/meeting-series-inventory-command.js +0 -1
  18. package/dist/cli/messenger/admin-commands.js +14 -14
  19. package/dist/cli/messenger/archive-commands.js +2 -2
  20. package/dist/cli/messenger/attachments-command.js +7 -8
  21. package/dist/cli/messenger/backfill-command.js +1 -1
  22. package/dist/cli/messenger/chat-answers.js +3 -3
  23. package/dist/cli/messenger/chat-lists.js +3 -3
  24. package/dist/cli/messenger/chats-command.js +8 -8
  25. package/dist/cli/messenger/chats-members-command.js +1 -1
  26. package/dist/cli/messenger/contacts-command.js +10 -7
  27. package/dist/cli/messenger/context.d.ts +11 -4
  28. package/dist/cli/messenger/context.js +6 -0
  29. package/dist/cli/messenger/conversation-examples.js +7 -6
  30. package/dist/cli/messenger/conversations-command.d.ts +0 -4
  31. package/dist/cli/messenger/conversations-command.js +130 -135
  32. package/dist/cli/messenger/counters-command.js +4 -2
  33. package/dist/cli/messenger/doctor-command.js +8 -4
  34. package/dist/cli/messenger/gaps-command.js +2 -2
  35. package/dist/cli/messenger/hearing-command.d.ts +1 -1
  36. package/dist/cli/messenger/hearing-command.js +1 -1
  37. package/dist/cli/messenger/images-command.js +1 -1
  38. package/dist/cli/messenger/inbox.js +1 -3
  39. package/dist/cli/messenger/lacks.d.ts +1 -0
  40. package/dist/cli/messenger/lacks.js +1 -1
  41. package/dist/cli/messenger/mcp-command.js +4 -4
  42. package/dist/cli/messenger/messages-comments-command.js +10 -5
  43. package/dist/cli/messenger/messages-send-command.js +44 -3
  44. package/dist/cli/messenger/metadata-command.js +5 -5
  45. package/dist/cli/messenger/models-command.js +101 -90
  46. package/dist/cli/messenger/private-people-command.js +5 -6
  47. package/dist/cli/messenger/replies-edit-command.js +0 -1
  48. package/dist/cli/messenger/review.js +1 -3
  49. package/dist/cli/messenger/serve-relay.d.ts +2 -0
  50. package/dist/cli/messenger/stats-command.js +1 -1
  51. package/dist/cli/messenger/store-maintenance-command.d.ts +2 -2
  52. package/dist/cli/messenger/store-maintenance-command.js +4 -4
  53. package/dist/cli/messenger/stored.js +5 -0
  54. package/dist/cli/messenger/tags-command.js +4 -10
  55. package/dist/cli/messenger/tasks-command.js +3 -3
  56. package/dist/cli/messenger/transcribe-command.js +1 -1
  57. package/dist/cli/moved.d.ts +2 -0
  58. package/dist/cli/moved.js +39 -1
  59. package/dist/cli/permission-keys.js +2 -0
  60. package/dist/cli/settings.js +1 -1
  61. package/dist/cli/setup-answers.d.ts +2 -2
  62. package/dist/cli/setup-answers.js +2 -2
  63. package/dist/cli/steps.js +4 -4
  64. package/dist/cli/store-settings.js +1 -1
  65. package/dist/cli/upgrade-command.js +0 -1
  66. package/dist/domain/models.d.ts +3 -3
  67. package/dist/domain/task-categories.js +1 -1
  68. package/dist/embeddings/remote.js +1 -1
  69. package/dist/entities/index.d.ts +380 -0
  70. package/dist/entities/index.js +2 -1
  71. package/dist/entities/member.d.ts +2 -2
  72. package/dist/entities/member.js +2 -2
  73. package/dist/entities/message-write.d.ts +386 -0
  74. package/dist/entities/message-write.js +6 -0
  75. package/dist/mcp/agent.d.ts +1 -0
  76. package/dist/mcp/agent.js +1 -1
  77. package/dist/mcp/tools/attachments.js +1 -1
  78. package/dist/meetings/mcp/index.d.ts +15 -15
  79. package/dist/ports/app.d.ts +1 -1
  80. package/dist/ports/messenger.d.ts +8 -1
  81. package/dist/ports/traits.d.ts +2 -0
  82. package/dist/search/task-similarity.js +1 -1
  83. package/dist/sends/guard.js +2 -2
  84. package/dist/sends/permission-aliases.d.ts +5 -0
  85. package/dist/sends/permission-aliases.js +49 -0
  86. package/dist/sends/permissions.d.ts +1 -1
  87. package/dist/sends/permissions.js +35 -25
  88. package/dist/services/admin.js +7 -7
  89. package/dist/services/chats.js +1 -1
  90. package/dist/services/conversations.d.ts +1 -1
  91. package/dist/services/conversations.js +1 -1
  92. package/dist/services/counters.js +1 -1
  93. package/dist/services/embeddings-maintenance.js +2 -2
  94. package/dist/services/embeddings-search.js +1 -1
  95. package/dist/services/embeddings.d.ts +4 -4
  96. package/dist/services/messages-search.d.ts +1 -1
  97. package/dist/services/messages-search.js +2 -2
  98. package/dist/services/messages.d.ts +5 -0
  99. package/dist/services/messages.js +23 -0
  100. package/dist/services/metadata.js +2 -2
  101. package/dist/services/notes-search.js +3 -3
  102. package/dist/services/search-catchup.js +1 -1
  103. package/dist/speech/install.d.ts +4 -2
  104. package/dist/speech/install.js +16 -4
  105. package/dist/speech/local.js +1 -1
  106. package/dist/speech/transcribe.js +1 -1
  107. package/dist/store/search-index.d.ts +1 -1
  108. package/dist/store/sqlite/attachment-texts.d.ts +1 -1
  109. package/dist/store/sqlite/attachment-texts.js +1 -1
  110. package/dist/store/sqlite/batches.js +1 -1
  111. package/dist/store/sqlite/involvements.d.ts +1 -1
  112. package/dist/store/sqlite/note-index.d.ts +2 -2
  113. package/dist/store/sqlite/note-index.js +2 -2
  114. package/dist/store/sqlite/search-index.d.ts +1 -1
  115. package/dist/store/sqlite/search-index.js +1 -1
  116. package/dist/store/sqlite/stems-fill.d.ts +3 -3
  117. package/dist/store/sqlite/stems-fill.js +3 -3
  118. package/dist/store/sqlite/stems.d.ts +1 -1
  119. package/dist/store/sqlite/task-pairs.d.ts +1 -1
  120. package/dist/store/sqlite/task-pairs.js +1 -1
  121. package/package.json +1 -1
  122. package/parity.json +186 -179
  123. package/skills/follow-ups/SKILL.md +5 -5
  124. package/skills/link-conversations/SKILL.md +8 -8
package/dist/cli/moved.js CHANGED
@@ -6,12 +6,50 @@
6
6
  export const MOVED_TO_MEMO = {
7
7
  "search mail": { what: "mail is searched by the separate memo CLI", memo: "memo search mail …" },
8
8
  };
9
+ /** Retired spellings are guidance only; none is mounted as a command alias. */
10
+ export const RENAMED_COMMANDS = {
11
+ "contacts alias rm": "contacts aliases remove",
12
+ "contacts alias": "contacts aliases",
13
+ "contacts profile": "contacts info",
14
+ "contacts timeline": "contacts events",
15
+ "chats link revoke": "chats links remove",
16
+ "chats link": "chats links",
17
+ "chats members audit": "chats members check",
18
+ "chats requests accept": "chats requests confirm",
19
+ "chats requests decline": "chats requests reject",
20
+ "metadata get": "metadata show",
21
+ "metadata refresh": "metadata sync",
22
+ "tasks plan": "tasks update",
23
+ "tags auto": "tags rebuild",
24
+ "attachments text set": "attachments update",
25
+ "conversations build": "conversations links rebuild",
26
+ "conversations embed status": "conversations embeddings status",
27
+ "conversations embed clear": "conversations embeddings clear",
28
+ "conversations batches next": "conversations batches show",
29
+ "conversations consents revoke": "conversations consents remove",
30
+ "doctor report create": "doctor reports create",
31
+ "doctor report": "doctor reports show",
32
+ "mcp setup": "mcp add",
33
+ "mcp doctor": "mcp check",
34
+ "commands schema": "commands info",
35
+ "store gaps plan": "store gaps show",
36
+ "store reindex": "store rebuild",
37
+ "stats messages counters refresh": "stats messages counters sync",
38
+ "models text key": "models keys",
39
+ "models audio list": "models list kind:audio",
40
+ "models text list": "models list kind:text",
41
+ "models audio download": "models download",
42
+ "models text download": "models download",
43
+ };
9
44
  export const movedPointer = (path) => {
45
+ const renamed = RENAMED_COMMANDS[path];
46
+ if (renamed)
47
+ return `use \`${renamed}\``;
10
48
  const moved = MOVED_TO_MEMO[path];
11
49
  return moved && `${moved.what}: install @wirecat/cli-memo, then \`${moved.memo}\``;
12
50
  };
13
51
  /** The longest moved path the words start with, unless the program still has it. */
14
- export const movedPath = (words, has) => Object.keys(MOVED_TO_MEMO)
52
+ export const movedPath = (words, has) => [...Object.keys(MOVED_TO_MEMO), ...Object.keys(RENAMED_COMMANDS)]
15
53
  .filter((path) => path.split(" ").every((word, at) => words[at] === word))
16
54
  .sort((a, b) => b.length - a.length)
17
55
  .find((path) => !has(path));
@@ -1,3 +1,4 @@
1
+ import { canonicalPermissionKey } from "../sends/permission-aliases.js";
1
2
  import { CEILING_KEY, keyForCommand, WRITE_KEYS } from "../sends/permissions.js";
2
3
  const pathOf = (command) => {
3
4
  const words = [];
@@ -19,6 +20,7 @@ const everyCommand = (command) => [command, ...command.commands.flatMap(everyCom
19
20
  export const knownPermissionKeys = (command, keyOf = (one) => keyForCommand(pathOf(one)), extra = []) => {
20
21
  const known = new Set();
21
22
  const add = (key) => {
23
+ key = canonicalPermissionKey(key);
22
24
  for (let parts = key.split("."); parts.length > 0; parts = parts.slice(0, -1))
23
25
  known.add(parts.join("."));
24
26
  };
@@ -60,7 +60,7 @@ const SHARED_PROFILE_ENTRIES = {
60
60
  sends_per_hour: v.optional(count),
61
61
  requests_per_minute: v.optional(countOrZero),
62
62
  transcribe_with: v.optional(v.picklist(["auto", "messenger", "local"], plain("has to be auto, messenger or local"))),
63
- speech_model: v.optional(v.string(plain("has to be a model id from `models audio list`, in quotes"))),
63
+ speech_model: v.optional(v.string(plain("has to be a model id from `models list`, in quotes"))),
64
64
  search_catch_up: v.optional(flag),
65
65
  picture_search: v.optional(flag),
66
66
  ...AI_ENTRIES,
@@ -1,6 +1,6 @@
1
1
  import type { Level } from "../sends/permissions.js";
2
- /** "allow" leaves every profile as its own configuration says. */
3
- export declare const PERMISSION_ANSWERS: readonly ["readonly", "ask", "allow"];
2
+ /** One switch for every tool, the same on the command line and over MCP; "allow" leaves each profile as configured. */
3
+ export declare const PERMISSION_ANSWERS: readonly ["readonly", "allow"];
4
4
  export type PermissionAnswer = (typeof PERMISSION_ANSWERS)[number];
5
5
  /**
6
6
  * The first-run answers every WireCat CLI shares. Languages live in the store (`search_stemmers`), so only the
@@ -1,8 +1,8 @@
1
1
  import { CliError } from "@wirecat/cli-base";
2
2
  import { storePath } from "../store/path.js";
3
3
  import { readSharedSection, sharedConfigPath, writeSharedSection } from "../store/shared-config.js";
4
- /** "allow" leaves every profile as its own configuration says. */
5
- export const PERMISSION_ANSWERS = ["readonly", "ask", "allow"];
4
+ /** One switch for every tool, the same on the command line and over MCP; "allow" leaves each profile as configured. */
5
+ export const PERMISSION_ANSWERS = ["readonly", "allow"];
6
6
  export const QUESTIONS = ["languages", "tools", "permissions"];
7
7
  const SECTION = "setup";
8
8
  export const readSetupAnswers = (path) => {
package/dist/cli/steps.js CHANGED
@@ -83,7 +83,7 @@ export const STEPS = defineSteps([
83
83
  },
84
84
  {
85
85
  id: "models.download",
86
- command: "models text download",
86
+ command: "models download",
87
87
  args: [{ name: "model", required: true }],
88
88
  why: "{model} is not downloaded, so nothing is searched by meaning",
89
89
  },
@@ -116,7 +116,7 @@ export const STEPS = defineSteps([
116
116
  },
117
117
  {
118
118
  id: "store.reindex",
119
- command: "store reindex",
119
+ command: "store rebuild",
120
120
  args: [],
121
121
  why: "the stems were built by another stemmer; this builds them again",
122
122
  },
@@ -134,7 +134,7 @@ export const STEPS = defineSteps([
134
134
  },
135
135
  {
136
136
  id: "conversations.build",
137
- command: "conversations build",
137
+ command: "conversations links rebuild",
138
138
  args: [{ name: "chat", required: false }],
139
139
  why: "conversations are missing or older than the messages; this builds them",
140
140
  },
@@ -175,7 +175,7 @@ export const STEPS = defineSteps([
175
175
  },
176
176
  {
177
177
  id: "doctor.report-create",
178
- command: "doctor report create",
178
+ command: "doctor reports create",
179
179
  args: [{ name: "run", required: false }],
180
180
  why: "writes the report to a file to read and send; it holds no message text",
181
181
  },
@@ -132,7 +132,7 @@ const changeCategory = async (app, env, setting, value) => {
132
132
  return {
133
133
  result: { store: storePath(env), file, scope: "shared", setting, value: set ? taskCategoryValue(set) : null },
134
134
  note: [
135
- `saved in ${file} — rules, tasks add and tasks plan in tg, MAX and memo take categories from it; ` +
135
+ `saved in ${file} — rules, tasks add and tasks update in tg, MAX and memo take categories from it; ` +
136
136
  "tasks keep the category they have",
137
137
  ...unlisted,
138
138
  ].join("\n"),
@@ -32,7 +32,6 @@ export const restartServers = (app, script, env, spawn) => {
32
32
  };
33
33
  export const upgradeCommand = (app, packageName, contextFor) => grantsAuthority(annotate(new Command("upgrade"), {
34
34
  effects: LOCAL_WRITE,
35
- mcp: false,
36
35
  offline: false,
37
36
  examples: [`${app.command} upgrade --check`, `${app.command} upgrade`],
38
37
  }), { unless: "check" })
@@ -155,7 +155,7 @@ export interface InviteLink {
155
155
  /** People who joined by it. */
156
156
  joined?: number;
157
157
  }
158
- /** What `chats link update` changes; a field left out stays as it is. */
158
+ /** What `chats links update` changes; a field left out stays as it is. */
159
159
  export interface InviteLinkChange {
160
160
  approval?: boolean;
161
161
  /** ISO 8601; `null` makes it never expire. */
@@ -741,7 +741,7 @@ export interface Registered {
741
741
  /** How fine `at` is: Telegram tells a month, an estimate a month at best. */
742
742
  precision: "day" | "month";
743
743
  }
744
- /** Everything the messenger itself says about one person, as `contacts profile` reads it. */
744
+ /** Everything the messenger itself says about one person, as `contacts info` reads it. */
745
745
  export interface ProfileFacts {
746
746
  id: Id;
747
747
  name: string | null;
@@ -794,7 +794,7 @@ export interface PersonAlias {
794
794
  lastSeenAt: string;
795
795
  source: "profile" | "messages";
796
796
  }
797
- /** `contacts profile`: the person, and their activity in every chat shared with them. */
797
+ /** `contacts info`: the person, and their activity in every chat shared with them. */
798
798
  export interface PersonProfile extends Omit<ProfileFacts, "chats"> {
799
799
  chats: SharedChatActivity[];
800
800
  /** Earlier names and usernames, oldest first; the current ones are not repeated. */
@@ -694,7 +694,7 @@ export const DEFAULT_TASK_CATEGORIES = [
694
694
  export const FALLBACK_CATEGORY = "other";
695
695
  /** One line per unlisted category that says how to find and move its tasks; none when every category is listed. */
696
696
  export const unlistedNote = (unlisted, tool) => unlisted.map(({ name, open, total }) => `${total} task${total === 1 ? "" : "s"} (${open} open) still use ${name}, which is not in the list: ` +
697
- `${tool} tasks list category:${name} shows them, ${tool} tasks plan <id> --category <name> moves one`);
697
+ `${tool} tasks list category:${name} shows them, ${tool} tasks update <id> --category <name> moves one`);
698
698
  const LANGUAGES = ["en", "ru", "es"];
699
699
  const NAME = /^[a-z][a-z0-9-]{0,29}$/;
700
700
  const MAX_CATEGORIES = 80;
@@ -69,7 +69,7 @@ export const openRemote = (remote, apiKey, { concurrency = 4, fetch: post = fetc
69
69
  }
70
70
  const code = await errorCode(response);
71
71
  if (response.status === 401 || response.status === 403) {
72
- throw new CliError("authentication_error", `${remote.provider} refused the key (HTTP ${response.status}${code}) — set it again with \`models text key set\``);
72
+ throw new CliError("authentication_error", `${remote.provider} refused the key (HTTP ${response.status}${code}) — set it again with \`models keys set\``);
73
73
  }
74
74
  const again = response.status === 429 || response.status >= 500;
75
75
  if (!again || attempt >= tries) {
@@ -2555,6 +2555,386 @@ export declare const ENTITIES: {
2555
2555
  }, undefined>, undefined>, undefined>;
2556
2556
  readonly scheduled_for: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.IsoTimestampAction<string, "an ISO 8601 time in UTC">, v.EndsWithAction<string, "Z", "an ISO 8601 time in UTC, ending in `Z`">]>, undefined>;
2557
2557
  }, undefined>;
2558
+ readonly message_send: v.UnionSchema<[v.StrictObjectSchema<{
2559
+ readonly operation_id: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.MinLengthAction<string, 1, undefined>]>;
2560
+ readonly message: v.StrictObjectSchema<{
2561
+ readonly ref: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, "a reference such as `note:42`">]>;
2562
+ readonly id: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.MinLengthAction<string, 1, undefined>]>;
2563
+ readonly provider: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
2564
+ readonly account: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
2565
+ readonly chat_id: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.MinLengthAction<string, 1, undefined>]>;
2566
+ readonly chat_title: v.OptionalSchema<v.NullableSchema<v.StringSchema<undefined>, undefined>, undefined>;
2567
+ readonly sender_id: v.NullableSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.MinLengthAction<string, 1, undefined>]>, undefined>;
2568
+ readonly sender_name: v.NullableSchema<v.StringSchema<undefined>, undefined>;
2569
+ readonly sender_username: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
2570
+ readonly sender_is_chat: v.OptionalSchema<v.BooleanSchema<undefined>, undefined>;
2571
+ readonly mentions: v.OptionalSchema<v.ArraySchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.MinLengthAction<string, 1, undefined>]>, undefined>, undefined>;
2572
+ readonly timestamp: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.IsoTimestampAction<string, "an ISO 8601 time in UTC">, v.EndsWithAction<string, "Z", "an ISO 8601 time in UTC, ending in `Z`">]>;
2573
+ readonly edited_at: v.NullableSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.IsoTimestampAction<string, "an ISO 8601 time in UTC">, v.EndsWithAction<string, "Z", "an ISO 8601 time in UTC, ending in `Z`">]>, undefined>;
2574
+ readonly text: v.StringSchema<undefined>;
2575
+ readonly transcript: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
2576
+ readonly anchor: v.OptionalSchema<v.BooleanSchema<undefined>, undefined>;
2577
+ readonly excerpt: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
2578
+ readonly matched_in: v.OptionalSchema<v.PicklistSchema<["text", "transcript", "filename", "file", "context", "picture"], undefined>, undefined>;
2579
+ readonly score: v.OptionalSchema<v.NumberSchema<undefined>, undefined>;
2580
+ readonly match: v.OptionalSchema<v.PicklistSchema<["words", "beginnings", "corrected"], undefined>, undefined>;
2581
+ readonly corrections: v.OptionalSchema<v.ArraySchema<v.StrictObjectSchema<{
2582
+ readonly from: v.StringSchema<undefined>;
2583
+ readonly to: v.ArraySchema<v.StringSchema<undefined>, undefined>;
2584
+ }, undefined>, undefined>, undefined>;
2585
+ readonly found_in: v.OptionalSchema<v.PicklistSchema<["archive", "server", "both"], undefined>, undefined>;
2586
+ readonly discovery: v.OptionalSchema<v.StrictObjectSchema<{
2587
+ readonly coverage: v.NumberSchema<undefined>;
2588
+ readonly matched_terms: v.ArraySchema<v.StringSchema<undefined>, undefined>;
2589
+ readonly missing_terms: v.ArraySchema<v.StringSchema<undefined>, undefined>;
2590
+ readonly parent: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, "a reference such as `note:42`">]>, undefined>;
2591
+ }, undefined>, undefined>;
2592
+ readonly context: v.OptionalSchema<v.ArraySchema<v.StrictObjectSchema<{
2593
+ readonly ref: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, "a reference such as `note:42`">]>;
2594
+ readonly timestamp: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.IsoTimestampAction<string, "an ISO 8601 time in UTC">, v.EndsWithAction<string, "Z", "an ISO 8601 time in UTC, ending in `Z`">]>;
2595
+ readonly sender_name: v.NullableSchema<v.StringSchema<undefined>, undefined>;
2596
+ readonly text: v.StringSchema<undefined>;
2597
+ }, undefined>, undefined>, undefined>;
2598
+ readonly outgoing: v.NullableSchema<v.BooleanSchema<undefined>, undefined>;
2599
+ readonly attachments: v.ArraySchema<v.StrictObjectSchema<{
2600
+ readonly message: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, "a reference such as `note:42`">]>, undefined>;
2601
+ readonly kind: v.StringSchema<undefined>;
2602
+ readonly position: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.IntegerAction<number, undefined>, v.MinValueAction<number, 0, undefined>]>, undefined>;
2603
+ readonly url: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
2604
+ readonly name: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
2605
+ readonly title: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
2606
+ readonly mime: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
2607
+ readonly size: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.IntegerAction<number, undefined>, v.MinValueAction<number, 0, undefined>]>, undefined>;
2608
+ readonly width: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.IntegerAction<number, undefined>, v.MinValueAction<number, 0, undefined>]>, undefined>;
2609
+ readonly height: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.IntegerAction<number, undefined>, v.MinValueAction<number, 0, undefined>]>, undefined>;
2610
+ readonly duration: v.OptionalSchema<v.NumberSchema<undefined>, undefined>;
2611
+ readonly text: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
2612
+ readonly extraction: v.OptionalSchema<v.StrictObjectSchema<{
2613
+ readonly origin: v.StringSchema<undefined>;
2614
+ readonly extractor: v.StringSchema<undefined>;
2615
+ readonly chars: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.IntegerAction<number, undefined>, v.MinValueAction<number, 0, undefined>]>;
2616
+ readonly error: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
2617
+ }, undefined>, undefined>;
2618
+ readonly local_path: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
2619
+ readonly buttons: v.OptionalSchema<v.ArraySchema<v.ArraySchema<v.StrictObjectSchema<{
2620
+ readonly kind: v.PicklistSchema<["callback", "link", "message", "chat", "contact", "location", "app", "clipboard", "other"], undefined>;
2621
+ readonly text: v.StringSchema<undefined>;
2622
+ readonly url: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
2623
+ }, undefined>, undefined>, undefined>, undefined>;
2624
+ }, undefined>, undefined>;
2625
+ readonly reply_to: v.NullableSchema<v.StrictObjectSchema<{
2626
+ readonly id: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.MinLengthAction<string, 1, undefined>]>;
2627
+ readonly sender_id: v.NullableSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.MinLengthAction<string, 1, undefined>]>, undefined>;
2628
+ readonly sender_name: v.NullableSchema<v.StringSchema<undefined>, undefined>;
2629
+ readonly timestamp: v.NullableSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.IsoTimestampAction<string, "an ISO 8601 time in UTC">, v.EndsWithAction<string, "Z", "an ISO 8601 time in UTC, ending in `Z`">]>, undefined>;
2630
+ readonly text: v.StringSchema<undefined>;
2631
+ readonly attachments: v.ArraySchema<v.StrictObjectSchema<{
2632
+ readonly message: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, "a reference such as `note:42`">]>, undefined>;
2633
+ readonly kind: v.StringSchema<undefined>;
2634
+ readonly position: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.IntegerAction<number, undefined>, v.MinValueAction<number, 0, undefined>]>, undefined>;
2635
+ readonly url: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
2636
+ readonly name: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
2637
+ readonly title: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
2638
+ readonly mime: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
2639
+ readonly size: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.IntegerAction<number, undefined>, v.MinValueAction<number, 0, undefined>]>, undefined>;
2640
+ readonly width: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.IntegerAction<number, undefined>, v.MinValueAction<number, 0, undefined>]>, undefined>;
2641
+ readonly height: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.IntegerAction<number, undefined>, v.MinValueAction<number, 0, undefined>]>, undefined>;
2642
+ readonly duration: v.OptionalSchema<v.NumberSchema<undefined>, undefined>;
2643
+ readonly text: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
2644
+ readonly extraction: v.OptionalSchema<v.StrictObjectSchema<{
2645
+ readonly origin: v.StringSchema<undefined>;
2646
+ readonly extractor: v.StringSchema<undefined>;
2647
+ readonly chars: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.IntegerAction<number, undefined>, v.MinValueAction<number, 0, undefined>]>;
2648
+ readonly error: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
2649
+ }, undefined>, undefined>;
2650
+ readonly local_path: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
2651
+ readonly buttons: v.OptionalSchema<v.ArraySchema<v.ArraySchema<v.StrictObjectSchema<{
2652
+ readonly kind: v.PicklistSchema<["callback", "link", "message", "chat", "contact", "location", "app", "clipboard", "other"], undefined>;
2653
+ readonly text: v.StringSchema<undefined>;
2654
+ readonly url: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
2655
+ }, undefined>, undefined>, undefined>, undefined>;
2656
+ }, undefined>, undefined>;
2657
+ readonly outgoing: v.NullableSchema<v.BooleanSchema<undefined>, undefined>;
2658
+ }, undefined>, undefined>;
2659
+ readonly reply_to_id: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.MinLengthAction<string, 1, undefined>]>, undefined>;
2660
+ readonly forwarded_from: v.NullableSchema<v.StrictObjectSchema<{
2661
+ readonly id: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.MinLengthAction<string, 1, undefined>]>;
2662
+ readonly sender_id: v.NullableSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.MinLengthAction<string, 1, undefined>]>, undefined>;
2663
+ readonly sender_name: v.NullableSchema<v.StringSchema<undefined>, undefined>;
2664
+ readonly timestamp: v.NullableSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.IsoTimestampAction<string, "an ISO 8601 time in UTC">, v.EndsWithAction<string, "Z", "an ISO 8601 time in UTC, ending in `Z`">]>, undefined>;
2665
+ readonly text: v.StringSchema<undefined>;
2666
+ readonly attachments: v.ArraySchema<v.StrictObjectSchema<{
2667
+ readonly message: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, "a reference such as `note:42`">]>, undefined>;
2668
+ readonly kind: v.StringSchema<undefined>;
2669
+ readonly position: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.IntegerAction<number, undefined>, v.MinValueAction<number, 0, undefined>]>, undefined>;
2670
+ readonly url: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
2671
+ readonly name: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
2672
+ readonly title: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
2673
+ readonly mime: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
2674
+ readonly size: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.IntegerAction<number, undefined>, v.MinValueAction<number, 0, undefined>]>, undefined>;
2675
+ readonly width: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.IntegerAction<number, undefined>, v.MinValueAction<number, 0, undefined>]>, undefined>;
2676
+ readonly height: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.IntegerAction<number, undefined>, v.MinValueAction<number, 0, undefined>]>, undefined>;
2677
+ readonly duration: v.OptionalSchema<v.NumberSchema<undefined>, undefined>;
2678
+ readonly text: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
2679
+ readonly extraction: v.OptionalSchema<v.StrictObjectSchema<{
2680
+ readonly origin: v.StringSchema<undefined>;
2681
+ readonly extractor: v.StringSchema<undefined>;
2682
+ readonly chars: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.IntegerAction<number, undefined>, v.MinValueAction<number, 0, undefined>]>;
2683
+ readonly error: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
2684
+ }, undefined>, undefined>;
2685
+ readonly local_path: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
2686
+ readonly buttons: v.OptionalSchema<v.ArraySchema<v.ArraySchema<v.StrictObjectSchema<{
2687
+ readonly kind: v.PicklistSchema<["callback", "link", "message", "chat", "contact", "location", "app", "clipboard", "other"], undefined>;
2688
+ readonly text: v.StringSchema<undefined>;
2689
+ readonly url: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
2690
+ }, undefined>, undefined>, undefined>, undefined>;
2691
+ }, undefined>, undefined>;
2692
+ readonly outgoing: v.NullableSchema<v.BooleanSchema<undefined>, undefined>;
2693
+ }, undefined>, undefined>;
2694
+ readonly thread_id: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.MinLengthAction<string, 1, undefined>]>, undefined>;
2695
+ readonly thread_root_id: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.MinLengthAction<string, 1, undefined>]>, undefined>;
2696
+ readonly reactions: v.OptionalSchema<v.NullableSchema<v.StrictObjectSchema<{
2697
+ readonly counts: v.ArraySchema<v.StrictObjectSchema<{
2698
+ readonly reaction: v.StringSchema<undefined>;
2699
+ readonly count: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.IntegerAction<number, undefined>, v.MinValueAction<number, 0, undefined>]>;
2700
+ }, undefined>, undefined>;
2701
+ readonly mine: v.NullableSchema<v.StringSchema<undefined>, undefined>;
2702
+ readonly total: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.IntegerAction<number, undefined>, v.MinValueAction<number, 0, undefined>]>;
2703
+ }, undefined>, undefined>, undefined>;
2704
+ readonly scheduled_for: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.IsoTimestampAction<string, "an ISO 8601 time in UTC">, v.EndsWithAction<string, "Z", "an ISO 8601 time in UTC, ending in `Z`">]>, undefined>;
2705
+ readonly starred: v.OptionalSchema<v.LiteralSchema<true, undefined>, undefined>;
2706
+ readonly delivery: v.OptionalSchema<v.PicklistSchema<["delivered", "read"], undefined>, undefined>;
2707
+ readonly email: v.OptionalSchema<v.StrictObjectSchema<{
2708
+ readonly subject: v.NullableSchema<v.StringSchema<undefined>, undefined>;
2709
+ readonly from: v.NullableSchema<v.StrictObjectSchema<{
2710
+ readonly name: v.NullableSchema<v.StringSchema<undefined>, undefined>;
2711
+ readonly address: v.StringSchema<undefined>;
2712
+ readonly ref: v.NullableSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, "a reference such as `note:42`">]>, undefined>;
2713
+ }, undefined>, undefined>;
2714
+ readonly to: v.ArraySchema<v.StrictObjectSchema<{
2715
+ readonly name: v.NullableSchema<v.StringSchema<undefined>, undefined>;
2716
+ readonly address: v.StringSchema<undefined>;
2717
+ readonly ref: v.NullableSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, "a reference such as `note:42`">]>, undefined>;
2718
+ }, undefined>, undefined>;
2719
+ readonly cc: v.ArraySchema<v.StrictObjectSchema<{
2720
+ readonly name: v.NullableSchema<v.StringSchema<undefined>, undefined>;
2721
+ readonly address: v.StringSchema<undefined>;
2722
+ readonly ref: v.NullableSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, "a reference such as `note:42`">]>, undefined>;
2723
+ }, undefined>, undefined>;
2724
+ readonly bcc: v.ArraySchema<v.StrictObjectSchema<{
2725
+ readonly name: v.NullableSchema<v.StringSchema<undefined>, undefined>;
2726
+ readonly address: v.StringSchema<undefined>;
2727
+ readonly ref: v.NullableSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, "a reference such as `note:42`">]>, undefined>;
2728
+ }, undefined>, undefined>;
2729
+ readonly reply_addresses: v.ArraySchema<v.StrictObjectSchema<{
2730
+ readonly name: v.NullableSchema<v.StringSchema<undefined>, undefined>;
2731
+ readonly address: v.StringSchema<undefined>;
2732
+ readonly ref: v.NullableSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, "a reference such as `note:42`">]>, undefined>;
2733
+ }, undefined>, undefined>;
2734
+ readonly labels: v.ArraySchema<v.StringSchema<undefined>, undefined>;
2735
+ readonly thread: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, "a reference such as `note:42`">]>;
2736
+ readonly read: v.NullableSchema<v.BooleanSchema<undefined>, undefined>;
2737
+ readonly flagged: v.NullableSchema<v.BooleanSchema<undefined>, undefined>;
2738
+ readonly sender_score: v.OptionalSchema<v.StrictObjectSchema<{
2739
+ readonly score: v.NumberSchema<undefined>;
2740
+ readonly signals: v.ArraySchema<v.StringSchema<undefined>, undefined>;
2741
+ readonly demoted: v.OptionalSchema<v.LiteralSchema<true, undefined>, undefined>;
2742
+ }, undefined>, undefined>;
2743
+ }, undefined>, undefined>;
2744
+ readonly provider_metadata: v.OptionalSchema<v.RecordSchema<v.StringSchema<undefined>, v.UnknownSchema, undefined>, undefined>;
2745
+ }, undefined>;
2746
+ readonly messages: v.OptionalSchema<v.ArraySchema<v.StrictObjectSchema<{
2747
+ readonly ref: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, "a reference such as `note:42`">]>;
2748
+ readonly id: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.MinLengthAction<string, 1, undefined>]>;
2749
+ readonly provider: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
2750
+ readonly account: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
2751
+ readonly chat_id: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.MinLengthAction<string, 1, undefined>]>;
2752
+ readonly chat_title: v.OptionalSchema<v.NullableSchema<v.StringSchema<undefined>, undefined>, undefined>;
2753
+ readonly sender_id: v.NullableSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.MinLengthAction<string, 1, undefined>]>, undefined>;
2754
+ readonly sender_name: v.NullableSchema<v.StringSchema<undefined>, undefined>;
2755
+ readonly sender_username: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
2756
+ readonly sender_is_chat: v.OptionalSchema<v.BooleanSchema<undefined>, undefined>;
2757
+ readonly mentions: v.OptionalSchema<v.ArraySchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.MinLengthAction<string, 1, undefined>]>, undefined>, undefined>;
2758
+ readonly timestamp: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.IsoTimestampAction<string, "an ISO 8601 time in UTC">, v.EndsWithAction<string, "Z", "an ISO 8601 time in UTC, ending in `Z`">]>;
2759
+ readonly edited_at: v.NullableSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.IsoTimestampAction<string, "an ISO 8601 time in UTC">, v.EndsWithAction<string, "Z", "an ISO 8601 time in UTC, ending in `Z`">]>, undefined>;
2760
+ readonly text: v.StringSchema<undefined>;
2761
+ readonly transcript: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
2762
+ readonly anchor: v.OptionalSchema<v.BooleanSchema<undefined>, undefined>;
2763
+ readonly excerpt: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
2764
+ readonly matched_in: v.OptionalSchema<v.PicklistSchema<["text", "transcript", "filename", "file", "context", "picture"], undefined>, undefined>;
2765
+ readonly score: v.OptionalSchema<v.NumberSchema<undefined>, undefined>;
2766
+ readonly match: v.OptionalSchema<v.PicklistSchema<["words", "beginnings", "corrected"], undefined>, undefined>;
2767
+ readonly corrections: v.OptionalSchema<v.ArraySchema<v.StrictObjectSchema<{
2768
+ readonly from: v.StringSchema<undefined>;
2769
+ readonly to: v.ArraySchema<v.StringSchema<undefined>, undefined>;
2770
+ }, undefined>, undefined>, undefined>;
2771
+ readonly found_in: v.OptionalSchema<v.PicklistSchema<["archive", "server", "both"], undefined>, undefined>;
2772
+ readonly discovery: v.OptionalSchema<v.StrictObjectSchema<{
2773
+ readonly coverage: v.NumberSchema<undefined>;
2774
+ readonly matched_terms: v.ArraySchema<v.StringSchema<undefined>, undefined>;
2775
+ readonly missing_terms: v.ArraySchema<v.StringSchema<undefined>, undefined>;
2776
+ readonly parent: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, "a reference such as `note:42`">]>, undefined>;
2777
+ }, undefined>, undefined>;
2778
+ readonly context: v.OptionalSchema<v.ArraySchema<v.StrictObjectSchema<{
2779
+ readonly ref: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, "a reference such as `note:42`">]>;
2780
+ readonly timestamp: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.IsoTimestampAction<string, "an ISO 8601 time in UTC">, v.EndsWithAction<string, "Z", "an ISO 8601 time in UTC, ending in `Z`">]>;
2781
+ readonly sender_name: v.NullableSchema<v.StringSchema<undefined>, undefined>;
2782
+ readonly text: v.StringSchema<undefined>;
2783
+ }, undefined>, undefined>, undefined>;
2784
+ readonly outgoing: v.NullableSchema<v.BooleanSchema<undefined>, undefined>;
2785
+ readonly attachments: v.ArraySchema<v.StrictObjectSchema<{
2786
+ readonly message: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, "a reference such as `note:42`">]>, undefined>;
2787
+ readonly kind: v.StringSchema<undefined>;
2788
+ readonly position: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.IntegerAction<number, undefined>, v.MinValueAction<number, 0, undefined>]>, undefined>;
2789
+ readonly url: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
2790
+ readonly name: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
2791
+ readonly title: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
2792
+ readonly mime: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
2793
+ readonly size: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.IntegerAction<number, undefined>, v.MinValueAction<number, 0, undefined>]>, undefined>;
2794
+ readonly width: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.IntegerAction<number, undefined>, v.MinValueAction<number, 0, undefined>]>, undefined>;
2795
+ readonly height: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.IntegerAction<number, undefined>, v.MinValueAction<number, 0, undefined>]>, undefined>;
2796
+ readonly duration: v.OptionalSchema<v.NumberSchema<undefined>, undefined>;
2797
+ readonly text: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
2798
+ readonly extraction: v.OptionalSchema<v.StrictObjectSchema<{
2799
+ readonly origin: v.StringSchema<undefined>;
2800
+ readonly extractor: v.StringSchema<undefined>;
2801
+ readonly chars: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.IntegerAction<number, undefined>, v.MinValueAction<number, 0, undefined>]>;
2802
+ readonly error: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
2803
+ }, undefined>, undefined>;
2804
+ readonly local_path: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
2805
+ readonly buttons: v.OptionalSchema<v.ArraySchema<v.ArraySchema<v.StrictObjectSchema<{
2806
+ readonly kind: v.PicklistSchema<["callback", "link", "message", "chat", "contact", "location", "app", "clipboard", "other"], undefined>;
2807
+ readonly text: v.StringSchema<undefined>;
2808
+ readonly url: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
2809
+ }, undefined>, undefined>, undefined>, undefined>;
2810
+ }, undefined>, undefined>;
2811
+ readonly reply_to: v.NullableSchema<v.StrictObjectSchema<{
2812
+ readonly id: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.MinLengthAction<string, 1, undefined>]>;
2813
+ readonly sender_id: v.NullableSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.MinLengthAction<string, 1, undefined>]>, undefined>;
2814
+ readonly sender_name: v.NullableSchema<v.StringSchema<undefined>, undefined>;
2815
+ readonly timestamp: v.NullableSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.IsoTimestampAction<string, "an ISO 8601 time in UTC">, v.EndsWithAction<string, "Z", "an ISO 8601 time in UTC, ending in `Z`">]>, undefined>;
2816
+ readonly text: v.StringSchema<undefined>;
2817
+ readonly attachments: v.ArraySchema<v.StrictObjectSchema<{
2818
+ readonly message: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, "a reference such as `note:42`">]>, undefined>;
2819
+ readonly kind: v.StringSchema<undefined>;
2820
+ readonly position: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.IntegerAction<number, undefined>, v.MinValueAction<number, 0, undefined>]>, undefined>;
2821
+ readonly url: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
2822
+ readonly name: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
2823
+ readonly title: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
2824
+ readonly mime: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
2825
+ readonly size: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.IntegerAction<number, undefined>, v.MinValueAction<number, 0, undefined>]>, undefined>;
2826
+ readonly width: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.IntegerAction<number, undefined>, v.MinValueAction<number, 0, undefined>]>, undefined>;
2827
+ readonly height: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.IntegerAction<number, undefined>, v.MinValueAction<number, 0, undefined>]>, undefined>;
2828
+ readonly duration: v.OptionalSchema<v.NumberSchema<undefined>, undefined>;
2829
+ readonly text: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
2830
+ readonly extraction: v.OptionalSchema<v.StrictObjectSchema<{
2831
+ readonly origin: v.StringSchema<undefined>;
2832
+ readonly extractor: v.StringSchema<undefined>;
2833
+ readonly chars: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.IntegerAction<number, undefined>, v.MinValueAction<number, 0, undefined>]>;
2834
+ readonly error: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
2835
+ }, undefined>, undefined>;
2836
+ readonly local_path: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
2837
+ readonly buttons: v.OptionalSchema<v.ArraySchema<v.ArraySchema<v.StrictObjectSchema<{
2838
+ readonly kind: v.PicklistSchema<["callback", "link", "message", "chat", "contact", "location", "app", "clipboard", "other"], undefined>;
2839
+ readonly text: v.StringSchema<undefined>;
2840
+ readonly url: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
2841
+ }, undefined>, undefined>, undefined>, undefined>;
2842
+ }, undefined>, undefined>;
2843
+ readonly outgoing: v.NullableSchema<v.BooleanSchema<undefined>, undefined>;
2844
+ }, undefined>, undefined>;
2845
+ readonly reply_to_id: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.MinLengthAction<string, 1, undefined>]>, undefined>;
2846
+ readonly forwarded_from: v.NullableSchema<v.StrictObjectSchema<{
2847
+ readonly id: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.MinLengthAction<string, 1, undefined>]>;
2848
+ readonly sender_id: v.NullableSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.MinLengthAction<string, 1, undefined>]>, undefined>;
2849
+ readonly sender_name: v.NullableSchema<v.StringSchema<undefined>, undefined>;
2850
+ readonly timestamp: v.NullableSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.IsoTimestampAction<string, "an ISO 8601 time in UTC">, v.EndsWithAction<string, "Z", "an ISO 8601 time in UTC, ending in `Z`">]>, undefined>;
2851
+ readonly text: v.StringSchema<undefined>;
2852
+ readonly attachments: v.ArraySchema<v.StrictObjectSchema<{
2853
+ readonly message: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, "a reference such as `note:42`">]>, undefined>;
2854
+ readonly kind: v.StringSchema<undefined>;
2855
+ readonly position: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.IntegerAction<number, undefined>, v.MinValueAction<number, 0, undefined>]>, undefined>;
2856
+ readonly url: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
2857
+ readonly name: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
2858
+ readonly title: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
2859
+ readonly mime: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
2860
+ readonly size: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.IntegerAction<number, undefined>, v.MinValueAction<number, 0, undefined>]>, undefined>;
2861
+ readonly width: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.IntegerAction<number, undefined>, v.MinValueAction<number, 0, undefined>]>, undefined>;
2862
+ readonly height: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.IntegerAction<number, undefined>, v.MinValueAction<number, 0, undefined>]>, undefined>;
2863
+ readonly duration: v.OptionalSchema<v.NumberSchema<undefined>, undefined>;
2864
+ readonly text: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
2865
+ readonly extraction: v.OptionalSchema<v.StrictObjectSchema<{
2866
+ readonly origin: v.StringSchema<undefined>;
2867
+ readonly extractor: v.StringSchema<undefined>;
2868
+ readonly chars: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.IntegerAction<number, undefined>, v.MinValueAction<number, 0, undefined>]>;
2869
+ readonly error: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
2870
+ }, undefined>, undefined>;
2871
+ readonly local_path: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
2872
+ readonly buttons: v.OptionalSchema<v.ArraySchema<v.ArraySchema<v.StrictObjectSchema<{
2873
+ readonly kind: v.PicklistSchema<["callback", "link", "message", "chat", "contact", "location", "app", "clipboard", "other"], undefined>;
2874
+ readonly text: v.StringSchema<undefined>;
2875
+ readonly url: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
2876
+ }, undefined>, undefined>, undefined>, undefined>;
2877
+ }, undefined>, undefined>;
2878
+ readonly outgoing: v.NullableSchema<v.BooleanSchema<undefined>, undefined>;
2879
+ }, undefined>, undefined>;
2880
+ readonly thread_id: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.MinLengthAction<string, 1, undefined>]>, undefined>;
2881
+ readonly thread_root_id: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.MinLengthAction<string, 1, undefined>]>, undefined>;
2882
+ readonly reactions: v.OptionalSchema<v.NullableSchema<v.StrictObjectSchema<{
2883
+ readonly counts: v.ArraySchema<v.StrictObjectSchema<{
2884
+ readonly reaction: v.StringSchema<undefined>;
2885
+ readonly count: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.IntegerAction<number, undefined>, v.MinValueAction<number, 0, undefined>]>;
2886
+ }, undefined>, undefined>;
2887
+ readonly mine: v.NullableSchema<v.StringSchema<undefined>, undefined>;
2888
+ readonly total: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.IntegerAction<number, undefined>, v.MinValueAction<number, 0, undefined>]>;
2889
+ }, undefined>, undefined>, undefined>;
2890
+ readonly scheduled_for: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.IsoTimestampAction<string, "an ISO 8601 time in UTC">, v.EndsWithAction<string, "Z", "an ISO 8601 time in UTC, ending in `Z`">]>, undefined>;
2891
+ readonly starred: v.OptionalSchema<v.LiteralSchema<true, undefined>, undefined>;
2892
+ readonly delivery: v.OptionalSchema<v.PicklistSchema<["delivered", "read"], undefined>, undefined>;
2893
+ readonly email: v.OptionalSchema<v.StrictObjectSchema<{
2894
+ readonly subject: v.NullableSchema<v.StringSchema<undefined>, undefined>;
2895
+ readonly from: v.NullableSchema<v.StrictObjectSchema<{
2896
+ readonly name: v.NullableSchema<v.StringSchema<undefined>, undefined>;
2897
+ readonly address: v.StringSchema<undefined>;
2898
+ readonly ref: v.NullableSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, "a reference such as `note:42`">]>, undefined>;
2899
+ }, undefined>, undefined>;
2900
+ readonly to: v.ArraySchema<v.StrictObjectSchema<{
2901
+ readonly name: v.NullableSchema<v.StringSchema<undefined>, undefined>;
2902
+ readonly address: v.StringSchema<undefined>;
2903
+ readonly ref: v.NullableSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, "a reference such as `note:42`">]>, undefined>;
2904
+ }, undefined>, undefined>;
2905
+ readonly cc: v.ArraySchema<v.StrictObjectSchema<{
2906
+ readonly name: v.NullableSchema<v.StringSchema<undefined>, undefined>;
2907
+ readonly address: v.StringSchema<undefined>;
2908
+ readonly ref: v.NullableSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, "a reference such as `note:42`">]>, undefined>;
2909
+ }, undefined>, undefined>;
2910
+ readonly bcc: v.ArraySchema<v.StrictObjectSchema<{
2911
+ readonly name: v.NullableSchema<v.StringSchema<undefined>, undefined>;
2912
+ readonly address: v.StringSchema<undefined>;
2913
+ readonly ref: v.NullableSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, "a reference such as `note:42`">]>, undefined>;
2914
+ }, undefined>, undefined>;
2915
+ readonly reply_addresses: v.ArraySchema<v.StrictObjectSchema<{
2916
+ readonly name: v.NullableSchema<v.StringSchema<undefined>, undefined>;
2917
+ readonly address: v.StringSchema<undefined>;
2918
+ readonly ref: v.NullableSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, "a reference such as `note:42`">]>, undefined>;
2919
+ }, undefined>, undefined>;
2920
+ readonly labels: v.ArraySchema<v.StringSchema<undefined>, undefined>;
2921
+ readonly thread: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, "a reference such as `note:42`">]>;
2922
+ readonly read: v.NullableSchema<v.BooleanSchema<undefined>, undefined>;
2923
+ readonly flagged: v.NullableSchema<v.BooleanSchema<undefined>, undefined>;
2924
+ readonly sender_score: v.OptionalSchema<v.StrictObjectSchema<{
2925
+ readonly score: v.NumberSchema<undefined>;
2926
+ readonly signals: v.ArraySchema<v.StringSchema<undefined>, undefined>;
2927
+ readonly demoted: v.OptionalSchema<v.LiteralSchema<true, undefined>, undefined>;
2928
+ }, undefined>, undefined>;
2929
+ }, undefined>, undefined>;
2930
+ readonly provider_metadata: v.OptionalSchema<v.RecordSchema<v.StringSchema<undefined>, v.UnknownSchema, undefined>, undefined>;
2931
+ }, undefined>, undefined>, undefined>;
2932
+ readonly scheduled_for: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.IsoTimestampAction<string, "an ISO 8601 time in UTC">, v.EndsWithAction<string, "Z", "an ISO 8601 time in UTC, ending in `Z`">]>, undefined>;
2933
+ }, undefined>, v.StrictObjectSchema<{
2934
+ readonly operation_id: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.MinLengthAction<string, 1, undefined>]>;
2935
+ readonly chat_id: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.MinLengthAction<string, 1, undefined>]>;
2936
+ readonly saved: v.LiteralSchema<true, undefined>;
2937
+ }, undefined>], undefined>;
2558
2938
  readonly message_pin: v.StrictObjectSchema<{
2559
2939
  readonly operation_id: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.MinLengthAction<string, 1, undefined>]>;
2560
2940
  readonly chat_id: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.MinLengthAction<string, 1, undefined>]>;