Managing your users using RumbleTalk API
Creating a user
POST
https://api.rumbletalk.com/users
- *username
- string
-
The user name of the user;
this is the name that will be used to login to the chat as well as the name displayed in the chat.
There are two restrictions on the username field:
1. Must not contain commas: ,
2. The username must not be a number (e.g. 123, 1e3)
- *password
- string
-
The password of the user;
this is the password that will be used to log into the chat
- image
- string
- A valid URL of an image
- firstName
- string
- The first name of the user
- lastName
- string
- The last name of the user
- email
- string
- The email address of the user
- description
- string
- The description of the user is displayed when you view the users details in the chat
- rooms
- array
- Array of room ids the user should have access to
Response format
- status
- boolean
- true on success, false otherwise
- userId
- integer
- The ID of the created user
cURL example
curl \
-X POST \
"https://api.rumbletalk.com/users" \
-H "Authorization: Bearer <token>" \
-d "{\"username\":\"John\", \"password\": \"zimBalu2ya\"}"
Response example
{
"status": true,
"userId": 123
}
Looking up your users
GET
https://api.rumbletalk.com/users
- status
- boolean
- true on success, false otherwise
- count
- integer
- Total number of users in the query
- data
- array
- An array of objects, each representing a user
Format of the data parameter
- id
- integer
- The ID of the user
- username
- string
-
The user name of the user;
this is the name that is used to log into the chat as well as displayed in the chat
- firstName
- string
- The first name of the user
- lastName
- string
- The last name of the user
- email
- string
- The email address of the user
- image
- string
- A URL to an image of the user
- description
- string
- The description of the user is displayed when you view the users details in the chat
- rooms
- string
- Comma separated list of room ids the user has access to
- paid
- integer
- Number of rooms the user has paid access to
- lastLogin
- timestamp
- The last time the user has logged in
- numLogins
- integer
- The number of times the user has logged in
- created
- timestamp
- The time the user was created
cURL example
curl \
-X GET \
"https://api.rumbletalk.com/users" \
-H "Authorization: Bearer <token>"
Response example
{
"status": true,
"count": 2,
"data": [
{
"id": 2,
"lastLogin": null,
"numLogins": 0,
"created": 1457878326,
"rooms": "3,4,12",
"firstName": null,
"lastName": null,
"username": "nim",
"email": null,
"level": 0,
"image": "",
"description": null
},
...
]
}
Looking up specific user
GET
https://api.rumbletalk.com/users/{userId}
GET
https://api.rumbletalk.com/users/{username}
Username with "#", or any other HTTP reserved character, won't be accessible using the /{username} route
Response format
cURL example
curl \
-X GET \
"https://api.rumbletalk.com/users/123" \
-H "Authorization: Bearer <token>" \
Response example
{
"status": true,
"data": {
"id": 2,
"lastLogin": null,
"numLogins": 0,
"created": 1457878326,
"rooms": "3,4,12",
"firstName": null,
"lastName": null,
"username": "nim",
"email": null,
"level": 0,
"image": "",
"description": null
}
}
Retrieving current online users
GET
https://api.rumbletalk.com/chats/{chatId}/onlineUsers
Response format
- status
- boolean
- true on success, false otherwise
- users
- array
- An array of objects, each representing a user
Format of the data parameter
- id
- integer
- The ID of the user
- ssoType
- integer
-
The SSO type of the user.
Facebook: 0
Twitter: 1
RumbleTalk: 2
Guest: 4
Listener: NULL
- ssoUid
- string
- The external ID of the user based on the SSO type
- ip
- string
- The user's IP address
- username
- string
-
The user name of the user;
this is the name that is used to log into the chat as well as displayed in the chat
cURL example
curl \
-X GET \
"https://api.rumbletalk.com/chats/123/onlineUsers" \
-H "Authorization: Bearer <token>" \
Response example
{
"status": true,
"data": [
{
"id": 12,
"userLevel": 5,
"ssoType": 2,
"ssoUid": "123456",
"ip": 127.0.0.1,
"username": Nim
},
{
"id": 16,
"userLevel": 3,
"ssoType": 0,
"ssoUid": "654321",
"ip": 127.0.0.1,
"username": Eyal
},
...
]
}
Updating a user
PUT
https://api.rumbletalk.com/users/{userId}
PUT
https://api.rumbletalk.com/users/{username}
Username with "#", or any other HTTP reserved character, won't be accessible using the /{username} route
Request format
Response format
- status
- boolean
- true on success, false otherwise
cURL example
curl \
-X PUT \
"https://api.rumbletalk.com/users/123" \
-H "Authorization: Bearer <token>" \
-d "{\"description\":\"This is our chat adminsitrator\"}"
Response example
{
"status": true
}
Resetting a user password
PUT
https://api.rumbletalk.com/users/{userId}/password
PUT
https://api.rumbletalk.com/users/{username}/password
Username with "#", or any other HTTP reserved character, won't be accessible using the /{username} route
Request format
- password
- string
- The new user password
Response format
- status
- boolean
- true on success, false otherwise
cURL example
curl \
-X PUT \
"https://api.rumbletalk.com/users/123/password" \
-H "Authorization: Bearer <token>" \
-d "{\"password\":\"MyPassword!\"}"
Response example
{
"status": true
}
Deleting a user
DELETE
https://api.rumbletalk.com/users/{userId}
DELETE
https://api.rumbletalk.com/users/{username}
Username with "#", or any other HTTP reserved character, won't be accessible using the /{username} route
Response format
- status
- boolean
- true on success, false otherwise
cURL example
curl \
-X DELETE \
"https://api.rumbletalk.com/users/123456" \
-H "Authorization: Bearer <token>"
Response example
{
"status": true
}