StackStorm / hubot-stackstorm

Hubot plugin for integration with StackStorm event-driven infrastructure automation platform.
Apache License 2.0
49 stars 39 forks source link

Allow threading for the ack and result messages for the slack backend #237

Open skiedude opened 1 month ago

skiedude commented 1 month ago

Fixes: https://github.com/StackStorm/hubot-stackstorm/issues/161

Example action alias definition

ack:
  extra:
    slack:
      thread_response: true
  format: ":speech_balloon: ACK, Looking that up for you..."
  append_url: false
result:
  extra:
    slack:
      thread_response: true
  format: |
    On-Call:
    Name: {{execution.result.output.result.name}}
    Username: `@{{execution.result.output.result.user_name}}`
    Phone: {{execution.result.output.result.mobile_phone}}
Screenshot 2024-09-30 at 1 17 33 PM

Hubot-slack checks for the existence of envelope.message.thread_ts in order to thread the response instead of sending to the open channel https://github.com/slackapi/hubot-slack/blob/main/src/client.coffee#L191