@wirecat/attio-cli 0.8.0 → 0.10.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 (207) hide show
  1. package/CHANGELOG.md +23 -0
  2. package/contracts/wirecat.json +1 -0
  3. package/dist/bin/attio.js +11 -11
  4. package/dist/bundle/attio.js +5 -166
  5. package/dist/bundle/{chunk-UXJZISVL.js → chunk-OGWKDPR5.js} +2 -1
  6. package/dist/bundle/chunk-TQAECZFO.js +13 -0
  7. package/dist/bundle/{definitions-FODOIPM2.js → definitions-J73IBAHT.js} +1 -1
  8. package/dist/bundle/program-NSBWZ25F.js +6201 -0
  9. package/dist/bundle/{schemas-YGSTNU6F.js → schemas-G3HFAS45.js} +576 -29
  10. package/dist/commands/api.js +1 -2
  11. package/dist/commands/crm.js +1 -4
  12. package/dist/commands/schedule.js +1 -1
  13. package/dist/commands/session.js +1 -2
  14. package/dist/config.js +1 -2
  15. package/dist/context.js +1 -1
  16. package/dist/identity.js +1 -0
  17. package/dist/program.js +1 -2
  18. package/dist/version.js +1 -1
  19. package/package.json +4 -4
  20. package/dist/activities.d.ts +0 -4
  21. package/dist/activities.d.ts.map +0 -1
  22. package/dist/activities.js.map +0 -1
  23. package/dist/bin/attio.d.ts +0 -3
  24. package/dist/bin/attio.d.ts.map +0 -1
  25. package/dist/bin/attio.js.map +0 -1
  26. package/dist/bundle/agent-GUXXSLT5.js +0 -38
  27. package/dist/bundle/all-profiles-63N3EQ46.js +0 -320
  28. package/dist/bundle/anthropic-B4W7MZQE.js +0 -91
  29. package/dist/bundle/app-server-EXNGTHWO.js +0 -250
  30. package/dist/bundle/bun-OPDGMZZQ.js +0 -169
  31. package/dist/bundle/bun-sqlite-NBAY7FR2.js +0 -76
  32. package/dist/bundle/chunk-2JHVQMVC.js +0 -16
  33. package/dist/bundle/chunk-2QDUP74I.js +0 -794
  34. package/dist/bundle/chunk-2XBDILVW.js +0 -53
  35. package/dist/bundle/chunk-3HC5F3P7.js +0 -24
  36. package/dist/bundle/chunk-3MSHGNVE.js +0 -1243
  37. package/dist/bundle/chunk-3YM4B2GT.js +0 -63
  38. package/dist/bundle/chunk-4N7PP76S.js +0 -6848
  39. package/dist/bundle/chunk-4RBMCXZT.js +0 -1337
  40. package/dist/bundle/chunk-4RSWOPKL.js +0 -323
  41. package/dist/bundle/chunk-5JKTVAXX.js +0 -2788
  42. package/dist/bundle/chunk-5N2V6XO7.js +0 -119
  43. package/dist/bundle/chunk-5WD22IXQ.js +0 -66
  44. package/dist/bundle/chunk-6K4Z6CAM.js +0 -43997
  45. package/dist/bundle/chunk-6TD3DCWC.js +0 -106
  46. package/dist/bundle/chunk-7Z53MLQP.js +0 -388
  47. package/dist/bundle/chunk-AATTOFNY.js +0 -2045
  48. package/dist/bundle/chunk-APARYILG.js +0 -743
  49. package/dist/bundle/chunk-D72URWJE.js +0 -532
  50. package/dist/bundle/chunk-DFDN6AUB.js +0 -21
  51. package/dist/bundle/chunk-DM7KWVDZ.js +0 -3752
  52. package/dist/bundle/chunk-DNCLQPOM.js +0 -7
  53. package/dist/bundle/chunk-DPD4FMHN.js +0 -388
  54. package/dist/bundle/chunk-DPV53EZC.js +0 -206
  55. package/dist/bundle/chunk-DURNR4RO.js +0 -353
  56. package/dist/bundle/chunk-EH6ZEJGT.js +0 -932
  57. package/dist/bundle/chunk-EVUMQKV7.js +0 -76
  58. package/dist/bundle/chunk-EY36BTKZ.js +0 -108
  59. package/dist/bundle/chunk-FH6OEGGN.js +0 -557
  60. package/dist/bundle/chunk-FOP6G45D.js +0 -358
  61. package/dist/bundle/chunk-GGMAIIVE.js +0 -38
  62. package/dist/bundle/chunk-GTEX4IUO.js +0 -334
  63. package/dist/bundle/chunk-HZ3C4WXD.js +0 -142
  64. package/dist/bundle/chunk-IA7LLLEI.js +0 -100
  65. package/dist/bundle/chunk-J6GVVISK.js +0 -185
  66. package/dist/bundle/chunk-JG6LCSEX.js +0 -407
  67. package/dist/bundle/chunk-JIGEJZ4I.js +0 -68943
  68. package/dist/bundle/chunk-KVTNYRDO.js +0 -1007
  69. package/dist/bundle/chunk-L45WN3AR.js +0 -80
  70. package/dist/bundle/chunk-L72WUJAS.js +0 -54
  71. package/dist/bundle/chunk-LKH3UKLO.js +0 -230
  72. package/dist/bundle/chunk-LM3W7YOM.js +0 -274
  73. package/dist/bundle/chunk-M4AC55ZB.js +0 -12733
  74. package/dist/bundle/chunk-MCLQTCGH.js +0 -1202
  75. package/dist/bundle/chunk-NB7EOAUZ.js +0 -123
  76. package/dist/bundle/chunk-NISH4UXM.js +0 -58
  77. package/dist/bundle/chunk-OYEVYOCL.js +0 -259
  78. package/dist/bundle/chunk-P7G5HFY3.js +0 -288
  79. package/dist/bundle/chunk-PAEKXVJW.js +0 -188
  80. package/dist/bundle/chunk-PL5P7UKW.js +0 -25216
  81. package/dist/bundle/chunk-PLPBEWD4.js +0 -170
  82. package/dist/bundle/chunk-PMQ7GP6X.js +0 -95
  83. package/dist/bundle/chunk-Q7ICVP25.js +0 -18
  84. package/dist/bundle/chunk-QPPOIWPY.js +0 -1246
  85. package/dist/bundle/chunk-QSJKSPWF.js +0 -131
  86. package/dist/bundle/chunk-RDVTHFPP.js +0 -338
  87. package/dist/bundle/chunk-RQORQN2V.js +0 -4072
  88. package/dist/bundle/chunk-RRTMPSQR.js +0 -29
  89. package/dist/bundle/chunk-S4UUN6LD.js +0 -1410
  90. package/dist/bundle/chunk-S6JG4YUH.js +0 -72
  91. package/dist/bundle/chunk-SCI7QEHF.js +0 -362
  92. package/dist/bundle/chunk-SSA6JBPA.js +0 -778
  93. package/dist/bundle/chunk-T4J7XFXT.js +0 -9667
  94. package/dist/bundle/chunk-TTF5DP4V.js +0 -1197
  95. package/dist/bundle/chunk-TXDR6YSF.js +0 -23
  96. package/dist/bundle/chunk-TY7NDMFY.js +0 -46
  97. package/dist/bundle/chunk-UDSL3MUU.js +0 -2333
  98. package/dist/bundle/chunk-UKHF37ZU.js +0 -1068
  99. package/dist/bundle/chunk-V57E7PJQ.js +0 -161
  100. package/dist/bundle/chunk-V7IF2K3P.js +0 -52
  101. package/dist/bundle/chunk-VB7FZOYX.js +0 -633
  102. package/dist/bundle/chunk-VZ5PPYDG.js +0 -77
  103. package/dist/bundle/chunk-WOPVBRPV.js +0 -29
  104. package/dist/bundle/chunk-WXQGA6XK.js +0 -50
  105. package/dist/bundle/chunk-XQGN2D44.js +0 -86
  106. package/dist/bundle/chunk-XQUUANA2.js +0 -24600
  107. package/dist/bundle/chunk-Y5E2WNWB.js +0 -35
  108. package/dist/bundle/chunk-YNGU36GW.js +0 -218
  109. package/dist/bundle/chunk-YWDFYQOU.js +0 -82
  110. package/dist/bundle/chunk-ZVVMGPBJ.js +0 -50
  111. package/dist/bundle/chunk-ZZD2YPOX.js +0 -156
  112. package/dist/bundle/command-contract-KCCW4LNI.js +0 -37
  113. package/dist/bundle/command-server-entry-3NPPABQQ.js +0 -166
  114. package/dist/bundle/decode-26M7XE2B.js +0 -297
  115. package/dist/bundle/dispatch-2FTOHA5D.js +0 -411
  116. package/dist/bundle/dist-EM7KLEG4.js +0 -7577
  117. package/dist/bundle/dist-PAKDDIBT.js +0 -191
  118. package/dist/bundle/echarts-O3TNDAXJ.js +0 -42501
  119. package/dist/bundle/embed-XJLEAWXE.js +0 -38
  120. package/dist/bundle/embedder-OEL6PXEH.js +0 -111
  121. package/dist/bundle/failure-OHIXWTR6.js +0 -25
  122. package/dist/bundle/first-run-CIXGBXY6.js +0 -29
  123. package/dist/bundle/first-screen-5FK4D45F.js +0 -38
  124. package/dist/bundle/instructions-AMH5RWVJ.js +0 -11
  125. package/dist/bundle/mcp-5HFPWC3W.js +0 -167
  126. package/dist/bundle/meeting-combined-DMVGQNJ7.js +0 -24
  127. package/dist/bundle/meeting-model-2THAT7OH.js +0 -25
  128. package/dist/bundle/meeting-semantic-Q6XYFYUD.js +0 -22
  129. package/dist/bundle/node-EGMCBAO7.js +0 -176
  130. package/dist/bundle/node-KM3CUABH.js +0 -2340
  131. package/dist/bundle/node-TLZSIHIJ.js +0 -21
  132. package/dist/bundle/node-sqlite-2SWWGW6H.js +0 -74
  133. package/dist/bundle/oauth-V5LGTXF2.js +0 -20
  134. package/dist/bundle/open-25EKOTZA.js +0 -23
  135. package/dist/bundle/openai-VX3OLIHM.js +0 -238
  136. package/dist/bundle/process-SGHEN6MQ.js +0 -91
  137. package/dist/bundle/program-Z5NUNXME.js +0 -34214
  138. package/dist/bundle/prompt-2VSPX5S7.js +0 -17
  139. package/dist/bundle/recognize-NA5XUFKK.js +0 -26
  140. package/dist/bundle/remote-BOME6XOE.js +0 -31
  141. package/dist/bundle/rerank-NG3XMFCV.js +0 -52
  142. package/dist/bundle/serve-MR67OBED.js +0 -199
  143. package/dist/bundle/server-4BWAGJQO.js +0 -80
  144. package/dist/bundle/server-OP2HJNXD.js +0 -213
  145. package/dist/bundle/sqlite-runtime-V5U6F5EB.js +0 -20
  146. package/dist/bundle/state-L4MWAATO.js +0 -36
  147. package/dist/bundle/store-2ALTEH55.js +0 -181
  148. package/dist/bundle/store-CXZFRG5D.js +0 -297
  149. package/dist/bundle/store-maintenance-command-LC55DRQA.js +0 -67
  150. package/dist/bundle/surface-3GRJ7473.js +0 -66
  151. package/dist/commands/api.d.ts +0 -12
  152. package/dist/commands/api.d.ts.map +0 -1
  153. package/dist/commands/api.js.map +0 -1
  154. package/dist/commands/crm.d.ts +0 -7
  155. package/dist/commands/crm.d.ts.map +0 -1
  156. package/dist/commands/crm.js.map +0 -1
  157. package/dist/commands/schedule.d.ts +0 -3
  158. package/dist/commands/schedule.d.ts.map +0 -1
  159. package/dist/commands/schedule.js.map +0 -1
  160. package/dist/commands/session.d.ts +0 -8
  161. package/dist/commands/session.d.ts.map +0 -1
  162. package/dist/commands/session.js.map +0 -1
  163. package/dist/config.d.ts +0 -13
  164. package/dist/config.d.ts.map +0 -1
  165. package/dist/config.js.map +0 -1
  166. package/dist/context.d.ts +0 -37
  167. package/dist/context.d.ts.map +0 -1
  168. package/dist/context.js.map +0 -1
  169. package/dist/generated/definitions.d.ts +0 -3
  170. package/dist/generated/definitions.d.ts.map +0 -1
  171. package/dist/generated/definitions.js.map +0 -1
  172. package/dist/generated/manifest.d.ts +0 -6
  173. package/dist/generated/manifest.d.ts.map +0 -1
  174. package/dist/generated/manifest.js.map +0 -1
  175. package/dist/generated/schemas.d.ts +0 -383
  176. package/dist/generated/schemas.d.ts.map +0 -1
  177. package/dist/generated/schemas.js.map +0 -1
  178. package/dist/generated/types.d.ts +0 -10166
  179. package/dist/generated/types.d.ts.map +0 -1
  180. package/dist/generated/types.js.map +0 -1
  181. package/dist/generated/wirecat-config.d.ts +0 -15
  182. package/dist/generated/wirecat-config.d.ts.map +0 -1
  183. package/dist/generated/wirecat-config.js.map +0 -1
  184. package/dist/hooks.d.ts +0 -33
  185. package/dist/hooks.d.ts.map +0 -1
  186. package/dist/hooks.js.map +0 -1
  187. package/dist/identity.d.ts +0 -33
  188. package/dist/identity.d.ts.map +0 -1
  189. package/dist/identity.js.map +0 -1
  190. package/dist/index.d.ts +0 -3
  191. package/dist/index.d.ts.map +0 -1
  192. package/dist/index.js.map +0 -1
  193. package/dist/links.d.ts +0 -10
  194. package/dist/links.d.ts.map +0 -1
  195. package/dist/links.js.map +0 -1
  196. package/dist/meetings.d.ts +0 -57
  197. package/dist/meetings.d.ts.map +0 -1
  198. package/dist/meetings.js.map +0 -1
  199. package/dist/program.d.ts +0 -6
  200. package/dist/program.d.ts.map +0 -1
  201. package/dist/program.js.map +0 -1
  202. package/dist/version.d.ts +0 -2
  203. package/dist/version.d.ts.map +0 -1
  204. package/dist/version.js.map +0 -1
  205. package/dist/wcat.d.ts +0 -3
  206. package/dist/wcat.d.ts.map +0 -1
  207. package/dist/wcat.js.map +0 -1
