Create Trigger to notify active Webhook through API


1 댓글

  • Zach Anthony
    Zendesk Product Manager

    Hi Pavel,

    In order to create a Trigger via our API to notify a webhook the action should be specified as notification_webhook and follows the same structure as creating a Target.

    You can provide the Webhook's request body through the API as well - you will just need to use an escaped JSON string.

    An example of the request body would look like the sample below, where the action has two properties; field (which should be set to notification_webhook) and the value which takes an array consisting of two strings specifying the ID of the Webhook and the message body

    "trigger": {
    "title": "Test Trigger",
    "description": "Test Trigger to Notify Webhook",
    "actions": [
    "field": "notification_webhook",
    "value": [
    "{\"ticket-title\": \"{{ticket.title}}\",\"static-string\": \"Sample\"}"
    "conditions": {
    "all": [
    "field": "status",
    "operator": "is",
    "value": "new"
    "any": []
    "category_id": "809956"

    I've noticed that our documentation is unclear on this particular topic, so I'll go ahead and update that.

    Hope this helps!


댓글을 남기려면 로그인하세요.

Zendesk 제공