Users webhook

The Users webhook notifies you of user lifecycle events in real-time.

Events

Event TypeDescriptionPayload
user_createdNew user added to the systemFull user data
user_updatedUser profile was modifiedFull user data
user_archivedUser was archivedUser ID only
user_restoredUser was unarchivedUser ID only
user_deletedUser was permanently deletedUser ID only
user_promotedUser promoted to adminUser ID only
user_demotedAdmin demoted to userUser ID only

Event Examples

user_created

{
  "requestId": "ba973227-6f19-4e5f-8847-875147a05cb9",
  "company": "your_company_id",
  "activityType": "User",
  "eventTimestamp": 1731595939,
  "eventType": "user_created",
  "data": [
    {
      "userId": 9063791,
      "firstName": "John",
      "lastName": "Smith",
      "phoneNumber": "+15253214234",
      "email": "[email protected]",
      "userType": "user",
      "isArchived": false,
      "kioskCode": "JS1234",
      "createdAt": 1731595936,
      "modifiedAt": 1731595938,
      "archivedAt": null,
      "lastLogin": 0,
      "smartGroupsIds": [],
      "invitedToBeManager": null,
      "customFields": [
        {
          "customFieldId": 6208756,
          "name": "Employment Start Date",
          "type": "date",
          "value": "24/11/2024"
        },
        {
          "customFieldId": 6208760,
          "name": "Direct manager",
          "type": "directManager",
          "value": 7053349
        }
      ]
    }
  ]
}

user_updated

{
  "requestId": "57a1eb7c-27c5-4a19-9a46-7df7d885df83",
  "company": "your_company_id",
  "activityType": "User",
  "eventTimestamp": 1731596007,
  "eventType": "user_updated",
  "data": [
    {
      "userId": 9063791,
      "firstName": "John",
      "lastName": "Smith",
      "phoneNumber": "+15253214234",
      "email": "[email protected]",
      "userType": "user",
      "isArchived": false,
      "kioskCode": "JS1234",
      "createdAt": 1731595936,
      "modifiedAt": 1731596007,
      "archivedAt": null,
      "lastLogin": 0,
      "smartGroupsIds": [5321397],
      "invitedToBeManager": null,
      "customFields": [
        {
          "customFieldId": 7687992,
          "name": "Employee ID",
          "type": "str",
          "value": "EMP-2024-001"
        }
      ]
    }
  ]
}

user_archived

{
  "requestId": "f04c4bff-0db4-41db-b9e5-03f3de8f5092",
  "company": "your_company_id",
  "activityType": "User",
  "eventTimestamp": 1731596054,
  "eventType": "user_archived",
  "data": [
    {
      "id": 9063791
    }
  ]
}

user_restored

{
  "requestId": "b8cc847f-a9da-4bc9-8f02-d69850c938c0",
  "company": "your_company_id",
  "activityType": "User",
  "eventTimestamp": 1731596058,
  "eventType": "user_restored",
  "data": [
    {
      "id": 9063791
    }
  ]
}

user_deleted

{
  "requestId": "fbbe8d61-5942-425e-8a5f-04c26cbd9b0d",
  "company": "your_company_id",
  "activityType": "User",
  "eventTimestamp": 1731596229,
  "eventType": "user_deleted",
  "data": [
    {
      "id": 9063791
    }
  ]
}

user_promoted

{
  "requestId": "a57d404d-5ae8-400d-b4bb-4144a90e6e7e",
  "company": "your_company_id",
  "activityType": "User",
  "eventTimestamp": 1731596140,
  "eventType": "user_promoted",
  "data": [
    {
      "id": 9063791
    }
  ]
}

user_demoted

{
  "requestId": "e0a0392e-de31-4c0e-951a-8ec2bcbd9d34",
  "company": "your_company_id",
  "activityType": "User",
  "eventTimestamp": 1731589332,
  "eventType": "user_demoted",
  "data": [
    {
      "id": 9063791
    }
  ]
}

User Payload Fields

For user_created and user_updated events:

FieldTypeDescription
userIdintegerUnique user identifier
firstNamestringUser's first name
lastNamestringUser's last name
phoneNumberstringUser's phone number with country code
emailstringUser's email address
userTypestringuser, manager, or owner
isArchivedbooleanWhether the user is archived
kioskCodestringCode for kiosk app access
createdAtintegerUnix timestamp of user creation
modifiedAtintegerUnix timestamp of last modification
archivedAtintegerUnix timestamp when archived (null if active)
lastLoginintegerUnix timestamp of last login (0 if never logged in)
smartGroupsIdsarrayIDs of smart groups the user belongs to
invitedToBeManagerbooleanWhether user has pending manager invite
customFieldsarrayUser's custom field values

Fetching Additional User Data

For events that only include the user ID (archived, restored, deleted, promoted, demoted), use the Get Users API to fetch complete user details.


API Reference