Keyword search over YouTube videos with relevance or popularity sorting, upload-date filters and cursor pagination.
2 credits/ call
Never more than 16 credits a call.
You only pay when data comes back.
curl -X POST "https://api.primaryapi.com/v1/run/youtube.search" \
-H "Authorization: Bearer $PRIMARYAPI_API_KEY" \
-H "Content-Type: application/json" \
-d '{"query":"running shoes review"}'{
"output": {
"found": true,
"data": {
"nextCursor": "eyJsIjoieW91dHViZS5zZWFyY2gjc2NyYXB…",
"videos": [
{
"title": "NF - RUNNING (Audio)",
"views": 14860541,
"durationSeconds": 254,
"image": "https://i.ytimg.com/vi/BzSzwqb-OEE/…", …
}
]
}
},
"credits": 2
}Input and output
6 fields, 1 advanced
running shoes review.14 fields
Good to know
One page per call. Send nextCursor back as cursor to read the next page.
The same key and credits work for every API.