@erdoai/cli 0.116.0 → 0.117.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/dist/index.js +11 -0
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -1605,6 +1605,9 @@ var ErdoClient = class {
|
|
|
1605
1605
|
attachKnowledgeAsset(objectID, input) {
|
|
1606
1606
|
return this.request("POST", `/v1/knowledge/${encodeURIComponent(objectID)}/attachments`, input);
|
|
1607
1607
|
}
|
|
1608
|
+
listKnowledgeAssets(objectID) {
|
|
1609
|
+
return this.request("GET", `/v1/knowledge/${encodeURIComponent(objectID)}/attachments`);
|
|
1610
|
+
}
|
|
1608
1611
|
// --- automations (heartbeats) ---
|
|
1609
1612
|
listHeartbeats() {
|
|
1610
1613
|
return this.request("GET", "/v1/heartbeats");
|
|
@@ -8185,6 +8188,14 @@ knowledgeCmd.command("attach <objectId> <file>").description(
|
|
|
8185
8188
|
}
|
|
8186
8189
|
}
|
|
8187
8190
|
);
|
|
8191
|
+
var knowledgeAssetsCmd = knowledgeCmd.command("assets").description("Knowledge object files");
|
|
8192
|
+
knowledgeAssetsCmd.command("list <objectId>").description("List files attached to a knowledge object").action(async (objectId) => {
|
|
8193
|
+
try {
|
|
8194
|
+
print(await new ErdoClient().listKnowledgeAssets(objectId));
|
|
8195
|
+
} catch (e) {
|
|
8196
|
+
fail(e);
|
|
8197
|
+
}
|
|
8198
|
+
});
|
|
8188
8199
|
var autoCmd = program.command("automations").description("Scheduled automations (heartbeats)");
|
|
8189
8200
|
autoCmd.command("list").description("List automations").action(async () => {
|
|
8190
8201
|
try {
|