Users webhook
Upon integrating with the users webhook, you will be notified of a variety of events that reflect the actions taken by users and admins within the system. These events are crucial for real-time monitoring and management of user-related activities.
Important to know
This article provides helpful insights and examples about users events. For the most up-to-date information, please follow this link.
Below is a detailed overview of the events you can expect to receive (you can set the relevant events for the webhook configuration via the API/UI):
eventType | Description |
---|---|
user_created | User was created in the system (whether from API/import/manual creation in the UI). |
user_updated | User field was updated in the system. In case of updating multiple fields, it will trigger a webhook for every updated field. The system will send the payload with all user fields (see examples below). |
user_archived | User was archived in the system. |
user_restored | User has been restored (unarchived) in the system. |
user_deleted | User was permanently deleted from the system. |
user_promoted | User was promoted from 'user' to 'admin'. |
user_demoted | User was demoted from 'admin' to 'user'. |
Additional information provided
- For created or updated events, the full payload of the user will be sent with the webhook, including all custom fields, smart group IDs, etc. (same as the payload in the response for Get users method).
- For archived, restored, deleted, promoted, or demoted events, only the user ID will be sent with the webhook. If additional information about the user is needed, you can use the 'Get Users' method and provide the user ID
Event examples
This section includes examples of the JSON payloads for event types mentioned, illustrating how the data is structured and what information is included. This practical insight helps in understanding how to process and react to each event within your system effectively:
Good to know
The most up-to-date payloads are shown in the API reference. Make sure to review the received payload for the most accurate configuration on your end.
user_created
{
"requestId": "ba973227-6f19-4e5f-8847-875147a05cb9",
"company": "gxwfiwvtldjuolft",
"activityType": "",
"evnetTimestamp": 1731595939,
"eventType": "user_created",
"data": [
{
"firstName": "Omer",
"lastName": "Vered",
"phoneNumber": "+15253214234",
"userType": "user",
"email": "[email protected]",
"customFields": [
{
"customFieldId": 6208756,
"value": "24/11/2024",
"type": "date",
"name": "Employment Start Date"
},
{
"customFieldId": 6208760,
"value": 7053349,
"type": "directManager",
"name": "Direct manager"
},
{
"customFieldId": 6208761,
"value": "25/01/1990",
"type": "birthday",
"name": "Birthday"
}
],
"isArchived": false,
"userId": 9063791,
"createdAt": 1731595936,
"modifiedAt": 1731595938,
"archivedAt": null,
"lastLogin": 0,
"smartGroupsIds": [],
"invitedToBeManager": null
}
]
}
user_updated
{
"requestId": "57a1eb7c-27c5-4a19-9a46-7df7d885df83",
"company": "gxwfiwvtldjuolft",
"activityType": "",
"evnetTimestamp": 1731596007,
"eventType": "user_updated",
"data": [
{
"firstName": "Omer",
"lastName": "Vered",
"phoneNumber": "+15253214234",
"userType": "user",
"email": "[email protected]",
"customFields": [
{
"customFieldId": 6208756,
"value": "24/11/2024",
"type": "date",
"name": "Employment Start Date"
},
{
"customFieldId": 6208760,
"value": 7053349,
"type": "directManager",
"name": "Direct manager"
},
{
"customFieldId": 6208761,
"value": "25/01/1990",
"type": "birthday",
"name": "Birthday"
},
{
"customFieldId": 7687992,
"value": "2132143",
"type": "str",
"name": "Employee ID"
},
{
"customFieldId": 7687993,
"value": [
{
"id": 0,
"value": "Man"
}
],
"type": "dropdown",
"name": "Gender"
}
],
"isArchived": false,
"userId": 9063791,
"createdAt": 1731595936,
"modifiedAt": 1731595938,
"archivedAt": null,
"lastLogin": 0,
"smartGroupsIds": [],
"invitedToBeManager": null
}
]
}
user_archived
{
"requestId": "f04c4bff-0db4-41db-b9e5-03f3de8f5092",
"company": "gxwfiwvtldjuolft",
"activityType": "",
"evnetTimestamp": 1731596054,
"eventType": "user_archived",
"data": [
{
"id": 9063791
}
]
user_restored
{
"requestId": "b8cc847f-a9da-4bc9-8f02-d69850c938c0",
"company": "gxwfiwvtldjuolft",
"activityType": "",
"evnetTimestamp": 1731596058,
"eventType": "user_restored",
"data": [
{
"id": 9063791
}
]
}
user_deleted
{
"requestId": "fbbe8d61-5942-425e-8a5f-04c26cbd9b0d",
"company": "gxwfiwvtldjuolft",
"activityType": "",
"evnetTimestamp": 1731596229,
"eventType": "user_deleted",
"data": [
{
"id": 9063791
}
]
}
user_promoted
{
"requestId": "a57d404d-5ae8-400d-b4bb-4144a90e6e7e",
"company": "gxwfiwvtldjuolft",
"activityType": "",
"evnetTimestamp": 1731596140,
"eventType": "user_promoted",
"data": [
{
"id": 9063791
}
]
}
user_demoted
{
"requestId": "e0a0392e-de31-4c0e-951a-8ec2bcbd9d34",
"company": "gxwfiwvtldjuolft",
"activityType": "",
"evnetTimestamp": 1731589332,
"eventType": "user_demoted",
"data": [
{
"id": 7330610
}
]
}
Updated 25 days ago