Daftar di bawah menunjukkan kasus penggunaan umum untuk metode ini. Arahkan kursor ke kasus penggunaan untuk melihat deskripsinya, atau klik kasus penggunaan untuk memuat nilai parameter contoh di APIs Explorer. Anda dapat membuka Penjelajah API layar penuh untuk melihat contoh kode yang diperbarui secara dinamis untuk mencerminkan nilai parameter yang dimasukkan di Explorer.
Tabel di bawah menunjukkan kasus penggunaan umum untuk metode ini. Anda dapat mengklik nama kasus penggunaan untuk memuat nilai parameter contoh di APIs Explorer. Atau, Anda dapat melihat contoh kode untuk kasus penggunaan di APIs Explorer layar penuh dengan mengklik ikon kode di bawah nama kasus penggunaan. Di UI layar penuh, Anda dapat memperbarui nilai parameter dan properti, serta contoh kode akan diperbarui secara dinamis untuk mencerminkan nilai yang Anda masukkan.
Metode ini memiliki satu kasus penggunaan umum, yang dijelaskan di bawah ini. Tombol di bawah deskripsi mengisi APIs Explorer dengan nilai contoh atau membuka APIs Explorer layar penuh untuk menampilkan contoh kode yang menggunakan nilai tersebut. Contoh kode juga diperbarui secara dinamis jika Anda mengubah nilainya.
Use cases | |
---|---|
list (by video ID) | This example retrieves information about a specific video. It uses the id parameter to identify the video. |
list (multiple video IDs) | This example retrieves information about a group of videos. The id parameter value is a comma-separated list of YouTube video IDs. You might issue a request like this to retrieve additional information about the items in a playlist or the results of a search query. |
list (most popular videos) | This example retrieves a list of YouTube's most popular videos. The regionCode parameter identifies the country for which you are retrieving videos. The sample code is set to default to return the most popular videos in the United States. You could also use the videoCategoryId parameter to retrieve the most popular videos in a particular category. |
list (my liked videos) | This example retrieves a list of videos liked by the user authorizing the API request. By setting the rating parameter value to dislike , you could also use this code to retrieve disliked videos. |