Create

  • POST
  • /workspaces
  • /:workspace
  • /webhooks

Creates a new webhook. Restricted to admins only.

Request

REQUIRED SCOPES
WEBHOOK_ADD
URL PARAMETERS
workspacerequiredstring
The workspace name.
POST PARAMETERS
eventsrequiredstring[]
The array of events describing when the webhook will be executed. Can be set of PUSH, EXECUTION_STARTED, EXECUTION_SUCCESSFUL, EXECUTION_FAILED or EXECUTION_FINISHED.
target_urlrequiredstring
The URL to which the payload will be sent.
projectsrequiredstring[]
The array of project name IDs from which webhooks will be executed.
secret_keyrequiredstring
The value sent in the payload required by the webservice to validate the request.

Last modified on Jan 19, 2026

Request example

curl -X POST "https://api.buddy.works/workspaces/:workspace/webhooks" \ -H "Authorization: Bearer <YOUR-TOKEN>" \ -H "Content-Type: application/json" \ -d '{ "target_url": "http://localhost", "secret_key": "mysecretkey", "projects": [ "company-website", "beta-project" ], "events": [ "EXECUTION_FAILED" ] }'

Response

EXAMPLE RESPONSE
{ "url": "https://api.buddy.works/workspaces/buddy/webhooks/2", "html_url": "https://app.buddy.works/buddy/webhook/2", "id": 2, "target_url": "http://localhost", "secret_key": "mysecretkey", "projects": [ "company-website", "beta-project" ], "events": [ "EXECUTION_FAILED" ] }
STATUS
201 Created