Get Enter/Exit Logs
GET /api/log
Section titled “ /api/log”This endpoint retrieves a list of visitor entry and exit logs ordered by most recent.
Query Parameters
Section titled “Query Parameters”siteId Optional
ID of the subsite to filter announcements by. Default is “main”.
userName Optional
<first-name>:<last-name>
of the visitor to filter logs by.
startsAt Optional
Unix Epoch format (millis). This is the timestamp where the results will start and continue in the past (most recent).
Default is the current time.
endsAt Optional
Unix Epoch format (millis). This is the timestamp where the results will end and not go any further into the past (oldest).
limit Optional
Max item count in response.
Default is 30.
Security
Section titled “Security”This endpoint requires authentication. You must include a valid API key in the request header. Permission(s) Required: VIEW_USER_LOGS
Response Body
Section titled “Response Body”{ "last_date": timestamp, "data": LogEntry[]}
last_date
Unix Epoch format (millis). This is the timestmap of the last log entry in the response.
Use this to get the next page of logs by passing it as a query parameter to the next request.
data
Log entry data.
[ { "first_name": string, "last_name": string, "timestamp": timestamp, "direction": "enter" | "exit", "card_type": "CAC" | "ID" | "MANUAL", "selected_project": string | null, "site_id": string }, {...}]
first_name
First name of the visitor.
last_name
Last name of the visitor.
timestamp
Unix Epoch format (millis). This is the time when the log entry was created.
direction
Direction of the log entry. Either “enter” or “exit”.
card_type
Type of card used to enter/exit the system.
CAC
- Military ID cardID
- Plastic access cardMANUAL
- Manual entry (keyboard)
selected_project Nullable
Name of the project selected by the visitor.
This will be null if no project was selected.
site_id
ID of the subsite the visitor entered/exited from.