# Query analytics events **GET /v2/analytics/events** Returns paginated raw engagement events (views and clicks) for the authenticated organization, filtered by date range and optional storyId / versionId / userEmail. ## Plan This endpoint is available on the **Team** plan only. ## Date Range Both `dateFrom` and `dateTo` are required ISO 8601 strings. The `dateTo` boundary is inclusive (events on the supplied day are returned). The maximum range is 92 days (3 months). ## Pagination Results are paginated with a fixed page size of 1000. Pages are 1-indexed. Use the `pagination.hasMore` flag to determine whether to request the next page. ## Filtering by user Pass `userEmail` to restrict results to events on versions created by that user. The email is resolved to a user in the authenticated organization before querying. ## Servers - Production API server: https://api.storydoc.com (Production API server) ## Authentication methods - Bearer auth ## Parameters ### Query parameters - **dateFrom** (string(date-time)) Inclusive start of the date range (ISO 8601, UTC) - **dateTo** (string(date-time)) Inclusive end of the date range (ISO 8601, UTC). Must be at most 92 days after dateFrom. - **storyId** (string) Restrict events to a single story - **versionId** (string) Restrict events to a single version - **userEmail** (string(email)) Restrict events to versions created by the user with this email. Must match a user in the authenticated organization. - **page** (integer) 1-indexed page number. Defaults to 1. ## Responses ### 200 Events retrieved successfully #### Body: application/json (object) - **data** (array[object]) - **pagination** (object) ### 400 Invalid request (missing/invalid params, range > 3 months, invalid token, etc.) #### Body: application/json (object) - **error** (string) ### 403 Authentication failed, missing token, or account is not on the Team plan #### Body: application/json (object) - **error** (string) ### 404 userEmail does not match any user in the organization #### Body: application/json (object) - **error** (string) ### 429 Rate limit exceeded #### Headers - **x-rate-limit-counter** (integer) Current request count - **x-rate-limit-maximum** (integer) Maximum allowed requests per minute #### Body: application/json (object) - **error** (string) ### 500 Internal server error #### Body: application/json (object) - **error** (string) - **errorId** (string) [Powered by Bump.sh](https://bump.sh)