Skip to content

Commit ea295b1

Browse files
claude[bot]claude
andauthored
docs(ui): the flow face of recordLoadDenied is populated since #15168 (#15303) (#15583)
The "Flow actions" paragraph under "Authorization inside an action" still carried the honesty clause the contract's TSDoc carried before #15168: that on the flow face `recordLoadDenied` is "declared but not yet populated" and a guard on it is "inert (never `true`), never wrong". That is false on `main`. `dispatchFlowAction` spreads `actionRecordLoadSignal(subject)` into the context it hands `automation.execute` (`packages/runtime/src/action-execution.ts:904`), and both action doors reach it through that one function — the REST `/actions` route (`packages/runtime/src/domains/actions.ts:732`) and the MCP `run_action` bridge (`packages/runtime/src/action-execution.ts:1758`), each passing the whole `ActionSubjectRecordLoad` rather than a bare record. The direction of the defect is the inverted form of the Prime Directive #10 corollary: not a doc advertising a capability the runtime does not deliver, but a doc denying one it now does — so an author reading it would not write the `runAs: 'system'` guard the two-card sequence exists to enable, and no gate reports it. The replacement transcribes the sentence that landed on the contract (`packages/spec/src/contracts/automation-service.ts:56`), adapted to docs voice by naming the two doors, which that page's readers otherwise cannot resolve. The surrounding `runAs: 'user'` / `runAs: 'system'` prose and the `ctx.record.id` table are untouched. Claude-Session: https://claude.ai/code/session_012zGPuVVX3deAx9LdjK8jCk Co-authored-by: Claude <noreply@anthropic.com>
1 parent 17ec4b1 commit ea295b1

1 file changed

Lines changed: 6 additions & 5 deletions

File tree

‎content/docs/ui/actions.mdx‎

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -379,11 +379,12 @@ default for a row-scoped action on a `private` object is to refuse.
379379
(`AutomationContext`, the `@objectstack/spec` contract) declares the same key
380380
in the same spelling, `recordLoadDenied?: true`, so a `runAs: 'system'` flow
381381
has something to guard on before it acts on a row its invoker could not read.
382-
On the flow face the key is **declared but not yet populated**: the flow
383-
dispatcher does not pass the signal into the run's context yet, so until that
384-
lands a flow run never sees it and a guard on it is inert (never `true`), never
385-
wrong. A `runAs: 'user'` flow needs no guard — it re-derives the caller's
386-
scope on its own reads, and the stub resolves to nothing.
382+
On the flow face the key is **populated** since #15168: `dispatchFlowAction`
383+
takes the producer's load outcome and spreads the signal into the context it
384+
hands `automation.execute`, on both doors — the REST `/actions` endpoint and
385+
the MCP `run_action` bridge — so a flow run receives this key exactly when a
386+
handler would. A `runAs: 'user'` flow needs no guard — it re-derives the
387+
caller's scope on its own reads, and the stub resolves to nothing.
387388
388389
## Call it over REST
389390

0 commit comments

Comments
 (0)