Skip to main content

Slack Channel Members API

Written by Kadri - RichAPI Support Team

POST /slack_channel_members • Credits: 2 credits per call

Slack Channel Members returns the member list of one Slack channel. The response holds a data object with the channel ID, the workspace, a members array and a total count. Each member carries a user ID, a real name, a display name, an email and a title. Each member also carries a phone number, a status text, a timezone, an admin flag, an owner flag and an avatar URL. Each call costs 2 credits, whatever the number of members returned.

What does Slack Channel Members do?

A Slack channel holds the people behind a community, a customer program or a partner program. Slack shows that list in the app, but Slack gives no export for it. Slack Channel Members reads the channel through the Slack Web API and returns the full member list as structured JSON. RichAPI calls two Slack methods for each request: conversations.members for the member IDs, and users.info for the profile of each member. One call covers one channel.

CAUTION: Slack Channel Members reads a private workspace, not a public page. You must supply your own Slack session credentials. RichAPI provides no Slack access of its own.

Which endpoint does Slack Channel Members use?

  • Method:POST

  • URL:https://api.richapi.ai/api/v1/slack_channel_members

  • Authentication to RichAPI:x-api-key header

  • Authentication to Slack: The cookie and token parameters in the request body

  • Response: Synchronous JSON

  • Credits: 2 credits per call

How does RichAPI authenticate to Slack?

RichAPI holds no Slack credential and runs no Slack OAuth app. The caller supplies the Slack credentials in the request body of every call. Two separate authentications happen in one request.

Question

Answer

Does the caller supply the Slack credentials?

Yes. The cookie parameter and the token parameter carry them.

Does RichAPI hold a shared Slack credential?

No. RichAPI holds no Slack credential of its own.

Does the endpoint use a connected app?

No. Connected Apps in the RichAPI dashboard lists MCP clients such as Claude Desktop and Cursor. It holds no Slack connection.

Which OAuth scopes apply?

None. The endpoint uses a browser session, not an OAuth app, so no scope list exists.

Which permissions apply instead?

The permissions of the signed-in Slack user. That user must be a member of the channel.

RichAPI builds the outbound Slack request from your two values.

Parameter

Slack value

How RichAPI sends it

cookie

The value of the Slack d browser cookie. The value starts with xoxd-.

As the header Cookie: d=<value>

token

The Slack client token. The value starts with xoxc-.

As the header Authorization: Bearer <value>

The x-api-key header authenticates you to RichAPI and pays the credits. The cookie and the token authenticate the call to Slack. A valid x-api-key with a stale Slack session returns 401. A valid Slack session with no RichAPI key returns 401 as well.

If Slack answers missing_scope or not_in_channel, RichAPI returns 403. If Slack answers invalid_auth, token_revoked or not_authed, RichAPI returns 401.

How do you get your Slack cookie and token?

  1. Open your Slack workspace in a browser. Do not use the desktop app.

  2. Open the browser developer tools.

  3. Select the Application tab.

  4. Under Cookies, copy the value of the d cookie. That value is the cookie parameter.

  5. Select the Network tab.

  6. Open any request that Slack sends to a Slack API method.

  7. Copy the value that starts with xoxc- from the request payload. That value is the token parameter.

A Slack session expires. If a working request starts to return 401, repeat these steps and send the new values.

How to send a Slack Channel Members request

  1. Copy your API key from the RichAPI dashboard.

  2. Set the workspace parameter to the workspace subdomain, for example northwind for northwind.slack.com.

  3. Set the channel_id parameter to the channel ID, for example C0123456789.

  4. Set the cookie parameter to the value of your Slack d cookie.

  5. Set the token parameter to your Slack xoxc- token.

  6. Set the max_members parameter to a number between 1 and 10000.

  7. Send a POST request to https://api.richapi.ai/api/v1/slack_channel_members.

  8. Send the API key in the x-api-key header.

  9. Read the member list from data.members.

CAUTION: Set max_members in every request. The configured default value is 0, and the accepted range is 1 to 10000. A request without max_members returns 422.

cURL

curl -X POST https://api.richapi.ai/api/v1/slack_channel_members   
-H "x-api-key: YOUR_API_KEY"
-H "Content-Type: application/json"
-d '{
"workspace": "northwind",
"channel_id": "C0123456789",
"cookie": "xoxd-YOUR_SLACK_D_COOKIE",
"token": "xoxc-YOUR_SLACK_TOKEN",
"max_members": 500,
"cache": true
}'

Python

import requests

response = requests.post(
"https://api.richapi.ai/api/v1/slack_channel_members",
headers={"x-api-key": "YOUR_API_KEY"},
json={
"workspace": "northwind",
"channel_id": "C0123456789",
"cookie": "xoxd-YOUR_SLACK_D_COOKIE",
"token": "xoxc-YOUR_SLACK_TOKEN",
"max_members": 500,
"cache": True,
},
timeout=180,
)
response.raise_for_status()
members = response.json()["data"]["members"]
for member in members:
print(member["real_name"], member["email"], member["title"])

Node.js

