CircleCI Orb for sending Slack messages via webhooks.
Find a file
2020-10-17 23:15:33 +09:00
CHANGELOG.md Prepare 1.0.0 release. 2020-10-17 23:15:33 +09:00
LICENSE Add initial orb config. 2020-10-17 19:32:37 +09:00
README.md Fix typo. 2020-10-17 22:57:34 +09:00
slack-webhook-orb.yml Prepare 1.0.0 release. 2020-10-17 23:15:33 +09:00

Slack Webhook CircleCI Orb CircleCI Orb Version

Setup

  1. Create a webhook.
  2. Generate a JSON payload.
  3. Place the webhook in a CircleCI environment variable (SLACK_WEBHOOK by default, but customizable).
  4. Call the orb:
    slack-webhook/send-message:
      json-payload: |
        {
          "blocks": [
            {
              "type": "section",
              "text": {
                "type": "mrkdwn",
                "text": "Hello from <https://github.com/adamu|@adamu>'s `slack-webhook` CircleCi orb! 👋"
              }
            }
          ]
        }    
    

Usage

The json-payload argument must always be provided.

There are three ways to provide the webhook URL:

  1. Via the SLACK_WEBHOOK environment variable.
  2. Via a custom environment variable. Provide the name with the webhook-url-env-var parameter.
  3. Directly to the send-message command with the webhook-url parameter.

See the full examples on the orb's CircleCI Orb Repository listing.

Changelog

See the CHANGELOG.