Skip to content

step-security/action-discord

Folders and files

NameName
Last commit message
Last commit date

Latest commit

ย 

History

25 Commits
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 

Repository files navigation

๐Ÿš€ Discord for GitHub Actions

Sends a Discord notification message. Simple as that. Supports all workflow event types by using the Discord GitHub webhooks.

Compatibility note

As this Action is containerized with Docker, it can only run on Linux environments.

Docker container actions can only execute in the GitHub-hosted Linux environment. Self-hosted runners must use a Linux operating system and have Docker installed to run Docker container actions. For more information about the requirements of self-hosted runners, see "About self-hosted runners."


Usage

- name: Discord notification
  env:
    DISCORD_WEBHOOK: ${{ secrets.DISCORD_WEBHOOK }}
  uses: step-security/action-discord@v0
  with:
    args: "The project {{ EVENT_PAYLOAD.repository.full_name }} has been deployed."

Arguments

By default, the GitHub action will send a notification with the event information. Providing the arguments will override the message.

Environment variables can be interpolated in the message using brackets ({{ and }}) :

e.g.: Action called : {{ GITHUB_ACTION }}

Event Payload data can also be interpolated in the message using brackets ({{ and }}) with the EVENT_PAYLOAD variable.

e.g.: Action called: {{ GITHUB_ACTION }} as {{ EVENT_PAYLOAD.pull_request.id }}

See the event types for valid payload information.

Examples

  • args = "Hello, beautiful ! I ran a GitHub Actions for you <3"
  • args = "I showed you my commit. Please respond."

Environment variables