cursorstring
Continuation token from a previous response for pagination.
https://api.sandbase.ai/v1/api/youtube/channel-community-postsList a YouTube channel's community posts by handle or channel ID with cursor pagination (text, likes, image, publish time).
आपका आउटपुट यहाँ दिखाई देगा
इनपुट पूरा करें, फिर Run पर क्लिक करें।
Returns a list of community posts for a YouTube channel, with the post text, like count, image links and publish time. You pass a channel handle such as @MrBeast or a channelId.
likeCount across posts to see which posts get the most engagement.curl -X POST "https://api.sandbase.ai/v1/api/youtube/channel-community-posts" \
-H "Authorization: Bearer $SANDBASE_API_KEY" \
-H "Content-Type: application/json" \
-d '{"handle": "@MrBeast"}'
The result is returned in outputs[0].data.
| Name | Type | Required | Description |
|---|---|---|---|
channelId | string | No | YouTube channel ID. |
cursor | string | No | Continuation token from a previous response for pagination. |
handle | string | No | YouTube channel handle. |
Real response for the request above, trimmed: lists keep their first item and long strings are cut.
{
"data": {
"nextCursor": "cur_VMouee4IpseKyQo6IPoYVg",
"posts": [
{
"channelHandle": "MrBeast",
"channelId": "UCX6OQ3DkcsbYNE6H8uQQuVA",
"channelTitle": "MrBeast",
"content": "We spent $7,000,000 making the new MrBeast Lab animation series, and EPISODE 1 I…",
"createdUtc": 1793605689,
"id": "UgkxvMrKTpUbvqLPjv-lVi7N0wn68DV_NCBQ",
"image": "",
"likeCount": 9000,
"publishedTime": "1 day ago",
"url": "https://www.youtube.com/post/UgkxvMrKTpUbvqLPjv-lVi7N0wn68DV_NCBQ"
}
]
},
"found": true
}
| Field | Meaning |
|---|---|
data.posts[] | List of community posts for the channel, as returned on this page. |
data.posts[].id | ID of the post. It also appears at the end of the post url. |
data.posts[].content | Text of the post. Long text can end with an ellipsis. |
data.posts[].likeCount | Number of likes on the post, as a whole number. |
data.posts[].createdUtc | Time the post was created, as a Unix timestamp in seconds. |
data.posts[].publishedTime | Relative publish time as shown on YouTube, for example 2 weeks ago. |
data.posts[].image / data.posts[].images[] | Image attached to the post. image is an empty string when the post has no image. images appears on posts that have images. |
data.posts[].url | Link to the post on YouTube. |
data.posts[].channelHandle / data.posts[].channelId / data.posts[].channelTitle | Handle, ID and display name of the channel that made the post. |
data.nextCursor | Token for the next page of posts. Send it as cursor. |
handle or channelId. The handle in the response (channelHandle) has no leading @.cursor set to the data.nextCursor value.id or url with YouTube Community Post.Billed at the actual cost of each call, about $0.0012 for the request above. Failed calls are not charged.
बिल्डिंग शुरू करें
एकीकृत authentication और usage tracking के साथ Platform API endpoint.
curl -X POST "https://api.sandbase.ai/v1/api/youtube/channel-community-posts" \
-H "Authorization: Bearer $SANDBASE_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"handle": "@MrBeast"
}'अपने SandBase API key को अपने सर्वर environment में सेट करें। Requests Bearer authentication का उपयोग करती हैं।
export SANDBASE_API_KEY="YOUR_API_KEY"अपना key सर्वर पर रखें। इसे browser code में expose न करें।
cursorstringContinuation token from a previous response for pagination.
handlestringYouTube channel handle.
channelIdstringYouTube channel ID.
इस API के लिए सेव किया गया example response; इसे देखते समय कोई live request नहीं की जाती।
कोई सेव response प्रकाशित नहीं किया गया है। इसका response देखने के लिए Playground में API चलाएँ।
और जानें
| API | कीमत | प्रतिक्रिया |
|---|---|---|
YouTube | $0.0012 प्रति कॉल से | JSON |
YouTube | $0.00045 प्रति कॉल से | JSON |
YouTube | $0.0012 प्रति कॉल से | JSON |
YouTube | $0.0012 प्रति कॉल से | JSON |
YouTube | $0.014286 प्रति कॉल | JSON |
YouTube | $0.014286 प्रति कॉल | JSON |
प्रश्न
https://api.sandbase.ai/v1/api/youtube/channel-community-posts पर Authorization header (Bearer) में अपनी SandBase API key और parameters को JSON body के रूप में भेजें। आप इस पेज के Playground में बिना code लिखे भी इसे आज़मा सकते हैं।
$0.0012 से प्रति call, आपकी SandBase balance से बिल किया जाएगा। आपसे केवल आपके किए गए calls के लिए शुल्क लिया जाता है; कोई subscription नहीं है।
कोई parameters आवश्यक नहीं हैं। वैकल्पिक: cursor (string), handle (string) और channelId (string)। Parameters table और इस पेज का Playground हर field सूचीबद्ध करते हैं।
एक JSON response जो उसी HTTP request में लौटाया जाता है (synchronous)। इस पेज का README एक sample response शामिल करता है।
नहीं। YouTube Channel Community Posts SandBase के माध्यम से चलता है, इसलिए एक SandBase API key इस endpoint और catalog के हर अन्य API और model को कवर करती है। आपको अलग से YouTube API access के लिए आवेदन करने की आवश्यकता नहीं है।