Squidie.Step behaviour (squidie v0.1.2)

Copy Markdown View Source

Public contract for authoring native Squidie workflow steps.

Native steps return Squidie values and receive a Squidie.Step.Context. The runtime adapts them into the internal Jido execution path, so authors do not need to depend on Jido for the common workflow-step path.

Summary

Types

result()

@type result() ::
  {:ok, map()}
  | {:ok, map(), keyword()}
  | {:defer, term(), keyword()}
  | {:error, term()}
  | {:retry, term()}
  | {:retry, term(), keyword()}

schema()

@type schema() :: keyword(keyword())

Callbacks

run(input, context)

@callback run(input :: map(), context :: Squidie.Step.Context.t()) :: result()