lua-cli 3.32.4 → 3.32.6
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/api-exports.d.ts +32 -1
- package/dist/api-exports.js +342 -60
- package/dist/api-exports.js.map +1 -1
- package/dist/index.js +1033 -497
- package/dist/index.js.map +1 -1
- package/dist/workflow-builder.d.ts +5 -0
- package/dist/workflow-builder.js +215 -8
- package/dist/workflow-builder.js.map +1 -1
- package/docs/CLI_REFERENCE.md +6 -2
- package/docs/README.md +2 -2
- package/docs/workflows/approvals.md +1 -1
- package/docs/workflows/limits.md +4 -0
- package/docs/workflows/testing-offline.md +1 -1
- package/package.json +3 -3
- package/template/package.json +1 -1
package/dist/api-exports.d.ts
CHANGED
|
@@ -582,6 +582,13 @@ declare interface ApiResponse<T = any> {
|
|
|
582
582
|
stepId?: string;
|
|
583
583
|
/** the live step status on 409 NOT_SUSPENDED (LUA-644) */
|
|
584
584
|
status?: string;
|
|
585
|
+
/** LUA-810 — 503 UPSTREAM_UNAVAILABLE: the internal Lua service behind the API that answered a fault or did
|
|
586
|
+
* not answer (`lua-agents`, `lua-core`, …), and the id on the server's matching error log line. */
|
|
587
|
+
upstream?: string;
|
|
588
|
+
requestId?: string;
|
|
589
|
+
/** LUA-812 — 503 VENDOR_UNAVAILABLE: the third-party vendor behind the API that failed (`unified` | `github` |
|
|
590
|
+
* `pusher` | `google`); `retryAfterSeconds` above is present only when a blind retry is safe. */
|
|
591
|
+
vendor?: string;
|
|
585
592
|
};
|
|
586
593
|
}
|
|
587
594
|
|
|
@@ -599,6 +606,11 @@ export declare interface ApprovalOptions {
|
|
|
599
606
|
/** default 'continue' (denial is data unless 'fail') */
|
|
600
607
|
onDeny?: WorkflowApprovalOnDeny;
|
|
601
608
|
businessHours?: WorkflowBusinessHours;
|
|
609
|
+
/**
|
|
610
|
+
* Optional — inferred `true` from a non-empty `editablePaths` (LUA-808 / LUA-825: the validator's `approvalEditable`
|
|
611
|
+
* rule, applied by the builder too); an explicit `false` beside paths is refused as contradictory. Absent with no
|
|
612
|
+
* paths ⇒ `false` (the approver decides, never edits).
|
|
613
|
+
*/
|
|
602
614
|
editable?: boolean;
|
|
603
615
|
/** grammar: `drafts`, `drafts[*]`, `drafts[*].body`, `drafts[3].body`, `summary.title` */
|
|
604
616
|
editablePaths?: string[];
|
|
@@ -2229,6 +2241,15 @@ declare abstract class HttpClient {
|
|
|
2229
2241
|
* @private
|
|
2230
2242
|
*/
|
|
2231
2243
|
private calculateBackoff;
|
|
2244
|
+
/**
|
|
2245
|
+
* The wait before the next attempt: the client's jittered exponential backoff, floored by the server's
|
|
2246
|
+
* `retryAfterSeconds` on a 429 (the limiter's word is final) and on an idempotent read (GET / HEAD). LUA-810: a
|
|
2247
|
+
* POST / PUT / PATCH / DELETE that met a 5xx keeps the client's own backoff — every 503 body carries
|
|
2248
|
+
* `retryAfterSeconds: 5` (`CONTROL_UNAVAILABLE`, `UPSTREAM_UNAVAILABLE`), which floored all three waits at 5 s:
|
|
2249
|
+
* a ≥15 s stall on a write that may already have landed, and retrying an ambiguous write harder does not make
|
|
2250
|
+
* it less ambiguous. The client's own schedule is ≤1 s + ≤2 s + ≤4 s.
|
|
2251
|
+
*/
|
|
2252
|
+
private retryDelayMs;
|
|
2232
2253
|
/**
|
|
2233
2254
|
* Wraps request with retry logic for transient failures
|
|
2234
2255
|
* @param url - The full URL to request
|
|
@@ -7314,11 +7335,21 @@ declare interface WorkflowRun {
|
|
|
7314
7335
|
parentRunId?: string;
|
|
7315
7336
|
correlationKey?: string;
|
|
7316
7337
|
tags?: string[];
|
|
7338
|
+
/** R4 `gate` (02 §2.4). LUA-788: a `kind:'billing'` gate names the wallet's refusal (`code`), the held step and its expiry. */
|
|
7317
7339
|
gate?: {
|
|
7318
7340
|
kind: string;
|
|
7319
7341
|
reason?: string;
|
|
7320
|
-
since?: string;
|
|
7342
|
+
since?: string | number;
|
|
7343
|
+
code?: string;
|
|
7344
|
+
stepId?: string;
|
|
7345
|
+
expiresAt?: number;
|
|
7321
7346
|
};
|
|
7347
|
+
/**
|
|
7348
|
+
* Server-decided (09 §9.6): `raise_budget` on a budget gate (LUA-665), `top_up` on a billing gate (LUA-788 — the
|
|
7349
|
+
* wallet clears it; the engine re-checks and resumes on its own), `cancel_again` / `force` under a pending cancel,
|
|
7350
|
+
* else `none`. Absent on an older server.
|
|
7351
|
+
*/
|
|
7352
|
+
nextAction?: 'cancel_again' | 'force' | 'none' | 'raise_budget' | 'top_up';
|
|
7322
7353
|
/**
|
|
7323
7354
|
* The pending / audited cancel request (`runCancelView`): who asked and when; `wall` when it was the run wall's
|
|
7324
7355
|
* own (LUA-686); LUA-704: `forcedBy` / `forcedAt` / `forceReason` on a forced terminal (`abandoned`, or
|