Tracking Changes with Audit Entries

Audit Entries serve as change logs and provide a lot of useful information that can be helpful when investigating an unexpected change that has occurred within an account.

Query Params

There are no required parameters when making a call to List Audit Entries, however, there are a number of optional params that help with narrowing down your results.

locationId - when provided results will only consist of events that have been associated with that locationId. Events for some entity types will not be listed when a locationId is provided ie. services, resources, account-wide webhooks, etc. If no locationId is provided, all events for the account will be listed (assuming the User associated with the api-key has access to all locations on the account).

event - This is entity type (ie. location, resource, service, etc) combined with the event type (created, updated or removed), ie. location.updated, resource.removed, etc.

entityId - this can be the visitId, customerId, resourceId, serviceId, userId, etc. For example, if you want to see what user made a change to a specific visit, you can provide the visitId to narrow down your search to only show events for that visit.

fromDate/toDate - When provided, the created timestamp for all entries will fall within that date range. If not fromDate is not provided in the request, results will only be show for the previous month (~30days).

Entity & Event Types

Entity TypeDescriptionEvent Types
ACCOUNTAny change made to an account such as account level settings and plan/billing related updates. Because account endpoints are not currently publicly exposed in the API, most of these events will be automated CRON tasks or required/requested account updates made by Waitwhile staff. account.updated
LOCATIONLogs when a location is created, removed, or a location level setting or configuration has been changed. ie. a User changes business hours, or "force closes" the Waitlist. location.created
location.updated
location.removed
USERLogs when a user is created, removed, logs in/out of Waitwhile, or some aspect of the user is updated such as personal profile details or user notification preferences. user.created
user.updated
user.removed
user.log-in
user.log-out
user.password-reset
CUSTOMERLogs when a customer is created, removed, or some aspect of the customer profile has been changed (ie. name, email, phone, tags, etc), a customer note has been added/changed, or a customer had a new recent visit. customer.created
customer.updated
customer.removed
VISITLogs when a visit (Waitlist, Booking, Capacity Management) has been created, removed (deleted completely). or any aspect of a visit has been updated such either automatically (ie. position in line has changed, or visit has expired), by a user (ie. User has marked visit as SERVED, or manually changed the appointment time) or by the customer themselves (ie. Customer has marked themselves as ARRIVED from their Status Page).visit.created
visit.updated
visit.removed
visit.exported
visit.imported
MESSAGELogs when a customer or user notification has been created and when the delivery status of a message has been updated. These events can apply to SMS, EMAIL, and PUSH Notifications. message.created
message.updated
SERVICELogs when an individual Service or Service Category has been created, updated, duplicated or removed.service.created
service.updated
service.duplicated
service.removed
RESOURCELogs when an individual Resource or Resource Category has been created, updated, duplicated or removed. resource.created
resource.updated
resource.duplicated
resource.removed
DATA-FIELDLogs when a Data-Field has been created, updated, duplicated or removed.data-field.created
data-field.updated
data-field.duplicated
data-field.removed
WEBHOOKLogs when a Webhook (on an account, location, or via Zapier) has been created, updated, or removed. webhook.created
webhook.updated
webhook.removed

Additional Uncommon Entity and Event Types

There are some additional entity and event types that may show up in results when no filters have been provided in the request, but tend to be less common or are related to automated CRON tasks or changes made by Waitwhile. Entity Types listed below that are not available as filter options when Listing Audit Entries are marked with an asterisk*.

Entity TypeEvent Types
ACCOUNTaccount.anonymized-customer-data
account.expired-account-data
account.expired-account-hours
account.removed-customer-data
account.merged
account.saml-sso-configured
account.settings-copied
account.replenished
account.low-visit-quota
account.low-message-quota
account.low-message-credit
ADMIN*admin.anonymized-contact-personal-data
API-KEY*api-key.created
api-key.removed
ANALYTICS*analytics.removed-customer-data
analytics.moved-data
AUDIT-ENTRY*audit-entry.copied-data
BACKUP*backup.created
backup.removed
backup.restored
backup.restore-started
CUSTOMER-NOTE*customer-note.created
customer-note.updated
customer-note.removed
FILE*file.created
file.removed
file.copied
INVITE*invite.created
invite.resend
invite.resolved
invite.expired
invite.removed
LOCATIONlocation.cleared-visits
location.messaging-provisioned
location.messaging-deprovisioned
location.bot-provisioned
location.bot-deprovisioned
MESSAGE-BLOCK*message-block.created
message-block.removed
MESSAGE-TEMPLATE*message-template.created
message-template.updated
message-template.removed
USERuser.email-verification-sent
user.moved
user.sso-provisioned
user.auth-tokens-revoked

Audit Entry Responses

The main parts of every audit entry:

id - unique ID for this specific audit entry

requestID - unique ID to log this specific audit entry pull

