MCPcopy Create free account
hub / github.com/adcontextprotocol/adcp / getChannelMembers

Function getChannelMembers

server/src/slack/client.ts:712–738  ·  view source on GitHub ↗
(channelId: string)

Source from the content-addressed store, hash-verified

710 * Get members of a channel
711 */
712export async function getChannelMembers(channelId: string): Promise<string[]> {
713 const members: string[] = [];
714 let cursor: string | undefined;
715
716 do {
717 const response = await slackRequest<{
718 members: string[];
719 response_metadata?: { next_cursor?: string };
720 }>('conversations.members', {
721 channel: channelId,
722 limit: 200,
723 cursor,
724 });
725
726 if (response.members) {
727 members.push(...response.members);
728 }
729
730 cursor = response.response_metadata?.next_cursor;
731
732 if (cursor) {
733 await sleep(RATE_LIMIT_DELAY_MS);
734 }
735 } while (cursor);
736
737 return members;
738}
739
740/**
741 * Check if a user has access to a channel

Callers 3

createMeetingRoutersFunction · 0.85
scheduleMeetingFunction · 0.85

Calls 1

sleepFunction · 0.70

Tested by

no test coverage detected