contentstack Events API
The events endpoint allows applications to track user actions and behavioral events for experience analytics and audience rule evaluation.
The events endpoint allows applications to track user actions and behavioral events for experience analytics and audience rule evaluation.
Every API here is available over the APIs.io API and to AI agents over MCP.
One button, every client — Claude, Cursor, VS Code and the rest.
https://apis.io/mcp
find_apisBrowse and filter every API in the catalog.get_api_artifactsOne API's artifacts, grouped by type.get_openapiThe primary OpenAPI for this API.find_similar_apisAPIs that look like this one.apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.resolveTurn a domain, URL or GitHub org into the provider it belongs to.find_cohortsEvery scored population of providers in the catalog.curl "https://apis.io/api/v1/apis/contentstack-events-api"
curl "https://apis.io/api/v1/apis?limit=25"
Discovery needs no key. Ratings and market analysis are Pro.
Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. See our Privacy Policy and Terms.
A second provider on the same verified email joins the account you already have.
openapi: 3.2.0
info:
title: Contentstack Events API
version: v1
contact:
name: Contentstack Support
url: https://www.contentstack.com/contact
termsOfService: https://www.contentstack.com/legal/terms-of-service
description: 'Operations tagged Events across 2 of this provider''s published API definitions: contentstack-personalize-edge-api-openapi.yml, contentstack-personalize-management-api-openapi.yml. Each path carries the servers of the definition it was published in.'
servers:
- url: https://personalize-edge.contentstack.com
description: AWS North America Production Server
- url: https://eu-personalize-edge.contentstack.com
description: AWS Europe Production Server
- url: https://au-personalize-edge.contentstack.com
description: AWS Australia Production Server
- url: https://azure-na-personalize-edge.contentstack.com
description: Azure North America Production Server
- url: https://azure-eu-personalize-edge.contentstack.com
description: Azure Europe Production Server
- url: https://personalize-api.contentstack.com
description: AWS North America Production Server
- url: https://eu-personalize-api.contentstack.com
description: AWS Europe Production Server
- url: https://au-personalize-api.contentstack.com
description: AWS Australia Production Server
- url: https://azure-na-personalize-api.contentstack.com
description: Azure North America Production Server
- url: https://azure-eu-personalize-api.contentstack.com
description: Azure Europe Production Server
tags:
- name: Events
description: The events endpoint allows applications to track user actions and behavioral events for experience analytics and audience rule evaluation.
paths:
/events:
post:
operationId: trackEvents
summary: Track user events
description: Records one or more user behavior events for experience analytics and audience evaluation. Supports both impression events (automatic tracking when experiences are shown) and custom events (defined in the Personalize Management API and triggered by specific user actions).
tags:
- Events
parameters:
- $ref: '#/components/parameters/ProjectUid'
- $ref: '#/components/parameters/PersonalizeUserUidRequired'
requestBody:
required: true
content:
application/json:
schema:
$ref: '#/components/schemas/TrackEventsRequest'
responses:
'202':
description: Events accepted for processing.
'400':
$ref: '#/components/responses/BadRequest'
'403':
$ref: '#/components/responses/Forbidden'
get:
operationId: getAllEvents
summary: Get all events
description: Retrieves all custom event definitions in the Personalize project. Events are used to track user interactions and trigger audience membership updates.
tags:
- Events
parameters:
- $ref: '#/components/parameters/ProjectUid'
responses:
'200':
description: A list of all events in the project.
content:
application/json:
schema:
$ref: '#/components/schemas/EventList'
'401':
$ref: '#/components/responses/Unauthorized'
servers:
- url: https://personalize-edge.contentstack.com
description: AWS North America Production Server
- url: https://eu-personalize-edge.contentstack.com
description: AWS Europe Production Server
- url: https://au-personalize-edge.contentstack.com
description: AWS Australia Production Server
- url: https://azure-na-personalize-edge.contentstack.com
description: Azure North America Production Server
- url: https://azure-eu-personalize-edge.contentstack.com
description: Azure Europe Production Server
components:
responses:
BadRequest:
description: The request is malformed or contains invalid parameters.
content:
application/json:
schema:
$ref: '#/components/schemas/Error'
Forbidden:
description: The request is not authorized for this project.
content:
application/json:
schema:
$ref: '#/components/schemas/Error'
Unauthorized:
description: Authentication credentials are missing or invalid.
content:
application/json:
schema:
$ref: '#/components/schemas/Error'
schemas:
TrackEventsRequest:
type: array
description: Array of event objects to track.
items:
$ref: '#/components/schemas/TrackEvent'
TrackEvent:
type: object
description: A single event to be tracked for the user.
required:
- eventKey
properties:
eventKey:
type: string
description: The key of the event to track. Use "impression" for automatic view tracking or a custom event key defined in the Personalize Management API.
experience_uid:
type: string
description: The UID of the experience associated with this event. Required for impression events.
variant_uid:
type: string
description: The UID of the variant shown to the user. Required for impression events.
Error:
type: object
description: Standard error response.
properties:
message:
type: string
description: Human-readable description of the error.
status:
type: integer
description: HTTP status code.
EventList:
type: object
description: A list of custom event definitions.
properties:
data:
type: array
description: Array of event objects.
items:
$ref: '#/components/schemas/PersonalizeEvent'
CreateEventRequest:
type: object
description: Parameters for creating an event.
required:
- name
- key
properties:
name:
type: string
description: Display name for the event.
key:
type: string
description: Machine-readable key for SDK tracking calls.
PersonalizeEvent:
type: object
description: A custom event definition for tracking user actions.
properties:
uid:
type: string
description: Unique identifier of the event.
name:
type: string
description: Display name of the event.
key:
type: string
description: Machine-readable event key used in SDK tracking calls.
created_at:
type: string
format: date-time
description: ISO 8601 timestamp when the event was created.
parameters:
PersonalizeUserUidRequired:
name: x-cs-personalize-user-uid
in: header
required: true
description: The unique identifier for the end user whose events are being tracked.
schema:
type: string
ProjectUid:
name: x-project-uid
in: header
required: true
description: The UID of the Contentstack Personalize project.
schema:
type: string
securitySchemes:
bearerAuth:
type: http
scheme: bearer
description: OAuth 2.0 Bearer token with personalize:manage or personalize:read scope.
authtokenAuth:
type: apiKey
in: header
name: authtoken
description: Contentstack user authtoken for session-based authentication.
x-refined-from:
- contentstack-personalize-edge-api-openapi.yml
- contentstack-personalize-management-api-openapi.yml