Creates or identifies a user within the specified environment. If the user already exists, this marks them as identified and may update attributes. If they don’t exist, a new user is created.
Endpoint
POST /api/v1/client/{environmentId}/userPath Parameters
| Name | Type | Required | Description |
|---|---|---|---|
environmentId | string | ✅ | Environment ID from the Project’s config |
Request Body
application/json · object
Response – 200 OK
{
"data": {
"state": {
"data": {
"displays": [
{
"createdAt": "2025-02-03T11:23:13.050Z",
"surveyId": "cm6orqtdd000a19wjhnbces5s"
}
],
"lastDisplayAt": "2025-02-03T11:23:13.050Z",
"responses": [
"cm6orqtdd000a19wjhnbces5s"
],
"segments": [
"cm6onrezn000hw2ahcokiz41v"
],
"userId": "hello-user"
},
"expiresAt": "2025-02-03T11:23:13.050Z"
}
}
}Was this article helpful?
That’s Great!
Thank you for your feedback
Sorry! We couldn't be helpful
Thank you for your feedback
Feedback sent
We appreciate your effort and will try to fix the article