@karmaniverous/jeeves-scripts-core
    Preparing search index...

    Function dispatchWithSlack

    • Dispatch a worker with job-side Slack I/O.

      Parameters

      • task: string

        Base TASK text.

      • options: DispatchOptions

        Runner dispatch options (jobId, thinking, timeout, …).

      • slackConfig: {
            accountId?: string;
            posts?: {
                editTs?: string[];
                pin?: boolean;
                purpose: string;
                target: string;
            }[];
            reads?: {
                label: string;
                limit?: number;
                target: string;
                threadTs?: string;
            }[];
        }

        Reads and allowed post targets (validated here).

        • OptionalaccountId?: string

          Gateway Slack account id (multi-account gateways, e.g. <account-id>).

        • Optionalposts?: { editTs?: string[]; pin?: boolean; purpose: string; target: string }[]

          Targets the worker may post to. Each normalized target may appear once: aliases (C… vs channel:C…) would otherwise overwrite each other's editTs/pin permissions order-dependently.

        • Optionalreads?: { label: string; limit?: number; target: string; threadTs?: string }[]

          Reads made before dispatch.

      • Optionalflags:
            | readonly string[]
            | Partial<ParsedArgs<{ dryRun: FlagSpec; printTask: FlagSpec }>>

        dryRun / printTask (lib/dispatcher-flags), or raw arguments to read them from (default: process.argv).

      Returns Promise<WorkerSlackResult>

      The run result.

      Error when the Slack config is invalid (before any side effect).