Expand my Community achievements bar.

SOLVED

kick a user from a room and delete a room using server2server api

Avatar

Level 3

Hi,

I'm using server2server api with php.

How can I kick a user from a room?

I've tried calling $rtc->invalidateSession($room) but I don't see any effect.

Maybe invalidateSession just invalidate existing auth tokens?

I'm deleting a room with:

$rtc->deleteRoom($roomName);

I can see that the room is deleted from the room console but users are still logged in.

Do I need to close the room or kick all the sessions first?

I couldn't find the info in lccs.php and in the wiki

http://learn.adobe.com/wiki/display/lccs/6.2+Provisioning+rooms

Thanks

1 Accepted Solution

Avatar

Correct answer by
Employee

yes, I meant retractItem (I never remember

room is the room name where the user is running, collection should be "UserManager", node should be "UserList", itemID should be the userID you want to kick out.

to end the room you do a publishItem like

publishItem(room, "RoomManager", "meetingEnded", array( 'body' => true));

View solution in original post

4 Replies

Avatar

Employee

In order to kick a user out of the room you need to do a removeItem of that user descriptor.

If you want to close the room there is a way to do so with the RoomManager APIs but I can't remember on the top of my head.

Avatar

Level 3

I couldn't find a function removeItem but I found

retractItem($room, $collection, $node, $itemID)

Is this what I need to use?

What are the $collection, $node and $itemID needed to kick a user?

What do you mean by "user descriptor"?

In a previous post you said we need to send a "roomEnded" message to the RoomManager to end it

http://forums.adobe.com/thread/831832?decorator=print&displayFullThread=true

Can you explain how to do it with the php api?

Thanks

Avatar

Correct answer by
Employee

yes, I meant retractItem (I never remember

room is the room name where the user is running, collection should be "UserManager", node should be "UserList", itemID should be the userID you want to kick out.

to end the room you do a publishItem like

publishItem(room, "RoomManager", "meetingEnded", array( 'body' => true));

Avatar

Level 3

retractItem and publishItem works.

I still think that there is a bug or confusing behaviour when using deleteRoom.+

Users are not kicked from the room and able to keep sending messages.

Thanks