Skip to main content

Create Webhook Configuration

Overview​

Creates a new webhook configuration for the dynamic webhook router. Each configuration defines a unique key that serves as the webhook endpoint identifier, a path for the incoming URL, and specifies how incoming payloads should be processed via one of four execution types.

Command Details​

  • Command: CreateWebHookConfigCommand
  • Type: Command (write operation)

API Endpoint​

POST /api/bpm/cmd

Request Structure​

FieldTypeRequiredDescription
$typestringYesMust be CreateWebHookConfigCommand
keystringYesUnique key used as the webhook endpoint identifier
descriptionstringYesDescription of the webhook purpose
isEnabledboolYesWhether the configuration is enabled
pathstringYesThe URL path for this webhook
actionstringYesHTTP method (e.g., POST, GET)
executionTypeintYes0=ExecuteNativeCommand, 1=ExecuteCommandChain, 2=ExecuteCode, 3=StartProcess
executionCodestringConditionalInline script (required if executionType is 2)
processDefinitionIdlongConditionalBPMN process ID (required if executionType is 3)
commandNamestringConditionalBPM command name (required if executionType is 0)
allowableIPsstringNoComma-separated list of allowed IP addresses or CIDR ranges
info

Provide exactly one of commandName, processDefinitionId, or executionCode depending on the selected executionType.

Try It Out​

POST/api/bpm/cmdCreateWebHookConfigCommand
Request Body

Response Structure​

Success:

{
"success": true,
"data": {
"id": 201,
"key": "payment-notification",
"description": "Handle incoming payment notifications from NIBSS",
"isEnabled": true,
"path": "/webhooks/nibss/payment",
"action": "POST",
"executionType": 0,
"commandName": "ProcessNibssPaymentNotificationCommand",
"createdAt": "2026-03-09T10:30:00Z"
},
"message": "Webhook configuration created successfully"
}

Error:

{
"success": false,
"data": null,
"message": "Validation failed",
"errors": [
"Key is required",
"A webhook configuration with this key already exists"
]
}