This message was deleted.
# helpdesk
s
This message was deleted.
s
I believe you are looking for room name. https://docs.livekit.io/client-sdk-js/classes/Room.html#name
s
Thank you for your quick reply 🙂 But unfortunately I am not looking for the “name” attribute. I’m interested if there is a way to find out which room or rooms I am currently connected to without having to store them locally.
m
@stocky-sandwich-45001 would you say a little more about your use case/need for this feature?
s
Here is a bit of background information: I'm looking to eventually migrate my service https://www.thing.online/ to LiveKit in the medium term. "Thing" is a browser based software to run virtual workshops. A room we call meetingspace and you can, among many other features, enter very lightweight conversations with others. Before a potential migration I want to find out what works and how. In the course of a first test I also tried to connect several rooms/meetingspaces and the question came up if I can get the information with which rooms I am currently connected to without having to remember the created room with "new Room(...)". The idea to have multiple rooms is also useful for performance/network reasons if you have very full meetings/rooms to divide the area into several "subrooms". Of course I can save all created room objects in an array or similar. My question is really more out of interest. Does the LiveKit client know which rooms it is connected to and can I get the information or do I HAVE to save the created objects?
👌 1
Ah and btw thanks for implementing such a cool and really good product 👍 and of course the nice support here 🙂
🙏 1
❤️ 1
m
@stocky-sandwich-45001 gotcha, I understand this better now. There isn’t support for this (yet) from the client side. I’ll let @polite-kilobyte-67570 weigh in on that. From one of our server SDKs, there are a number of room-management APIs: https://docs.livekit.io/server/room-management/#roomservice-apis But, it looks like you can’t filter the List endpoint by participant ID. So not super helpful at the moment for what you want.
s
Thank you very much for the quick reply @magnificent-art-43333 🙂 My question was only about the client, but it is interesting to know that neither the server nor the client knows this. But maybe @polite-kilobyte-67570 can bring more light into the darkness.
👍 1
m
Heh, to be clear, the server knows it, but doesn’t expose it yet. 🙃
d
Reference from @shy-sandwich-47644 was the one you're looking for: https://docs.livekit.io/client-sdk-js/classes/Room.html#name In livekit room id is treated as name. During create room you'll require to set unique room id which is room name in livekit. For setting up room title or other information you'll require to use metadata. At least that is what we're using in plugNmeet.
d
I think your client would need to store references to all the rooms that you are connected to. Our client tries to not store global values because it'd be difficult to clean up.
1
👍 1