@servicenow/sdk - v4.9.0
    Preparing search index...

    Triggers object for a Playbook (Argument 2 of PlaybookDefinition).

    An object containing a triggers array. The I generic captures the playbook's declared inputs schema so that the mapper passed to each PlaybookTrigger() can be type-checked against it: both the left-side (mapping keys must be declared input names) and right-side (trigger.current autocompletes the trigger table) are constrained.

    { triggers: [
    PlaybookTrigger(
    PlaybookTriggerTypes.RecordCreate,
    { $id: ..., label: 'On Create' },
    { table: 'incident' },
    (trigger) => ({
    priority: wfa.playbook.dataPill(trigger.current.priority), // ← left + right intellisense
    }),
    ),
    ]}
    type PlaybookTriggerDeclaration<I extends Record<string, Column>> = {
        triggers: PlaybookTriggerInstance<I>[];
    }

    Type Parameters

    Index

    Properties

    Properties