Change permissions for user connected to session - opentok

When people initially connect to a live stream I only want them to be able to view the stream and send messages, but not publish their camera. Then I would like the moderator of the stream to be able to "grant them access" to be able to publish the camera. How can I do this?

The OpenTok team replied to me via a support ticket:
For publishing in the session after getting permission from the moderator, you need to use your own logic to restrict the user to publish until moderator approves, as the moderator privilege in Opentok only allows you to forceDisconnect any client from the session or forceUnpublish any publisher of a stream. More on moderation available here: https://tokbox.com/developer/guides/moderation/js/

Related

How is Geekbot app in slack is able to post as me although I did not allowed my access to it?

I am creating a slack bot app like geekbot. In the geekbot it is able to broadcast standup messages on behalf of the user. But as a regular user, I did not allow any access to the bot. I understand that the admin can allow the "post as me" scope.
In that case, does the bot get access to all user's access tokens in that workspace? If not then how is it able to post as me?

Slack Api: is it ever possible to update other user's messages?

We basically want to annotate certain messages (adding links) but it does not
seem to be possible using Slack API. Only way to modify is to give permission
to the user who posted that message and modify it as that user.
I can delete other users comments or file.
I have tried to update others messages using legacy token, app token's with
full permissions but no success. I called Slack API as a owner or admin.
I used chat.update Slack api method.
The response from the api call is an error "cant_update_message"
"headers": {
....
},
"ok": false,
"error": "cant_update_message"
}
Well it is not possible even if you are an admin, as slack article say:
Mistkaes Mistakes sometimes happen. Fortunately, members can edit and delete the messages they send in Slack (if allowed by Workspace Owners and Admins). Workspace Owners can also delete messages in public channels and private channels they've joined.
Slack Roles are the following:
Owner
Admin
Permissions
Owner and admin permissions:
Manage or #mention user groups
Set private channel retention
Delete a channel
Rename a channel if you created the channel you can rename it.
Make a public channel private
Create a private shared channel
Create a shared channel
Delete your own messages
Remove people from channels
Invite Guests to a public channel
Invite a Single-Channel Guest to a private channel
Delete other people's messages
Invite new Guest members
Deactivate a member's account
Promote a Workspace Admin
Only Owners
Demote a Workspace Admin
Promote a Workspace Owner
Turn on Approved Apps
All of these permissions are allowed to them just, if you want to know all permissions, read more
It is only possible to edit your own messages (assuming this is allows in your workspace), but never the messages of others. That is the same for all users including admins and owners. And its the same with the API method chat.update.
But there is a workaround: Your app can gather tokens from every user in your workspace and then use those token to impersonate each users allowing your app to change every message. This will require each user to install the app once. Your app then just needs to use the matching token to update each message.
Note that this workaround has some obvious drawbacks, e.g. giving your app access to all message and channels on the workspace and also requires some organizational effort to maintain.

Using streaming notifications with delegate access

So far all information that I read about streaming notifications says that you are expected to use impersonation with streaming subscriptions when you want to subscribe to not your mailboxes. This sounds reasonable when you have service application that accesses user mailboxes. In my case I need to subscribe to calendars of room mailboxes.
Based on this answer: Getting notification from Resource calendar in EWS room mailboxes usually have their account disabled and I need to use delegation.
So what is proper way to subscribe and maintain affinity when using delegation? Should I just ignore setting the impersonation header and do everything else as described in How to: Maintain affinity between a group of subscriptions and the Mailbox server in Exchange?
When you creating folder object, pass the other user email address which shared his calendar with you. AS below
folders[0] = new FolderId(WellKnownFolderName.Calendar, new Mailbox("OtherUserEmail"));
And then subscribe.
service.SubscribeToStreamingNotifications
For resource rooms I use impersonation as the preferred access. I know that in general the AD userids for room resources are disabled for login in AD, but my guess is that affects only Windows login. Technically when you impersonate, you don't really login as the room user. You log in as the service account with those credentials, and then indicate with the impersonation id that you want Exchange to pretend it's actually the room making all the requests you are about to make.

Sinch Instant Messaging: User Not Found

I am integrating Sinch instant messenger into my app. The purpose of this is to facilitate one-on-one communication between the user and app owner. I have created the Sinch account and have the app keys. When I try to send the message, I get an HTTP response : User not found.
Two questions:
I thought that since there will only ever be communication between the app owner and user, that I could get away without implementing Parse (or equivalent). Is this true? Could this be the cause of my issue?
How does Sinch create users? I am having difficulty seeing in the documentation how that is handled and where the user data is stored.
Thanks
You dont need to use parse, but we dont proivde a login mechanism for users so you if you want login you need somekind of backend to handle you users,
WE create the users onhte fly when you start a client with that username, but again we trust that you authenticated them.

How do you get Yammer to treat registered app as a user

In messaging platforms like Slack and HipChat you can integrate apps that can post messages to groups without them being sent from a user e.g.
Defect Management System: A new defect was logged at 12pm
Instead of:
John Smith: A new defect was logged at 12pm
Is it possible to do the same thing in Yammer?
There are two options available for you:
1 - You can create a new user on Yammer, name it however you want (e.g., "Defect Management System" with a snazzy avatar), then take the user's OAUTH token and use it to impersonate that user programmatically. This is fine for quick development.
2 - You can create a new user on Yammer, name it however you want, then register a new app on Yammer to get a permanent token and client ID, then use those to impersonate that user programmatically. This is the right way to do it. You can read more about how to do this on https://developer.yammer.com/introduction/#gs-registerapp.
This is an example of a user that we impersonate. It is a bot on our network. It is a separate account in AD and is registered as an app in Yammer and interacts with Yammer automatically.
You are always impersonating a user in Yammer via the API, there isn't a way to impersonate a group, in the way that Slack does (i.e. being able to override the username displayed and replace it with a bot for example in your payload)
If this app is for internal use, you could consider creating a dummy user as a bot to post defects, and then using Custom Object Types & Actions in Open Graph to further customize the messages. Obviously there are some business & administration considerations in doing that, not just development ones.

Resources