I18nLanguages
i18nLanguage
資源會標示 YouTube 網站支援的應用程式語言。應用程式語言也稱為使用者介面語言。在 YouTube 網站上,應用程式語言會根據 Google 帳戶設定、瀏覽器語言或 IP 位置自動選取。使用者也可以在 YouTube 網站頁尾手動選取所需的使用者介面語言。
每個 i18nLanguage
資源都會標示語言代碼和名稱。在呼叫 videoCategories.list
和 guideCategories.list
等 API 方法時,語言代碼可用來做為 hl
參數的值。
方法
這個 API 支援 i18nLanguages
資源的下列方法:
- list
- 傳回 YouTube 網站支援的應用程式語言清單。立即試用。
資源表示法
以下 JSON 結構顯示 i18nLanguages
資源的格式:
{
"kind": "youtube#i18nLanguage",
"etag": etag,
"id": string,
"snippet": {
"hl": string,
"name": string
}
}
屬性
下表定義了這個資源中顯示的屬性:
屬性 |
kind |
string
識別 API 資源的類型。值為 youtube#i18nLanguage 。 |
etag |
etag
這項資源的 Etag。 |
id |
string
YouTube 用來識別 i18n 語言的 ID。 |
snippet |
object
snippet 物件包含 i18n 語言的基本詳細資料,例如語言代碼和名稱。 |
snippet.hl |
string
用於唯一識別語言的 BCP-47 代碼。 |
snippet.name |
string
使用 i18nLanguage.list 方法的 hl 參數指定的語言名稱,以該語言編寫。 |
除非另有註明,否則本頁面中的內容是採用創用 CC 姓名標示 4.0 授權,程式碼範例則為阿帕契 2.0 授權。詳情請參閱《Google Developers 網站政策》。Java 是 Oracle 和/或其關聯企業的註冊商標。
上次更新時間:2024-11-29 (世界標準時間)。
[null,null,["上次更新時間:2024-11-29 (世界標準時間)。"],[[["The i18nLanguage resource identifies a language supported by the YouTube website, which can be automatically set based on Google Account settings, browser language, or IP location, or manually selected by the user."],["Each i18nLanguage resource includes a language code and a name, with the language code being usable as the value for the `hl` parameter in API calls like `videoCategories.list` and `guideCategories.list`."],["The i18nLanguages resource can be retrieved using the `i18nLanguages.list` method, which provides a list of supported application languages."],["The resource is represented in JSON format, containing properties such as `kind` (identifying the resource type), `etag`, `id`, and a `snippet` object with details like the `hl` code and the language `name`."]]],[]]