Youku APIs - Video Details (V1)
This API retrieves detailed information of a specific Youku video, including video ID, title, description, cover image, duration, tags, play count, like count, publish time, and the video's detail page URL.
Typical use cases:
- Fetching comprehensive metadata for a single video.
- Tracking engagement metrics like play counts and likes.
- Integrating detailed video info into third-party dashboards.
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
token | query | string | Yes | TOKEN |
videoId | query | string | Yes | The unique identifier for the video. |
Code Samples
💡 Environment Note
Default samples use https://api.justoneapi.com (prod-global). For users in Mainland China, it is recommended to replace it with http://47.117.133.51:30015 (prod-cn) for better performance. See Environment Guide.
bash
# Tip: For Mainland China, replace https://api.justoneapi.com with http://47.117.133.51:30015
curl -X GET "https://api.justoneapi.com/api/youku/get-video-detail/v1?token=YOUR_API_KEY&videoId=VALUE"text
I want to use the "Video Details (V1)" API from Just One API.
API Endpoint: https://api.justoneapi.com/api/youku/get-video-detail/v1
HTTP Method: GET
Authentication: Append "?token=YOUR_API_KEY" to the URL.
OpenAPI Definition: https://docs.justoneapi.com/openapi/youku-apis/video-details-v1-en.json
Parameters:
- token (query): TOKEN (Required)
- videoId (query): The unique identifier for the video. (Required)
Return format: JSON
Response Handling & Error Codes:
1. Business results should be determined by the "code" field in the response body (code 0 means success).
2. Timeout Recommendation: Set request timeout to at least 60 seconds.
3. Business Code Reference:
- 0: Success
- 100: Invalid or Inactive Token
- 301: Collection Failed. Please Retry.
- 302: Rate Limit Exceeded
- 303: Daily Quota Exceeded
- 400: Invalid Parameters
- 500: Internal Server Error
- 600: Permission Denied
- 601: Insufficient Balance
Please help me write a script in my preferred programming language to call this API and handle the response.python
# Tip: For Mainland China, replace https://api.justoneapi.com with http://47.117.133.51:30015
import requests
url = "https://api.justoneapi.com/api/youku/get-video-detail/v1?token=YOUR_API_KEY&videoId=VALUE"
response = requests.get(url)
print(response.json())js
// Tip: For Mainland China, replace https://api.justoneapi.com with http://47.117.133.51:30015
const response = await fetch("https://api.justoneapi.com/api/youku/get-video-detail/v1?token=YOUR_API_KEY&videoId=VALUE", {
method: "GET"
});
const data = await response.json();
console.log(data);java
// Tip: For Mainland China, replace https://api.justoneapi.com with http://47.117.133.51:30015
import java.net.URI;
import java.net.http.HttpClient;
import java.net.http.HttpRequest;
import java.net.http.HttpResponse;
public class Main {
public static void main(String[] args) throws Exception {
HttpClient client = HttpClient.newHttpClient();
HttpRequest request = HttpRequest.newBuilder()
.uri(URI.create("https://api.justoneapi.com/api/youku/get-video-detail/v1?token=YOUR_API_KEY&videoId=VALUE"))
.method("GET", HttpRequest.BodyPublishers.noBody())
.build();
HttpResponse<String> response = client.send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
}
}go
// Tip: For Mainland China, replace https://api.justoneapi.com with http://47.117.133.51:30015
package main
import (
"fmt"
"io"
"net/http"
)
func main() {
client := &http.Client{}
url := "https://api.justoneapi.com/api/youku/get-video-detail/v1?token=YOUR_API_KEY&videoId=VALUE"
req, _ := http.NewRequest("GET", url, nil)
resp, _ := client.Do(req)
defer resp.Body.Close()
body, _ := io.ReadAll(resp.Body)
fmt.Println(string(body))
}php
// Tip: For Mainland China, replace https://api.justoneapi.com with http://47.117.133.51:30015
<?php
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, "https://api.justoneapi.com/api/youku/get-video-detail/v1?token=YOUR_API_KEY&videoId=VALUE");
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, "GET");
$response = curl_exec($ch);
curl_close($ch);
echo $response;Responses
json
{
"code": 0,
"data": {
"headers": {
"nobelTrackInfo": "1148:[email protected]@0@",
"manufacturingDate": "20260309 22:00:01"
},
"videoMap": {
"videoId": "XNjQ5ODcwMjQ4OA==",
"videoLongId": 1624675622,
"videoCategoryId": 97,
"videoCategory": "电视剧",
"videoType": null,
"videoTypeCode": null,
"videoImg": "https://m.ykimg.com/0548060168F6E9851F08888AB10C277D",
"videoImgV": "https://m.ykimg.com/0575060168F6E9851F08888AB10C277D",
"showVideoStage": null,
"videoPublishTime": "2025-10-21 10:05:43",
"videoTitle": "盛夏芬德拉:最后一场戏开拍前的情绪拉扯",
"showVideoStageDesc": "",
"showId": null,
"showLongId": null,
"showCategoryId": null,
"showCategory": null,
"episodeTotal": null,
"showName": null,
"showSubtitle": null,
"completed": null,
"showImg": null,
"showImgV": null,
"showImgW3H2": null,
"episodeLast": null,
"showReleaseTime": null,
"episodeFinalStage": null,
"playlistId": null,
"playlistLongId": null,
"playlistTitle": null,
"scgId": null,
"userId": null,
"allowComment": true,
"allowShare": true,
"allowDownload": true,
"allowLike": true,
"isFavorite": false,
"reportUrl": "",
"pageKey": "LOCVIDEO_OTHER_DEFAULT",
"prePaid": null,
"paid": 0,
"duration": 115.8,
"totalComment": 499,
"totalUp": 17,
"verticalStyle": null,
"isNewReservation": false,
"politicsSensitive": null,
"interactiveChapter": null,
"playingType": null,
"isTracking": false,
"isPugv": false,
"adRestricted": 0,
"autoPay": false,
"albumId": null,
"microVideoSchema": null,
"videoRiskMark": null,
"allowUnionRefresh": 1,
"dspPopDisplayTime": null,
"pcSearchSeoStr": null,
"audiolang": [],
"videoSizes": null,
"downloadStatus": [],
"videoKind": null,
"subCategories": null,
"hasVideoType": null,
"animeEdition": null,
"videoCacheConfig": null,
"showPackageType": null,
"videoPackageType": null,
"showLibraryTag": null,
"videoLibraryTag": null,
"streamTypes": [
"flvhd"
],
"safetyContentElement": null,
"videoUpsStream": null,
"isShort": true,
"toFind": true,
"isVideo": true,
"pageTitle": "盛夏芬德拉:最后一场戏开拍前的情绪拉扯",
"vId": "XNjQ5ODcwMjQ4OA=="
},
"pushInfo": {},
"drawerList": [
{
"type": 10001,
"id": 13682,
"componentList": [
51729
]
}
],
"componentList": [
{
"id": 51729,
"type": 10049,
"componentId": "h5-detail-guide",
"componentName": "播放页引导",
"dataNode": [
{
"data": {
"img": "http://ykimg.alicdn.com/develop/image/2019-08-02/89bcdfe700fc4babe08c7ca76a7ecb17.jpg",
"title": "预览播放中,打开优酷APP看高清完整版",
"action": {
"type": "JUMP_TO_NATIVE",
"value": "youku://",
"contentType": null,
"contentValue": null,
"reportDisabled": false,
"extra": null,
"callback": null,
"reportConfig": null,
"report": {
"pageName": "page_playpage",
"arg1": "h5_detail_guide",
"spmAB": "a2h0j.10182321",
"spmC": "card_1",
"spmD": "1_0",
"scmAB": "20140719.manual",
"scmC": "51721",
"scmD": "native_youku%3A%2F%2F",
"index": 0,
"reportDataOpt": null,
"trackInfo": {
"component_id": "h5_detail_guide",
"pvv_vid": "XNjQ5ODcwMjQ4OA==",
"component_instance_id": 51729,
"servertime": 1773064801708,
"pageid": "LOCVIDEO_OTHER_DEFAULT",
"drawerid": "13682",
"cms_req_id": "213dee4817730648017038551e2f64"
},
"utParam": null
}
},
"subType": "NORMAL"
},
"id": 455807,
"type": 10030
}
],
"title": "",
"props": {}
}
],
"nobelTrackHeader": "",
"playPageData": {
"headerCallApp": {
"btnTitle": "下载APP",
"type": "JUMP_TO_NATIVE",
"jumpUrl": ""
},
"PopCallApp": {
"btnTitle": "打开",
"type": "JUMP_TO_NATIVE",
"jumpUrl": "",
"subtitle": "为好内容全力以赴",
"expires": 1,
"unit": "hour",
"logo": "https://gw.alicdn.com/imgextra/i3/O1CN01CO6s7L1qQvicY255E_!!6000000005491-2-tps-112-112.png",
"title": "优酷"
},
"bottomCallApp": {
"btnTitle": "打开优酷APP更流畅",
"type": "JUMP_TO_NATIVE",
"jumpUrl": ""
},
"callSwitch": true
}
}
}💡 Note: For list data, the example shows only 1-2 items for simplicity. The actual count depends on the API response.
