Skip to content

SudoAuthContext

Describes an execution that runs with system authority on behalf of a named principal.

The context carries Runtime authority within its Workspace, so Role checks and operation Grants pass. The Runtime stamps SudoAuthContext.underlyingPrincipalId on published Events as their originating principal and uses it when a Role is assigned to 'current'.

readonly tag: string

A short label naming what started this execution, such as a script or subsystem, for tracing.


readonly type: "sudo"

Discriminates this context from the other members of AlpyneAuthContext.


readonly underlyingPrincipalId: string

The principal the system is acting for; stamped on published Events and used when a Role is assigned to 'current'.


readonly workspaceId: string

The Workspace every operation in this execution is scoped to.