const response = await fetch("https://api.richapi.ai/api/v1/slack_channel_members", {
method: "POST",
headers: {
"x-api-key": "YOUR_API_KEY",
"Content-Type": "application/json",
},
body: JSON.stringify({
workspace: "northwind",
channel_id: "C0123456789",
cookie: "xoxd-YOUR_SLACK_D_COOKIE",
token: "xoxc-YOUR_SLACK_TOKEN",
max_members: 500,
cache: true,
}),
});

const data = await response.json();
console.log(data.data.total_members);
console.log(data.data.members);

Which parameters does Slack Channel Members accept?

Parameter

Type

Required

Default

Description

workspace

string

Yes

None

The workspace subdomain. Send northwind for northwind.slack.com. The value accepts letters, digits and hyphens, up to 63 characters.

channel_id

string

Yes

None

The Slack channel ID, for example C0123456789. The value accepts capital letters and digits only. A channel URL is not accepted.

cookie

string

Yes

None

The value of your Slack d browser cookie. The value starts with xoxd-.

token

string

Yes

None

Your Slack client token. The value starts with xoxc-.

max_members

integer

No

0

The maximum number of members to return. The accepted range is 1 to 10000. The default value of 0 sits outside that range, so set this parameter in every request.

cache

boolean

No

false

Set to true to accept a stored result from the last 15 minutes. Set to false to read the live channel.

Which channel identifier does Slack Channel Members accept?

Slack Channel Members accepts the channel ID and nothing else. The channel ID is the value that starts with C and holds capital letters and digits, for example C0123456789. To find the ID, open the channel in a browser. The address bar shows https://<workspace>.slack.com/archives/C0123456789. The last path segment is the channel ID.

A full channel URL in channel_id returns 422, because the value fails the channel pattern. A channelUrl field returns 400, because channelUrl is not an accepted parameter name.

What does Slack Channel Members return?

The block below is an example response for a channel with two members. The field names and the structure are exact. The people, the workspace, the IDs and the timings are illustrative.

{
"data": {
"channel_id": "C0123456789",
"workspace": "northwind",
"members": [
{
"user_id": "U04H7K2P9QA",
"real_name": "Priya Raman",
"display_name": "priya",
"email": "[email protected]",
"title": "Head of Developer Relations",
"phone": "+1 415 555 0142",
"status_text": "Reviewing pull requests",
"timezone": "America/Los_Angeles",
"is_admin": true,
"is_owner": false,
"avatar_url": "https://avatars.slack-edge.com/2026-04-18/u04h7k2p9qa_192.png"
},
{
"user_id": "U05M3B8TX2C",
"real_name": "Tomas Lindqvist",
"display_name": "tomas.l",
"email": "[email protected]",
"title": "Backend Engineer",
"phone": null,
"status_text": null,
"timezone": "Europe/Stockholm",
"is_admin": false,
"is_owner": false,
"avatar_url": "https://avatars.slack-edge.com/2026-02-03/u05m3b8tx2c_192.png"
}
],
"total_members": 2
},
"meta": {
"cache_hit": false,
"execution_time_ms": 4318,
"quality_warning": null
}
}

Which fields does the Slack Channel Members response hold?

Field

Type

Description

data

object

The result of the call.

data.channel_id

string

The channel ID that you sent.

data.workspace

string

The workspace subdomain that you sent.

data.members

array of objects

One object per channel member.

data.members[].user_id

string

The Slack user ID of the member. This field always holds a value.

data.members[].real_name

string or null

The full name on the Slack profile.

data.members[].display_name

string or null

The display name on the Slack profile.

data.members[].email

string or null

The email address on the Slack profile.

data.members[].title

string or null

The job title on the Slack profile.

data.members[].phone

string or null

The phone number on the Slack profile.

data.members[].status_text

string or null

The current Slack status text of the member.

data.members[].timezone

string or null

The Slack timezone of the member, for example Europe/Stockholm.

data.members[].is_admin

boolean

The value is true for a workspace admin.

data.members[].is_owner

boolean

The value is true for a workspace owner.

data.members[].avatar_url

string or null

The URL of the profile picture of the member.

data.total_members

integer

The number of objects in data.members.

meta

object

The metadata of the call.

meta.cache_hit

boolean

The value is true for a result served from the 15-minute cache.

meta.execution_time_ms

integer

The duration of the call, in milliseconds.

meta.quality_warning

string or null

A note about an empty result. The value is null for a normal call.

Every profile field except user_id reads from the Slack profile of the member. If Slack hides a field or the member left it empty, the field is null. If Slack refuses the profile of one member, the response still holds that member with user_id and null in every other field.

Does Slack Channel Members paginate?

Slack Channel Members returns the whole member list in one response. The request accepts no cursor, and the response holds no cursor and no next page token. RichAPI walks the Slack cursor pagination inside the single call.

  1. RichAPI reads member IDs from Slack in pages of 200.

  2. RichAPI follows the Slack cursor until Slack returns no next cursor, or until the count reaches max_members.

  3. RichAPI reads the profile of each member, ten profiles at a time.

  4. RichAPI returns the members in one response, capped at max_members.

