JavaScript SDK - setUserID method
This method allows you to set a user ID on the currently active session. This allows you to associate a user to the replay, which would allow you to filter and search sessions for one particular user.
Signature
Section titled SignaturesetUserID(id: string): void
Parameters
Section titled Parametersid: string
: The ID of the user. This is a string and can be anything as long as it’s a string and it allows you to uniquely identify a user within your system (i.e. email, database id, etc).
Return value
Section titled Return valueThis method doesn’t return any values, the results will be visible in the OpenReplay platform.