Skip to content

@intutic/gate / workflow / IntuticWorkflowRefusal

Class: IntuticWorkflowRefusal ​

A refused call inside a durable workflow.

name is 'FatalError' — NOT 'IntuticGateRefusal' — on purpose: the workflow runtime's FatalError.is() duck-types on that exact string (see module doc), and it is the only cross-VM-realm-safe way to tell the runtime "abort, do not retry". Everything else about the refusal contract is preserved: instanceof IntuticGateRefusal still holds (same realm), .message still carries the [Intutic Governance] BLOCKED: prefix, and .reason/.code/.incidentId carry the structured verdict. fatal: true mirrors the property the real FatalError class sets, for code that checks the flag rather than the name.

Extends ​

Constructors ​

Constructor ​

ts
new IntuticWorkflowRefusal(
   reason, 
   code, 
   incidentId?, 
   holdId?
): IntuticWorkflowRefusal;

Parameters ​

ParameterType
reasonstring
code| "SSO_GROUP" | "SNAPSHOT" | "HELD" | "SERVER_BLOCKED" | "SERVER_HELD" | "SERVER_NOT_APPROVED" | "TOOL_DISABLED" | "SERVER_NOT_ALLOWED" | "POLICY_SNAPSHOT_UNVERIFIED" | "SOP_RULE" | "HOOK_GATE" | "COMMAND_TOO_LARGE" | "CHAOS_FAULT" | "E_UNPINNED_LATEST" | "E_UNPINNED_TAG" | "E_UNKNOWN_REGISTRY" | "E_UNKNOWN_IMAGE" | "E_DIGEST_MISMATCH" | "E_MANIFEST_UNPARSEABLE" | "WORKFLOW_SANDBOX" | "NO_GATE"
incidentId?string
holdId?string

Returns ​

IntuticWorkflowRefusal

Overrides ​

IntuticGateRefusal.constructor

Properties ​

PropertyModifierTypeDescriptionInherited from
codereadonly| "SSO_GROUP" | "SNAPSHOT" | "HELD" | "SERVER_BLOCKED" | "SERVER_HELD" | "SERVER_NOT_APPROVED" | "TOOL_DISABLED" | "SERVER_NOT_ALLOWED" | "POLICY_SNAPSHOT_UNVERIFIED" | "SOP_RULE" | "HOOK_GATE" | "COMMAND_TOO_LARGE" | "CHAOS_FAULT" | "E_UNPINNED_LATEST" | "E_UNPINNED_TAG" | "E_UNKNOWN_REGISTRY" | "E_UNKNOWN_IMAGE" | "E_DIGEST_MISMATCH" | "E_MANIFEST_UNPARSEABLE" | "WORKFLOW_SANDBOX" | "NO_GATE"-IntuticGateRefusal.code
fatalreadonlytrue--
holdIdreadonlystring | undefinedThe hold's id when the refusal was a hold (code HELD); see IntuticGateHold.-
incidentIdreadonlystring | undefined-IntuticGateRefusal.incidentId
reasonreadonlystring-IntuticGateRefusal.reason

Methods ​

from() ​

ts
static from(refusal): IntuticWorkflowRefusal;

Rewrap a core refusal so the durable runtime treats it as fatal.

Parameters ​

ParameterType
refusalIntuticGateRefusal

Returns ​

IntuticWorkflowRefusal


is() ​

ts
static is(value): boolean;

Cross-realm-safe detection (the same trick FatalError.is itself uses): instanceof fails across the workflow vm boundary, so this checks the duck-typed name plus this package's own message prefix.

Parameters ​

ParameterType
valueunknown

Returns ​

boolean

The circuit breaker for AI agents