octwin-cli 0.8.14 → 0.8.15
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 +1017 -1008
- package/dist/cli.js +10 -5
- package/dist/lib/page.js +1 -1
- package/package.json +46 -46
package/dist/cli.js
CHANGED
|
@@ -2529,8 +2529,13 @@ async function cmdRecords(flags) {
|
|
|
2529
2529
|
if (status !== 200)
|
|
2530
2530
|
die(`could not read entities (HTTP ${status})`);
|
|
2531
2531
|
out.result(json, () => {
|
|
2532
|
+
if (json?.has_data === false) {
|
|
2533
|
+
out.print('No AI Agent is loaded in this project.');
|
|
2534
|
+
return;
|
|
2535
|
+
}
|
|
2532
2536
|
if (json?.has_xrm === false) {
|
|
2533
|
-
|
|
2537
|
+
// No record TYPES of its own — but the platform's own records (an order, a case) still read by name.
|
|
2538
|
+
out.print('This pack declares no record types of its own. Platform records still read by name: octwin records order | product | case | …');
|
|
2534
2539
|
return;
|
|
2535
2540
|
}
|
|
2536
2541
|
const ents = (json?.entities ?? []);
|
|
@@ -2614,8 +2619,8 @@ async function cmdRecordsWrite(flags) {
|
|
|
2614
2619
|
const { status, json } = await apiSend('POST', `${base}/xrm/records`, body, t);
|
|
2615
2620
|
if (status !== 200 && status !== 201)
|
|
2616
2621
|
writeFail(`create the ${entity} record`, status, json, url, true);
|
|
2617
|
-
if (json?.
|
|
2618
|
-
die('
|
|
2622
|
+
if (json?.has_data === false)
|
|
2623
|
+
die('no AI Agent is loaded in this project');
|
|
2619
2624
|
const rec = json?.record ?? {};
|
|
2620
2625
|
out.result(json, () => {
|
|
2621
2626
|
// 200 = the entity's identity matched an existing row; 201 = genuinely new.
|
|
@@ -2701,8 +2706,8 @@ async function cmdRecordsWrite(flags) {
|
|
|
2701
2706
|
if (status !== 200)
|
|
2702
2707
|
writeFail('read tasks', status, json, url);
|
|
2703
2708
|
out.result(json, () => {
|
|
2704
|
-
if (json?.
|
|
2705
|
-
out.print('
|
|
2709
|
+
if (json?.has_data === false) {
|
|
2710
|
+
out.print('No AI Agent is loaded in this project.');
|
|
2706
2711
|
return;
|
|
2707
2712
|
}
|
|
2708
2713
|
const page = readPage(json);
|
package/dist/lib/page.js
CHANGED
|
@@ -29,7 +29,7 @@
|
|
|
29
29
|
* Read a `Page` envelope defensively.
|
|
30
30
|
*
|
|
31
31
|
* Returns an empty view for a non-object or a body with no `rows` ARRAY, so a
|
|
32
|
-
* degraded read (`{
|
|
32
|
+
* degraded read (`{ ...emptyPage(), has_data: false }`) and an error body both
|
|
33
33
|
* land on "no rows" without throwing. `total` stays **null** when absent rather
|
|
34
34
|
* than defaulting to 0 — a caller that prints "0 of 0" when the server said
|
|
35
35
|
* nothing is inventing a fact.
|
package/package.json
CHANGED
|
@@ -1,46 +1,46 @@
|
|
|
1
|
-
{
|
|
2
|
-
"name": "octwin-cli",
|
|
3
|
-
"version": "0.8.
|
|
4
|
-
"description": "Octwin external-pack developer CLI (by CEQUENS) — scaffold, validate, deploy, and check pure-YAML packs on your tenant.",
|
|
5
|
-
"type": "module",
|
|
6
|
-
"bin": {
|
|
7
|
-
"octwin": "dist/index.js"
|
|
8
|
-
},
|
|
9
|
-
"files": [
|
|
10
|
-
"dist",
|
|
11
|
-
"templates",
|
|
12
|
-
"README.md",
|
|
13
|
-
"CHANGELOG.md",
|
|
14
|
-
"LICENSE"
|
|
15
|
-
],
|
|
16
|
-
"engines": {
|
|
17
|
-
"node": ">=22"
|
|
18
|
-
},
|
|
19
|
-
"scripts": {
|
|
20
|
-
"build": "tsc -p tsconfig.json",
|
|
21
|
-
"prepublishOnly": "npm run build"
|
|
22
|
-
},
|
|
23
|
-
"dependencies": {
|
|
24
|
-
"yaml": "^2.6.0"
|
|
25
|
-
},
|
|
26
|
-
"devDependencies": {
|
|
27
|
-
"@types/node": "^22.0.0",
|
|
28
|
-
"typescript": "^5.7.0"
|
|
29
|
-
},
|
|
30
|
-
"publishConfig": {
|
|
31
|
-
"access": "public"
|
|
32
|
-
},
|
|
33
|
-
"keywords": [
|
|
34
|
-
"octwin",
|
|
35
|
-
"cequens",
|
|
36
|
-
"cli",
|
|
37
|
-
"whatsapp",
|
|
38
|
-
"chatbot",
|
|
39
|
-
"pack",
|
|
40
|
-
"conversational-ai",
|
|
41
|
-
"yaml"
|
|
42
|
-
],
|
|
43
|
-
"author": "CEQUENS",
|
|
44
|
-
"homepage": "https://octwin.ai",
|
|
45
|
-
"license": "MIT"
|
|
46
|
-
}
|
|
1
|
+
{
|
|
2
|
+
"name": "octwin-cli",
|
|
3
|
+
"version": "0.8.15",
|
|
4
|
+
"description": "Octwin external-pack developer CLI (by CEQUENS) — scaffold, validate, deploy, and check pure-YAML packs on your tenant.",
|
|
5
|
+
"type": "module",
|
|
6
|
+
"bin": {
|
|
7
|
+
"octwin": "dist/index.js"
|
|
8
|
+
},
|
|
9
|
+
"files": [
|
|
10
|
+
"dist",
|
|
11
|
+
"templates",
|
|
12
|
+
"README.md",
|
|
13
|
+
"CHANGELOG.md",
|
|
14
|
+
"LICENSE"
|
|
15
|
+
],
|
|
16
|
+
"engines": {
|
|
17
|
+
"node": ">=22"
|
|
18
|
+
},
|
|
19
|
+
"scripts": {
|
|
20
|
+
"build": "tsc -p tsconfig.json",
|
|
21
|
+
"prepublishOnly": "npm run build"
|
|
22
|
+
},
|
|
23
|
+
"dependencies": {
|
|
24
|
+
"yaml": "^2.6.0"
|
|
25
|
+
},
|
|
26
|
+
"devDependencies": {
|
|
27
|
+
"@types/node": "^22.0.0",
|
|
28
|
+
"typescript": "^5.7.0"
|
|
29
|
+
},
|
|
30
|
+
"publishConfig": {
|
|
31
|
+
"access": "public"
|
|
32
|
+
},
|
|
33
|
+
"keywords": [
|
|
34
|
+
"octwin",
|
|
35
|
+
"cequens",
|
|
36
|
+
"cli",
|
|
37
|
+
"whatsapp",
|
|
38
|
+
"chatbot",
|
|
39
|
+
"pack",
|
|
40
|
+
"conversational-ai",
|
|
41
|
+
"yaml"
|
|
42
|
+
],
|
|
43
|
+
"author": "CEQUENS",
|
|
44
|
+
"homepage": "https://octwin.ai",
|
|
45
|
+
"license": "MIT"
|
|
46
|
+
}
|