Webhooks allow you to subscribe to build events on your QuickBuild instance. When one of those events is triggered, we'll send a HTTP POST payload to the webhook's configured URL.
You can set up Webhooks for one configuration as many as you want. The configuration setting looks like below:
The build events include:
- BUILD_STARED when build is stared
- BUILD_FINISHED when build is finished
- BUILD_RECOMMENDED when build is recommended
- BUILD_UNRECOMMENDED when build is un-recommended
The payload data can be any JSON string. If it is empty, the build model will be delivered.
Below is an example of build model:
HTTP POST payloads that are delivered to your webhook's configured URL endpoint will contain several special headers:
|X-QB-EventType||Name of the event type that triggered the delivery, can be: BUILD_STARTED, BUILD_FINISHED|
|X-QB-Signatuer||The HMAC hex digest of the response body. This header will be sent if the webhook is configured with a secret. The HMAC hex digest is generated using the sha1 hash function and the secret as the HMAC key.|
Below is an example with Java on how to create the signature: