Update Webhook
Endpoint: PUT /api/metadata/webhook
Updates an existing webhook definition.
Path parameters
| Paramaeter | Description | Type | Required |
|---|---|---|---|
| id | The unique identifier of the webhook to update. | string | Required. |
Request body
Format the request body as an array with the following parameters:
| Paramaeter | Description | Type | Required |
|---|---|---|---|
| name | The updated name of the webhook. | string | Required. |
| receiverWorkflowNamesToVersions | Map of workflow names to versions that receive the incoming webhook event. If the webhook is only used to start a workflow, this object can be empty. For example: "receiverWorkflowNamesToVersions": { "<WORKFLOW-NAME>": <WORKFLOW-VERSION> } | object | Optional. |
| sourcePlatform | The platform that sends webhook requests to Conductor. Supported values:
| string | Required. |
| verifier | The verification method used to validate incoming webhook requests. Supported values:
| string | Required. |
| headerKey | The header key used to verify incoming webhook requests. Supported values:
| string | Required for GitHub, Microsoft Teams, and Stripe. Not applicable for other platforms. |
| secretValue | The secret value used to verify incoming webhook requests. Supported platforms:
| string | Required for GitHub, Microsoft Teams, SendGrid, and Stripe. Not applicable for other platforms. |
| headers | The key-value pairs of headers used to validate incoming webhook requests. | object | Required for Custom. |
| workflowsToStart | Map of workflows configured to start when the webhook event is received. For example: "workflowsToStart": { "<WORKFLOW-NAME>": <WORKFLOW-VERSION> } | object | Optional. |
| workflowsToStart.idempotencyKey | The idempotency key to prevent duplicate workflow executions for the same webhook event. Supports variables from the workflow input, for example, ${workflow.input.someKey}. | string | Optional. |
| workflowsToStart.idempotencyStrategy | The strategy to use when a workflow with the same idempotency key already exists. Supported values:
| string | Optional. |
Response
Returns 200 OK with the updated webhook object.
Examples
Update a webhook
Request
curl -X 'PUT' \
'https://<YOUR-SERVER-URL>/api/metadata/webhook/dbe38f11-d0fd-4b1b-b6c8-5e6a72840dea' \
-H 'accept: application/json' \
-H 'X-Authorization: <TOKEN>' \
-H 'Content-Type: application/json' \
-d '{
"name": "updatedName",
"id": "dbe38f11-d0fd-4b1b-b6c8-5e6a72840dea",
"receiverWorkflowNamesToVersions": {
"http": 1
},
"urlVerified": false,
"sourcePlatform": "Custom",
"verifier": "HEADER_BASED",
"headers": {
"Some-key-4rhnv": "Some-val-xvdhu"
},
"secretValue": "***"
}'
Response
{
"name": "updatedName",
"id": "dbe38f11-d0fd-4b1b-b6c8-5e6a72840dea",
"receiverWorkflowNamesToVersions": {
"http": 1
},
"urlVerified": false,
"sourcePlatform": "Custom",
"verifier": "HEADER_BASED",
"headers": {
"Some-key-4rhnv": "Some-val-xvdhu"
},
"secretValue": "***",
"createdBy": "john.doe@acme.com"
}