List user events Returns events for one user within a specified date range and with optional filters.
This endpoint returns events for a single user within a selected date range.
Provide either id or identifier as query parameter to select the user, and use the request body to define date range, optional filters, and pagination.
Examples
Below you can see several examples of how to use this endpoint to retrieve events from a single user. Further down this page, you can find a detailed reference of all the available options you can pass.
Copy the JSON body of any of these examples, and use it in a POST request to https://api.vemetric.com/v1/users/events?id=123 (or ?identifier=your-user-id) with your API key.
All events for one user in the last 30 days Only specific events in January Pagination: fetch the next page of events
Be sure to also check out the filter values endpoint to see which values you can use in the filters field.
Bearer token for a project API key. This endpoint returns data for that project only.
Example: Bearer vem_abcdefghijklmnopqrstuvwxyz123456
Query Parameters
Vemetric's internal user ID. You have to either provide id or identifier.
Example: 123
identifier
string
optional
User identifier value. You have to either provide identifier or id.
Example: your-user-id
Request Body (required) application/json object
dateRange
* required
Description
Can be either one of the preset strings below, or an array with two date strings [start, end]. Date strings can be either in YYYY-MM-DD format or UTC ISO-8601 format with second precision. Type
"live" | "1hr" | "24hrs" | "7days" | "30days" | "3months" | "6months" | "1year" | array<string, string>
Example
["2026-01-01T12:00:00Z","2026-01-31T12:00:00Z"]
filters
Description
Optional filters to restrict returned events.
Show nested properties (5)
type: event
Description
Filter by event name and/or event property values. Example
{"type":"event","name":{"operator":"eq","value":"signup"},"properties":[{"property":"plan","operator":"eq","value":"pro"}]}
Show nested properties (2)
name
Description
Filter by event name.
Show nested properties (2)
value
* required
Description
Value to filter by operator
* required
Description
Operator to apply for the string filter. "eq" means equals, "notEq" means not equals. Type
"any" | "eq" | "notEq" | "contains" | "notContains" | "startsWith" | "endsWith"
properties
Description
Filter by one or more custom event properties.
Show nested properties (3)
property
* required
Description
Event property key inside custom event data. value
* required
Description
Event property value to compare against. operator
* required
Description
String matching operator for value. Type
"any" | "eq" | "notEq" | "contains" | "notContains" | "startsWith" | "endsWith"
type: page
Description
Filter based on specific page view properties, like the full URL (origin + path + hash) or its individual parts. Example
{"type":"page","origin":{"value":"https://example.com","operator":"eq"},"path":{"value":"/blog","operator":"startsWith"}}
Show nested properties (3)
origin
Description
Filter based on the page origin (protocol + host). For example, "https://example.com".
Show nested properties (2)
value
* required
Description
Value to filter by operator
* required
Description
Operator to apply for the string filter. "eq" means equals, "notEq" means not equals. Type
"any" | "eq" | "notEq" | "contains" | "notContains" | "startsWith" | "endsWith"
path
Description
Filter based on the page path. For example, "/blog".
Show nested properties (2)
value
* required
Description
Value to filter by operator
* required
Description
Operator to apply for the string filter. "eq" means equals, "notEq" means not equals. Type
"any" | "eq" | "notEq" | "contains" | "notContains" | "startsWith" | "endsWith"
hash
Description
Filter based on the page hash. For example, "#section1".
Show nested properties (2)
value
* required
Description
Value to filter by operator
* required
Description
Operator to apply for the string filter. "eq" means equals, "notEq" means not equals. Type
"any" | "eq" | "notEq" | "contains" | "notContains" | "startsWith" | "endsWith"
type: browser
Description
Filter by browser. Example
{"type":"browser","operator":"oneOf","value":["Chrome"]}
Show nested properties (2)
value
* required
Description
List of browser names to match. Example
["Chrome","Safari"]
operator
* required
Description
List matching operator for value. Type
"any" | "oneOf" | "noneOf"
type: device
Description
Filter by device type. Example
{"type":"device","operator":"oneOf","value":["desktop"]}
Show nested properties (2)
value
* required
Description
List of device types to match. Example
["desktop","mobile"]
operator
* required
Description
List matching operator for value. Type
"any" | "oneOf" | "noneOf"
type: os
Description
Filter by operating system. Example
{"type":"os","operator":"oneOf","value":["macOS"]}
Show nested properties (2)
value
* required
Description
List of operating system names to match. Example
["macOS","Windows"]
operator
* required
Description
List matching operator for value. Type
"any" | "oneOf" | "noneOf"
filtersOperator
Description
Operator to apply between multiple filters. limit
Description
Limits the number of returned events. Max value is 1000. offset
Description
Number of events to skip from the start of the result set. Responses 200 Success
application/json period
Description
Resolved query period. from
Description
Resolved UTC start timestamp for the events query window. Type
string<pattern:^\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}Z$>
Example
"2026-01-19T12:30:00Z"
to
Description
Resolved UTC end timestamp for the events query window. Type
string<pattern:^\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}Z$>
Example
"2026-01-19T12:30:00Z"
pagination
Description
Pagination metadata. limit
Description
Applied row limit. offset
Description
Applied row offset. returned
Description
Number of event rows returned in events. events
Description
List of user events for the requested page. sessionId
Description
Session id of the event. isPageView
Description
Whether this event is a pageview. createdAt
Description
UTC timestamp when the event was created. Type
string<pattern:^\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}Z$>
Example
"2026-01-19T12:30:00Z"
origin
Description
URL origin if available (for pageviews). path
Description
URL path if available (for pageviews). hash
Description
URL hash if available (for pageviews). data
Description
Event data key-value map. 400 Bad request - invalid request payload or parameters
application/json error
Description
Validation error details. code
Description
Machine-readable validation error code. message
Description
Human-readable validation summary. details
Description
Per-field validation issues.
Show nested properties (2)
field
Description
Path to the invalid request field. message
Description
Validation error message for the field. 401 Unauthorized - invalid or revoked API key
application/json error
Description
Error details. code
Description
Machine-readable error code. message
Description
Human-readable error message. 403 Requested date range is not allowed for the current plan
application/json error
code
Type
"PLAN_LIMIT_EXCEEDED"
404 User was not found
application/json error
Description
Error details. code
Description
Machine-readable error code. message
Description
Human-readable error message. 429 Rate limit exceeded
application/json error
Description
Error details. code
Description
Machine-readable error code. Type
"RATE_LIMIT_EXCEEDED"
message
Description
Human-readable error message. 500 Unexpected internal error
application/json error
Description
Error details. code
Description
Machine-readable error code. Type
"INTERNAL_SERVER_ERROR"
message
Description
Human-readable error message.