Post
/api/v1/login - with Twitter
Changelog
| Version | Description | 
|---|---|
| 1.0.0 | Added avatarUrl property to response | 
| 0.64.0 | Added me property. | 
| 0.63.0 | Added | 
Body parameters
Example
{
  "serviceName": "twitter",
  "accessToken": "hash",
  "accessTokenSecret": "hash",
  "appSecret": "hash",
  "appId": "hash",
  "expiresIn": 200
}object  
serviceName
string    Required
The desired OAuth service name. In this case, twitter.
Exampletwitter
accessToken
string    Required
Access token provided by Twitter OAuth.
Examplehash
accessTokenSecret
string    Required
The access token secret provided by Twitter OAuth.
Examplehash
appSecret
string    Required
The app secret provided by Twitter.
Examplehash
appId
string    Required
The app ID provided by Twitter.
Examplehash
expiresIn
integer    Required
Lifetime of token (in seconds).
Example200
Responses
200
Success Example
{
  "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"
    }
  }
}object  
status
string    
data
object  
authToken
string    
userId
string    
me
object  
_id
string    
name
string    
emails 
Array of object   
object  
address
string    
verified
boolean    
status
string    
statusConnection
string    
username
string    
utcOffset
integer    
active
boolean    
roles 
Array of string   
string    
settings
object  
preferences
object  
avatarUrl
string