@wirecat/hubspot-cli 0.6.0 → 0.7.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.
- package/CHANGELOG.md +22 -0
- package/dist/bin/hubspot.js +2 -2
- package/dist/bundle/agent-JXICB6TB.js +40 -0
- package/dist/bundle/{all-profiles-HFVXPMF6.js → all-profiles-GVEX5MXB.js} +7 -7
- package/dist/bundle/{anthropic-VE6WR6IN.js → anthropic-GK6VBQUD.js} +2 -2
- package/dist/bundle/{app-server-GZ4DCQK7.js → app-server-JRROE463.js} +60 -60
- package/dist/bundle/{bun-2DHMKD34.js → bun-B7XTFPUF.js} +2 -2
- package/dist/bundle/{bun-sqlite-T5XTYL7L.js → bun-sqlite-QSNZ2YP4.js} +3 -3
- package/dist/bundle/{chunk-6DABKZYH.js → chunk-2FLLS5IL.js} +34 -20
- package/dist/bundle/{chunk-UVGJL753.js → chunk-2HSYAKWO.js} +51 -51
- package/dist/bundle/{chunk-PDVMYIBP.js → chunk-2IRBXFIU.js} +1166 -599
- package/dist/bundle/{chunk-YIH2A2PQ.js → chunk-2PCVKD27.js} +1 -1
- package/dist/bundle/{chunk-VR2CJFVL.js → chunk-2V5KOOJV.js} +7 -7
- package/dist/bundle/{chunk-5O5WYSSO.js → chunk-4F62XXF6.js} +495 -375
- package/dist/bundle/{chunk-67YPTVGP.js → chunk-4HZQ5UIY.js} +2 -2
- package/dist/bundle/{chunk-5WDNG4QE.js → chunk-4LHNA6LJ.js} +1 -1
- package/dist/bundle/{chunk-THGAVPRA.js → chunk-52NC5E42.js} +10 -10
- package/dist/bundle/{chunk-XRFYVVFU.js → chunk-5AVU5SF6.js} +1 -1
- package/dist/bundle/{chunk-UCGZRZJA.js → chunk-5EJ3C3JG.js} +1 -1
- package/dist/bundle/{chunk-3W5R3XAH.js → chunk-5ISQ4KJM.js} +6 -6
- package/dist/bundle/{chunk-CU76ZACK.js → chunk-5MFZYHPO.js} +2 -2
- package/dist/bundle/{chunk-K4Y2ZWOO.js → chunk-63YWTFZF.js} +3 -3
- package/dist/bundle/{chunk-GWXTVO43.js → chunk-6EHX762H.js} +6 -6
- package/dist/bundle/{chunk-YDG5FIQB.js → chunk-6IHXKMY6.js} +6 -6
- package/dist/bundle/{chunk-J76CMNWQ.js → chunk-6WKK4UZP.js} +1 -1
- package/dist/bundle/{chunk-CTN4DW2F.js → chunk-A7KGBXBT.js} +3 -3
- package/dist/bundle/{chunk-3YTTWJKL.js → chunk-ALOPYWYY.js} +1 -1
- package/dist/bundle/{chunk-Q6AC7WLD.js → chunk-B3JVNOTB.js} +2 -2
- package/dist/bundle/{chunk-5NIIXJV3.js → chunk-BQPAIGAF.js} +2 -2
- package/dist/bundle/{chunk-HZIGGAC7.js → chunk-BRBBZDMZ.js} +1 -1
- package/dist/bundle/{chunk-E27NRLJZ.js → chunk-BXXU4EXK.js} +17 -17
- package/dist/bundle/{chunk-5IPB5WLB.js → chunk-BY3NKT34.js} +10 -10
- package/dist/bundle/{chunk-HYDXA624.js → chunk-CBTWKTWN.js} +5 -5
- package/dist/bundle/{chunk-MJ24YFXZ.js → chunk-CEHBT7QX.js} +5 -5
- package/dist/bundle/{chunk-RLK2EGQD.js → chunk-DBHJIFDS.js} +28 -15
- package/dist/bundle/{chunk-EJZIEBAR.js → chunk-DIHVN5IC.js} +6 -6
- package/dist/bundle/{chunk-2VUIJ5XB.js → chunk-DMYLQX2O.js} +1 -1
- package/dist/bundle/{chunk-J2SCELII.js → chunk-DWWZAQ4N.js} +13 -13
- package/dist/bundle/{chunk-WE4JSHIG.js → chunk-GD5JTKLS.js} +1 -1
- package/dist/bundle/{chunk-R26OEZOL.js → chunk-GHBJBDTW.js} +1 -1
- package/dist/bundle/{chunk-3HS7JTPI.js → chunk-GYH2AXPO.js} +13 -13
- package/dist/bundle/{chunk-JFLKTYH5.js → chunk-GZD6BYO7.js} +5 -5
- package/dist/bundle/{chunk-AKSWXRIU.js → chunk-I5WHQH5K.js} +1 -1
- package/dist/bundle/{chunk-J4FXBF44.js → chunk-INT5JXGP.js} +1 -1
- package/dist/bundle/{chunk-KKMOKSS5.js → chunk-IRFFXKKK.js} +2 -2
- package/dist/bundle/{chunk-RLNPTES2.js → chunk-J5HHB27S.js} +4 -4
- package/dist/bundle/{chunk-GEJI27GN.js → chunk-JEUYZCWF.js} +5 -5
- package/dist/bundle/{chunk-EB53G4HO.js → chunk-JQUS4KFV.js} +2 -2
- package/dist/bundle/{chunk-GR4HZBWO.js → chunk-KGLMYQXM.js} +1 -1
- package/dist/bundle/{chunk-JDCFHZNU.js → chunk-L3DUZVBP.js} +7 -7
- package/dist/bundle/{chunk-I75ON7VM.js → chunk-LGGBKAVQ.js} +7 -7
- package/dist/bundle/{chunk-ID4GJFE7.js → chunk-LJ52BS6C.js} +6 -6
- package/dist/bundle/{chunk-ZERQSELP.js → chunk-M3JDGRXM.js} +184 -157
- package/dist/bundle/{chunk-3TLNO3VM.js → chunk-MR2BNER3.js} +1 -1
- package/dist/bundle/{chunk-NQOQG7L3.js → chunk-NUPAXK4Z.js} +1 -1
- package/dist/bundle/{chunk-LTU4BQ4S.js → chunk-OX37ZK27.js} +2 -2
- package/dist/bundle/{chunk-LHY5XGIR.js → chunk-P7N3TZLH.js} +56 -56
- package/dist/bundle/{chunk-PZ3QJDTD.js → chunk-QAQK2WXJ.js} +4 -4
- package/dist/bundle/{chunk-BU5CEMUH.js → chunk-QY7EOB66.js} +12 -12
- package/dist/bundle/{chunk-MSQGZHKM.js → chunk-RE55EPBX.js} +25 -24
- package/dist/bundle/{chunk-X2QRCFGJ.js → chunk-SBORPDIQ.js} +3 -3
- package/dist/bundle/{chunk-GHXTNKX2.js → chunk-SFFV2F3Y.js} +2 -2
- package/dist/bundle/{chunk-24HPBWKZ.js → chunk-SMEEFN65.js} +2 -2
- package/dist/bundle/{chunk-UZ2CL435.js → chunk-SVRCPPNI.js} +1 -1
- package/dist/bundle/{chunk-G6LDK6DJ.js → chunk-SZZVNPTI.js} +4 -4
- package/dist/bundle/{chunk-TXO4CJW3.js → chunk-TXCINEH6.js} +5 -5
- package/dist/bundle/{chunk-ZKTYTOF4.js → chunk-UMXA357W.js} +7 -7
- package/dist/bundle/{chunk-KDW7B7AR.js → chunk-VJQLJQHT.js} +4 -4
- package/dist/bundle/{chunk-H4W2OO35.js → chunk-WSTF2MWW.js} +1 -1
- package/dist/bundle/{chunk-TRLV5NWZ.js → chunk-WSUS3MUK.js} +478 -385
- package/dist/bundle/{chunk-M3LRSN6J.js → chunk-WWIYZN67.js} +12 -12
- package/dist/bundle/{chunk-2I2KBCS6.js → chunk-XL3NAXZY.js} +3 -3
- package/dist/bundle/{chunk-QK5HQUHB.js → chunk-XWYYFAML.js} +2 -2
- package/dist/bundle/{chunk-5VTKBGPW.js → chunk-XZLOQNS7.js} +10 -10
- package/dist/bundle/{chunk-TAPQZYXY.js → chunk-YDTFPDAJ.js} +1 -1
- package/dist/bundle/{chunk-4UEYVM46.js → chunk-YFHCKAGU.js} +3 -3
- package/dist/bundle/{chunk-TT75CEYZ.js → chunk-YGZ37OEN.js} +1 -1
- package/dist/bundle/{chunk-V7N2K5OT.js → chunk-YOVIH4QI.js} +22 -22
- package/dist/bundle/{chunk-PR7ZDMGF.js → chunk-YVMLFHWS.js} +2 -2
- package/dist/bundle/{chunk-T4MZJMEJ.js → chunk-ZH76HQDA.js} +16 -16
- package/dist/bundle/{chunk-QH47G73D.js → chunk-ZNNGK73C.js} +2 -2
- package/dist/bundle/{chunk-5ILCAAY4.js → chunk-ZNRZJIRM.js} +33 -33
- package/dist/bundle/{chunk-BM5F2ZNI.js → chunk-ZS6T2PYQ.js} +1 -1
- package/dist/bundle/command-contract-7EWUA6E6.js +40 -0
- package/dist/bundle/{command-server-entry-H6IAJNOF.js → command-server-entry-BFXXPNJO.js} +24 -24
- package/dist/bundle/{decode-TR2EC46M.js → decode-5M7R44BR.js} +2 -2
- package/dist/bundle/{echarts-7OP7I5B2.js → echarts-7MBFY6SZ.js} +2 -2
- package/dist/bundle/{embed-FLGS4LN7.js → embed-Y4GYNHRX.js} +3 -3
- package/dist/bundle/{embedder-JIXQXCP3.js → embedder-FI4T4LQB.js} +6 -6
- package/dist/bundle/{first-run-XJ2NWIK2.js → first-run-YY66AKKG.js} +6 -6
- package/dist/bundle/first-screen-U7Z63VXE.js +40 -0
- package/dist/bundle/hubspot.js +17 -17
- package/dist/bundle/{instructions-PYCYV6QE.js → instructions-SM7TKV6L.js} +1 -1
- package/dist/bundle/{meeting-combined-IHTM5H5B.js → meeting-combined-B444C4NF.js} +11 -11
- package/dist/bundle/{meeting-model-2PA5WJY5.js → meeting-model-DKLMBQXX.js} +8 -8
- package/dist/bundle/{meeting-semantic-5IH63QFV.js → meeting-semantic-C5T6UDVB.js} +2 -2
- package/dist/bundle/{node-6GTNIVBM.js → node-OS6OQF3F.js} +2 -2
- package/dist/bundle/{node-sqlite-FBCEHPNT.js → node-sqlite-2XTWZ4HL.js} +4 -4
- package/dist/bundle/{oauth-BFP4SCL5.js → oauth-BSSJ66FC.js} +4 -4
- package/dist/bundle/{open-MLU4MHGO.js → open-UZ3TKWDY.js} +2 -2
- package/dist/bundle/{openai-R7WJI6SO.js → openai-POVKFBTC.js} +12 -12
- package/dist/bundle/{process-NMNQLJHZ.js → process-A7ZJGQ6G.js} +1 -1
- package/dist/bundle/{program-Z735HPFG.js → program-Q3JFUVC6.js} +193 -102
- package/dist/bundle/{prompt-A6RM55Q4.js → prompt-TYOYTRJM.js} +2 -2
- package/dist/bundle/{recognize-ORRDV45M.js → recognize-GGFRONZT.js} +1 -1
- package/dist/bundle/{remote-UF3WSC4X.js → remote-K4SLWHMI.js} +6 -6
- package/dist/bundle/{rerank-ZSJORUGH.js → rerank-2QTKDUBV.js} +4 -4
- package/dist/bundle/{serve-4KBJ6SIA.js → serve-FG2G2X6Y.js} +6 -6
- package/dist/bundle/{server-IFK4S6LJ.js → server-KRDHBT5Q.js} +52 -52
- package/dist/bundle/server-VFKK6OS4.js +86 -0
- package/dist/bundle/{source-PBCQAG4C.js → source-XP2JNUVU.js} +64 -64
- package/dist/bundle/{sqlite-runtime-XPDUWOPG.js → sqlite-runtime-TWV7KFLA.js} +3 -3
- package/dist/bundle/{state-4M26H7NL.js → state-EFX5ZQED.js} +3 -3
- package/dist/bundle/store-LON2XRIS.js +34 -0
- package/dist/bundle/{store-3W4ZOOIB.js → store-MNQ6YQIS.js} +20 -20
- package/dist/bundle/{store-ICTY3RIF.js → store-QPVH5VPJ.js} +18 -18
- package/dist/bundle/store-maintenance-command-YEMPRNJX.js +73 -0
- package/dist/bundle/surface-UJRMT6QT.js +72 -0
- package/dist/bundle/writer-NOSHE7ZI.js +86 -0
- package/dist/crm/records.d.ts.map +1 -1
- package/dist/crm/records.js +3 -0
- package/dist/crm/records.js.map +1 -1
- package/dist/version.d.ts +1 -1
- package/dist/version.js +1 -1
- package/package.json +2 -2
- package/skills/hubspot-cli/SKILL.md +10 -3
- package/dist/bundle/agent-XB35QVOK.js +0 -40
- package/dist/bundle/command-contract-5FXCYQUS.js +0 -40
- package/dist/bundle/first-screen-U73G5CMM.js +0 -40
- package/dist/bundle/server-MNUAZWTN.js +0 -86
- package/dist/bundle/store-CDY2PW6J.js +0 -34
- package/dist/bundle/store-maintenance-command-Y7TC3I43.js +0 -73
- package/dist/bundle/surface-4LNDJZD2.js +0 -72
- package/dist/bundle/writer-WGHWQTC2.js +0 -86
|
@@ -2,13 +2,13 @@ import { createRequire as __bundleRequire } from "node:module";
|
|
|
2
2
|
const require = __bundleRequire(import.meta.url);
|
|
3
3
|
import {
|
|
4
4
|
PROVIDER
|
|
5
|
-
} from "./chunk-
|
|
5
|
+
} from "./chunk-63YWTFZF.js";
|
|
6
6
|
import {
|
|
7
7
|
accountDetails
|
|
8
|
-
} from "./chunk-
|
|
8
|
+
} from "./chunk-KGLMYQXM.js";
|
|
9
9
|
import {
|
|
10
10
|
HUBSPOT_WRITES
|
|
11
|
-
} from "./chunk-
|
|
11
|
+
} from "./chunk-SMEEFN65.js";
|
|
12
12
|
import {
|
|
13
13
|
LONGEST_PACE_WAIT_MS,
|
|
14
14
|
PACE,
|
|
@@ -39,30 +39,30 @@ import {
|
|
|
39
39
|
skillCommand,
|
|
40
40
|
upgradeCommand,
|
|
41
41
|
writeCsv
|
|
42
|
-
} from "./chunk-
|
|
43
|
-
import "./chunk-
|
|
44
|
-
import "./chunk-
|
|
42
|
+
} from "./chunk-WSUS3MUK.js";
|
|
43
|
+
import "./chunk-ALOPYWYY.js";
|
|
44
|
+
import "./chunk-SVRCPPNI.js";
|
|
45
45
|
import {
|
|
46
46
|
SOURCE_SEARCHED,
|
|
47
47
|
allAnswer,
|
|
48
48
|
historySkipsOf,
|
|
49
49
|
offsetOf,
|
|
50
50
|
refuseOffline
|
|
51
|
-
} from "./chunk-
|
|
52
|
-
import "./chunk-
|
|
53
|
-
import "./chunk-
|
|
54
|
-
import "./chunk-
|
|
51
|
+
} from "./chunk-RE55EPBX.js";
|
|
52
|
+
import "./chunk-GD5JTKLS.js";
|
|
53
|
+
import "./chunk-5ISQ4KJM.js";
|
|
54
|
+
import "./chunk-YDTFPDAJ.js";
|
|
55
55
|
import {
|
|
56
56
|
addStoreMaintenanceCommands
|
|
57
|
-
} from "./chunk-
|
|
58
|
-
import "./chunk-
|
|
59
|
-
import "./chunk-
|
|
60
|
-
import "./chunk-
|
|
61
|
-
import "./chunk-
|
|
62
|
-
import "./chunk-
|
|
63
|
-
import "./chunk-
|
|
64
|
-
import "./chunk-
|
|
65
|
-
import "./chunk-
|
|
57
|
+
} from "./chunk-P7N3TZLH.js";
|
|
58
|
+
import "./chunk-GYH2AXPO.js";
|
|
59
|
+
import "./chunk-2V5KOOJV.js";
|
|
60
|
+
import "./chunk-TXCINEH6.js";
|
|
61
|
+
import "./chunk-BY3NKT34.js";
|
|
62
|
+
import "./chunk-JQUS4KFV.js";
|
|
63
|
+
import "./chunk-SBORPDIQ.js";
|
|
64
|
+
import "./chunk-VJQLJQHT.js";
|
|
65
|
+
import "./chunk-LJ52BS6C.js";
|
|
66
66
|
import {
|
|
67
67
|
CRM_ASSIGN_OTHERS_KEY,
|
|
68
68
|
CRM_SHARED_FOLDERS,
|
|
@@ -86,6 +86,7 @@ import {
|
|
|
86
86
|
crmViewerOf,
|
|
87
87
|
customConditions,
|
|
88
88
|
customNames,
|
|
89
|
+
embedCrmActivities,
|
|
89
90
|
extractText,
|
|
90
91
|
fieldPairsOf,
|
|
91
92
|
filterableFields,
|
|
@@ -114,12 +115,12 @@ import {
|
|
|
114
115
|
wantedCodes,
|
|
115
116
|
withCustomFields,
|
|
116
117
|
withReadableDeal
|
|
117
|
-
} from "./chunk-
|
|
118
|
+
} from "./chunk-4F62XXF6.js";
|
|
118
119
|
import {
|
|
119
120
|
safeName
|
|
120
|
-
} from "./chunk-
|
|
121
|
+
} from "./chunk-WWIYZN67.js";
|
|
121
122
|
import "./chunk-HX2BE7DO.js";
|
|
122
|
-
import "./chunk-
|
|
123
|
+
import "./chunk-YGZ37OEN.js";
|
|
123
124
|
import {
|
|
124
125
|
latestVersion,
|
|
125
126
|
runUpdate,
|
|
@@ -140,14 +141,14 @@ import {
|
|
|
140
141
|
unfilteredQuery,
|
|
141
142
|
withQuery,
|
|
142
143
|
withWords
|
|
143
|
-
} from "./chunk-
|
|
144
|
-
import "./chunk-
|
|
145
|
-
import "./chunk-
|
|
146
|
-
import "./chunk-
|
|
147
|
-
import "./chunk-
|
|
148
|
-
import "./chunk-
|
|
149
|
-
import "./chunk-
|
|
150
|
-
import "./chunk-
|
|
144
|
+
} from "./chunk-QY7EOB66.js";
|
|
145
|
+
import "./chunk-XWYYFAML.js";
|
|
146
|
+
import "./chunk-JEUYZCWF.js";
|
|
147
|
+
import "./chunk-52NC5E42.js";
|
|
148
|
+
import "./chunk-B3JVNOTB.js";
|
|
149
|
+
import "./chunk-J5HHB27S.js";
|
|
150
|
+
import "./chunk-ZNNGK73C.js";
|
|
151
|
+
import "./chunk-XL3NAXZY.js";
|
|
151
152
|
import {
|
|
152
153
|
Argument,
|
|
153
154
|
Command,
|
|
@@ -191,13 +192,13 @@ import {
|
|
|
191
192
|
sharedCommand,
|
|
192
193
|
snakeKeys,
|
|
193
194
|
snakeKeysKeeping
|
|
194
|
-
} from "./chunk-
|
|
195
|
-
import "./chunk-
|
|
196
|
-
import "./chunk-
|
|
197
|
-
import "./chunk-
|
|
198
|
-
import "./chunk-
|
|
199
|
-
import "./chunk-
|
|
200
|
-
import "./chunk-
|
|
195
|
+
} from "./chunk-M3JDGRXM.js";
|
|
196
|
+
import "./chunk-LGGBKAVQ.js";
|
|
197
|
+
import "./chunk-4HZQ5UIY.js";
|
|
198
|
+
import "./chunk-QAQK2WXJ.js";
|
|
199
|
+
import "./chunk-INT5JXGP.js";
|
|
200
|
+
import "./chunk-ZH76HQDA.js";
|
|
201
|
+
import "./chunk-IRFFXKKK.js";
|
|
201
202
|
import {
|
|
202
203
|
CRM_CHANGES,
|
|
203
204
|
CRM_SCOPES,
|
|
@@ -207,48 +208,48 @@ import {
|
|
|
207
208
|
crmSettingKey,
|
|
208
209
|
seenBy,
|
|
209
210
|
viewerSql
|
|
210
|
-
} from "./chunk-
|
|
211
|
-
import "./chunk-
|
|
211
|
+
} from "./chunk-2IRBXFIU.js";
|
|
212
|
+
import "./chunk-UMXA357W.js";
|
|
212
213
|
import {
|
|
213
214
|
aheadOf,
|
|
214
215
|
dayIn
|
|
215
|
-
} from "./chunk-
|
|
216
|
-
import "./chunk-
|
|
216
|
+
} from "./chunk-5MFZYHPO.js";
|
|
217
|
+
import "./chunk-6EHX762H.js";
|
|
217
218
|
import {
|
|
218
219
|
count,
|
|
219
220
|
createTaskService,
|
|
220
221
|
text,
|
|
221
222
|
time
|
|
222
|
-
} from "./chunk-
|
|
223
|
-
import "./chunk-
|
|
224
|
-
import "./chunk-
|
|
223
|
+
} from "./chunk-YOVIH4QI.js";
|
|
224
|
+
import "./chunk-BRBBZDMZ.js";
|
|
225
|
+
import "./chunk-L3DUZVBP.js";
|
|
225
226
|
import {
|
|
226
227
|
hostFetch,
|
|
227
228
|
retrying
|
|
228
|
-
} from "./chunk-
|
|
229
|
-
import "./chunk-
|
|
230
|
-
import "./chunk-
|
|
229
|
+
} from "./chunk-4LHNA6LJ.js";
|
|
230
|
+
import "./chunk-GZD6BYO7.js";
|
|
231
|
+
import "./chunk-A7KGBXBT.js";
|
|
231
232
|
import {
|
|
232
233
|
DESKTOP,
|
|
233
234
|
IDENTITY,
|
|
234
235
|
PACKAGE,
|
|
235
236
|
SKILL
|
|
236
|
-
} from "./chunk-
|
|
237
|
-
import "./chunk-
|
|
237
|
+
} from "./chunk-6IHXKMY6.js";
|
|
238
|
+
import "./chunk-MR2BNER3.js";
|
|
238
239
|
import "./chunk-EH6ZEJGT.js";
|
|
239
|
-
import "./chunk-
|
|
240
|
-
import "./chunk-
|
|
240
|
+
import "./chunk-2FLLS5IL.js";
|
|
241
|
+
import "./chunk-DIHVN5IC.js";
|
|
241
242
|
import {
|
|
242
243
|
installerOf
|
|
243
244
|
} from "./chunk-745FMNI5.js";
|
|
244
245
|
import {
|
|
245
246
|
fieldsOf
|
|
246
|
-
} from "./chunk-
|
|
247
|
+
} from "./chunk-SZZVNPTI.js";
|
|
247
248
|
import {
|
|
248
249
|
foldName
|
|
249
|
-
} from "./chunk-
|
|
250
|
-
import "./chunk-
|
|
251
|
-
import "./chunk-
|
|
250
|
+
} from "./chunk-BXXU4EXK.js";
|
|
251
|
+
import "./chunk-YVMLFHWS.js";
|
|
252
|
+
import "./chunk-I5WHQH5K.js";
|
|
252
253
|
import {
|
|
253
254
|
CRM_ACTIVITY_KINDS,
|
|
254
255
|
CRM_KINDS,
|
|
@@ -259,26 +260,26 @@ import {
|
|
|
259
260
|
normalCrmUserId,
|
|
260
261
|
parseDecimal,
|
|
261
262
|
scaleOf
|
|
262
|
-
} from "./chunk-
|
|
263
|
-
import "./chunk-
|
|
264
|
-
import "./chunk-
|
|
263
|
+
} from "./chunk-DBHJIFDS.js";
|
|
264
|
+
import "./chunk-GHBJBDTW.js";
|
|
265
|
+
import "./chunk-2PCVKD27.js";
|
|
265
266
|
import {
|
|
266
267
|
SAVE_HELP,
|
|
267
268
|
defineQuery,
|
|
268
269
|
queryFieldsOf,
|
|
269
270
|
timezoneOf,
|
|
270
271
|
zonedMoment
|
|
271
|
-
} from "./chunk-
|
|
272
|
+
} from "./chunk-2HSYAKWO.js";
|
|
272
273
|
import "./chunk-TCSVW7BA.js";
|
|
273
|
-
import "./chunk-
|
|
274
|
+
import "./chunk-CEHBT7QX.js";
|
|
274
275
|
import "./chunk-D72URWJE.js";
|
|
275
276
|
import {
|
|
276
277
|
readSecret
|
|
277
|
-
} from "./chunk-
|
|
278
|
-
import "./chunk-
|
|
279
|
-
import "./chunk-
|
|
280
|
-
import "./chunk-
|
|
281
|
-
import "./chunk-
|
|
278
|
+
} from "./chunk-OX37ZK27.js";
|
|
279
|
+
import "./chunk-ZS6T2PYQ.js";
|
|
280
|
+
import "./chunk-DMYLQX2O.js";
|
|
281
|
+
import "./chunk-CBTWKTWN.js";
|
|
282
|
+
import "./chunk-WSTF2MWW.js";
|
|
282
283
|
import {
|
|
283
284
|
renderPretty,
|
|
284
285
|
resolvePaths
|
|
@@ -307,7 +308,7 @@ import {
|
|
|
307
308
|
CliError,
|
|
308
309
|
isCliError
|
|
309
310
|
} from "./chunk-AP3CWDRK.js";
|
|
310
|
-
import "./chunk-
|
|
311
|
+
import "./chunk-6WKK4UZP.js";
|
|
311
312
|
import {
|
|
312
313
|
__export,
|
|
313
314
|
__name
|
|
@@ -316,7 +317,7 @@ import {
|
|
|
316
317
|
// dist/program.js
|
|
317
318
|
import { join as join4 } from "node:path";
|
|
318
319
|
|
|
319
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
320
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.748.0_@wirecat+cli-base@0.127.0_commander@15.0.0_esbuild@0.28.2_typ_80da9f03871bc395375181cc05991961/node_modules/@wirecat/cli-core/dist/update/index.js
|
|
320
321
|
import { realpathSync } from "node:fs";
|
|
321
322
|
import { fileURLToPath } from "node:url";
|
|
322
323
|
var npmRegistry = /* @__PURE__ */ __name(() => hostFetch({ hosts: ["registry.npmjs.org"] }), "npmRegistry");
|
|
@@ -7080,7 +7081,7 @@ var apiCommand = /* @__PURE__ */ __name(() => {
|
|
|
7080
7081
|
});
|
|
7081
7082
|
}, "apiCommand");
|
|
7082
7083
|
|
|
7083
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
7084
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.748.0_@wirecat+cli-base@0.127.0_commander@15.0.0_esbuild@0.28.2_typ_80da9f03871bc395375181cc05991961/node_modules/@wirecat/cli-core/dist/crm/stage-tasks.js
|
|
7084
7085
|
var DAY = 864e5;
|
|
7085
7086
|
var openStageTasks = /* @__PURE__ */ __name(async (store, account, now, { history = false } = {}) => {
|
|
7086
7087
|
const rules = await store.crm.stageTasks(account);
|
|
@@ -7117,7 +7118,7 @@ var openStageTasks = /* @__PURE__ */ __name(async (store, account, now, { histor
|
|
|
7117
7118
|
return opened;
|
|
7118
7119
|
}, "openStageTasks");
|
|
7119
7120
|
|
|
7120
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
7121
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.748.0_@wirecat+cli-base@0.127.0_commander@15.0.0_esbuild@0.28.2_typ_80da9f03871bc395375181cc05991961/node_modules/@wirecat/cli-core/dist/crm/cli/account.js
|
|
7121
7122
|
import { join } from "node:path";
|
|
7122
7123
|
var SHARED = new Set(Object.values(CRM_SHARED_FOLDERS));
|
|
7123
7124
|
var isShared = /* @__PURE__ */ __name((profile) => SHARED.has(profile.toLowerCase()), "isShared");
|
|
@@ -7223,7 +7224,7 @@ var crmAccountCommand = /* @__PURE__ */ __name((app, options) => annotate(new Co
|
|
|
7223
7224
|
...options.resolveSettings ? { resolveSettings: options.resolveSettings } : {}
|
|
7224
7225
|
}), { effects: LOCAL_WRITE }).hook("preAction", (_, action) => refuseSharedDelete(app, options, action))), "crmAccountCommand");
|
|
7225
7226
|
|
|
7226
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
7227
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.748.0_@wirecat+cli-base@0.127.0_commander@15.0.0_esbuild@0.28.2_typ_80da9f03871bc395375181cc05991961/node_modules/@wirecat/cli-core/dist/crm/digest.js
|
|
7227
7228
|
var HOUR = 36e5;
|
|
7228
7229
|
var SHOWN = 7;
|
|
7229
7230
|
var STALE_HOURS = 24;
|
|
@@ -7367,7 +7368,7 @@ var healthOf = /* @__PURE__ */ __name(async (store, account, { now, profile }) =
|
|
|
7367
7368
|
return stale > STALE_HOURS ? [{ ...named, stale_hours: Math.floor(stale) }] : [];
|
|
7368
7369
|
}, "healthOf");
|
|
7369
7370
|
|
|
7370
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
7371
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.748.0_@wirecat+cli-base@0.127.0_commander@15.0.0_esbuild@0.28.2_typ_80da9f03871bc395375181cc05991961/node_modules/@wirecat/cli-core/dist/crm/cli/csv.js
|
|
7371
7372
|
var csvFormatOption = /* @__PURE__ */ __name(() => annotateOption(new Option("--format <format>", "csv: this page as a table for a spreadsheet; --json=a,b picks its columns").choices(["csv"]), { mcp: false }), "csvFormatOption");
|
|
7372
7373
|
var DEAL_CSV_COLUMNS = [
|
|
7373
7374
|
"ref",
|
|
@@ -7489,7 +7490,7 @@ var renderCsv = /* @__PURE__ */ __name((command, open2, read, defaults = DEAL_CS
|
|
|
7489
7490
|
});
|
|
7490
7491
|
}, "renderCsv");
|
|
7491
7492
|
|
|
7492
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
7493
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.748.0_@wirecat+cli-base@0.127.0_commander@15.0.0_esbuild@0.28.2_typ_80da9f03871bc395375181cc05991961/node_modules/@wirecat/cli-core/dist/crm/cli/records.js
|
|
7493
7494
|
var time2 = nullable(isoTime);
|
|
7494
7495
|
var metadata = optional(record(string(), strictObject({
|
|
7495
7496
|
label: nullable(string()),
|
|
@@ -7710,7 +7711,7 @@ var addCrmRecordCommands = /* @__PURE__ */ __name((program, options) => {
|
|
|
7710
7711
|
});
|
|
7711
7712
|
});
|
|
7712
7713
|
});
|
|
7713
|
-
example(answerEntity(annotate(group.command("show"), { effects: REMOTE_READ, offline: false }), noun.entity, noun.schema).description(`one of the CRM's ${noun.what}, read live, with its phones and e-mails; one that is not your client counts toward the day's limit when the CRM sets one`).argument(`<${noun.kind}>`, `the CRM's id of the ${noun.kind}, as list prints it, or its exact name`), `${noun.noun} show 42`, `${noun.noun} show "Anna Example" --json`).action(async (given, _opts, command) => {
|
|
7714
|
+
example(answerEntity(annotate(group.command("show"), { effects: REMOTE_READ, offline: false }), noun.entity, noun.schema).description(`one of the CRM's ${noun.what}, read live, with its phones and e-mails; one that is not your client counts toward the day's limit when the CRM sets one`).argument(`<${noun.kind}>`, `the CRM's id of the ${noun.kind}, as list prints it, the ${noun.kind}:<id> a deal gives, or its exact name`), `${noun.noun} show 42`, `${noun.noun} show "Anna Example" --json`).action(async (given, _opts, command) => {
|
|
7714
7715
|
await within(command, async (run3) => {
|
|
7715
7716
|
const found = await recordNamed(run3, noun, given);
|
|
7716
7717
|
await quotaOf2(run3).spend(noun.kind, found);
|
|
@@ -7734,8 +7735,22 @@ var byIdOrNone = /* @__PURE__ */ __name(async (run3, noun, id) => {
|
|
|
7734
7735
|
throw error;
|
|
7735
7736
|
}
|
|
7736
7737
|
}, "byIdOrNone");
|
|
7738
|
+
var storedRecord = /* @__PURE__ */ __name(async (run3, noun, ref) => {
|
|
7739
|
+
const ids = await run3.store.crm.externalIdsOf(run3.account, ref);
|
|
7740
|
+
if (ids.length > 1)
|
|
7741
|
+
throw new CliError("validation_error", `${ref} is ${ids.length} records of the CRM; name one by its id`, {
|
|
7742
|
+
reason: "crm.record-ambiguous",
|
|
7743
|
+
candidates: ids.map((id) => ({ id }))
|
|
7744
|
+
});
|
|
7745
|
+
const found = ids[0] ? await sourceWith(run3, "get", noun.what).get(noun.kind, ids[0]) : null;
|
|
7746
|
+
if (!found)
|
|
7747
|
+
throw new CliError("not_found", `the copy holds no CRM ${noun.kind} as ${ref}, or this sign-in cannot see it`);
|
|
7748
|
+
return found;
|
|
7749
|
+
}, "storedRecord");
|
|
7737
7750
|
var recordNamed = /* @__PURE__ */ __name(async (run3, noun, given) => {
|
|
7738
7751
|
const id = given.trim();
|
|
7752
|
+
if (id.startsWith(`${noun.kind}:`) && /^\w+:\d+$/.test(id))
|
|
7753
|
+
return storedRecord(run3, noun, id);
|
|
7739
7754
|
const byId = RECORD_ID.test(id) ? await byIdOrNone(run3, noun, id) : null;
|
|
7740
7755
|
if (byId)
|
|
7741
7756
|
return byId;
|
|
@@ -7813,16 +7828,28 @@ var addRecordWrites = /* @__PURE__ */ __name((group, noun, { within, example, wr
|
|
|
7813
7828
|
if (!writes?.kinds.includes(noun.kind))
|
|
7814
7829
|
return;
|
|
7815
7830
|
const person = noun.kind === "person";
|
|
7831
|
+
const written = writes.fields?.[noun.kind];
|
|
7832
|
+
const takes = /* @__PURE__ */ __name((field) => !written || written.includes(field), "takes");
|
|
7816
7833
|
const fields = /* @__PURE__ */ __name((command2) => {
|
|
7817
7834
|
command2.option("--name <name>", person ? "the whole name" : "the company's name");
|
|
7818
|
-
if (person)
|
|
7819
|
-
command2.option("--first-name <name>", "the first name; empty clears it").option("--last-name <name>", "the last name; empty clears it")
|
|
7835
|
+
if (person) {
|
|
7836
|
+
command2.option("--first-name <name>", "the first name; empty clears it").option("--last-name <name>", "the last name; empty clears it");
|
|
7837
|
+
if (takes("position"))
|
|
7838
|
+
command2.option("--position <title>", "the job title; empty clears it");
|
|
7839
|
+
}
|
|
7820
7840
|
const repeated = /* @__PURE__ */ __name((value, previous = []) => [...previous, value], "repeated");
|
|
7821
|
-
|
|
7822
|
-
|
|
7823
|
-
|
|
7824
|
-
|
|
7825
|
-
|
|
7841
|
+
if (takes("emails"))
|
|
7842
|
+
command2.option("--email <address>", "an e-mail address to give it; repeat it for more; replaces its list, and an empty one clears it", repeated);
|
|
7843
|
+
if (takes("phones"))
|
|
7844
|
+
command2.option("--phone <phone>", "a phone number to give it, in international form starting with +; repeat it for more; replaces its list, and an empty one clears it", repeated);
|
|
7845
|
+
if (takes("owner"))
|
|
7846
|
+
command2.option("--owner <user>", "the CRM user it is assigned to; anyone but the sign-in's own user checks crm.assign-others");
|
|
7847
|
+
if (takes("custom"))
|
|
7848
|
+
command2.option("--field <key=value>", "one of the CRM's own fields, by its code or label as `fields list` prints them, and its value; a list field takes its option's label or id; repeat it for more fields, or for each value of a multiple field; an empty value clears it", (value, previous = []) => {
|
|
7849
|
+
if (value.indexOf("=") < 1)
|
|
7850
|
+
throw new CliError("validation_error", "--field takes <key>=<value>");
|
|
7851
|
+
return [...previous, value];
|
|
7852
|
+
}, []);
|
|
7826
7853
|
if (writes.idempotent)
|
|
7827
7854
|
command2.option("--operation-id <id>", "the operation_id a write that ended in outcome_unknown named: the CRM answers the repeat from its record");
|
|
7828
7855
|
return command2;
|
|
@@ -7870,7 +7897,7 @@ var addRecordWrites = /* @__PURE__ */ __name((group, noun, { within, example, wr
|
|
|
7870
7897
|
}, "addRecordWrites");
|
|
7871
7898
|
var idOf = /* @__PURE__ */ __name((opts) => opts.operationId === void 0 ? {} : { operationId: opts.operationId }, "idOf");
|
|
7872
7899
|
|
|
7873
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
7900
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.748.0_@wirecat+cli-base@0.127.0_commander@15.0.0_esbuild@0.28.2_typ_80da9f03871bc395375181cc05991961/node_modules/@wirecat/cli-core/dist/crm/cli/activities.js
|
|
7874
7901
|
var MOST2 = 500;
|
|
7875
7902
|
var nullableText = nullable(text);
|
|
7876
7903
|
var REFS = ["deal", "lead", "person", "organization"];
|
|
@@ -8028,7 +8055,7 @@ var addActivityWrites = /* @__PURE__ */ __name((group, options) => {
|
|
|
8028
8055
|
const task = kinds.includes("task");
|
|
8029
8056
|
example(write("create", `add a ${kinds.join(" or ")} to records of the CRM, then store the CRM's copy of it when the activities setting is on`).addArgument(new Argument("<kind>", "what to add").choices(kinds)).option(
|
|
8030
8057
|
"--subject <ref>",
|
|
8031
|
-
`a record it is on: ${leads ? "deal:<id
|
|
8058
|
+
`a record it is on: ${leads ? "deal:<id>, lead:<id>" : "deal:<id>"}, person:<id> or organization:<id> as a list or deals show gives it, or person:crm:<id> or organization:crm:<id> by the CRM's id as people list and organizations list print it; repeat it for more`,
|
|
8032
8059
|
(value, previous = []) => [...previous, value],
|
|
8033
8060
|
// The empty default marks the flag as repeatable, so an agent's tool takes a list.
|
|
8034
8061
|
[]
|
|
@@ -8063,7 +8090,7 @@ var writtenOf = /* @__PURE__ */ __name((run3, activity, on) => ({
|
|
|
8063
8090
|
untrusted: UNTRUSTED
|
|
8064
8091
|
}), "writtenOf");
|
|
8065
8092
|
|
|
8066
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
8093
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.748.0_@wirecat+cli-base@0.127.0_commander@15.0.0_esbuild@0.28.2_typ_80da9f03871bc395375181cc05991961/node_modules/@wirecat/cli-core/dist/crm/cli/changes.js
|
|
8067
8094
|
var MOST3 = 500;
|
|
8068
8095
|
var DAY2 = 864e5;
|
|
8069
8096
|
var nullableText2 = nullable(text);
|
|
@@ -8292,7 +8319,7 @@ var pipelineOf2 = /* @__PURE__ */ __name(async (run3, value) => {
|
|
|
8292
8319
|
}) : new CliError("not_found", `no pipeline ${value} in this account`, { reason: "pipeline.not-found" });
|
|
8293
8320
|
}, "pipelineOf");
|
|
8294
8321
|
|
|
8295
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
8322
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.748.0_@wirecat+cli-base@0.127.0_commander@15.0.0_esbuild@0.28.2_typ_80da9f03871bc395375181cc05991961/node_modules/@wirecat/cli-core/dist/crm/cli/files.js
|
|
8296
8323
|
import { createHash } from "node:crypto";
|
|
8297
8324
|
import { chmodSync, constants, copyFileSync, existsSync, linkSync, mkdirSync, readFileSync, renameSync, rmSync } from "node:fs";
|
|
8298
8325
|
import { open } from "node:fs/promises";
|
|
@@ -8829,7 +8856,7 @@ var syncFiles = /* @__PURE__ */ __name(async (context, outOfTime, deadline = (ms
|
|
|
8829
8856
|
return report;
|
|
8830
8857
|
}, "syncFiles");
|
|
8831
8858
|
|
|
8832
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
8859
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.748.0_@wirecat+cli-base@0.127.0_commander@15.0.0_esbuild@0.28.2_typ_80da9f03871bc395375181cc05991961/node_modules/@wirecat/cli-core/dist/crm/cli/pipeline-view.js
|
|
8833
8860
|
var sumOf = /* @__PURE__ */ __name((amounts) => amounts.map(({ amount, currency }) => `${groupDigits(amount)} ${currency}`).join(", ") || "\u2014", "sumOf");
|
|
8834
8861
|
var percent = /* @__PURE__ */ __name((share) => share === null ? "\u2014" : `${Math.round(share * 100)}%`, "percent");
|
|
8835
8862
|
var openStages = /* @__PURE__ */ __name((stages) => {
|
|
@@ -8875,12 +8902,14 @@ ${outcomes.join("\n")}`
|
|
|
8875
8902
|
].join("\n\n");
|
|
8876
8903
|
}, "pipelineView");
|
|
8877
8904
|
|
|
8878
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
8905
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.748.0_@wirecat+cli-base@0.127.0_commander@15.0.0_esbuild@0.28.2_typ_80da9f03871bc395375181cc05991961/node_modules/@wirecat/cli-core/dist/crm/cli/search-all.js
|
|
8879
8906
|
var SEARCHED = ["crm", ...SOURCE_SEARCHED];
|
|
8880
8907
|
var DEFAULT_LIMIT = 20;
|
|
8881
8908
|
var addCrmSearchAll = /* @__PURE__ */ __name((searches, { within, app, example, viewerOf: viewerOf2, leads = true }) => {
|
|
8882
8909
|
const deals = leads ? "deals and leads" : "deals";
|
|
8883
|
-
const all = annotate(new Command("all"), { effects: LOCAL_READ, partial: true, output: { entity: "hit" } }).summary(`search stored ${deals}, messages, notes, calendar events and meetings`).description(`search the CRM's ${deals} by the words of their title, company, contacts and activities, and the messages, notes, calendar events and meetings other WireCat tools stored \u2014 best match first. Use it when you do not know where something was written`).argument("<query...>", `words and "phrases"; ${deals} match the words of their title, company, contacts and activities`).addHelpText("after",
|
|
8910
|
+
const all = annotate(new Command("all"), { effects: LOCAL_READ, partial: true, output: { entity: "hit" } }).summary(`search stored ${deals}, messages, notes, calendar events and meetings`).description(`search the CRM's ${deals} by the words of their title, company, contacts and activities, and the messages, notes, calendar events and meetings other WireCat tools stored \u2014 best match first. Use it when you do not know where something was written`).argument("<query...>", `words and "phrases"; ${deals} match the words of their title, company, contacts and activities`).addHelpText("after", `
|
|
8911
|
+
It finds ${deals} by the meaning of their activities too, in other words or another language, once \`sync --embed\` has built their vectors with a downloaded model; until then it says it searched by words only.
|
|
8912
|
+
` + SAVE_HELP);
|
|
8884
8913
|
searches.addCommand(searchAllOptions(all, SEARCHED));
|
|
8885
8914
|
example(all, "search all Example LLC", "search all website --only crm --json");
|
|
8886
8915
|
all.action(async (words, _opts, leaf) => {
|
|
@@ -8890,7 +8919,7 @@ var addCrmSearchAll = /* @__PURE__ */ __name((searches, { within, app, example,
|
|
|
8890
8919
|
throw new CliError("permission_error", "this process is locked to one profile; search all reads its own CRM account only, without --source", { reason: "profile.locked" });
|
|
8891
8920
|
const asked = opts.only ?? SEARCHED;
|
|
8892
8921
|
const denied = deniedKinds(leaf, app, [
|
|
8893
|
-
...asked.includes("crm") ? [...DEAL_KINDS, "crm_file"] : [],
|
|
8922
|
+
...asked.includes("crm") ? [...DEAL_KINDS, "crm_file", "crm_activity"] : [],
|
|
8894
8923
|
...asked.filter((one) => one !== "crm" && one !== "mail")
|
|
8895
8924
|
]);
|
|
8896
8925
|
const out = new Set(denied.map(({ kind }) => kind));
|
|
@@ -8920,6 +8949,7 @@ var addCrmSearchAll = /* @__PURE__ */ __name((searches, { within, app, example,
|
|
|
8920
8949
|
...crmKinds.length < DEAL_KINDS.length ? { crmKinds } : {},
|
|
8921
8950
|
crmViewers: viewers,
|
|
8922
8951
|
...out.has("crm_file") ? { crmFiles: false } : {},
|
|
8952
|
+
...out.has("crm_activity") ? { crmActivities: false } : {},
|
|
8923
8953
|
...opts.source === void 0 ? {} : { source: opts.source },
|
|
8924
8954
|
...alone ? { scope: { crm: [run3.account] } } : {}
|
|
8925
8955
|
}, { app, hintCommand: commandAt(rootOf2(leaf), "models download") ? app.command : null }, void 0, meaningLane({ env, messenger: { app }, store: /* @__PURE__ */ __name(async () => run3.store, "store") }));
|
|
@@ -8930,6 +8960,11 @@ var addCrmSearchAll = /* @__PURE__ */ __name((searches, { within, app, example,
|
|
|
8930
8960
|
note(`${resource ?? source} not searched: ${reason}`);
|
|
8931
8961
|
if (!found.items.length)
|
|
8932
8962
|
note("nothing found in what the local store holds");
|
|
8963
|
+
const off = found.crm?.needsVectors && !await run3.store.crm.activitiesOn(run3.account);
|
|
8964
|
+
const build = off ? `\`${lineOf(leaf, "config set activities on")}\`, then \`${lineOf(leaf, "sync --embed")}\`, copy the activities and build` : `\`${lineOf(leaf, "sync --embed")}\` builds`;
|
|
8965
|
+
const vectors = found.crm?.needsVectors ? `deals and leads were found by words only: ${found.crm.meaningSkipped}; ${build} the vectors that find them by the meaning of their activities` : void 0;
|
|
8966
|
+
if (vectors)
|
|
8967
|
+
note(vectors);
|
|
8933
8968
|
const skips = await historySkipsOf(run3.store, found.accounts).catch(() => []);
|
|
8934
8969
|
const again = {
|
|
8935
8970
|
query: words.join(" "),
|
|
@@ -8937,12 +8972,64 @@ var addCrmSearchAll = /* @__PURE__ */ __name((searches, { within, app, example,
|
|
|
8937
8972
|
...opts.source === void 0 ? {} : { source: opts.source },
|
|
8938
8973
|
...opts.exact ? { exact: true } : {}
|
|
8939
8974
|
};
|
|
8940
|
-
|
|
8975
|
+
const body = allAnswer("search all", found, { limit, page: opts.page ?? 1, again }, opts.exact === true, skips, denied);
|
|
8976
|
+
return vectors ? { ...body, missing: [...body.missing ?? [], { field: "found_by", why: vectors }] } : body;
|
|
8941
8977
|
});
|
|
8942
8978
|
});
|
|
8943
8979
|
}, "addCrmSearchAll");
|
|
8944
8980
|
|
|
8945
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
8981
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.748.0_@wirecat+cli-base@0.127.0_commander@15.0.0_esbuild@0.28.2_typ_80da9f03871bc395375181cc05991961/node_modules/@wirecat/cli-core/dist/crm/cli/sync-embed.js
|
|
8982
|
+
var EMBED_MAX = 600;
|
|
8983
|
+
var crmSyncEmbeddings = strictObject({
|
|
8984
|
+
model: text,
|
|
8985
|
+
embedded: count,
|
|
8986
|
+
left: boolean(),
|
|
8987
|
+
stopped: optional(picklist(["deadline", "cancelled"])),
|
|
8988
|
+
remaining: optional(count)
|
|
8989
|
+
});
|
|
8990
|
+
var syncEmbeddings = /* @__PURE__ */ __name(async (command, store, report, app, again) => {
|
|
8991
|
+
if (report.stopped)
|
|
8992
|
+
return { item: {}, issues: [] };
|
|
8993
|
+
const { env, deadline, signal } = environmentOf(command);
|
|
8994
|
+
const ends = deadline?.();
|
|
8995
|
+
try {
|
|
8996
|
+
const embeddings = await embedCrmActivities(store, {
|
|
8997
|
+
maxChunks: EMBED_MAX,
|
|
8998
|
+
...ends ? { deadline: ends } : {},
|
|
8999
|
+
...signal ? { signal } : {},
|
|
9000
|
+
...env ? { env } : {},
|
|
9001
|
+
...commandAt(rootOf2(command), "models download") ? { command: app.command } : {}
|
|
9002
|
+
});
|
|
9003
|
+
if (!embeddings.left)
|
|
9004
|
+
return { item: { embeddings }, issues: [] };
|
|
9005
|
+
return {
|
|
9006
|
+
item: { embeddings },
|
|
9007
|
+
issues: [],
|
|
9008
|
+
next: [
|
|
9009
|
+
{
|
|
9010
|
+
kind: "command",
|
|
9011
|
+
step: "crm.sync",
|
|
9012
|
+
command: "sync",
|
|
9013
|
+
args: Object.fromEntries(Object.entries({ ...again, embed: true }).filter(([, value]) => value !== void 0)),
|
|
9014
|
+
why: `${embeddings.remaining === void 0 ? "some" : embeddings.remaining} activity chunks have no vectors yet, so search all may miss their deals by meaning; running sync --embed again embeds the next ones`,
|
|
9015
|
+
safe_to_auto_execute: true
|
|
9016
|
+
}
|
|
9017
|
+
]
|
|
9018
|
+
};
|
|
9019
|
+
} catch (error) {
|
|
9020
|
+
if (signal?.aborted || !isCliError(error))
|
|
9021
|
+
throw error;
|
|
9022
|
+
const reason = error.details.reason;
|
|
9023
|
+
return {
|
|
9024
|
+
item: {},
|
|
9025
|
+
issues: [
|
|
9026
|
+
{ code: error.code, reason: typeof reason === "string" ? reason : "sync.failed", source: "crm:embeddings" }
|
|
9027
|
+
]
|
|
9028
|
+
};
|
|
9029
|
+
}
|
|
9030
|
+
}, "syncEmbeddings");
|
|
9031
|
+
|
|
9032
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.748.0_@wirecat+cli-base@0.127.0_commander@15.0.0_esbuild@0.28.2_typ_80da9f03871bc395375181cc05991961/node_modules/@wirecat/cli-core/dist/cli/profile-store.js
|
|
8946
9033
|
import { mkdtempSync, rmSync as rmSync2 } from "node:fs";
|
|
8947
9034
|
import { tmpdir } from "node:os";
|
|
8948
9035
|
import { join as join3 } from "node:path";
|
|
@@ -8991,10 +9078,10 @@ var withProfile = /* @__PURE__ */ __name(async ({ app, profile, open: open2 }, e
|
|
|
8991
9078
|
}
|
|
8992
9079
|
}, "withProfile");
|
|
8993
9080
|
|
|
8994
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
9081
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.748.0_@wirecat+cli-base@0.127.0_commander@15.0.0_esbuild@0.28.2_typ_80da9f03871bc395375181cc05991961/node_modules/@wirecat/cli-core/dist/crm/cli/store.js
|
|
8995
9082
|
var openCrmStore = openProfileStore;
|
|
8996
9083
|
|
|
8997
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
9084
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.748.0_@wirecat+cli-base@0.127.0_commander@15.0.0_esbuild@0.28.2_typ_80da9f03871bc395375181cc05991961/node_modules/@wirecat/cli-core/dist/crm/cli/index.js
|
|
8998
9085
|
var MOST4 = 500;
|
|
8999
9086
|
var STAGE_REF = /^stage:\d+$/;
|
|
9000
9087
|
var timeField = /* @__PURE__ */ __name((name, example, relation) => nativeField({ name, type: "time", operators: ["term", "range"], example, relation }), "timeField");
|
|
@@ -9086,7 +9173,8 @@ var crmSync = strictObject({
|
|
|
9086
9173
|
stopped: optional(picklist(["requests", "deadline", "cancelled"])),
|
|
9087
9174
|
progress: strictObject({ requests: count, saved: count, steps: count }),
|
|
9088
9175
|
hint: optional(text),
|
|
9089
|
-
group_hint: optional(text)
|
|
9176
|
+
group_hint: optional(text),
|
|
9177
|
+
embeddings: optional(crmSyncEmbeddings)
|
|
9090
9178
|
});
|
|
9091
9179
|
var crmSyncProgress = strictObject({
|
|
9092
9180
|
kind: picklist(CRM_KINDS),
|
|
@@ -9165,7 +9253,7 @@ var addCrmCommandsDefinition = /* @__PURE__ */ __name((program, options) => {
|
|
|
9165
9253
|
const hasLeads = options.leads !== false;
|
|
9166
9254
|
const dealsAndLeads = hasLeads ? "deals and leads" : "deals";
|
|
9167
9255
|
example(answerEntity(annotate(program.command("sync"), { effects: FETCH, offline: false, cooperative: true, partial: true }), "crm_sync", crmSync).description(`bring the CRM's copy in the local store up to date: pipelines, companies, contacts, ${dealsAndLeads} that changed since the last sync, or everything with --rescan; a run stops before its deadline or --max-pages and the next one goes on from there`).addHelpText("after", `
|
|
9168
|
-
With the activities setting on, it also copies the activities and tasks on the ${dealsAndLeads} it keeps. Then each ${hasLeads ? "deal or lead" : "deal"} that moved into a stage the stage-tasks setting names opens a local task, once per move.`), "sync", "sync --rescan", "sync --
|
|
9256
|
+
With the activities setting on, it also copies the activities and tasks on the ${dealsAndLeads} it keeps. Then each ${hasLeads ? "deal or lead" : "deal"} that moved into a stage the stage-tasks setting names opens a local task, once per move. With --embed it then indexes the activities' text with a model already downloaded, so search all finds their deals and leads by meaning, not only by words.`), "sync", "sync --rescan", "sync --embed").option("--rescan", "list everything again, every id too, dropping a round in progress").option("--max-pages <pages>", "at most this many requests to the CRM in this run", integer(1e5)).option("--embed", "also index new activities and tasks for search all by meaning, with a model already downloaded").action(async (opts, command) => {
|
|
9169
9257
|
const { signal } = environmentOf(command);
|
|
9170
9258
|
await within(command, async (run3) => {
|
|
9171
9259
|
const source = run3.source();
|
|
@@ -9183,13 +9271,14 @@ With the activities setting on, it also copies the activities and tasks on the $
|
|
|
9183
9271
|
const retried = failed.filter((one) => one.setting === void 0);
|
|
9184
9272
|
const settings = [...new Set(failed.flatMap((one) => one.setting ?? []))];
|
|
9185
9273
|
const timeout = command.optsWithGlobals().timeout;
|
|
9274
|
+
const again = { max_pages: opts.maxPages, timeout, embed: opts.embed };
|
|
9186
9275
|
const stuck = report.state === "partial" && report.progress.steps === 0 && failed.length === 0;
|
|
9187
9276
|
const next = retried.length || report.state === "partial" && !stuck && failed.length === 0 ? [
|
|
9188
9277
|
{
|
|
9189
9278
|
kind: "command",
|
|
9190
9279
|
step: "crm.sync",
|
|
9191
9280
|
command: "sync",
|
|
9192
|
-
args: Object.fromEntries(Object.entries(
|
|
9281
|
+
args: Object.fromEntries(Object.entries(again).filter(([, value]) => value !== void 0)),
|
|
9193
9282
|
why: retried.length ? "a kind failed to sync; running sync again retries it" : "the sync stopped before its end to answer in time; running it again goes on from there",
|
|
9194
9283
|
safe_to_auto_execute: true
|
|
9195
9284
|
}
|
|
@@ -9198,6 +9287,7 @@ With the activities setting on, it also copies the activities and tasks on the $
|
|
|
9198
9287
|
const fixes = settings.map((setting) => lineOf(command, `config set ${setting} <value>`));
|
|
9199
9288
|
const hint = failed.length ? `${failed.map((one) => `${one.kind}: ${one.error}`).join("; ")} \u2014 ${fixes.length ? `fix the setting: ${fixes.join("; ")}` : "run sync again to retry"}` : stuck ? `this run moved nothing on: raise --timeout or --max-pages, then run sync again; see progress: ${progressAt}` : report.state === "partial" ? `run sync again to continue; see progress: ${progressAt}` : void 0;
|
|
9200
9289
|
const { hint: _hint, ...rest } = report;
|
|
9290
|
+
const embedded = opts.embed ? await syncEmbeddings(command, run3.store, report, options.app, again) : void 0;
|
|
9201
9291
|
const issues = [
|
|
9202
9292
|
...failed.map((one) => ({
|
|
9203
9293
|
code: one.setting === void 0 ? "provider_error" : "validation_error",
|
|
@@ -9208,12 +9298,13 @@ With the activities setting on, it also copies the activities and tasks on the $
|
|
|
9208
9298
|
code: "validation_error",
|
|
9209
9299
|
reason: one.reason,
|
|
9210
9300
|
source: one.externalId === void 0 ? `crm:${one.kind}` : `crm:${one.kind}/${one.externalId}`
|
|
9211
|
-
}))
|
|
9301
|
+
})),
|
|
9302
|
+
...embedded?.issues ?? []
|
|
9212
9303
|
];
|
|
9213
9304
|
const partial = report.state === "partial" || issues.length > 0;
|
|
9214
|
-
return itemOf(snakeKeys({ ...rest, stageTasks, ...hint === void 0 ? {} : { hint } }), {
|
|
9305
|
+
return itemOf(snakeKeys({ ...rest, stageTasks, ...hint === void 0 ? {} : { hint }, ...embedded?.item }), {
|
|
9215
9306
|
...partial ? { meta: { complete: false, ...issues.length ? { issues } : {} } } : {},
|
|
9216
|
-
...next ? { next } : {}
|
|
9307
|
+
...next || embedded?.next ? { next: next ?? embedded?.next } : {}
|
|
9217
9308
|
});
|
|
9218
9309
|
});
|
|
9219
9310
|
});
|
|
@@ -9617,7 +9708,7 @@ var HUBSPOT_ACCOUNT = {
|
|
|
9617
9708
|
|
|
9618
9709
|
// dist/commands/crm-shared.js
|
|
9619
9710
|
var savedAccount = /* @__PURE__ */ __name(async (env, profile) => {
|
|
9620
|
-
const { openHubspotStore } = await import("./store-
|
|
9711
|
+
const { openHubspotStore } = await import("./store-LON2XRIS.js");
|
|
9621
9712
|
const store = await openHubspotStore(env, { readOnly: true }).catch(() => void 0);
|
|
9622
9713
|
if (!store)
|
|
9623
9714
|
return void 0;
|
|
@@ -9632,9 +9723,9 @@ var savedAccount = /* @__PURE__ */ __name(async (env, profile) => {
|
|
|
9632
9723
|
var openProfile = /* @__PURE__ */ __name(async (command, { readOnly }) => {
|
|
9633
9724
|
const { env, profile, environment } = contextOf(command);
|
|
9634
9725
|
const [{ openHubspotStore, PROVIDER: PROVIDER2 }, { hubspotCrmSource }, { hubspotCrmWriter }] = await Promise.all([
|
|
9635
|
-
import("./store-
|
|
9636
|
-
import("./source-
|
|
9637
|
-
import("./writer-
|
|
9726
|
+
import("./store-LON2XRIS.js"),
|
|
9727
|
+
import("./source-XP2JNUVU.js"),
|
|
9728
|
+
import("./writer-NOSHE7ZI.js")
|
|
9638
9729
|
]);
|
|
9639
9730
|
const fromToken = fromEnvironment(command);
|
|
9640
9731
|
const online = metaOf(command).effects?.remote !== "none";
|
|
@@ -3,8 +3,8 @@ const require = __bundleRequire(import.meta.url);
|
|
|
3
3
|
import {
|
|
4
4
|
pasteHint,
|
|
5
5
|
readSecret
|
|
6
|
-
} from "./chunk-
|
|
7
|
-
import "./chunk-
|
|
6
|
+
} from "./chunk-OX37ZK27.js";
|
|
7
|
+
import "./chunk-ZS6T2PYQ.js";
|
|
8
8
|
import "./chunk-2K5BAY32.js";
|
|
9
9
|
import "./chunk-H5HBZCEJ.js";
|
|
10
10
|
import "./chunk-S4UUN6LD.js";
|