@@ -1,29 +1,576 @@
1
1
  import { createRequire as __bundleRequire } from "node:module";
2
2
  const require = __bundleRequire(import.meta.url);
3
3
  import {
4
- integer,
5
- number
6
- } from "./chunk-5N2V6XO7.js";
7
- import {
8
- array,
9
- boolean,
10
- lazy,
11
- literal,
12
- looseObject,
13
- maxLength,
14
- minLength,
15
- nullable,
16
- optional,
17
- picklist,
18
- pipe,
19
- record,
20
- regex,
21
- startsWith,
22
- string,
23
- union,
24
- unknown
25
- } from "./chunk-S4UUN6LD.js";
26
- import "./chunk-ZVVMGPBJ.js";
4
+ __name
5
+ } from "./chunk-TQAECZFO.js";
6
+
7
+ // dist/generated/schemas.js
8
+ import { integer, number } from "@wirecat/cli-base/codegen/runtime";
9
+
10
+ // node_modules/.pnpm/valibot@1.5.0_typescript@7.0.2/node_modules/valibot/dist/index.mjs
11
+ var store$4;
12
+ var DEFAULT_CONFIG = {
13
+ lang: void 0,
14
+ message: void 0,
15
+ abortEarly: void 0,
16
+ abortPipeEarly: void 0
17
+ };
18
+ // @__NO_SIDE_EFFECTS__
19
+ function getGlobalConfig(config$1) {
20
+ if (!config$1 && !store$4) return DEFAULT_CONFIG;
21
+ return {
22
+ lang: config$1?.lang ?? store$4?.lang,
23
+ message: config$1?.message,
24
+ abortEarly: config$1?.abortEarly ?? store$4?.abortEarly,
25
+ abortPipeEarly: config$1?.abortPipeEarly ?? store$4?.abortPipeEarly
26
+ };
27
+ }
28
+ __name(getGlobalConfig, "getGlobalConfig");
29
+ var store$3;
30
+ // @__NO_SIDE_EFFECTS__
31
+ function getGlobalMessage(lang) {
32
+ return store$3?.get(lang);
33
+ }
34
+ __name(getGlobalMessage, "getGlobalMessage");
35
+ var store$2;
36
+ // @__NO_SIDE_EFFECTS__
37
+ function getSchemaMessage(lang) {
38
+ return store$2?.get(lang);
39
+ }
40
+ __name(getSchemaMessage, "getSchemaMessage");
41
+ var store$1;
42
+ // @__NO_SIDE_EFFECTS__
43
+ function getSpecificMessage(reference, lang) {
44
+ return store$1?.get(reference)?.get(lang);
45
+ }
46
+ __name(getSpecificMessage, "getSpecificMessage");
47
+ // @__NO_SIDE_EFFECTS__
48
+ function _stringify(input) {
49
+ const type = typeof input;
50
+ if (type === "string") return `"${input}"`;
51
+ if (type === "number" || type === "bigint" || type === "boolean") return `${input}`;
52
+ if (type === "object" || type === "function") return (input && Object.getPrototypeOf(input)?.constructor?.name) ?? "null";
53
+ return type;
54
+ }
55
+ __name(_stringify, "_stringify");
56
+ function _addIssue(context, label, dataset, config$1, other) {
57
+ const input = other && "input" in other ? other.input : dataset.value;
58
+ const expected = other?.expected ?? context.expects ?? null;
59
+ const received = other?.received ?? /* @__PURE__ */ _stringify(input);
60
+ const issue = {
61
+ kind: context.kind,
62
+ type: context.type,
63
+ input,
64
+ expected,
65
+ received,
66
+ message: `Invalid ${label}: ${expected ? `Expected ${expected} but r` : "R"}eceived ${received}`,
67
+ requirement: context.requirement,
68
+ path: other?.path,
69
+ issues: other?.issues,
70
+ lang: config$1.lang,
71
+ abortEarly: config$1.abortEarly,
72
+ abortPipeEarly: config$1.abortPipeEarly
73
+ };
74
+ const isSchema = context.kind === "schema";
75
+ const message$1 = other?.message ?? context.message ?? /* @__PURE__ */ getSpecificMessage(context.reference, issue.lang) ?? (isSchema ? /* @__PURE__ */ getSchemaMessage(issue.lang) : null) ?? config$1.message ?? /* @__PURE__ */ getGlobalMessage(issue.lang);
76
+ if (message$1 !== void 0) issue.message = typeof message$1 === "function" ? message$1(issue) : message$1;
77
+ if (isSchema) dataset.typed = false;
78
+ if (dataset.issues) dataset.issues.push(issue);
79
+ else dataset.issues = [issue];
80
+ }
81
+ __name(_addIssue, "_addIssue");
82
+ // @__NO_SIDE_EFFECTS__
83
+ function _isSameValueZero(value1, value2) {
84
+ return value1 === value2 || Number.isNaN(value1) && Number.isNaN(value2);
85
+ }
86
+ __name(_isSameValueZero, "_isSameValueZero");
87
+ // @__NO_SIDE_EFFECTS__
88
+ function _isValidObjectKey(object$1, key) {
89
+ return Object.prototype.hasOwnProperty.call(object$1, key) && key !== "__proto__" && key !== "prototype" && key !== "constructor";
90
+ }
91
+ __name(_isValidObjectKey, "_isValidObjectKey");
92
+ // @__NO_SIDE_EFFECTS__
93
+ function _joinExpects(values$1, separator) {
94
+ const list = [...new Set(values$1)];
95
+ if (list.length > 1) return `(${list.join(` ${separator} `)})`;
96
+ return list[0] ?? "never";
97
+ }
98
+ __name(_joinExpects, "_joinExpects");
99
+ function _standardSchema(schema) {
100
+ schema["~standard"] = {
101
+ version: 1,
102
+ vendor: "valibot",
103
+ validate: /* @__PURE__ */ __name((value$1) => schema["~run"]({ value: value$1 }, /* @__PURE__ */ getGlobalConfig()), "validate")
104
+ };
105
+ return schema;
106
+ }
107
+ __name(_standardSchema, "_standardSchema");
108
+ var EMOJI_REGEX = new RegExp("^(?:[\\u{1F1E6}-\\u{1F1FF}]{2}|\\u{1F3F4}[\\u{E0061}-\\u{E007A}]{2}[\\u{E0030}-\\u{E0039}\\u{E0061}-\\u{E007A}]{1,3}\\u{E007F}|(?:\\p{Emoji}\\uFE0F\\u20E3?|\\p{Emoji_Modifier_Base}\\p{Emoji_Modifier}?|(?![\\p{Emoji_Modifier_Base}\\u{1F1E6}-\\u{1F1FF}])\\p{Emoji_Presentation})(?:\\u200D(?:\\p{Emoji}\\uFE0F\\u20E3?|\\p{Emoji_Modifier_Base}\\p{Emoji_Modifier}?|(?![\\p{Emoji_Modifier_Base}\\u{1F1E6}-\\u{1F1FF}])\\p{Emoji_Presentation}))*)+$", "u");
109
+ // @__NO_SIDE_EFFECTS__
110
+ function maxLength(requirement, message$1) {
111
+ return {
112
+ kind: "validation",
113
+ type: "max_length",
114
+ reference: maxLength,
115
+ async: false,
116
+ expects: `<=${requirement}`,
117
+ requirement,
118
+ message: message$1,
119
+ "~run"(dataset, config$1) {
120
+ if (dataset.typed && dataset.value.length > this.requirement) _addIssue(this, "length", dataset, config$1, { received: `${dataset.value.length}` });
121
+ return dataset;
122
+ }
123
+ };
124
+ }
125
+ __name(maxLength, "maxLength");
126
+ // @__NO_SIDE_EFFECTS__
127
+ function minLength(requirement, message$1) {
128
+ return {
129
+ kind: "validation",
130
+ type: "min_length",
131
+ reference: minLength,
132
+ async: false,
133
+ expects: `>=${requirement}`,
134
+ requirement,
135
+ message: message$1,
136
+ "~run"(dataset, config$1) {
137
+ if (dataset.typed && dataset.value.length < this.requirement) _addIssue(this, "length", dataset, config$1, { received: `${dataset.value.length}` });
138
+ return dataset;
139
+ }
140
+ };
141
+ }
142
+ __name(minLength, "minLength");
143
+ // @__NO_SIDE_EFFECTS__
144
+ function regex(requirement, message$1) {
145
+ return {
146
+ kind: "validation",
147
+ type: "regex",
148
+ reference: regex,
149
+ async: false,
150
+ expects: `${requirement}`,
151
+ requirement,
152
+ message: message$1,
153
+ "~run"(dataset, config$1) {
154
+ if (dataset.typed && !this.requirement.test(dataset.value)) _addIssue(this, "format", dataset, config$1);
155
+ return dataset;
156
+ }
157
+ };
158
+ }
159
+ __name(regex, "regex");
160
+ // @__NO_SIDE_EFFECTS__
161
+ function startsWith(requirement, message$1) {
162
+ return {
163
+ kind: "validation",
164
+ type: "starts_with",
165
+ reference: startsWith,
166
+ async: false,
167
+ expects: `"${requirement}"`,
168
+ requirement,
169
+ message: message$1,
170
+ "~run"(dataset, config$1) {
171
+ if (dataset.typed && !dataset.value.startsWith(this.requirement)) _addIssue(this, "start", dataset, config$1, { received: `"${dataset.value.slice(0, this.requirement.length)}"` });
172
+ return dataset;
173
+ }
174
+ };
175
+ }
176
+ __name(startsWith, "startsWith");
177
+ // @__NO_SIDE_EFFECTS__
178
+ function getFallback(schema, dataset, config$1) {
179
+ return typeof schema.fallback === "function" ? schema.fallback(dataset, config$1) : schema.fallback;
180
+ }
181
+ __name(getFallback, "getFallback");
182
+ // @__NO_SIDE_EFFECTS__
183
+ function getDefault(schema, dataset, config$1) {
184
+ return typeof schema.default === "function" ? schema.default(dataset, config$1) : schema.default;
185
+ }
186
+ __name(getDefault, "getDefault");
187
+ // @__NO_SIDE_EFFECTS__
188
+ function array(item, message$1) {
189
+ return _standardSchema({
190
+ kind: "schema",
191
+ type: "array",
192
+ reference: array,
193
+ expects: "Array",
194
+ async: false,
195
+ item,
196
+ message: message$1,
197
+ "~run"(dataset, config$1) {
198
+ const input = dataset.value;
199
+ if (Array.isArray(input)) {
200
+ dataset.typed = true;
201
+ dataset.value = [];
202
+ for (let key = 0; key < input.length; key++) {
203
+ const value$1 = input[key];
204
+ const itemDataset = this.item["~run"]({ value: value$1 }, config$1);
205
+ if (itemDataset.issues) {
206
+ const pathItem = {
207
+ type: "array",
208
+ origin: "value",
209
+ input,
210
+ key,
211
+ value: value$1
212
+ };
213
+ for (const issue of itemDataset.issues) {
214
+ if (issue.path) issue.path.unshift(pathItem);
215
+ else issue.path = [pathItem];
216
+ dataset.issues?.push(issue);
217
+ }
218
+ if (!dataset.issues) dataset.issues = itemDataset.issues;
219
+ if (config$1.abortEarly) {
220
+ dataset.typed = false;
221
+ break;
222
+ }
223
+ }
224
+ if (!itemDataset.typed) dataset.typed = false;
225
+ dataset.value.push(itemDataset.value);
226
+ }
227
+ } else _addIssue(this, "type", dataset, config$1);
228
+ return dataset;
229
+ }
230
+ });
231
+ }
232
+ __name(array, "array");
233
+ // @__NO_SIDE_EFFECTS__
234
+ function boolean(message$1) {
235
+ return _standardSchema({
236
+ kind: "schema",
237
+ type: "boolean",
238
+ reference: boolean,
239
+ expects: "boolean",
240
+ async: false,
241
+ message: message$1,
242
+ "~run"(dataset, config$1) {
243
+ if (typeof dataset.value === "boolean") dataset.typed = true;
244
+ else _addIssue(this, "type", dataset, config$1);
245
+ return dataset;
246
+ }
247
+ });
248
+ }
249
+ __name(boolean, "boolean");
250
+ // @__NO_SIDE_EFFECTS__
251
+ function lazy(getter) {
252
+ return _standardSchema({
253
+ kind: "schema",
254
+ type: "lazy",
255
+ reference: lazy,
256
+ expects: "unknown",
257
+ async: false,
258
+ getter,
259
+ "~run"(dataset, config$1) {
260
+ return this.getter(dataset.value)["~run"](dataset, config$1);
261
+ }
262
+ });
263
+ }
264
+ __name(lazy, "lazy");
265
+ // @__NO_SIDE_EFFECTS__
266
+ function literal(literal_, message$1) {
267
+ return _standardSchema({
268
+ kind: "schema",
269
+ type: "literal",
270
+ reference: literal,
271
+ expects: /* @__PURE__ */ _stringify(literal_),
272
+ async: false,
273
+ literal: literal_,
274
+ message: message$1,
275
+ "~run"(dataset, config$1) {
276
+ if (/* @__PURE__ */ _isSameValueZero(dataset.value, this.literal)) dataset.typed = true;
277
+ else _addIssue(this, "type", dataset, config$1);
278
+ return dataset;
279
+ }
280
+ });
281
+ }
282
+ __name(literal, "literal");
283
+ // @__NO_SIDE_EFFECTS__
284
+ function looseObject(entries$1, message$1) {
285
+ return _standardSchema({
286
+ kind: "schema",
287
+ type: "loose_object",
288
+ reference: looseObject,
289
+ expects: "Object",
290
+ async: false,
291
+ entries: entries$1,
292
+ message: message$1,
293
+ "~run"(dataset, config$1) {
294
+ const input = dataset.value;
295
+ if (input && typeof input === "object") {
296
+ dataset.typed = true;
297
+ dataset.value = {};
298
+ for (const key in this.entries) {
299
+ const valueSchema = this.entries[key];
300
+ if (key in input || (valueSchema.type === "exact_optional" || valueSchema.type === "optional" || valueSchema.type === "nullish") && valueSchema.default !== void 0) {
301
+ const value$1 = key in input ? input[key] : /* @__PURE__ */ getDefault(valueSchema);
302
+ const valueDataset = valueSchema["~run"]({ value: value$1 }, config$1);
303
+ if (valueDataset.issues) {
304
+ const pathItem = {
305
+ type: "object",
306
+ origin: "value",
307
+ input,
308
+ key,
309
+ value: value$1
310
+ };
311
+ for (const issue of valueDataset.issues) {
312
+ if (issue.path) issue.path.unshift(pathItem);
313
+ else issue.path = [pathItem];
314
+ dataset.issues?.push(issue);
315
+ }
316
+ if (!dataset.issues) dataset.issues = valueDataset.issues;
317
+ if (config$1.abortEarly) {
318
+ dataset.typed = false;
319
+ break;
320
+ }
321
+ }
322
+ if (!valueDataset.typed) dataset.typed = false;
323
+ dataset.value[key] = valueDataset.value;
324
+ } else if (valueSchema.fallback !== void 0) dataset.value[key] = /* @__PURE__ */ getFallback(valueSchema);
325
+ else if (valueSchema.type !== "exact_optional" && valueSchema.type !== "optional" && valueSchema.type !== "nullish") {
326
+ _addIssue(this, "key", dataset, config$1, {
327
+ input: void 0,
328
+ expected: `"${key}"`,
329
+ path: [{
330
+ type: "object",
331
+ origin: "key",
332
+ input,
333
+ key,
334
+ value: input[key]
335
+ }]
336
+ });
337
+ if (config$1.abortEarly) break;
338
+ }
339
+ }
340
+ if (!dataset.issues || !config$1.abortEarly) {
341
+ for (const key in input) if (/* @__PURE__ */ _isValidObjectKey(input, key) && !Object.prototype.hasOwnProperty.call(this.entries, key)) dataset.value[key] = input[key];
342
+ }
343
+ } else _addIssue(this, "type", dataset, config$1);
344
+ return dataset;
345
+ }
346
+ });
347
+ }
348
+ __name(looseObject, "looseObject");
349
+ // @__NO_SIDE_EFFECTS__
350
+ function nullable(wrapped, default_) {
351
+ return _standardSchema({
352
+ kind: "schema",
353
+ type: "nullable",
354
+ reference: nullable,
355
+ expects: `(${wrapped.expects} | null)`,
356
+ async: false,
357
+ wrapped,
358
+ default: default_,
359
+ "~run"(dataset, config$1) {
360
+ if (dataset.value === null) {
361
+ if (this.default !== void 0) dataset.value = /* @__PURE__ */ getDefault(this, dataset, config$1);
362
+ if (dataset.value === null) {
363
+ dataset.typed = true;
364
+ return dataset;
365
+ }
366
+ }
367
+ return this.wrapped["~run"](dataset, config$1);
368
+ }
369
+ });
370
+ }
371
+ __name(nullable, "nullable");
372
+ // @__NO_SIDE_EFFECTS__
373
+ function optional(wrapped, default_) {
374
+ return _standardSchema({
375
+ kind: "schema",
376
+ type: "optional",
377
+ reference: optional,
378
+ expects: `(${wrapped.expects} | undefined)`,
379
+ async: false,
380
+ wrapped,
381
+ default: default_,
382
+ "~run"(dataset, config$1) {
383
+ if (dataset.value === void 0) {
384
+ if (this.default !== void 0) dataset.value = /* @__PURE__ */ getDefault(this, dataset, config$1);
385
+ if (dataset.value === void 0) {
386
+ dataset.typed = true;
387
+ return dataset;
388
+ }
389
+ }
390
+ return this.wrapped["~run"](dataset, config$1);
391
+ }
392
+ });
393
+ }
394
+ __name(optional, "optional");
395
+ // @__NO_SIDE_EFFECTS__
396
+ function picklist(options, message$1) {
397
+ return _standardSchema({
398
+ kind: "schema",
399
+ type: "picklist",
400
+ reference: picklist,
401
+ expects: /* @__PURE__ */ _joinExpects(options.map(_stringify), "|"),
402
+ async: false,
403
+ options,
404
+ message: message$1,
405
+ "~run"(dataset, config$1) {
406
+ if (this.options.includes(dataset.value)) dataset.typed = true;
407
+ else _addIssue(this, "type", dataset, config$1);
408
+ return dataset;
409
+ }
410
+ });
411
+ }
412
+ __name(picklist, "picklist");
413
+ // @__NO_SIDE_EFFECTS__
414
+ function record(key, value$1, message$1) {
415
+ return _standardSchema({
416
+ kind: "schema",
417
+ type: "record",
418
+ reference: record,
419
+ expects: "Object",
420
+ async: false,
421
+ key,
422
+ value: value$1,
423
+ message: message$1,
424
+ "~run"(dataset, config$1) {
425
+ const input = dataset.value;
426
+ if (input && typeof input === "object") {
427
+ dataset.typed = true;
428
+ dataset.value = {};
429
+ for (const entryKey in input) if (/* @__PURE__ */ _isValidObjectKey(input, entryKey)) {
430
+ const entryValue = input[entryKey];
431
+ const keyDataset = this.key["~run"]({ value: entryKey }, config$1);
432
+ if (keyDataset.issues) {
433
+ const pathItem = {
434
+ type: "object",
435
+ origin: "key",
436
+ input,
437
+ key: entryKey,
438
+ value: entryValue
439
+ };
440
+ for (const issue of keyDataset.issues) {
441
+ issue.path = [pathItem];
442
+ dataset.issues?.push(issue);
443
+ }
444
+ if (!dataset.issues) dataset.issues = keyDataset.issues;
445
+ if (config$1.abortEarly) {
446
+ dataset.typed = false;
447
+ break;
448
+ }
449
+ }
450
+ const valueDataset = this.value["~run"]({ value: entryValue }, config$1);
451
+ if (valueDataset.issues) {
452
+ const pathItem = {
453
+ type: "object",
454
+ origin: "value",
455
+ input,
456
+ key: entryKey,
457
+ value: entryValue
458
+ };
459
+ for (const issue of valueDataset.issues) {
460
+ if (issue.path) issue.path.unshift(pathItem);
461
+ else issue.path = [pathItem];
462
+ dataset.issues?.push(issue);
463
+ }
464
+ if (!dataset.issues) dataset.issues = valueDataset.issues;
465
+ if (config$1.abortEarly) {
466
+ dataset.typed = false;
467
+ break;
468
+ }
469
+ }
470
+ if (!keyDataset.typed || !valueDataset.typed) dataset.typed = false;
471
+ if (keyDataset.typed) dataset.value[keyDataset.value] = valueDataset.value;
472
+ }
473
+ } else _addIssue(this, "type", dataset, config$1);
474
+ return dataset;
475
+ }
476
+ });
477
+ }
478
+ __name(record, "record");
479
+ // @__NO_SIDE_EFFECTS__
480
+ function string(message$1) {
481
+ return _standardSchema({
482
+ kind: "schema",
483
+ type: "string",
484
+ reference: string,
485
+ expects: "string",
486
+ async: false,
487
+ message: message$1,
488
+ "~run"(dataset, config$1) {
489
+ if (typeof dataset.value === "string") dataset.typed = true;
490
+ else _addIssue(this, "type", dataset, config$1);
491
+ return dataset;
492
+ }
493
+ });
494
+ }
495
+ __name(string, "string");
496
+ // @__NO_SIDE_EFFECTS__
497
+ function _subIssues(datasets) {
498
+ let issues;
499
+ if (datasets) for (const dataset of datasets) if (issues) for (const issue of dataset.issues) issues.push(issue);
500
+ else issues = dataset.issues;
501
+ return issues;
502
+ }
503
+ __name(_subIssues, "_subIssues");
504
+ // @__NO_SIDE_EFFECTS__
505
+ function union(options, message$1) {
506
+ return _standardSchema({
507
+ kind: "schema",
508
+ type: "union",
509
+ reference: union,
510
+ expects: /* @__PURE__ */ _joinExpects(options.map((option) => option.expects), "|"),
511
+ async: false,
512
+ options,
513
+ message: message$1,
514
+ "~run"(dataset, config$1) {
515
+ let validDataset;
516
+ let typedDatasets;
517
+ let untypedDatasets;
518
+ for (const schema of this.options) {
519
+ const optionDataset = schema["~run"]({ value: dataset.value }, config$1);
520
+ if (optionDataset.typed) if (optionDataset.issues) if (typedDatasets) typedDatasets.push(optionDataset);
521
+ else typedDatasets = [optionDataset];
522
+ else {
523
+ validDataset = optionDataset;
524
+ break;
525
+ }
526
+ else if (untypedDatasets) untypedDatasets.push(optionDataset);
527
+ else untypedDatasets = [optionDataset];
528
+ }
529
+ if (validDataset) return validDataset;
530
+ if (typedDatasets) {
531
+ if (typedDatasets.length === 1) return typedDatasets[0];
532
+ _addIssue(this, "type", dataset, config$1, { issues: /* @__PURE__ */ _subIssues(typedDatasets) });
533
+ dataset.typed = true;
534
+ } else if (untypedDatasets?.length === 1) return untypedDatasets[0];
535
+ else _addIssue(this, "type", dataset, config$1, { issues: /* @__PURE__ */ _subIssues(untypedDatasets) });
536
+ return dataset;
537
+ }
538
+ });
539
+ }
540
+ __name(union, "union");
541
+ // @__NO_SIDE_EFFECTS__
542
+ function unknown() {
543
+ return _standardSchema({
544
+ kind: "schema",
545
+ type: "unknown",
546
+ reference: unknown,
547
+ expects: "unknown",
548
+ async: false,
549
+ "~run"(dataset) {
550
+ dataset.typed = true;
551
+ return dataset;
552
+ }
553
+ });
554
+ }
555
+ __name(unknown, "unknown");
556
+ // @__NO_SIDE_EFFECTS__
557
+ function pipe(...pipe$1) {
558
+ return _standardSchema({
559
+ ...pipe$1[0],
560
+ pipe: pipe$1,
561
+ "~run"(dataset, config$1) {
562
+ for (const item of pipe$1) if (item.kind !== "metadata") {
563
+ if (dataset.issues && (item.kind === "schema" || item.kind === "transformation")) {
564
+ dataset.typed = false;
565
+ break;
566
+ }
567
+ if (!dataset.issues || !config$1.abortEarly && !config$1.abortPipeEarly) dataset = item["~run"](dataset, config$1);
568
+ }
569
+ return dataset;
570
+ }
571
+ });
572
+ }
573
+ __name(pipe, "pipe");
27
574
 
