Webhooks
Introduction
It’s possible to retrieve change-events of absence groups with webhooks.
Caution
Read the Webhooks page. There is important information on required implementation!
Note
When an absence group is saved in myProtime, all absence groups are saved, even if there are no changes. This will result in webhook events for all absence groups.
Tip
Check the Swagger page for more technical information on the endpoints.
Endpoint details
POST
https://<tenant>.myprotime.eu/connector/protimeapi/api/v1/webhooks
Request properties
This list of properties can be sent in the request body.
| Property | Type | Description |
|---|---|---|
destinationUrl |
string | The URL where webhook events will be sent. |
collectionName |
string | The name of the collection to subscribe to (absence-groups). |
Event properties
This list of properties is returned by this endpoint.
| Property | Type | Description |
|---|---|---|
changeVersion |
string | Property to indicate the order of changes. |
id |
integer | Internal unique identifier for the absence group. |
name.default |
string | Default name value of the absence group. |
name.translations |
object | A list of translated names of the absence group by language code. |
type |
string | The type of the absence group (Absence, WorkingElsewhere). |
External references
It’s possible to use custom external references. More information can be found on the External References Page
Note
Check the query options below the endpoint on the Swagger page for the relevant external references.
Examples
Creating a webhook for absence groups
POST
https://<tenant>.myprotime.eu/connector/protimeapi/api/v1/webhooks
{
"destinationUrl": "https://www.fictional-customer.com/protime/absence-groups",
"collectionName": "absence-groups"
}