Skip to main content

Function: normalizeAnnotateArgs()

normalizeAnnotateArgs(args): object[]

Defined in: packages/workflow-engine/src/kernel/helpers/annotation-buffer.ts:32

Normalize the three ctx.annotate(...) call forms into a flat list of { key, value, opts } records. Handlers wire these into the AnnotationBuffer with their own stage-scope fields.

Forms:

  • typedKey: (key: TypedKey<T>, value: T, opts?) — object with a string key property and no attributes field
  • string: (key: string, value: unknown, opts?)
  • batch: (args: { attributes, actor?, payload?, idempotencyKey? })

Parameters​

args​

unknown[]

Returns​

object[]