-
Notifications
You must be signed in to change notification settings - Fork 0
Join room endpoint
Alvin Cheng edited this page Apr 23, 2023
·
3 revisions
This is the join room endpoint, this endpoint will create a room in the database once called. The endpoint's source can be found at: /src/endpoints/joinRoom.ts
. Furthermore, the endpoint will execept a 'id' argument which is the id of room to join, a 'user' argument which is the user to add to the room and finally a 'passcode' argument which as the name suggests it's the passcode for the room(This value can also be null in public rooms). Also, the endpoint will return a status of '200' on sucess, '400' on error, '401' on a invalid API key and '500' on server error.
post("http://<URL>/api/join-room?key=<YOUR_API_KEY>", {
id: "<ROOM_ID>",
user: "<USER>",
passcode: "<PASSCODE>", // Must be raw unencrypted passcode!!
})
.then((res) => {
console.log(res);
})
.catch((err) => {
console.error(err);
});
- Home
- Login endpoint
- Block user endpoint
- Create room endpoint
- Delete user endpoint
- Get all rooms endpoint
- Get GIF endpoint
- Get messages endpoint
- Get public rooms endpoint
- Get user info endpoint
- Get users info endpoint (Deprecated)
- Join room endpoint
- Signup endpoint
- Report room endpoint
- Remove room endpoint
- Update description endpoint
- Follow user endpoint
- Unfollow user endpoint
- Update icon color endpoint
- Upload content endpoint
- Upload content endpoint (Deprecated)
- Verify client endpoint
- Upload token endpoint
- Chill&chat websockets
- Message socket
- Keyboard socket
- Delete message socket
- User content
- Final words&thoughts
- Run API