POST /youtube_channel • Credits: 1 credit per call
YouTube Channel Info takes one YouTube channel URL and returns the public profile of that channel. The response holds the name, the channel ID, the subscriber count, the video count, the view count, the avatar, the banner and the external links. Each call costs 1 credit.
What does YouTube Channel Info do?
Creator research starts with one question: how large is this channel? YouTube Channel Info answers that question from a single channel URL. The endpoint reads the public About page of the channel and returns the profile fields as structured JSON. It needs no YouTube API key and no login. One call covers one channel. The endpoint returns the profile of the channel only. For the list of videos of the channel, use the YouTube Channel Videos API.
Which endpoint does YouTube Channel Info use?
Method:
POSTURL:
https://api.richapi.ai/api/v1/youtube_channelAuthentication:
x-api-keyheaderResponse: Synchronous JSON
Credits: 1 credit per call
How to send a YouTube Channel Info request
Copy your API key from the RichAPI dashboard.
Set the
urlparameter to the full channel URL, such ashttps://www.youtube.com/@MrBeast.To accept a cached result, set the
cacheparameter totrue.Send a
POSTrequest tohttps://api.richapi.ai/api/v1/youtube_channel.Send the API key in the
x-api-keyheader.Read the profile fields from the
dataobject of the response.
CAUTION: Each YouTube Channel Info call costs 1 credit. A channel that returns incomplete data also costs 1 credit.
cURL
curl -X POST https://api.richapi.ai/api/v1/youtube_channel
-H "x-api-key: YOUR_API_KEY"
-H "Content-Type: application/json"
-d '{
"url": "https://www.youtube.com/@MrBeast",
"cache": true
}'
Python
import requests
response = requests.post(
"https://api.richapi.ai/api/v1/youtube_channel",
headers={"x-api-key": "YOUR_API_KEY"},
json={
"url": "https://www.youtube.com/@MrBeast",
"cache": True,
},
timeout=60,
)
response.raise_for_status()
channel = response.json()["data"]
print(channel["name"], channel["subscriber_count"], channel["video_count"])
Node.js
const response = await fetch("https://api.richapi.ai/api/v1/youtube_channel", {
method: "POST",
headers: {
"x-api-key": "YOUR_API_KEY",
"Content-Type": "application/json",
},
body: JSON.stringify({
url: "https://www.youtube.com/@MrBeast",
cache: true,
}),
});
const result = await response.json();
console.log(result.data.name, result.data.subscriber_count);
Which parameters does YouTube Channel Info accept?
Parameter | Type | Required | Default | Description |
| string | Yes | None | The full YouTube channel URL. The maximum length is 2048 characters. |
| boolean | No |
| Set to |
Which channel URL formats does YouTube Channel Info accept?
YouTube Channel Info accepts a full YouTube channel URL only. It accepts four URL forms.
Accepted URL form | Example |
Handle URL |
|
Channel ID URL |
|
Custom name URL |
|
Legacy user URL |
|
The www. prefix is optional. Both http:// and https:// work.
The endpoint rejects these four inputs with a 422 error:
Rejected input | Reason |
| A bare handle is not a URL. Wrap it as |
| A bare channel ID is not a URL. Wrap it as |
| The mobile host is not accepted. Use the |
| A video URL is not a channel URL. Send the channel URL of that video. |
What does YouTube Channel Info return?
The block below is an example response for https://www.youtube.com/@MrBeast. The field names and the structure are exact. The counts, the URLs and the timings are illustrative.
{
"data": {
"channel_id": "UCX6OQ3DkcsbYNE6H8uQQuVA",
"name": "MrBeast",
"description": "Go subscribe to my other channels! I make videos and give away money.",
"subscriber_count": "441000000",
"video_count": 892,
"view_count": 96482310755,
"joined_date": "2012-02-19",
"country": "US",
"avatar_url": "https://yt3.googleusercontent.com/ytc/AIdro_kQ8pMbXk3Zt2R1sVwq=s900-c-k-c0x00ffffff-no-rj",
"banner_url": "https://yt3.googleusercontent.com/Pq7Vd4mNfE1sK9xu0LbYhR3=w2560-fcrop64=1,00005a57ffffa5a8-k-c0xffffffff-no-nd-rj",
"links": [
"https://mrbeast.store",
"https://www.instagram.com/mrbeast",
"https://x.com/MrBeast"
]
},
"meta": {
"cache_hit": false,
"execution_time_ms": 2417,
"quality_warning": null
}
}
Which fields does the YouTube Channel Info response hold?
Field | Type | Description |
| object | The profile of the channel. |
| string | The permanent channel ID, such as |
| string | The display name of the channel. |
| string | The About text of the channel. |
| string | The subscriber count, as a string of digits. The value is |
| integer | The number of public videos on the channel. The value is |
| integer | The total view count of the channel. The value is |
| string | The creation date of the channel. The value is |
| string | The country of the channel, as a two-letter code such as |
| string | The URL of the profile picture of the channel. |
| string | The URL of the banner image of the channel. The value is |
| array of strings | The external links on the About page, such as a website URL and a social profile URL. |
| object | The metadata of the call. |
| boolean | The value is |
| integer | The duration of the call, in milliseconds. |
| string or null | A note about an extraction that returned no data or partial data. The value is |
Which fields can be empty?
Every field of data carries a default value. A channel that hides a number, or an About page that holds no link, returns the default instead of an error.
Field | Value for absent data |
|
|
|
|
|
|
If the extraction returns no data at all, data holds every default value and meta.quality_warning holds a failure note. If the extraction returns a record with no channel name, meta.quality_warning holds the text Channel returned incomplete data. Both responses cost 1 credit.
Read data.subscriber_count as a string, then convert it. An empty string means that the channel hides the count.
channel = response.json()["data"]
raw_subscribers = channel["subscriber_count"]
subscribers = int(raw_subscribers) if raw_subscribers else None
How do you qualify a creator channel before outreach?
A sponsorship list or an influencer list often holds channel URLs and nothing else. YouTube Channel Info turns one URL into the numbers that decide the outreach. One credit per channel keeps a large list affordable.
Send a YouTube Channel Info request with the channel URL as
url.Read
data.subscriber_countand convert the string to an integer.Drop every channel below your subscriber floor.
Read
data.countryto confirm that the channel matches your target market.Read
data.linksto find the website of the creator and the business contact URL.Store
data.channel_idas the stable key of the record.
The subscriber count and the video count qualify the size of a channel. They do not report the upload cadence. The data.video_count field is a lifetime total, so a channel with 892 videos can be dormant. For the upload cadence, send the channel URL to the YouTube Channel Videos API and read the publish_date field of the most recent videos.
A two-step qualification costs 3 credits per channel, or $0.06. Step one costs 1 credit and returns the size. Step two costs 2 credits and returns the cadence.
What is the difference between YouTube Channel Info and YouTube Channel Videos?
YouTube Channel Info returns the profile of one channel for 1 credit. YouTube Channel Videos returns the video list of the same channel for 2 credits. Both endpoints accept the same channel URL.
Item | YouTube Channel Info | YouTube Channel Videos |
Path |
|
|
Credits per call | 1 | 2 |
Returns | One profile object | A list of videos and a total count |
Subscriber count | Yes | No |
Avatar, banner, external links | Yes | No |
Per-video titles, view counts, publish dates | No | Yes |
Answers "how big is this channel?" | Yes | No |
Answers "how often does this channel publish?" | No | Yes |
Send both requests for a full picture of a channel. The total cost is 3 credits per channel, or $0.06.
How much does YouTube Channel Info cost?
YouTube Channel Info costs 1 credit per call. 1 credit costs $0.02 on the 1,000 and 5,000 credit packs, and less on larger packs. The table uses $0.02. The credit count does not change with the size of the channel or with the number of external links.
Calls | Credits | Cost |
1 | 1 | $0.02 |
100 | 100 | $2.00 |
1,000 | 1,000 | $20.00 |
10,000 | 10,000 | $200.00 |
RichAPI charges the credit for every 2xx response. A cached result costs the same 1 credit as a live extraction.
Which errors can YouTube Channel Info return?
Status | Meaning | What to do |
| The request body failed validation. | Correct the parameter that the message names. The |
| The API key is missing, wrong or revoked. | Send a valid key in the |
| This API key has no access to this endpoint ( | Call |
| The endpoint name is wrong. | Send the request to |
| The | Send a full channel URL, such as |
| The request rate is over the limit. | Wait, then send the request again. For a higher limit, contact support. |
| The API failed. | Send the request again. If the failure repeats, contact support. |
| The upstream service did not answer. | Wait a few seconds, then send the request again. |
RichAPI charges no credit for a 400, 401, 403, 404, 422, 429, 500 or 502 response.
Frequently asked questions
Can YouTube Channel Info accept a bare channel handle or a bare channel ID?
No. YouTube Channel Info accepts a full channel URL only, and it returns a 422 error for a bare handle or a bare channel ID. Wrap a handle as https://www.youtube.com/@handle and a channel ID as https://www.youtube.com/channel/UC....
Does YouTube Channel Info need a YouTube API key?
No. YouTube Channel Info reads the public channel page and needs no YouTube API key, no OAuth token and no login. Your RichAPI key in the x-api-key header is the only credential.
Why is the subscriber count a string and not a number?
YouTube Channel Info returns data.subscriber_count as a string of digits, because a channel that hides the count returns an empty string instead of a number. Convert the value to an integer in your code, and treat an empty string as an unknown count.
What is the difference between YouTube Channel Info and YouTube Channel Videos?
YouTube Channel Info returns the profile of a channel, such as the subscriber count and the external links, for 1 credit. YouTube Channel Videos returns the recent videos of the same channel, with titles, view counts and publish dates, for 2 credits.
How long does YouTube Channel Info cache a result?
YouTube Channel Info caches a channel for 6 hours. To accept a cached result inside that window, set cache to true. The meta.cache_hit field reports the source, and a cached call costs the same 1 credit.
How do you find a channel URL that you do not have?
Send a keyword to the YouTube Search API to find videos and their channels. Take the channel URL from those results, then send it to YouTube Channel Info for the subscriber count and the profile fields.
Does YouTube Channel Info return the email address of the creator?
No. YouTube Channel Info returns the external links of the About page in data.links, and it returns no email address. Send a website URL from data.links to the Website Email Extractor API to find a contact address.
Related articles
Website Email Extractor API
