@wirecat/bitrix24-cli 0.3.0 → 0.4.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 +52 -0
- package/dist/api-keys.d.ts +30 -8
- package/dist/api-keys.d.ts.map +1 -1
- package/dist/api-keys.js +81 -18
- package/dist/api-keys.js.map +1 -1
- package/dist/bin/b24.js +2 -2
- package/dist/bitrix/methods.d.ts.map +1 -1
- package/dist/bitrix/methods.js +7 -3
- package/dist/bitrix/methods.js.map +1 -1
- package/dist/bitrix/transport.d.ts +4 -7
- package/dist/bitrix/transport.d.ts.map +1 -1
- package/dist/bitrix/transport.js +12 -16
- package/dist/bitrix/transport.js.map +1 -1
- package/dist/bundle/{all-profiles-QJ444GSX.js → all-profiles-MBQZCOVK.js} +6 -6
- package/dist/bundle/{anthropic-RHRAVHC2.js → anthropic-QCYLKSJJ.js} +4 -4
- package/dist/bundle/{app-server-QIT6S7AZ.js → app-server-FSLZ2Y6N.js} +42 -42
- package/dist/bundle/b24.js +12 -12
- package/dist/bundle/{bun-H6RSODZ3.js → bun-UYRQXF33.js} +2 -2
- package/dist/bundle/{bun-sqlite-BO4LTQHX.js → bun-sqlite-GXME7EMT.js} +3 -3
- package/dist/bundle/{chunk-MBDK4YXG.js → chunk-2D5W4LWL.js} +1 -1
- package/dist/bundle/{chunk-U5ACMCAQ.js → chunk-2IZ6GGU2.js} +151 -151
- package/dist/bundle/{chunk-VEWWAGTD.js → chunk-4OVK5XW2.js} +8 -8
- package/dist/bundle/{chunk-45AKJVKV.js → chunk-66QLBRIT.js} +1 -1
- package/dist/bundle/{chunk-P364PLIK.js → chunk-6BLVBGRK.js} +9 -9
- package/dist/bundle/{chunk-FOTREPNS.js → chunk-6ERX33NC.js} +8 -8
- package/dist/bundle/{chunk-LRGYKOCP.js → chunk-AMVRNYD6.js} +1 -1
- package/dist/bundle/{chunk-YZ5LHE5Q.js → chunk-AOUNT22U.js} +2 -2
- package/dist/bundle/{chunk-ZDQQCXFG.js → chunk-B252WFK7.js} +13 -13
- package/dist/bundle/{chunk-WKRQ44EH.js → chunk-BHZ5VDDY.js} +13 -13
- package/dist/bundle/{chunk-ZIAQPTUS.js → chunk-COOOXDKZ.js} +3 -3
- package/dist/bundle/{chunk-W5YAO5G5.js → chunk-CR3TLGM4.js} +9 -4
- package/dist/bundle/{chunk-D5S6QV6R.js → chunk-D2IRPC5I.js} +6 -6
- package/dist/bundle/{chunk-POC3V3AO.js → chunk-DQIQIZQS.js} +297 -256
- package/dist/bundle/{chunk-QGMDQ2PM.js → chunk-EIGPMMGC.js} +3 -3
- package/dist/bundle/{chunk-WTPMJYMD.js → chunk-ELBOQHJA.js} +45 -45
- package/dist/bundle/{chunk-LSPIOT6Z.js → chunk-EQLWU6ZB.js} +7 -7
- package/dist/bundle/{chunk-WII44RXN.js → chunk-F5NH3UJQ.js} +2 -2
- package/dist/bundle/{chunk-HAXNUIGQ.js → chunk-GTDOUP6L.js} +26 -23
- package/dist/bundle/{chunk-QQXH2OPB.js → chunk-GTFRSYYJ.js} +17 -12
- package/dist/bundle/{chunk-H2ADPPSH.js → chunk-GTMCLOYY.js} +670 -465
- package/dist/bundle/{chunk-7GRZAKBB.js → chunk-IF27EQN6.js} +2 -2
- package/dist/bundle/{chunk-FZL7F5NR.js → chunk-IWEWDVZ6.js} +22 -22
- package/dist/bundle/{program-H3TGGRQ6.js → chunk-J7OMY6EO.js} +16654 -18332
- package/dist/bundle/{chunk-QIPTIUMJ.js → chunk-JAS3OZSP.js} +4 -4
- package/dist/bundle/{chunk-OTD2ZRXD.js → chunk-JB7OXYAU.js} +4 -4
- package/dist/bundle/{chunk-ZEW4P6AH.js → chunk-K7XWCZF6.js} +8 -8
- package/dist/bundle/{chunk-YYO7D2MO.js → chunk-LAYH344Y.js} +28 -28
- package/dist/bundle/{chunk-K3UIB6ZF.js → chunk-M5XMAUGZ.js} +2 -2
- package/dist/bundle/{chunk-2KCZ7BKW.js → chunk-MPI2FDJ4.js} +11 -11
- package/dist/bundle/{chunk-HGL63O5V.js → chunk-MY6FAZRA.js} +2 -2
- package/dist/bundle/{chunk-QC53QBNC.js → chunk-NDSOBIR3.js} +3 -3
- package/dist/bundle/{chunk-XRFJWHY5.js → chunk-NEK7LKC6.js} +4 -4
- package/dist/bundle/{chunk-2SNUMZ7S.js → chunk-NKLLI4B2.js} +6 -6
- package/dist/bundle/{chunk-QMPN6WKD.js → chunk-NWKXMMON.js} +100 -81
- package/dist/bundle/{chunk-P33NDCDI.js → chunk-O7FVOICH.js} +1 -1
- package/dist/bundle/{chunk-SFRNX2TI.js → chunk-OCRCVLZQ.js} +1 -1
- package/dist/bundle/{chunk-TE3FR6MI.js → chunk-OKDC6CLH.js} +5 -5
- package/dist/bundle/{chunk-DTXERR44.js → chunk-OWILUBCI.js} +2 -2
- package/dist/bundle/{chunk-CXL33BFL.js → chunk-OYLJHX74.js} +1 -1
- package/dist/bundle/{chunk-6WY72XVQ.js → chunk-POUSZWMP.js} +4 -4
- package/dist/bundle/{chunk-N6FLBXZS.js → chunk-Q4ILKTV4.js} +3 -3
- package/dist/bundle/{chunk-FLUEXJ4X.js → chunk-Q7Z5IMVY.js} +1 -1
- package/dist/bundle/{chunk-XJXONOB5.js → chunk-QVZSLBR6.js} +1 -1
- package/dist/bundle/{chunk-IRV2PCQ2.js → chunk-SBW2Y7AZ.js} +26 -26
- package/dist/bundle/{chunk-XNHSPHUN.js → chunk-UCLWWSQK.js} +2 -2
- package/dist/bundle/{chunk-BCF7P4FZ.js → chunk-UH56WLDS.js} +8 -8
- package/dist/bundle/{chunk-ZGZT5S6B.js → chunk-VMQL4GNH.js} +55 -55
- package/dist/bundle/{chunk-XD4FRDSL.js → chunk-VTIUWHZ3.js} +5 -5
- package/dist/bundle/{chunk-SGRYYE4X.js → chunk-WJRBX5QB.js} +4 -4
- package/dist/bundle/{chunk-VL6SPMZV.js → chunk-XG6QKS7L.js} +5 -5
- package/dist/bundle/{chunk-RRJNNPR4.js → chunk-XKQZLR2X.js} +1 -1
- package/dist/bundle/{chunk-QSNROIJL.js → chunk-XOPMSWFC.js} +9 -9
- package/dist/bundle/{chunk-EVYSBZ3I.js → chunk-XR5SUCAC.js} +4 -4
- package/dist/bundle/{chunk-PH5FZX6E.js → chunk-Y5PPMGCS.js} +2 -2
- package/dist/bundle/{chunk-EXOOKUEA.js → chunk-YFZXI3NN.js} +2 -2
- package/dist/bundle/{chunk-CNNEA2M4.js → chunk-ZU4HXKEW.js} +3 -3
- package/dist/bundle/command-contract-UON4EIC4.js +30 -0
- package/dist/bundle/{decode-5ZPLTYV6.js → decode-IF2F2SFC.js} +3 -3
- package/dist/bundle/{echarts-J6LAPIX7.js → echarts-WDDVEJO2.js} +2 -2
- package/dist/bundle/{embed-YG5LDHME.js → embed-VDUGYEAR.js} +4 -4
- package/dist/bundle/{embedder-7FNUA5OZ.js → embedder-DUN62H3Z.js} +7 -7
- package/dist/bundle/{first-run-JPZNWIJN.js → first-run-NDGYBQEN.js} +8 -8
- package/dist/bundle/first-screen-QAVKP5RF.js +28 -0
- package/dist/bundle/{instructions-AXWTQHMR.js → instructions-JIIKWS7X.js} +1 -1
- package/dist/bundle/{mcp-7F46P6AM.js → mcp-33JX6KP4.js} +2 -2
- package/dist/bundle/{mcp-5RSWNTHS.js → mcp-57EQ6QJO.js} +58 -47
- package/dist/bundle/mcp-PFJER2DE.js +87 -0
- package/dist/bundle/{node-CWKAIOEM.js → node-K57WT42O.js} +2 -2
- package/dist/bundle/{node-sqlite-LSEKVRDA.js → node-sqlite-KS6ORRIG.js} +4 -4
- package/dist/bundle/{oauth-THYNLRLD.js → oauth-SLSANN37.js} +5 -5
- package/dist/bundle/{open-E47QYKFC.js → open-WJPHADEX.js} +3 -3
- package/dist/bundle/{openai-EWSGC3BC.js → openai-HXB3GTOD.js} +12 -12
- package/dist/bundle/{process-WKTEA3WE.js → process-P73TFAXT.js} +1 -1
- package/dist/bundle/program-7BMG5NIN.js +2250 -0
- package/dist/bundle/{prompt-CAQ7QR3U.js → prompt-WDPV37R4.js} +3 -3
- package/dist/bundle/{recognize-6KGHNZC3.js → recognize-CXIFL6IV.js} +2 -2
- package/dist/bundle/{remote-3UO2WDC3.js → remote-Q4VJ4OQW.js} +5 -5
- package/dist/bundle/{rerank-2JVDPZBX.js → rerank-SUFYK63I.js} +5 -5
- package/dist/bundle/{serve-ES7AG5IK.js → serve-B7PGFOC2.js} +7 -7
- package/dist/bundle/server-4DBNJWW6.js +58 -0
- package/dist/bundle/server-OKE7SXJ2.js +45 -0
- package/dist/bundle/{state-7NH5G4XJ.js → state-EZCCXQV7.js} +4 -4
- package/dist/bundle/{store-7O4JQD2Z.js → store-MZ7JBYR6.js} +12 -12
- package/dist/bundle/store-maintenance-command-T5QZMENJ.js +47 -0
- package/dist/commands/api.d.ts.map +1 -1
- package/dist/commands/api.js +57 -7
- package/dist/commands/api.js.map +1 -1
- package/dist/commands/crm-writes.d.ts.map +1 -1
- package/dist/commands/crm-writes.js +24 -8
- package/dist/commands/crm-writes.js.map +1 -1
- package/dist/commands/crm.d.ts.map +1 -1
- package/dist/commands/crm.js +29 -3
- package/dist/commands/crm.js.map +1 -1
- package/dist/commands/fields.d.ts +3 -0
- package/dist/commands/fields.d.ts.map +1 -0
- package/dist/commands/fields.js +45 -0
- package/dist/commands/fields.js.map +1 -0
- package/dist/commands/write.d.ts +6 -1
- package/dist/commands/write.d.ts.map +1 -1
- package/dist/commands/write.js +7 -5
- package/dist/commands/write.js.map +1 -1
- package/dist/config.d.ts.map +1 -1
- package/dist/config.js +2 -1
- package/dist/config.js.map +1 -1
- package/dist/crm/conditions.js +1 -1
- package/dist/crm/conditions.js.map +1 -1
- package/dist/crm/custom-query.d.ts +19 -0
- package/dist/crm/custom-query.d.ts.map +1 -0
- package/dist/crm/custom-query.js +79 -0
- package/dist/crm/custom-query.js.map +1 -0
- package/dist/crm/deal.d.ts +1 -0
- package/dist/crm/deal.d.ts.map +1 -1
- package/dist/crm/fields.d.ts +44 -0
- package/dist/crm/fields.d.ts.map +1 -0
- package/dist/crm/fields.js +143 -0
- package/dist/crm/fields.js.map +1 -0
- package/dist/crm/items.d.ts +7 -1
- package/dist/crm/items.d.ts.map +1 -1
- package/dist/crm/items.js +17 -15
- package/dist/crm/items.js.map +1 -1
- package/dist/crm/lead.d.ts +1 -0
- package/dist/crm/lead.d.ts.map +1 -1
- package/dist/crm/organization.d.ts +1 -0
- package/dist/crm/organization.d.ts.map +1 -1
- package/dist/crm/person.d.ts +1 -0
- package/dist/crm/person.d.ts.map +1 -1
- package/dist/crm/values.d.ts +7 -1
- package/dist/crm/values.d.ts.map +1 -1
- package/dist/crm/values.js +12 -3
- package/dist/crm/values.js.map +1 -1
- package/dist/mcp.d.ts.map +1 -1
- package/dist/mcp.js +4 -1
- package/dist/mcp.js.map +1 -1
- package/dist/program.d.ts.map +1 -1
- package/dist/program.js +4 -1
- package/dist/program.js.map +1 -1
- package/dist/reasons.d.ts.map +1 -1
- package/dist/reasons.js +6 -1
- package/dist/reasons.js.map +1 -1
- package/dist/version.d.ts +1 -1
- package/dist/version.js +1 -1
- package/package.json +3 -3
- package/skills/bitrix24-cli/SKILL.md +8 -3
- package/dist/bundle/command-contract-OKQOE6G4.js +0 -30
- package/dist/bundle/first-screen-VQM4MTS7.js +0 -28
- package/dist/bundle/mcp-J5R5A65I.js +0 -87
- package/dist/bundle/server-5LE5LNUQ.js +0 -45
- package/dist/bundle/server-BU4VBM6S.js +0 -58
- package/dist/bundle/store-maintenance-command-UDVGEY2D.js +0 -47
- /package/dist/bundle/{chunk-4PDYYS5K.js → chunk-NDTJE6JQ.js} +0 -0
|
@@ -4,25 +4,26 @@ import {
|
|
|
4
4
|
formatMeetingReference,
|
|
5
5
|
moneyLabel,
|
|
6
6
|
parseMeetingReference
|
|
7
|
-
} from "./chunk-
|
|
7
|
+
} from "./chunk-VMQL4GNH.js";
|
|
8
8
|
import {
|
|
9
9
|
CliError,
|
|
10
10
|
singleLine
|
|
11
|
-
} from "./chunk-
|
|
11
|
+
} from "./chunk-SBW2Y7AZ.js";
|
|
12
12
|
import {
|
|
13
13
|
__name
|
|
14
14
|
} from "./chunk-ZVVMGPBJ.js";
|
|
15
15
|
|
|
16
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
16
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.590.0_@wirecat+cli-base@0.80.1_commander@15.0.0_esbuild@0.28.2_type_4c7167080feb2ba6356a64767981f5fd/node_modules/@wirecat/cli-core/dist/domain/deals.js
|
|
17
|
+
var DEAL_KINDS = ["deal", "lead"];
|
|
17
18
|
var DEAL_STATUSES = ["open", "won", "lost"];
|
|
19
|
+
var STAGE_OUTCOMES = DEAL_STATUSES;
|
|
18
20
|
var DEAL_ROLES = ["owner", "contact", "decision-maker"];
|
|
19
21
|
var dealLine = /* @__PURE__ */ __name((deal) => {
|
|
20
22
|
const money = deal.amount === null || deal.currency === null ? "" : `, ${moneyLabel(deal.amount, deal.currency)}`;
|
|
21
|
-
|
|
22
|
-
return `${deal.title} \xB7 ${deal.stage}${money}${notes ? ` (${notes})` : ""}`;
|
|
23
|
+
return `${deal.title} \xB7 ${deal.stage}${money}${deal.status === "open" ? "" : ` (${deal.status})`}`;
|
|
23
24
|
}, "dealLine");
|
|
24
25
|
|
|
25
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
26
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.590.0_@wirecat+cli-base@0.80.1_commander@15.0.0_esbuild@0.28.2_type_4c7167080feb2ba6356a64767981f5fd/node_modules/@wirecat/cli-core/dist/domain/locator.js
|
|
26
27
|
var SCHEME = "msg:";
|
|
27
28
|
var formatLocator = /* @__PURE__ */ __name(({ provider, account, chat, message }) => SCHEME + [provider, account, chat, message].map(encodeURIComponent).join("/"), "formatLocator");
|
|
28
29
|
var isLocator = /* @__PURE__ */ __name((reference) => reference.trim().startsWith(SCHEME), "isLocator");
|
|
@@ -36,7 +37,7 @@ var parseLocator = /* @__PURE__ */ __name((reference) => {
|
|
|
36
37
|
return { provider, account, chat, message };
|
|
37
38
|
}, "parseLocator");
|
|
38
39
|
|
|
39
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
40
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.590.0_@wirecat+cli-base@0.80.1_commander@15.0.0_esbuild@0.28.2_type_4c7167080feb2ba6356a64767981f5fd/node_modules/@wirecat/cli-core/dist/domain/references.js
|
|
40
41
|
var SIMPLE_REFERENCES = [
|
|
41
42
|
"note",
|
|
42
43
|
"document",
|
|
@@ -52,6 +53,8 @@ var SIMPLE_REFERENCES = [
|
|
|
52
53
|
"payment",
|
|
53
54
|
"order",
|
|
54
55
|
"deal",
|
|
56
|
+
"lead",
|
|
57
|
+
"pipeline",
|
|
55
58
|
"entity"
|
|
56
59
|
];
|
|
57
60
|
var malformed = /* @__PURE__ */ __name((text, shape) => new CliError("validation_error", `"${singleLine(text)}" is not a reference \u2014 expected ${shape}`, {
|
|
@@ -185,8 +188,8 @@ var looksLikeReference = /* @__PURE__ */ __name((text) => {
|
|
|
185
188
|
return match !== null && byPrefix.has(match[1]);
|
|
186
189
|
}, "looksLikeReference");
|
|
187
190
|
|
|
188
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
189
|
-
var KINDS = ["messages", "mail", "notes", "documents", "meetings", "events"];
|
|
191
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.590.0_@wirecat+cli-base@0.80.1_commander@15.0.0_esbuild@0.28.2_type_4c7167080feb2ba6356a64767981f5fd/node_modules/@wirecat/cli-core/dist/domain/providers.js
|
|
192
|
+
var KINDS = ["messages", "mail", "notes", "documents", "meetings", "events", "crm"];
|
|
190
193
|
var MESSENGER_OPENS = { chat: "messages list", message: "messages show", contact: "contacts show" };
|
|
191
194
|
var PROVIDERS = [
|
|
192
195
|
{ name: "telegram", kind: "messages", aliases: ["tg"], command: "tg", opens: MESSENGER_OPENS },
|
|
@@ -301,7 +304,7 @@ var providerNamed = /* @__PURE__ */ __name((word) => {
|
|
|
301
304
|
var kindIn = /* @__PURE__ */ __name((provider) => isFolderProvider(provider) ? "notes" : registry.find(({ name }) => name === provider)?.kind, "kindIn");
|
|
302
305
|
var kindOf = /* @__PURE__ */ __name((provider) => kindIn(provider) ?? "messages", "kindOf");
|
|
303
306
|
|
|
304
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
307
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.590.0_@wirecat+cli-base@0.80.1_commander@15.0.0_esbuild@0.28.2_type_4c7167080feb2ba6356a64767981f5fd/node_modules/@wirecat/cli-core/dist/domain/records.js
|
|
305
308
|
import { createHash } from "node:crypto";
|
|
306
309
|
var RECORDS_SCHEMA_VERSION = 1;
|
|
307
310
|
var RECORD_OPERATIONS = ["upsert", "delete"];
|
|
@@ -390,7 +393,7 @@ var recordFingerprint = /* @__PURE__ */ __name((fields, relations) => createHash
|
|
|
390
393
|
]).sort((a, b) => a.join("\0").localeCompare(b.join("\0")))
|
|
391
394
|
}))).digest("hex"), "recordFingerprint");
|
|
392
395
|
|
|
393
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
396
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.590.0_@wirecat+cli-base@0.80.1_commander@15.0.0_esbuild@0.28.2_type_4c7167080feb2ba6356a64767981f5fd/node_modules/@wirecat/cli-core/dist/domain/counters.js
|
|
394
397
|
var COUNTER_FIELDS = ["views", "reactions", "comments"];
|
|
395
398
|
var validCounter = /* @__PURE__ */ __name((value) => typeof value === "number" && Number.isFinite(value) && value >= 0, "validCounter");
|
|
396
399
|
var counterObservationTime = /* @__PURE__ */ __name((observation, now) => {
|
|
@@ -409,7 +412,7 @@ var counterFreshness = /* @__PURE__ */ __name((states) => {
|
|
|
409
412
|
return states.some((one) => one.freshness === "stale") ? "stale" : "fresh";
|
|
410
413
|
}, "counterFreshness");
|
|
411
414
|
|
|
412
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
415
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.590.0_@wirecat+cli-base@0.80.1_commander@15.0.0_esbuild@0.28.2_type_4c7167080feb2ba6356a64767981f5fd/node_modules/@wirecat/cli-core/dist/domain/rankings-options.js
|
|
413
416
|
var MESSAGE_MEASURES = ["views", "reactions", "forwards", "comments", "replies", "thread-size"];
|
|
414
417
|
var AUTHOR_MEASURES = [
|
|
415
418
|
"messages",
|
|
@@ -554,7 +557,9 @@ export {
|
|
|
554
557
|
validCounter,
|
|
555
558
|
counterObservationTime,
|
|
556
559
|
counterFreshness,
|
|
560
|
+
DEAL_KINDS,
|
|
557
561
|
DEAL_STATUSES,
|
|
562
|
+
STAGE_OUTCOMES,
|
|
558
563
|
DEAL_ROLES,
|
|
559
564
|
dealLine,
|
|
560
565
|
formatLocator,
|