Skip to content

feat(slack-notify): add bot-token path with thread + update support#6

Merged
vklimontovich merged 1 commit into
mainfrom
feat/slack-bot-thread
May 11, 2026
Merged

feat(slack-notify): add bot-token path with thread + update support#6
vklimontovich merged 1 commit into
mainfrom
feat/slack-bot-thread

Conversation

@vklimontovich
Copy link
Copy Markdown
Contributor

Summary

  • Adds bot-token path to the composite slack-notify action: when bot_token + channel are set, the action posts via chat.postMessage (or chat.update when update_ts is set) and outputs ts.
  • Adds thread_ts input for posting threaded replies.
  • Adds ts and channel outputs so callers can thread or edit later.
  • Webhook path stays as backward-compatible fallback (with a warning if thread_ts / update_ts are passed — webhooks can't thread).
  • Reusable workflow (.github/workflows/slack-notify.yml) surfaces the same new inputs/outputs and pulls the new DEPLOY_BOT_SLACK_TOKEN org secret directly (with CI_SLACK_WEBHOOK retained as fallback).

Required secrets

  • DEPLOY_BOT_SLACK_TOKEN — already created at org level (xoxb-... from the deploy_bot Slack app, scope: chat:write).

Merge order

This PR is the first of three coordinated changes; the downstream PRs depend on it. After merging:

  • Cut a new release tag if you want downstream callers to pin (optional — the downstream PRs currently reference @main).
  • Then merge:
    1. jitsucom/jitsu#<PR> — services.yaml uses the reusable workflow + accepts slack_thread_ts.
    2. jitsucom/jitsu-cloud-infra#<PR> — deploy.yaml threads notifications and propagates thread_ts into the services.yaml dispatch.

Test plan

  • Manually trigger Slack notify (reusable) via the Actions UI, verify it posts to #dev and outputs a ts.
  • Re-trigger with thread_ts set to that ts, verify the reply lands in the thread.
  • Re-trigger with update_ts set, verify the original message updates in place.
  • Test the legacy webhook path by calling the composite action with only slack_webhook_url set.

Adds chat.postMessage / chat.update support via bot_token + channel inputs.
Returns the message ts as an output so callers can thread later messages or
edit the parent. Webhook path remains as backward-compatible fallback.

Reusable workflow surfaces the new inputs/outputs and now pulls the
DEPLOY_BOT_SLACK_TOKEN org secret directly.
Copy link
Copy Markdown

@jitsu-code-review jitsu-code-review Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Validated the range a8928dc..200b7b1, including the new bot-token Slack path, webhook fallback, and reusable-workflow outputs wiring. I don’t see new actionable bugs, security issues, or correctness regressions in this change set.

@vklimontovich vklimontovich merged commit e6d052a into main May 11, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant