Hi @socialjawn ,
Sincere apologies for the delayed response.
The current usage of secured mode is incorrect. The method createUserToken
is intended for obtaining a user access token, not an authentication token.
To obtain an authentication token, follow these steps:
- Your front-end (FE) should make a call to retrieve the authentication token.
- On the back-end (BE) side, invoke the authentication API (Amity API ) using the
userId
obtained in step 1 and the securely storedserverKey
on the BE side. - Pass the token received from the authentication API back to the front-end.
- Utilize the authentication token for logging in."
Amity Support