@lotics/cli 0.261.0 → 0.262.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/src/cli.js +7 -7
- package/dist/src/client.d.ts +1 -1
- package/dist/src/client.js +2 -2
- package/package.json +1 -1
package/dist/src/cli.js
CHANGED
|
@@ -52,7 +52,7 @@ var __toESM = (mod2, isNodeMode, target) => (target = mod2 != null ? __create(__
|
|
|
52
52
|
var define_LOTICS_KIT_VERSIONS_default;
|
|
53
53
|
var init_define_LOTICS_KIT_VERSIONS = __esm({
|
|
54
54
|
"<define:__LOTICS_KIT_VERSIONS__>"() {
|
|
55
|
-
define_LOTICS_KIT_VERSIONS_default = { runtime: "0.
|
|
55
|
+
define_LOTICS_KIT_VERSIONS_default = { runtime: "0.44.0" };
|
|
56
56
|
}
|
|
57
57
|
});
|
|
58
58
|
|
|
@@ -30149,13 +30149,13 @@ var LoticsClient = class {
|
|
|
30149
30149
|
* Execute a workflow by alias declared in package.json#lotics.workflows.
|
|
30150
30150
|
* Mirrors POST /v1/apps/{app_id}/workflows/{alias}/execute.
|
|
30151
30151
|
*/
|
|
30152
|
-
async appWorkflow(app_id, alias2, inputs) {
|
|
30152
|
+
async appWorkflow(app_id, alias2, inputs, minted_ids) {
|
|
30153
30153
|
const url2 = `${this.baseUrl}/v1/apps/${encodeURIComponent(app_id)}/workflows/${encodeURIComponent(alias2)}/execute`;
|
|
30154
30154
|
const headers = this.buildHeaders();
|
|
30155
30155
|
headers["Content-Type"] = "application/json";
|
|
30156
30156
|
let response;
|
|
30157
30157
|
try {
|
|
30158
|
-
response = await fetch(url2, { method: "POST", headers, body: JSON.stringify({ inputs }) });
|
|
30158
|
+
response = await fetch(url2, { method: "POST", headers, body: JSON.stringify({ inputs, ...minted_ids === void 0 ? {} : { minted_ids } }) });
|
|
30159
30159
|
} catch (err) {
|
|
30160
30160
|
return { status: "error", message: err instanceof Error ? err.message : "The workflow request failed." };
|
|
30161
30161
|
}
|
|
@@ -64304,7 +64304,7 @@ function resultSideEffects(result) {
|
|
|
64304
64304
|
|
|
64305
64305
|
// src/version.ts
|
|
64306
64306
|
init_define_LOTICS_KIT_VERSIONS();
|
|
64307
|
-
var VERSION = "0.
|
|
64307
|
+
var VERSION = "0.262.0";
|
|
64308
64308
|
|
|
64309
64309
|
// src/timezone.ts
|
|
64310
64310
|
init_define_LOTICS_KIT_VERSIONS();
|
|
@@ -81357,7 +81357,6 @@ function createSource(plan) {
|
|
|
81357
81357
|
const opening = [
|
|
81358
81358
|
`const made = await create_records({`,
|
|
81359
81359
|
` table_id: ${str(plan.table.id)},`,
|
|
81360
|
-
` ids: isNull(i.${RECORD_INPUT}) ? null : [i.${RECORD_INPUT}],`,
|
|
81361
81360
|
` records: [`,
|
|
81362
81361
|
` {`,
|
|
81363
81362
|
...cells.map((cell) => ` ${cell}`),
|
|
@@ -82468,7 +82467,7 @@ function fieldInput(ctx, bf, required2) {
|
|
|
82468
82467
|
}
|
|
82469
82468
|
}
|
|
82470
82469
|
function createInputs(ctx, alias2, writes) {
|
|
82471
|
-
const inputs = {
|
|
82470
|
+
const inputs = {};
|
|
82472
82471
|
if (writes.parent !== void 0) {
|
|
82473
82472
|
const via = fieldOf2(ctx, alias2, writes.parent);
|
|
82474
82473
|
if (via.field.type !== "select_record_link") fail(`"${alias2}.${via.alias}" files a row under its record, so it must be a link`);
|
|
@@ -86813,7 +86812,8 @@ async function dispatchRpc(client, body, opts) {
|
|
|
86813
86812
|
if (!p || typeof p.alias !== "string") {
|
|
86814
86813
|
throw new Error("workflow payload must include `alias`");
|
|
86815
86814
|
}
|
|
86816
|
-
|
|
86815
|
+
const minted = Array.isArray(p.minted_ids) && p.minted_ids.every((id) => typeof id === "string") ? p.minted_ids : void 0;
|
|
86816
|
+
return client.appWorkflow(body.app_id, p.alias, p.inputs, minted);
|
|
86817
86817
|
}
|
|
86818
86818
|
case "members": {
|
|
86819
86819
|
const p = body.payload;
|
package/dist/src/client.d.ts
CHANGED
|
@@ -1436,7 +1436,7 @@ export declare class LoticsClient {
|
|
|
1436
1436
|
* Execute a workflow by alias declared in package.json#lotics.workflows.
|
|
1437
1437
|
* Mirrors POST /v1/apps/{app_id}/workflows/{alias}/execute.
|
|
1438
1438
|
*/
|
|
1439
|
-
appWorkflow(app_id: string, alias: string, inputs: unknown): Promise<unknown>;
|
|
1439
|
+
appWorkflow(app_id: string, alias: string, inputs: unknown, minted_ids?: readonly string[]): Promise<unknown>;
|
|
1440
1440
|
/**
|
|
1441
1441
|
* Bind (create or replace) an app workflow by alias via the `set_app_workflow`
|
|
1442
1442
|
* tool — the SINGLE author of `apps.workflows` + the workflow row. `source` is
|
package/dist/src/client.js
CHANGED
|
@@ -895,13 +895,13 @@ var LoticsClient = class {
|
|
|
895
895
|
* Execute a workflow by alias declared in package.json#lotics.workflows.
|
|
896
896
|
* Mirrors POST /v1/apps/{app_id}/workflows/{alias}/execute.
|
|
897
897
|
*/
|
|
898
|
-
async appWorkflow(app_id, alias, inputs) {
|
|
898
|
+
async appWorkflow(app_id, alias, inputs, minted_ids) {
|
|
899
899
|
const url = `${this.baseUrl}/v1/apps/${encodeURIComponent(app_id)}/workflows/${encodeURIComponent(alias)}/execute`;
|
|
900
900
|
const headers = this.buildHeaders();
|
|
901
901
|
headers["Content-Type"] = "application/json";
|
|
902
902
|
let response;
|
|
903
903
|
try {
|
|
904
|
-
response = await fetch(url, { method: "POST", headers, body: JSON.stringify({ inputs }) });
|
|
904
|
+
response = await fetch(url, { method: "POST", headers, body: JSON.stringify({ inputs, ...minted_ids === void 0 ? {} : { minted_ids } }) });
|
|
905
905
|
} catch (err) {
|
|
906
906
|
return { status: "error", message: err instanceof Error ? err.message : "The workflow request failed." };
|
|
907
907
|
}
|