Skip to main content

Documentation Index

Fetch the complete documentation index at: https://docs.mindcase.co/llms.txt

Use this file to discover all available pages before exploring further.

$0.2 / 1k results Extract YouTube search results for a query, providing video, channel, and playlist titles, links, and descriptions

Endpoint

POST /api/v1/agents/youtube/search/run

Parameters

query
string
required
Text · The YouTube keywords to search for.
type
string
default:"video"
Dropdown · Filter by content type (videos, channels, playlists).Options: video, channel, playlist, movie, show, shorts
maxResults
integer
default:50
Number · Total results to fetch. Use 0 for all (minimum: 20).
sortBy
string
Dropdown · Sort order for the results. Relevance by default. Note: sorting is not available for Shorts.Options: relevance, rating, date, views
duration
string
Dropdown · Filter by video length.Options: short, medium, long
uploadDate
string
Dropdown · Restrict results to a recent time range.Options: hour, today, week, month, year
country
string
Dropdown · Country to search YouTube from.View all 57 options →
language
string
Dropdown · Language for results.View all 36 options →

Response columns

FieldDisplay nameType
titleTitletext
descriptionDescriptiontext
durationDurationtext
viewsViewstext
publishedAtPublished Attext
channelChanneltext
channelHandleChannel Handletext
channelBadgesChannel Badgestext
channelVerifiedChannel Verifiedboolean
typeTypetext
thumbnailThumbnailurl
animatedThumbnailAnimated Thumbnailurl
channelAvatarChannel Avatarurl

Example

curl -X POST https://api.mindcase.co/api/v1/agents/youtube/search/run \
  -H "Authorization: Bearer mk_live_abc123def456" \
  -H "Content-Type: application/json" \
  -d '{
  "params": {
    "query": "Automation",
    "maxResults": 20
  }
}'

Example response

Response
{
  "job_id": "job_7f3a2b1c",
  "status": "completed",
  "data": [
    {
      "title": "AI Automation: Complete Beginners Guide",
      "description": "Subscribe to the channel for more up-to-date beginner content! In this video tutorial, I will show you how to run any ChatGPT\u00a0...",
      "duration": "7:56",
      "views": "362575",
      "publishedAt": "2024-05-01T00:00:00Z",
      "channel": "The AI Advantage",
      "channelHandle": "@aiadvantage",
      "channelBadges": [
        "Verified"
      ],
      "channelVerified": true,
      "type": "video",
      "thumbnail": null,
      "animatedThumbnail": null,
      "channelAvatar": null
    }
  ]
}