Skip to content

Interface: SlackNamespace ​

Defined in: slack/src/builders/slack-namespace-contract.ts:10

Public DSL builder namespace for @paraharness/slack (slack.*).

Exposes declarative factories for bidirectional Slack Socket Mode bots (slack.bot) and one-way incoming webhook notification channels (slack.webhook).

Methods ​

bot() ​

ts
bot(options): SlackApproverNode;

Defined in: slack/src/builders/slack-namespace-contract.ts:21

Creates a passive SlackApproverNode with interactionMode: 'bidirectional'.

Supports outbound notifications, interactive .ask() / .escalate() decisions, keep-alive heartbeats, cancelDecision, and Socket Mode control-plane signals.

Parameters ​

ParameterTypeDescription
optionsSlackBotOptionsApp token, bot token, and target Slack channel configuration.

Returns ​

SlackApproverNode

Frozen passive bidirectional Slack bot AST node.


webhook() ​

ts
webhook(webhookUrl): SlackNotifierNode;

Defined in: slack/src/builders/slack-namespace-contract.ts:33

Creates a passive SlackNotifierNode with interactionMode: 'notify-only'.

Dispatches outbound notifications via Slack incoming webhooks while statically forbidding bidirectional .ask() or .escalate() usage at AST validation time.

Parameters ​

ParameterTypeDescription
webhookUrlstring | EnvRefSlack incoming webhook URL or symbolic P.env(...) reference.

Returns ​

SlackNotifierNode

Frozen passive notify-only Slack webhook AST node.

Released under the MIT License.