Workflows

Add a workflow

Add a new workflow

post/workflows

Request

Request body

namestring

A name you can use to describe your workflow

activeboolean

Indicates whether the workflow is currently active

Example request

{
  "name": "Webhooks workflow",
  "active": true,
  "conditions": [
    {
      "type": "event",
      "events": {
        "gateway": [
          "payment_approved",
          "payment_declined",
          "card_verification_declined",
          "card_verified",
          "payment_authorization_incremented",
          "payment_authorization_increment_declined",
          "payment_capture_declined",
          "payment_captured",
          "payment_refund_declined",
          "payment_refunded",
          "payment_void_declined",
          "payment_voided"
        ],
        "dispute": [
          "dispute_canceled",
          "dispute_evidence_required",
          "dispute_expired",
          "dispute_lost",
          "dispute_resolved",
          "dispute_won"
        ]
      }
    },
    {
      "type": "entity",
      "entities": [
        "ent_xyfdshfudosfdshfdiosfds",
        "ent_fidjosfjdisofdjsifdosfu"
      ]
    },
    {
      "type": "processing_channel",
      "processing_channels": [
        "pc_axclravnqf5u5ejkweijnp5zc4"
      ]
    }
  ],
  "actions": [
    {
      "type": "webhook",
      "url": "https://example.com/webhooks",
      "headers": {
        "Authorization": "<AUTHORIZATION_UUID>"
      },
      "signature": {
        "method": "HMACSHA256",
        "key": "8V8x0dLK%AyD*DNS8JJr"
      }
    }
  ]
}

Response

Workflow added successfully

idstring

The workflow identifier

Example response

{
  "id": "wf_wlu3wxc26jounofs5iez75qaqa",
  "_links": {
    "self": {
      "href": "https://{prefix}.api.checkout.com/workflows/wf_wlu3wxc26jounofs5iez75qaqa"
    }
  }
}

Changes

No recorded changes to this operation across all 1 revision of this API.