Skip to content

Instantly share code, notes, and snippets.

@Porrapat
Created January 27, 2020 06:50
Show Gist options
  • Select an option

  • Save Porrapat/3b128379c29c35f1ad1fc7d93daf4c5c to your computer and use it in GitHub Desktop.

Select an option

Save Porrapat/3b128379c29c35f1ad1fc7d93daf4c5c to your computer and use it in GitHub Desktop.

Revisions

  1. Porrapat created this gist Jan 27, 2020.
    8 changes: 8 additions & 0 deletions send-slack-message.sh
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,8 @@
    # To use : add your slack oauth access api token
    SLACK_API_OAUTH_ACCESS_TOKEN=
    # Provide your slack channel
    SLACK_CHANNEL=
    # Provide your text
    TEXT=

    curl -s -X POST -d "token=$SLACK_API_OAUTH_ACCESS_TOKEN&channel=$SLACK_CHANNEL&text=$TEXT&pretty=1" "https://slack.com/api/chat.postMessage" > /dev/null