event - the type of change event, ie. account.updated, location.created, visit.removed, etc

user - object containing details pertaining to the user responsible for the change. If impersonatorId has a value, then the change was facilitated by a Waitwhile employee

entity - object consisting of entity ID and type

changes - array containing details of all changes that occurred for the respective event. Includes what previous values were before the change.

created - the time (in UTC) in which the change event took place

Response Examples

Below are a few single entry response examples for the most common entity and event types.

Updated Events

{
  "results": [
    {
      "id": "29amWruk66nVBf8qXuHS",
      "created": "2023-03-30T20:08:54.254Z",
      "event": "account.updated",
      "requestId": "807e85c12ea9edb8d928029cf925b55d",
      "organizationId": "U0DYdKDfhzfhQPawmhnz",
      "accountId": "itiDKblwItcJsAxO8kFs",
      "locationId": null,
      "user": {
        "id": "CX66OjfGV7aFJoAhDq7p0b6PH2M2",
        "impersonatorId": null,
        "remoteIp": "127.0.0.1",
        "country": "US",
        "region": "state/region abbreviation",
        "city": "city name",
        "userAgent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/111.0.0.0 Safari/537.36"
      },
      "entity": {
        "id": "FejxZ0WWpXTjzIScVEq0",
        "type": "ACCOUNT"
      },
      "locationId": "FejxZ0WWpXTjzIScVEq0",
      "event": "account.updated",
      "info": [],
      "changes": [
        {
          "name": "lastActive",
          "new": "2023-03-30T20:08:54.202Z",
          "old": "2023-03-30T13:37:04.526Z",
          "op": "UPDATE"
        }
      ],
    }
  ],
  "limit": 20,
  "startAt": "0HwAhbQfKaErDRMfvtNX",
  "endAt": "FHc40kMS7KEBHMa9DOBL"
}
{
  "results": [
    {
      "id": "29amWruk66nVBf8qXuHS",
      "created": "2023-03-30T20:08:54.254Z",
      "event": "location.updated",
      "requestId": "807e85c12ea9edb8d928029cf925b55a",
      "organizationId": "U0DYdKDfhzfhQPawmhnz",
      "accountId": "itiDKblwItcJsAxO8kFs",
      "locationId": "mu9bxRmGIckqIK61fDtP",
      "user": {
        "id": "CX66OjfGV7aFJoAhDq7p0b6PH2M2",
        "impersonatorId": null,
        "remoteIp": "127.0.0.1",
        "country": "US",
        "region": "state/region abbreviation",
        "city": "city name",
        "userAgent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/111.0.0.0 Safari/537.36"
      },
      "entity": {
        "id": "mu9bxRmGIckqIK61fDtP",
        "type": "LOCATION"
      },
      "info": [],
      "changes": [
        {
          "name": "hoursByDate.20230308.isOpen",
          "new": "false",
          "old": null,
          "op": "ADD"
        }
      ]
    }
  ],
  "limit": 20,
  "startAt": "0HwAhbQfKaErDRMfvtNX",
  "endAt": "FHc40kMS7KEBHMa9DOBL"
}
{
  "results": [
    {
      "id": "29amWruk66nVBf8qXuHS",
      "created": "2023-03-09T16:48:14.519Z",
      "event": "visit.updated",
      "requestId": "807e85c12ea9edb8d928029cf925b55a",
      "organizationId": "U0DYdKDfhzfhQPawmhnz",
      "accountId": "itiDKblwItcJsAxO8kFs",
      "locationId": "mu9bxRmGIckqIK61fDtP",
      "user": {
        "id": "CX66OjfGV7aFJoAhDq7p0b6PH2M2",
        "impersonatorId": null,
        "remoteIp": "127.0.0.1",
        "country": "US",
        "region": "state/region abbreviation",
        "city": "city name",
        "userAgent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/111.0.0.0 Safari/537.36"
      },
      "entity": {
        "id": "EPblTwHucwmxJ30qCd48",
        "type": "visit"
      },
      "info": [],
      "changes": [
        {
          "name": "completedTime",
          "new": "2023-03-09T16:48:14.519Z",
          "old": null,
          "op": "ADD"
        },
        {
          "name": "tags.0",
          "new": "REMOVED",
          "old": null,
          "op": "ADD"
        },
        {
          "name": "state",
          "new": "COMPLETE",
          "old": "DRAFT",
          "op": "UPDATE"
        },
        {
          "name": "removedTime",
          "new": "2023-03-09T16:48:14.519Z",
          "old": null,
          "op": "ADD"
        },
        {
          "name": "ticket",
          "new": "A046",
          "old": null,
          "op": "ADD"
        }
      ]
    }
  ],
  "limit": 20,
  "startAt": "0HwAhbQfKaErDRMfvtNX",
  "endAt": "FHc40kMS7KEBHMa9DOBL"
}