@fabricorg/platform-host 8.3.0 → 8.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 +6 -0
- package/README.md +2 -0
- package/dist/index.cjs +3 -1
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +9 -3
- package/dist/index.d.ts +9 -3
- package/dist/index.js +3 -1
- package/dist/index.js.map +1 -1
- package/package.json +3 -3
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,11 @@
|
|
|
1
1
|
# @fabricorg/platform-host
|
|
2
2
|
|
|
3
|
+
## 8.4.0
|
|
4
|
+
|
|
5
|
+
### Minor Changes
|
|
6
|
+
|
|
7
|
+
- f1b6def: Add the parked action invocation ID and durable invocation record to `authorizeApproval` input so applications can authorize decisions for the specific proposal being resumed.
|
|
8
|
+
|
|
3
9
|
## 8.3.0
|
|
4
10
|
|
|
5
11
|
### Minor Changes
|
package/README.md
CHANGED
|
@@ -738,6 +738,8 @@ An approval workflow calls `resumeApprovedInvocation()` instead of invoking the
|
|
|
738
738
|
host authorizes the approver (using `authorizeApproval` when provided), then atomically persists the
|
|
739
739
|
decision and changes `waiting_for_approval` to either leased `running` or terminal `failed`. This keeps
|
|
740
740
|
the decision in the mutation ledger and prevents an approval/worker race.
|
|
741
|
+
`authorizeApproval` receives the parked `actionInvocationId` and durable, post-redaction `invocation`
|
|
742
|
+
record so the application can verify the approver's authority over that specific invocation.
|
|
741
743
|
|
|
742
744
|
```ts
|
|
743
745
|
await host.resumeApprovedInvocation(actionInvocationId, tenantId, spaceId, {
|
package/dist/index.cjs
CHANGED
|
@@ -3441,7 +3441,9 @@ function createGovernedActionHost(options) {
|
|
|
3441
3441
|
const entitled = await options.authorization.checkEntitlement(approvalAuthorizationInput);
|
|
3442
3442
|
const authorized = options.authorization.authorizeApproval ? await options.authorization.authorizeApproval({
|
|
3443
3443
|
...approvalAuthorizationInput,
|
|
3444
|
-
|
|
3444
|
+
actionInvocationId,
|
|
3445
|
+
decision,
|
|
3446
|
+
invocation: structuredClone(invocation)
|
|
3445
3447
|
}) : await options.authorization.authorize(approvalAuthorizationInput);
|
|
3446
3448
|
if (!entitled || !authorized) return {
|
|
3447
3449
|
...actionResult(invocation),
|