Use max_members to control the size of the response and the duration of the call. A large channel takes a long time, because RichAPI reads one Slack profile per member. Set the client timeout to 180 seconds. If the call passes the RichAPI time budget, the response is 504 and RichAPI charges no credit.

How do you research a community Slack workspace?

Community teams and developer relations teams run large Slack workspaces. The channel list holds the members, but Slack shows no titles, no emails and no timezones in one view. Slack Channel Members turns one channel into a table that you can sort and filter.

  1. Open the community channel in a browser and copy the channel ID from the address bar.

  2. Send a Slack Channel Members request with that channel_id and your workspace subdomain.

  3. Read data.members and keep real_name, email, title and timezone.

  4. Group the members by title to find the practitioners, the founders and the students.

  5. Group the members by timezone to pick the hour for a community event.

  6. Send the emails to the Email Verifier endpoint before any outreach.

Two channels of 400 members each cost 4 credits in total, or $0.08 on the 1,000 and 5,000 credit packs.

What is your responsibility for this data?

Slack Channel Members returns names, email addresses, job titles, phone numbers, status text, timezones and avatar URLs for real people inside a private workspace. You supply the Slack session that reads that workspace, and you decide what happens to the data afterwards. You are responsible for lawful and compliant handling of the member records, and for the workspace rules that apply to your Slack account.

How much does Slack Channel Members cost?

Slack Channel Members costs 2 credits per call. 1 credit costs $0.02 on the 1,000 and 5,000 credit packs, so one call costs $0.04 there. Larger packs cost less per credit. The price is per call. A channel with 5 members and a channel with 5,000 members both cost 2 credits.

Calls

Credits

Cost

1

2

$0.04

100

200

$4.00

1,000

2,000

$40.00

10,000

20,000

$400.00

CAUTION: A successful call to an empty channel costs 2 credits. The response then holds total_members of 0 and a meta.quality_warning value.

Which errors can Slack Channel Members return?

Status

Meaning

What to do

400

The request body failed RichAPI validation. An unknown field name or a missing required field causes it.

Correct the field that the message names. The error response holds a supported_fields object with every accepted name.

401

The request holds no RichAPI API key, or Slack rejected the cookie and the token.

Send a valid key in the x-api-key header. If the key is correct, copy a new d cookie and a new xoxc- token from Slack.

402

The organization has no credits left, or the team reached its monthly spend limit.

Buy credits in the RichAPI dashboard.

403

The API key has no access to this endpoint, or the Slack user is not a member of the channel.

Check the plan of the key. Join the channel in Slack, then send the request again.

404

Slack found no channel with that ID in that workspace.

Correct the channel_id and the workspace values.

422

A parameter value failed validation.

Set max_members between 1 and 10000. Send the workspace subdomain and the channel ID, not a URL.

429

Slack rate limited the call, or the RichAPI scraping service is busy.

Wait a few seconds, then send the request again.

500

The API failed.

Send the request again. If the failure repeats, write to [email protected].

502

Slack returned an unexpected error.

Wait a few seconds, then send the request again.

504

The call passed the RichAPI time budget.

Lower max_members, then send the request again.

RichAPI charges no credit for an error response. An error carries one of these statuses: 400, 401, 402, 403, 404, 422, 429, 500, 502, 504. RichAPI charges 2 credits for every 200 response.

Frequently asked questions

Does RichAPI need my Slack password?

No. Slack Channel Members needs two values from a signed-in Slack browser session: the d cookie value and the xoxc- client token. RichAPI sends no password to Slack and stores no Slack login.

Does RichAPI provide the Slack access, or must I bring my own?

You must bring your own. RichAPI holds no shared Slack credential and runs no Slack OAuth app, so every call carries your cookie and your token. The call reads only the workspace and the channel that your own Slack account can open.

Which Slack OAuth scopes does Slack Channel Members need?

None. The endpoint uses a Slack browser session instead of an OAuth app, so no scope list applies. The call inherits the permissions of the signed-in Slack user, and that user must be a member of the channel.

Can I send a Slack channel URL instead of a channel ID?

No. The channel_id parameter accepts capital letters and digits only, for example C0123456789. A full URL returns 422, and a channelUrl field returns 400 with the list of accepted parameter names.

Why does the response hold no email for some members?

The email field reads from the Slack profile of the member. If the Slack profile holds no email that your session can read, the field is null. The member still appears in data.members with a user_id.

Does a large channel cost more than a small channel?

No. Slack Channel Members costs 2 credits per call, whatever the value of total_members. A channel with 5,000 members and a channel with 5 members both cost 2 credits.

How long does RichAPI cache a member list?

RichAPI caches a member list for 15 minutes. The cache key covers the workspace, the channel_id and the max_members values. It does not cover your Slack credentials. To read the live channel instead, set cache to false.

Does the response mark bot users?

No. The response holds no bot flag and no is_bot field. Slack counts an app or a bot as a channel member, so a bot can appear in data.members with a user_id and few other values.

Related articles

Did this answer your question?