Help Finding Granular Scope: team_chat:write:members

Endpoint:
POST /chat/channels/{channelId}/members
Error:
Code: 4711,
message: ‘Invalid access token, does not contain scopes:[team_chat:write:members].’

Description
I am trying (for the first time) to create a Zoom integration. The App is a general App, and its purpose is to post “announcements” to all users in an organization by authenticating as an admin, then creating a “announcements” channel if it does not exist, then looping through all users and adding them to the channel if they are not added, and then finally mentioning @all in the channel with the announcement.

According to the error message, I obviously don’t have the correct scopes, however I can not seem to find the team_chat:write:members scope in the App settings page.
I do have the team_chat:write:members:Admin scope enable however!

Here are the scopes I currently have added:

Team Chat
Enable Chatbot within Zoom Team Chat Channel
app:channel_content:write:admin
	
Enable Chatbot within Zoom Team Chat Channel
	
View all users' team chat channels
team_chat:read:channel:admin
	
View a chat channel
	
team_chat:read:user_channel:admin
	
View a user's chat channel
	
team_chat:read:list_members:admin
	
View a chat channel's members
	
team_chat:read:list_channels:admin
	
View chat channels
	
team_chat:read:list_administrators:admin
	
View a chat channel's admins
	
team_chat:read:list_user_channels:admin
	
View a user's chat channels
	
View and manage all users' team chat channels
team_chat:write:groups:admin
	
Add groups to a chat channel
	
team_chat:write:members:admin
	
Add members to a chat channel
	
team_chat:write:user_channel:admin
	
Create a chat channel for a user
	
team_chat:write:administrator:admin
	
Add administrators to a chat channel
	
team_chat:write:search_channels:admin
	
Search account's channels
	
team_chat:update:user_channel:admin
	
Update a user's chat channel
	
team_chat:read:list_groups:admin
	
View a chat channel's member groups
	
View and manage all users' team chat messages
team_chat:write:user_message:admin
	
Create a chat message for a user
	
User
View all user information
user:read:list_users:admin
	
View users
	
user:read:user:admin
	
View a user 

pls… :^)
feel like I am taking crazy pills, as they say.
is that scope not available for certain apps or users?

Hi @halleyscomet
Thanks for reaching out to us
I believe the endpoint you are trying to call is intended to be used only for User-Level apps, but allow me some time to troubleshoot this on my end.

Is this workflow correct?

  1. Create a channel (if the channel announcements doesn’t exist under the admin account)
  2. Add all users to announcement channels (using the Invite channel members endpoint: Team Chat APIs - Zoom Developers)

Is that correct or am I missing anything?

Thank so much Elisa.

Yes, you are correct.
Currently I am using the chat/channels/{channelID}/members endpiont, and get this error:

message: 'Invalid access token, does not contain scopes:[team_chat:write:members].'

Is ther eanother endpoint I should be using?

The app information in the marketplace gui is here:

Status: Draft
Date Updated: Nov 22 02:24 PM
General App
Account Level
Team Chat

It is a administrator managed app.

The scopes that I am being told to add in the error message however do not appear in the add scopes search. I have a screenshot, but can not embed the image in posts it seems.

Thanks @halleyscomet
and sorry for the late reply here! It appears that this is an endpoint that is only to be access using an User level app

Thank you for your reply.
What would be the design pattern for creating a channel and adding users to it be from an admin app? Adding users to channels seems like an admin-y thing to do…

Hey @halleyscomet
Have you tried using the Create a channel endpoint?

You can pass the members in your post request

Elisa, thank you for helping me out.
The create a channel endpoint does indeed work correctly.
There are a few snags that I would like to ask you about however.

  1. The create a channel endpoint has a max 20 user add limit. My app is more geared towards enterprise orgs, where there may be 100s or 1000s of users. If I could use the above add users endpoint, this wouldn’t be a problem. Should my App be a user app instead of a admin level app after all?

  2. Additionally, as employees join / leave a company, I would the ability to add them to the channel programmatically. Using the create channel endpoint, that would imply I would have to re-make the channel instead of just adding / deleting users from the channel. Do you have any advice for that?

Hello Elisa,
If you (or anyone else) has advice about the best way to

  1. Create a Channel if it does not exist
  2. Add all users of an organization to that channel
  3. @all the channel

or like above

  1. Create a channel with all users of an org in it
  2. @all the channel

it would be much appreciated. From where I am now, it seems like making my App an admin level app was a mistake, because I can not add users to the chat, and can only create a chat with 20 users in it max.