28
575
  // dist/generated/schemas.js
29
576
  var Status = looseObject({
@@ -1933,7 +2480,7 @@ var Email = looseObject({
1933
2480
  record_id: string()
1934
2481
  }))
1935
2482
  });
1936
- var File = looseObject({
2483
+ var File2 = looseObject({
1937
2484
  id: looseObject({
1938
2485
  workspace_id: string(),
1939
2486
  file_id: string()
@@ -20470,7 +21017,7 @@ var GetV2MeetingsByMeetingIdCallRecordingsByCallRecordingIdTranscriptResponse =
20470
21017
  })
20471
21018
  });
20472
21019
  var GetV2FilesResponse = looseObject({
20473
- data: array(union([lazy(() => File), lazy(() => Folder), lazy(() => ConnectedFile), lazy(() => ConnectedFolder)])),
21020
+ data: array(union([lazy(() => File2), lazy(() => Folder), lazy(() => ConnectedFile), lazy(() => ConnectedFolder)])),
20474
21021
  pagination: looseObject({
20475
21022
  next_cursor: nullable(string())
20476
21023
  })
@@ -20510,11 +21057,11 @@ var PostV2FilesUploadRequest = looseObject({
20510
21057
  parent_folder_id: optional(string())
20511
21058
  });
20512
21059
  var PostV2FilesUploadResponse = looseObject({
20513
- data: lazy(() => File)
21060
+ data: lazy(() => File2)
20514
21061
  });
20515
21062
  var GetV2FilesByFileIdResponse = looseObject({
20516
21063
  data: union([
20517
- lazy(() => File),
21064
+ lazy(() => File2),
20518
21065
  looseObject({
20519
21066
  id: looseObject({
20520
21067
  workspace_id: string(),
@@ -21048,7 +21595,7 @@ var schemas = {
21048
21595
  WorkspaceMember,
21049
21596
  Comment,
21050
21597
  Email,
21051
- File,
21598
+ File: File2,
21052
21599
  Folder,
21053
21600
  ConnectedFile,
21054
21601
  ConnectedFolder,
@@ -21239,7 +21786,7 @@ export {
21239
21786
  DeleteV2WebhooksByWebhookIdResponse,
21240
21787
  DeleteV2WorkspaceBlocklistAddressesByAddressResponse,
21241
21788
  Email,
21242
- File,
21789
+ File2 as File,
21243
21790
  Folder,
21244
21791
  GetV2ActivitiesByActivityRecordsByRecordIdResponse,
21245
21792
  GetV2ActivitiesByActivityResponse,
@@ -1,6 +1,5 @@
1
1
  import { retrying } from "@wirecat/cli-base/http";
2
- import { hostsFetch, serviceApiCommand } from "@wirecat/cli-core/cli";
3
- import { Pacer, pacePathFor } from "@wirecat/cli-core/sends";
2
+ import { hostsFetch, Pacer, pacePathFor, serviceApiCommand } from "@wirecat/cli-core";
4
3
  import { API, configuration } from "../config.js";
5
4
  import { contextOf, PACE, tokenOf } from "../context.js";
6
5
  import { DESKTOP, IDENTITY } from "../identity.js";
@@ -1,9 +1,6 @@
1
1
  import { CliError } from "@wirecat/cli-base";
2
2
  import { retrying } from "@wirecat/cli-base/http";
3
- import { openAppStore, outputFor, recalledAccount, serviceApiCall } from "@wirecat/cli-core/cli";
4
- import { crmManifestWriteCapabilities, crmManifestWrites, crmSourceFromManifest } from "@wirecat/cli-core/crm";
5
- import { addCrmCommands, openCrmStore } from "@wirecat/cli-core/crm/cli";
6
- import { Pacer, pacePathFor } from "@wirecat/cli-core/sends";
3
+ import { addCrmCommands, crmManifestWriteCapabilities, crmManifestWrites, crmSourceFromManifest, openAppStore, openCrmStore, outputFor, Pacer, pacePathFor, recalledAccount, serviceApiCall, } from "@wirecat/cli-core";
7
4
  import { Command } from "commander";
8
5
  import { ACTIVITIES } from "../activities.js";
9
6
  import { API, configuration, permissions } from "../config.js";
@@ -1,4 +1,4 @@
1
- import { baseContext, scheduleCommandFor } from "@wirecat/cli-core/cli";
1
+ import { baseContext, scheduleCommandFor } from "@wirecat/cli-core";
2
2
  import { configuration } from "../config.js";
3
3
  import { IDENTITY } from "../identity.js";
4
4
  const contextOf = (command, resolving) => {
@@ -1,5 +1,4 @@
1
- import { manifestVerify, tokenSessionCommand } from "@wirecat/cli-core/cli";
2
- import { crmAccountClaim } from "@wirecat/cli-core/crm/cli";
1
+ import { crmAccountClaim, manifestVerify, tokenSessionCommand } from "@wirecat/cli-core";
3
2
  import { API, configuration } from "../config.js";
4
3
  import { contextOf } from "../context.js";
5
4
  import { VERIFY } from "../generated/wirecat-config.js";
package/dist/config.js CHANGED
@@ -1,5 +1,4 @@
1
- import { commandPermissions, serviceApiOperations, serviceApiPermissions, settingsFor, } from "@wirecat/cli-core/cli";
2
- import { CRM_WRITE_DEFAULTS, CRM_WRITE_KEYS, crmAlsoChecks, crmManifestActivityKeys, crmManifestWriteKeys, } from "@wirecat/cli-core/crm";
1
+ import { CRM_WRITE_DEFAULTS, CRM_WRITE_KEYS, commandPermissions, crmAlsoChecks, crmManifestActivityKeys, crmManifestWriteKeys, serviceApiOperations, serviceApiPermissions, settingsFor, } from "@wirecat/cli-core";
3
2
  import { ACTIVITIES } from "./activities.js";
4
3
  import * as manifest from "./generated/manifest.js";
5
4
  import { SOURCE } from "./generated/wirecat-config.js";
package/dist/context.js CHANGED
@@ -1,4 +1,4 @@
1
- import { baseContext, environmentOf, ProfileTokenStore, refuseOffline, } from "@wirecat/cli-core/cli";
1
+ import { baseContext, environmentOf, ProfileTokenStore, refuseOffline, } from "@wirecat/cli-core";
2
2
  import { API, configuration } from "./config.js";
3
3
  import { IDENTITY } from "./identity.js";
4
4
  // Attio allows 100 reads and 25 writes a second (docs.attio.com/rest-api/guides/rate-limiting); half of the writes.