{"version":"1.0","type":"rich","title":"PHP API To get Direct Link of YouTube videos","description":"This example shows a PHP API that extracts direct video and audio stream URLs from YouTube by parsing the `get_video_info` response. It demonstrates how the code uses `file_get_contents` to fetch YouTube’s embedded video data, then employs `parse_str` and `explode` to decode the URL-encoded stream map. The API outputs a JSON array of available formats, including metadata like MIME type, resolution, and itag, while also handling error cases when a video is unavailable. The implementation relies on standard PHP functions and JSON encoding without external libraries.","provider_name":"VizHub AI Studio","provider_url":"https://next.vizhub.com","html":"<iframe src=\"https://next.vizhub.com/viz/gist-0cc2f163adbb77bbe2b3f53bd9c8f77a?mode=embed\" width=\"960\" height=\"500\" scrolling=\"no\" frameborder=\"1\"></iframe>","width":960,"height":500,"cache_age":3600}