Skip to content
message-square

GitHub Action

Dingtalk Webhook

v1.0.0 Latest version

Dingtalk Webhook

message-square

Dingtalk Webhook

Send DingTalk messages via webhook

Installation

Copy and paste the following snippet into your .yml file.

              

- name: Dingtalk Webhook

uses: ghostoy/dingtalk-action@v1.0.0

Learn more about this action in ghostoy/dingtalk-action

Choose a version

Dingtalk robot action

Github action for sending dingtalk messages via webhook

Example Usage

- name: send dingtalk message
  uses: ghostoy/dingtalk-action@master
  with:
    webhook: ${{ secrets.DINGTALK_WEBHOOK}}
    msgtype: markdown
    content: |
      {
        "title": "New push",
        "text": "commit: ${{ github.sha }}"
      }
    at: |
      {
        "atMobiles": [
          "1234567890"
        ],
        "isAtAll": false
      }

Options

option type required default description
webhook string Yes none The full address of dingtalk robot: https://oapi.dingtalk.com/robot/send?access_token=xxxxxx
msgtype string No text Dingtalk message type. Valid types are: text,markdown,link,actionCard,feedCard. Default: text.
content string Yes none Message content in JSON type. See Dingtalk Developer document for details.
at string No none At users in JSON type.
secret string No none Secret key generated by DingTalk. See DingTalk Developer document for details.