Users

Create or replace an identified user

Server-side equivalent of identifyUser() with replace semantics: creates the user if it doesn't exist (201), otherwise replaces its entire metadata object (200). Prefer PATCH for scheduled syncs so you don't clobber attributes set client-side.

put/users/{userId}

Request

  • Base URL: https://api.produktly.com/api/v1
  • URL: https://api.produktly.com/api/v1/users/{userId}
  • Auth: HTTP bearer

Path parameters

userIdstring required

The user's external ID — the same value you pass to window.Produktly.identifyUser(). URL-encode it.

Example:user_123

Request body

metadataobject required

User attributes as a JSON object (nested values allowed, max 32 KB serialized). Replaces the entire stored metadata object.

Example request

{
  "metadata": {
    "plan": "pro",
    "seats": 12
  }
}

Response

Replaced

userIdstring required
metadataobject nullable required
createdAtstring date-time required
updatedAtstring date-time required

Changes

No recorded changes to this operation across all 1 revision of this API.