Although none of the body parameters are required, it's mandatory to include either the
userANDpasswordor only theresumeparameter.To authenticate a request, you need to pass the
userIdandauthTokenvalues from this JSON response object as headers in the request. TheauthTokenis passed asX-Auth-Tokenheader, while theuserIdasX-User-Idheader.If LDAP authentication is enabled, you must maintain the login in the same way as you normally do. Similarly, if 2FA is enabled for an LDAP user, everything stays the same.
Changelog
| Version | Description |
|---|---|
| 1.0.0 | Added avatarUrl property to response |
| 0.64.0 | Added me property. |
| 0.60.0 | Added |
{
"user": "test@rocket.test",
"password": "vanvica32"
}Your user name or email.
Your pasword.
Your previously issued authToken.
The 2FA code. It is required if your account has two-factor authentication enabled .
{
"status": "success",
"data": {
"authToken": "9HqLlyZOugoStsXCUfD_0YdwnNnunAJF8V47U3QHXSq",
"userId": "aobEdbYhXfu5hkeqG",
"me": {
"_id": "aYjNnig8BEAWeQzMh",
"name": "Rocket Cat",
"emails": [
{
"address": "rocket.cat@rocket.chat",
"verified": false
}
],
"status": "offline",
"statusConnection": "offline",
"username": "rocket.cat",
"utcOffset": -3,
"active": true,
"roles": [
"admin"
],
"settings": {
"preferences": {}
},
"avatarUrl": "http://localhost:3000/avatar/test"
}
}
}