Github action for sending dingtalk messages via webhook
- 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
}
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. |