In my application, I want to display the languages that youtube supports so that the user can select them to filter. On the caption Resource page https://developers.google.com/youtube/v3/docs/captions?hl=en, snippet.language
property is "The language of the caption track. The property value is a BCP-47
language tag".
But when I get the captions list of a video, the response is zh-Hans
. It's Chinese (Simplified)
. But the BCP47 language codes list that I saw on the internet, it only has the following codes: zh-CN - Chinese (China)
, zh-HK - Chinese (Hond Kong)
and zh-TW - Chinese (Taiwan)
. It does not have zh-Hans
. Why are they different?
Another problem is that the youtube api only returns the language code, and the name of the language is an empty value.
So how can I get exactly all the caption languages that youtube supports including language code and name?