Sanity Library Reference Docs
    Preparing search index...

    Function provisionWorkflowResource

    • Provision (create or update) a workflow resource: run the engine's definition deploy for the resource's deployment. One function for both lifecycle phases because the deploy is content-addressed and create-only — identical content is a per-definition no-op (unchanged), any change mints the next immutable version, and prior versions (with the instances pinned to them) are never touched. Re-running after a partial failure converges.

      A definition removed from the deployment since the last provision is retained, not deleted. Manifest edits and stack destroy never delete definitions; rollbackWorkflowResource is the sole lifecycle exception and removes only versions created by its partition-bound receipt.

      Parameters

      Returns Promise<WorkflowProvisionReceipt>