YouTube Get Signed Stream URL

2.07 credits/call
ae_youtube_get_signed_stream_url

Get a temporary signed playback URL for a selected YouTube stream format. Inputs: - itag (required integer): the format identifier selected from the video's available stream-format list. Retrieve that list first if you do not know the itag. - video_id: the video ID, recommended for identifying the video. - video_url: the full video URL, as an alternative to video_id. If both are provided, video_id takes precedence and video_url is ignored. The response data includes itag, url (the signed playback URL), and expires_in_seconds (its validity period in seconds, typically 21600, or about six hours). This tool returns the link, not the media file. Request a new link after it expires. No proxy configuration is needed to call this tool. It does not accept proxy_url or let you select the public network exit used to obtain the signed URL. The link may fail with HTTP 403 when accessed from a different public exit; a signature does not guarantee access from every network. Regional restrictions may also apply.

Video
2.07 credits/call

Pricing

2.07 credits/call
ConditionCharge
Each call2.07 credits/call

2.07 credits/call Charges are per query. A successful query is billed even if it returns no results.

Parameters

Optional parameters use the platform defaults when omitted.

ParameterTypeRequiredDescriptionDefault
itagintegerYes格式标识符 itag (从 get_video_streams 接口获取)/Format identifier itag (obtained from get_video_streams endpoint)—
video_idstringNo视频ID/Video ID—
video_urlstringNo视频URL/Video URL (如果提供video_id则忽略此参数/Ignored if video_id is provided)—

Invocation example

Copy the request and explore its response example.

POST/agent-api/v1/tool/executeX-Api-Key
Request coderequest.sh
curl --request POST \
  --url 'https://agentearth.ai/agent-api/v1/tool/execute?tool_name=ae_youtube_get_signed_stream_url' \
  --header "X-Api-Key: $AGENTEARTH_API_KEY" \
  --header 'Content-Type: application/json' \
  --data-raw '{
  "params": {
    "itag": 140,
    "video_id": "IQLQFEz21Js"
  }
}'
Response exampleresponse.json
JSONPartial content
{
  "code": 200,
  "data": {
    "expires_in_seconds": 21600,
    "itag": 140
  },
  "docs": "https://api.tikhub.io/#/YouTube-Web-V2-API/get_signed_stream_url_api_v1_youtube_web_v2_get_signed_stream_url_get",
  "message": "Request successful. This request will incur a charge.",
  "message_zh": "请求成功,本次请求将被计费。",
  "request_id": "a67937d9-5856-4abf-84df-68d196fa7f34"
}

This example shows part of the response. Copied content is valid JSON.