این صفحه تغییرات API و بهروزرسانیهای مستندات را برای هر دو API گزارشدهی یوتیوب و API تجزیه و تحلیل یوتیوب فهرست میکند. هر دو API به توسعهدهندگان امکان میدهند به دادههای تجزیه و تحلیل یوتیوب دسترسی داشته باشند، البته به روشهای مختلف. در این گزارش تغییرات مشترک شوید .
۱۵ ژانویه ۲۰۲۶
API گزارشدهی یوتیوب اکنون از گزارشهای دسترسی برای کانالها و صاحبان محتوا پشتیبانی میکند. گزارشهای دسترسی، آماری از تعداد نمایش ویدیوها و نرخ کلیک ارائه میدهند.
- گزارشهای
channel_reach_basic_a1وchannel_reach_combined_a1برای کانالها در دسترس هستند. - گزارشهای
content_owner_reach_basic_a1وcontent_owner_reach_combined_a1برای مالکان محتوا در دسترس هستند.
این گزارشها از معیارهای جدید زیر پشتیبانی میکنند:
-
video_thumbnail_impressions -
video_thumbnail_impressions_ctr
۲۲ سپتامبر ۲۰۲۵
منسوخ شدن گزارشها که قبلاً اعلام شده بود، از ۳۰ سپتامبر ۲۰۲۵ به ۳۱ اکتبر ۲۰۲۵ موکول شده است. نسخههای قبلی گزارشهای بهروزرسانیشده برای تغییرات تعداد بازدید Shorts تا آن زمان همچنان در دسترس خواهند بود، به استثنای گزارش Claims نسخه ۱.۰ ( content_owner_active_claims_a1 ) و گزارش Claims نسخه ۱.۱ ( content_owner_active_claims_a2 ) که همچنان در ۳۰ سپتامبر منسوخ میشوند.
۲۴ ژوئن ۲۰۲۵
همانطور که در تاریخ ۲۶ مارس ۲۰۲۵ اعلام شد، API گزارشهای انبوه به عنوان بخشی از تغییر جدید تعداد بازدیدهای Shorts بهروزرسانی خواهد شد. تغییرات زیر اعمال شده است:
- نسخههای گزارش جدیدی برای هر گزارشی که شامل نماها میشود، ایجاد شده است که اکثر گزارشها را تشکیل میدهد. نسخه هر گزارش آسیبدیده یک واحد افزایش یافته است، مانند نسخه
a2به نسخهa3. - برای ویدیوهای کوتاه، تعداد بازدیدها اکنون بر اساس تعداد دفعاتی که یک ویدیوی کوتاه شروع به پخش یا پخش مجدد میکند، محاسبه میشود. برای ویدیوها، هیچ تغییری ایجاد نشده است.
- گزارشهای بهروزرسانیشده شامل یک ستون جدید به
engaged_viewsخواهند بود که روش شمارش بازدید قبلی را منعکس میکند.
این تغییرات از تاریخ 30 ژوئن 2025 برای API گزارشهای انبوه (Bulk Reports API) اعمال میشوند. حتماً پردازش گزارش خود را بر این اساس تنظیم کنید.
نسخههای گزارش قبلی تا 30 سپتامبر 2025 در دسترس خواهند بود. پس از 30 سپتامبر 2025، نسخههای قبلی منسوخ میشوند. حتماً به آخرین نسخهها مهاجرت کنید.
در نهایت، حتماً هنگام پردازش گزارشها، بهترین شیوهها را دنبال کنید تا از تغییرات آینده در گزارشها که باعث اختلال در روند پردازش شما میشوند، جلوگیری شود.
جداول زیر نسخههای جدید گزارش را برای هر نوع گزارش نشان میدهند:
گزارشهای دادههای انبوه برای YouTube Analytics
| گزارشهای کانال - گزارشهای ویدیویی | ||
|---|---|---|
| نام گزارش | نسخه قبلی | آخرین نسخه |
| فعالیت کاربر | channel_basic_a2 | channel_basic_a3 |
| فعالیت کاربران بر اساس استان | channel_province_a2 | channel_province_a3 |
| مکانهای پخش | channel_playback_location_a2 | channel_playback_location_a3 |
| منابع ترافیک | channel_traffic_source_a2 | channel_traffic_source_a3 |
| نوع دستگاه و سیستم عامل | channel_device_os_a2 | channel_device_os_a3 |
| زیرنویسها | channel_subtitles_a2 | channel_subtitles_a3 |
| ترکیبی | channel_combined_a2 | channel_combined_a3 |
| گزارشهای کانال - گزارشهای لیست پخش | ||
|---|---|---|
| نام گزارش | نسخه قبلی | آخرین نسخه |
| فعالیت کاربر | playlist_basic_a1 | playlist_basic_a2 |
| فعالیت کاربران بر اساس استان | playlist_province_a1 | playlist_province_a2 |
| مکانهای پخش | playlist_playback_location_a1 | playlist_playback_location_a2 |
| منابع ترافیک | playlist_traffic_source_a1 | playlist_traffic_source_a2 |
| نوع دستگاه و سیستم عامل | playlist_device_os_a1 | playlist_device_os_a2 |
| ترکیبی | playlist_combined_a1 | playlist_combined_a2 |
| گزارشهای مالک محتوا - گزارشهای ویدیویی | ||
|---|---|---|
| نام گزارش | نسخه قبلی | آخرین نسخه |
| فعالیت کاربر | content_owner_basic_a3 | مالک_محتوای_پایه_a4 |
| فعالیت کاربران بر اساس استان | content_owner_province_a2 | content_owner_province_a3 |
| مکانهای پخش | مکان_پخش_مالک_محتوا_a2 | مکان_پخش_مالک_محتوا_a3 |
| منابع ترافیک | content_owner_traffic_source_a2 | content_owner_traffic_source_a3 |
| نوع دستگاه و سیستم عامل | مالک_محتوای_دستگاه_سیستم_عامل_a2 | مالک_محتوای_دستگاه_سیستم_عامل_a3 |
| زیرنویسها | زیرنویس_مالک_محتوای_a2 | زیرنویس_مالک_محتوای_a3 |
| ترکیبی | content_owner_combined_a2 | content_owner_combined_a3 |
| گزارشهای مالک محتوا - گزارشهای لیست پخش | ||
|---|---|---|
| نام گزارش | نسخه قبلی | آخرین نسخه |
| فعالیت کاربر | مالک_محتوا_لیست_پخش_پایه_a1 | مالک_محتوا_لیست_پخش_پایه_a2 |
| فعالیت کاربران بر اساس استان | content_owner_playlist_province_a1 | content_owner_playlist_province_a2 |
| مکانهای پخش | مالک_محتوا_لیست_پخش_مکان_پخش_a1 | مالک_محتوا_لیست_پخش_مکان_پخش_a2 |
| منابع ترافیک | مالک_محتوا_پخش_لیست_ترافیک_منبع_a1 | مالک_محتوا_لیست_پخش_ترافیک_منبع_a2 |
| نوع دستگاه و سیستم عامل | مالک_محتوا_لیست_پخش_دستگاه_سیستم_عامل_a1 | مالک_محتوا_لیست_پخش_دستگاه_سیستم_عامل_a2 |
| ترکیبی | مالک_محتوای_لیست_پخش_ترکیبی_a1 | مالک_محتوای_لیست_پخش_ترکیبی_a2 |
| گزارشهای مالک محتوا - گزارشهای دارایی | ||
|---|---|---|
| نام گزارش | نسخه قبلی | آخرین نسخه |
| فعالیت کاربر | مالک_محتوای_دارایی_پایه_a2 | مالک_محتوای_دارایی_پایه_a3 |
| فعالیت کاربران بر اساس استان | content_owner_asset_province_a2 | content_owner_asset_province_a3 |
| مکانهای پخش ویدیو | مکان_پخش_دارایی_مالک_محتوا_a2 | مکان_پخش_دارایی_مالک_محتوا_a3 |
| منابع ترافیک | content_owner_asset_traffic_source_a2 | content_owner_asset_traffic_source_a3 |
| نوع دستگاه و سیستم عامل | content_owner_asset_device_os_a2 | مالک_محتوای_دارایی_دستگاه_سیستم_عامل_a3 |
| ترکیبی | مالک_محتوای_دارایی_ترکیبی_a2 | مالک_دارایی_ترکیبی_محتوای_a3 |
گزارشهای مدیریتشده توسط سیستم - مالی (غیر از موسیقی)
| گزارشهای مالک محتوا - گزارشهای کوتاه (غیر موسیقی) | ||
|---|---|---|
| نام گزارش | نسخه قبلی | آخرین نسخه |
| خلاصه درآمد جهانی تبلیغات | content_owner_shorts_global_ad_revenue_summary_a1 | content_owner_shorts_global_ad_revenue_summary_a2 |
| خلاصه درآمد روزانه از تبلیغات | content_owner_shorts_day_ad_revenue_summary_a1 | content_owner_shorts_day_ad_revenue_summary_a2 |
| خلاصه درآمد تبلیغات کشور | content_owner_shorts_country_ad_revenue_summary_a1 | content_owner_shorts_country_ad_revenue_summary_a2 |
| خلاصه درآمد حاصل از تبلیغات | خلاصه آگهیها و درآمدها | content_owner_shorts_ad_revenue_summary_a2 |
گزارشهای مدیریتشده توسط سیستم - غیرمالی
| گزارشهای مالک محتوا - گزارشهای ادعا | ||
|---|---|---|
| نام گزارش | نسخه قبلی | آخرین نسخه |
| ادعاهای فعال | content_owner_active_claims_a2 | content_owner_active_claims_a3 |
| گزارشهای مالک محتوا - گزارشهای فراداده ویدیویی | ||
|---|---|---|
| نام گزارش | نسخه قبلی | آخرین نسخه |
| فراداده ویدئو | مالک_محتوای_ویدئو_فراداده_a3 | مالک_محتوای_ویدئو_فراداده_a4 |
| گزارشهای مالک محتوا - گزارشهای دارایی | ||
|---|---|---|
| نام گزارش | نسخه قبلی | آخرین نسخه |
| داراییها | content_owner_asset_a2 | content_owner_asset_a3 |
| اختلافات دارایی | تعارض_دارایی_مالک_محتوای_a2 | تعارض_دارایی_مالک_محتوای_a3 |
۲۴ آوریل ۲۰۲۵
همانطور که در تاریخ ۲۶ مارس ۲۰۲۵ اعلام شد، API مربوط به Targeted Queries به عنوان بخشی از تغییر جدید تعداد بازدیدهای Shorts بهروزرسانی خواهد شد:
- برای ویدیوهای کوتاه،
viewsاکنون بر اساس تعداد دفعاتی که یک ویدیوی کوتاه شروع به پخش یا پخش مجدد میکند، محاسبه میشود. - یک معیار جدید،
engagedViews، منعکسکننده روش شمارش بازدید قبلی خواهد بود.engagedViewsدر تمام گزارشها به همراهviewsدر دسترس خواهد بود.
این تغییرات از تاریخ 30 آوریل 2025 برای API مربوط به پرسوجوهای هدفمند (Targeted Queries API) اعمال خواهد شد. حتماً پرسوجوهای خود را بر این اساس تنظیم کنید.
برای اطلاع از تغییرات و زمان اعمال آنها در API گزارشهای انبوه، این تاریخچهی ویرایش را بررسی کنید.
۲۲ آوریل ۲۰۲۵
همانطور که در ۷ آوریل ۲۰۲۴ اعلام شد، بُعد isCurated برای گزارشهای کانال و گزارشهای لیست پخش مالک محتوا منسوخ شده است. از ۳۱ دسامبر ۲۰۲۴، این بُعد دیگر پشتیبانی نمیشود. این بُعد از گزارشها و مستندات حذف شده است.
۲۶ مارس ۲۰۲۵
این بهروزرسانی شامل تغییر زیر در رابطه با APIهای YouTube Analytics و Reporting است:
از ۳۱ مارس ۲۰۲۵، یوتیوب نحوه شمارش بازدیدهای ویدیوهای کوتاه را تغییر خواهد داد. در گذشته، برای ویدیوهای کوتاه، یک بازدید پس از پخش شدن یک ویدیوی کوتاه به مدت چند ثانیه مشخص محاسبه میشد. اکنون، بازدیدها تعداد دفعاتی را که ویدیوی کوتاه شما شروع به پخش یا پخش مجدد میکند، بدون نیاز به حداقل زمان تماشا، شمارش میکنند. اطلاعات بیشتر
رابطهای برنامهنویسی کاربردی (API) یوتیوب آنالیتیکس (پرسوجوهای هدفمند) و گزارشدهی (گزارشهای انبوه) با تغییرات زیر بهروزرسانی خواهند شد:
- برای ویدیوهای کوتاه، تعداد
viewsتعداد دفعاتی است که یک ویدیوی کوتاه شروع به پخش یا پخش مجدد میکند. - یک معیار جدید به
engagedViewsدر دسترس قرار خواهد گرفت و منعکسکننده روش شمارش بازدید قبلی خواهد بود. - اگر صاحب یک کانال هستید یا اجازه دسترسی به دادههای یک کانال را دارید، میتوانید هم نماهای بهروز شده و هم نماهای فعال را جستجو کنید.
کوئریهای هدفمند تا 30 آوریل و گزارشهای انبوه تا 30 ژوئن بهروزرسانی خواهند شد. تا آن زمان، بازدیدها بر اساس روش قدیمی خواهد بود. بازدیدهای کوتاه و کانالها با Analytics در Studio مطابقت نخواهند داشت.
علاوه بر این، منسوخ شدن گزارش «مطالب روزانه» (نسخه ۱.۰) که قبلاً اعلام شده بود، به تعویق افتاده است.
برای اطلاع از زمان اعمال تغییرات در APIها، تاریخچهی ویرایشهای این API را بررسی کنید.
۳ مارس ۲۰۲۵
این بهروزرسانی شامل تغییر زیر در رابطه با API گزارشدهی یوتیوب است:
توجه: این یک اطلاعیه منسوخ شده است.
گزارش «مطالب روزانه» (نسخه ۱.۰) برای شرکا منسوخ شده است. این گزارش از ۳۰ آوریل ۲۰۲۵ یا بعد از آن دیگر پشتیبانی نخواهد شد. تعریف آن گزارش نیز بر این اساس بهروزرسانی شده است. به جای آن از آخرین گزارش «مطالب روزانه» استفاده کنید.
۱۵ نوامبر ۲۰۲۴
توجه: تغییر زیر از تاریخ ۱۸ نوامبر ۲۰۲۴ لازمالاجرا است.
مستندات API مربوط به YouTube Analytics (Targeted Queries) بهروزرسانی شده است تا توجه داشته باشید که برای گزارشهای منبع ترافیک ، متد reports.query این API اکنون در صورتی که حاصلضرب تعداد ویدیوهای درخواستشده X تعداد روز در محدوده تاریخ از ۵۰۰۰۰ بیشتر شود، خطا میدهد. برای مثال، یک پرسوجو که دادههای ۵۰۰ شناسه ویدیویی را بازیابی میکند، میتواند حداکثر ۱۰۰ روز داده درخواست کند.
این تغییر، گزارشهای مربوط به کانالها و صاحبان محتوا را تحت تأثیر قرار میدهد.
برای کاهش تعداد ردیفهایی که یک درخواست برمیگرداند، پرسوجوی خود را به چندین پرسوجو تقسیم کنید که ویدیوهای کمتری را مشخص کنند یا محدودههای زمانی کوتاهتری را تعیین کنند. به عنوان یک قاعده، گزارشهای انبوه برای مجموعه دادههای بزرگ توصیه میشوند.
۶ مه ۲۰۲۴
API یوتیوب آنالیتیکس (جستجوهای هدفمند) از سه گزارش جدید برای کانالها پشتیبانی میکند:
گزارش فعالیت کاربر بر اساس DMA، یک گزارش جغرافیایی است که آمار فعالیت کاربر را بر اساس منطقه بازار تعیینشده (DMA) ارائه میدهد. برای این گزارش، باید مقدار پارامتر
filtersرا رویcountry==USتنظیم کنید.گزارش بینندگان همزمان ، تعداد بینندگان همزمان را برای بخشهای مختلف یک ویدیوی پخش زنده نشان میدهد.
گزارش لغو عضویت اعضا، آماری را ارائه میدهد که نشان میدهد چرا کاربران عضویت کانال خود را لغو کردهاند.
این گزارش از بُعد جدید
membershipsCancellationSurveyReasonاستفاده میکند که مشخص میکند چرا یک کاربر عضویت کانال را لغو کرده است. همچنین از معیار جدیدmembershipsCancellationSurveyResponsesاستفاده میکند که نشان میدهد چه تعداد عضویت کانال به آن دلیل لغو شده است.
علاوه بر این، گزارش حفظ مخاطب برای پشتیبانی از سه معیار جدید بهبود یافته است:
۷ آوریل ۲۰۲۴
رابط برنامهنویسی کاربردی (API) یوتیوب آنالیتیکس (جستجوهای هدفمند) بهروزرسانیهای متعددی در رابطه با گزارشهای لیست پخش مالک محتوا دارد. این بهروزرسانیها مشابه بهروزرسانیهای مربوط به گزارشهای لیست پخش کانال هستند که در ۱۹ ژانویه ۲۰۲۴ اعلام شدند.
مدخل تاریخچهی ویرایش زیر تقریباً همان اطلاعات مدخل مربوط به ۱۹ ژانویه ۲۰۲۴ را ارائه میدهد. با این حال، توجه داشته باشید که گزارشهای لیست پخش مالک محتوا تا ۳۱ دسامبر ۲۰۲۴ از بُعد isCurated پشتیبانی میکنند، در حالی که این بُعد برای گزارشهای لیست پخش کانال تا ۳۰ ژوئن ۲۰۲۴ پشتیبانی میشود.
توجه: این یک اطلاعیه منسوخ شده است.
بُعد
isCuratedبرای گزارشهای لیست پخش مالک محتوا منسوخ شده است. این بُعد دیگر در تاریخ ۳۱ دسامبر ۲۰۲۴ یا بعد از آن پشتیبانی نخواهد شد. تعریف این بُعد نیز بر این اساس بهروزرسانی شده است.برای حفظ سازگاری رو به عقب هنگام حذف بُعد
isCurated، باید کد خود را نیز بهروزرسانی کنید تا معیارplaylistViewsرا به جای معیارviewsفقط برای گزارشهای لیست پخش بازیابی کند. از آنجایی که معیارviewsهنوز برای گزارشهای لیست پخش پشتیبانی میشود، البته با معنای متفاوت، API در صورت عدم بهروزرسانی نام معیار، همچنان دادهها را برمیگرداند. البته، میتوانید برنامه خود را طوری تغییر دهید که همviewsو همplaylistViewsرا بازیابی و نمایش دهد.علاوه بر بُعد
isCurated، قابلیتهای API زیر دیگر در گزارشهای جدید پشتیبانی نمیشوند:- فیلترهای موقعیت مکانی، مانند
continentوsubcontinentبرای گزارشهای جدید لیست پخش کانال پشتیبانی نمیشوند. - معیارهای
redViewsوestimatedRedMinutesWatchedدیگر برای گزارشهای جدید لیست پخش کانال پشتیبانی نمیشوند. این معیارها در YouTube Studio در دسترس نبودهاند، بنابراین این تغییر، عملکرد API را با عملکردهای موجود در برنامه Studio همسو میکند. - ابعاد
subscribedStatusوyoutubeProductدیگر به عنوان فیلتر برای گزارشهای لیست پخش کانال پشتیبانی نمیشوند. این فیلترها در YouTube Studio در دسترس نبودهاند، بنابراین این تغییر، عملکرد API را با عملکردهای موجود در برنامه Studio همسو میکند.
- فیلترهای موقعیت مکانی، مانند
بخش گزارشهای لیست پخش در مستندات گزارشهای مالک محتوا بهروزرسانی شده است تا انواع معیارهای پشتیبانیشده برای گزارشهای لیست پخش را بهطور کاملتری توضیح دهد:
- معیارهای تجمیعشدهی ویدیو، معیارهای فعالیت و نمایش کاربر را ارائه میدهند که برای تمام ویدیوهای موجود در لیستهای پخش مالک محتوا که متعلق به همان مالک محتوا نیز هستند، تجمیع شدهاند. معیارهای تجمیعشدهی ویدیو فقط برای درخواستهای API که از بُعد
isCuratedاستفاده نمیکنند، پشتیبانی میشوند. - معیارهای درون لیست پخش، فعالیت و تعامل کاربر را در متن صفحه لیست پخش منعکس میکنند. این معیارها شامل دادههایی برای بازدیدهای ویدیوهای غیر متعلق به پخشکننده در لیست پخش نیز میشوند، اما فقط زمانی که این بازدیدها در متن لیست پخش رخ داده باشند.
- بخش معیارهای پشتیبانیشدهی لیست پخش، معیارهای تجمیعی ویدیو و معیارهای درون لیست پخش را که برای گزارشهای لیست پخش پشتیبانی میشوند، مشخص میکند.
- معیارهای تجمیعشدهی ویدیو، معیارهای فعالیت و نمایش کاربر را ارائه میدهند که برای تمام ویدیوهای موجود در لیستهای پخش مالک محتوا که متعلق به همان مالک محتوا نیز هستند، تجمیع شدهاند. معیارهای تجمیعشدهی ویدیو فقط برای درخواستهای API که از بُعد
معیارهای جدید درون لیست پخش زیر برای گزارشهای لیست پخش برای مالکان محتوا پشتیبانی میشوند. توجه داشته باشید که این معیارها فقط در صورتی پشتیبانی میشوند که درخواست API برای بازیابی گزارشها از بُعد
isCuratedاستفاده نکند . برای تعاریف هر معیار، به مستندات معیارها مراجعه کنید:رفتار معیار
viewsاکنون به این بستگی دارد که آیا درخواست API که گزارش لیست پخش را بازیابی کرده است، از بُعدisCuratedاستفاده کرده است یا خیر:- وقتی درخواستی شامل بُعد
isCuratedباشد، معیارviews، معیاری درونلیست پخش است که تعداد دفعاتی را که ویدیوها در چارچوب لیستهای پخش صاحب محتوا مشاهده شدهاند، نشان میدهد. - وقتی درخواستی شامل بُعد
isCuratedنباشد، معیارviews، یک معیار ویدیوی تجمیعی است که تعداد کل دفعاتی را که ویدیوهای موجود در لیستهای پخش مالک محتوا مشاهده شدهاند، صرف نظر از اینکه آیا این بازدیدها در متن لیست پخش رخ دادهاند یا خیر، مشخص میکند. مجموع تجمیعی فقط شامل بازدیدهای ویدیوهایی است که متعلق به مالک محتوای مرتبط با کانال مالک لیست پخش هستند.
در این گزارشها که از بُعدisCuratedاستفاده نمیکنند، معیارplaylistViewsتعداد دفعاتی را که ویدیوها در زمینه لیست پخش مشاهده شدهاند، نشان میدهد. این معیار، بازدیدها را برای همه ویدیوهای موجود در لیست پخش، صرف نظر از اینکه متعلق به کدام کانال هستند، شمارش میکند.
- وقتی درخواستی شامل بُعد
برای هر گزارش لیست پخش، مستندات گزارشهای مالک محتوا اکنون شامل جداولی است که معیارهای پشتیبانی شده برای آن گزارش را بسته به اینکه آیا درخواست API شامل بُعد
isCuratedمیشود یا خیر، نشان میدهد. برای مثال، به بخش تعریف گزارشهای لیست پخش مبتنی بر زمان مراجعه کنید.
۱۹ ژانویه ۲۰۲۴
رابط برنامهنویسی کاربردی (API) یوتیوب آنالیتیکس (جستجوهای هدفمند) چندین بهروزرسانی مرتبط با گزارشهای لیست پخش کانالها داشته است. این بهروزرسانیها شامل یک بُعد منسوخشده و چندین معیار جدید و بهروزرسانیشده هستند:
توجه: این یک اطلاعیه منسوخ شده است.
بُعد
isCuratedبرای گزارشهای کانال منسوخ شده است. این بُعد دیگر از تاریخ ۳۰ ژوئن ۲۰۲۴ یا بعد از آن پشتیبانی نخواهد شد. تعریف این بُعد نیز بر این اساس بهروزرسانی شده است.برای حفظ سازگاری رو به عقب هنگام حذف بُعد
isCurated، باید کد خود را نیز بهروزرسانی کنید تا معیارplaylistViewsرا به جای معیارviewsفقط برای گزارشهای لیست پخش بازیابی کند. از آنجایی که معیارviewsهنوز برای گزارشهای لیست پخش پشتیبانی میشود، البته با معنای متفاوت، API در صورت عدم بهروزرسانی نام معیار، همچنان دادهها را برمیگرداند. البته، میتوانید برنامه خود را طوری تغییر دهید که همviewsو همplaylistViewsرا بازیابی و نمایش دهد.علاوه بر بُعد
isCurated، قابلیتهای API زیر دیگر در گزارشهای جدید پشتیبانی نمیشوند:- فیلترهای موقعیت مکانی، مانند
continentوsubcontinentبرای گزارشهای جدید لیست پخش کانال پشتیبانی نمیشوند. - معیارهای
redViewsوestimatedRedMinutesWatchedدیگر برای گزارشهای جدید لیست پخش کانال پشتیبانی نمیشوند. این معیارها در YouTube Studio در دسترس نبودهاند، بنابراین این تغییر، عملکرد API را با عملکردهای موجود در برنامه Studio همسو میکند. - ابعاد
subscribedStatusوyoutubeProductدیگر به عنوان فیلتر برای گزارشهای لیست پخش کانال پشتیبانی نمیشوند. این فیلترها در YouTube Studio در دسترس نبودهاند، بنابراین این تغییر، عملکرد API را با عملکردهای موجود در برنامه Studio همسو میکند.
- فیلترهای موقعیت مکانی، مانند
بخش گزارشهای لیست پخش در مستندات گزارشهای کانال بهروزرسانی شده است تا انواع معیارهای پشتیبانیشده برای گزارشهای لیست پخش را بهطور کاملتری توضیح دهد:
- معیارهای تجمیعشدهی ویدیو، معیارهای فعالیت و بازدید کاربر را ارائه میدهند که برای تمام ویدیوهای موجود در لیستهای پخش کانال که متعلق به آن کانال نیز هستند، تجمیع شدهاند. معیارهای تجمیعشدهی ویدیو فقط برای درخواستهای API که از بُعد
isCuratedاستفاده نمیکنند، پشتیبانی میشوند. - معیارهای درون لیست پخش، فعالیت و تعامل کاربر را در متن صفحه لیست پخش منعکس میکنند. این معیارها شامل دادههایی برای بازدیدهای ویدیوهای غیر متعلق به پخشکننده در لیست پخش نیز میشوند، اما فقط زمانی که این بازدیدها در متن لیست پخش رخ داده باشند.
- بخش معیارهای پشتیبانیشدهی لیست پخش، معیارهای تجمیعی ویدیو و معیارهای درون لیست پخش را که برای گزارشهای لیست پخش پشتیبانی میشوند، مشخص میکند.
- معیارهای تجمیعشدهی ویدیو، معیارهای فعالیت و بازدید کاربر را ارائه میدهند که برای تمام ویدیوهای موجود در لیستهای پخش کانال که متعلق به آن کانال نیز هستند، تجمیع شدهاند. معیارهای تجمیعشدهی ویدیو فقط برای درخواستهای API که از بُعد
معیارهای جدید درون لیست پخش زیر برای گزارشهای لیست پخش کانالها پشتیبانی میشوند. این معیارها هنوز برای گزارشهای مالک محتوا پشتیبانی نمیشوند. توجه داشته باشید که این معیارها فقط در صورتی پشتیبانی میشوند که درخواست API برای بازیابی گزارشها از بُعد
isCuratedاستفاده نکند . برای تعاریف هر معیار، به مستندات معیارها مراجعه کنید:رفتار معیار
viewsاکنون به این بستگی دارد که آیا درخواست API که گزارش لیست پخش را بازیابی کرده است، از بُعدisCuratedاستفاده کرده است یا خیر:- وقتی درخواستی شامل بُعد
isCuratedباشد، معیارviews، معیاری درونلیست پخش است که تعداد دفعاتی را که ویدیوها در چارچوب لیستهای پخش کانال مشاهده شدهاند، نشان میدهد. - وقتی درخواستی شامل بُعد
isCuratedنباشد، معیارviews، یک معیار ویدیوی تجمیعی است که تعداد کل دفعاتی که آن ویدیو در لیستهای پخش کانال مشاهده شده است را مشخص میکند، صرف نظر از اینکه آیا این بازدیدها در متن لیست پخش رخ دادهاند یا خیر. مجموع تجمیعی فقط شامل بازدیدهای ویدیوهایی است که متعلق به کانالی است که صاحب لیست پخش است.
در این گزارشها که از بُعدisCuratedاستفاده نمیکنند، معیارplaylistViewsتعداد دفعاتی را که ویدیوها در زمینه لیست پخش مشاهده شدهاند، نشان میدهد. این معیار، بازدیدها را برای همه ویدیوهای موجود در لیست پخش، صرف نظر از اینکه متعلق به کدام کانال هستند، شمارش میکند.
- وقتی درخواستی شامل بُعد
برای هر گزارش لیست پخش، مستندات گزارشهای کانال اکنون شامل جداولی است که معیارهای پشتیبانی شده برای آن گزارش را بسته به اینکه آیا درخواست API شامل بُعد
isCuratedمیشود یا خیر، نشان میدهد. برای مثال، به بخش تعریف گزارشهای لیست پخش مبتنی بر زمان مراجعه کنید.
۴ دسامبر ۲۰۲۳
API یوتیوب آنالیتیکس (پرسوجوهای هدفمند) بهروزرسانی شده است تا دو مقدار بُعد insightTrafficSourceType را ادغام کند. پیش از این، این بُعد بین ویدیوهای پخششده به عنوان بخشی از یک لیست پخش ( PLAYLIST ) و بازدیدهایی که از صفحهای که تمام ویدیوهای موجود در یک لیست پخش ( YT_PLAYLIST_PAGE ) را فهرست میکند، تمایز قائل میشد. از این پس، هر دو نوع بازدید با مقدار بُعد PLAYLIST مرتبط خواهند شد.
۱۵ دسامبر ۲۰۲۲
API یوتیوب آنالیتیکس (جستجوهای هدفمند) از دو بُعد جدید و یک گزارش جدید پشتیبانی میکند:
گزارش جدیدی فعالیت کاربران را بر اساس شهر ارائه میدهد. این گزارش برای کانالها و صاحبان محتوا در دسترس است. این گزارش شامل بُعد جدید
cityاست که تخمین یوتیوب از شهری که فعالیت کاربر در آن انجام شده را مشخص میکند.بُعد جدید
creatorContentTypeنوع محتوای یوتیوب را که با معیارهای فعالیت کاربر در ردیف دادهها مرتبط است، مشخص میکند. مقادیر پشتیبانیشده عبارتند ازLIVE_STREAM،SHORTS،STORYوVIDEO_ON_DEMAND.بُعد
creatorContentTypeبه عنوان یک بُعد اختیاری برای همه گزارشهای ویدیویی کانال و مالک محتوا پشتیبانی میشود.راهنمای درخواستهای نمونه API یوتیوب آنالیتیکس اکنون شامل مثالهایی برای هر دو بُعد جدید است.
ارجاعات به ابعاد
7DayTotalsو30DayTotalsاز مستندات حذف شدهاند. منسوخ شدن این ابعاد در اکتبر 2019 اعلام شد.
۲۶ اوت ۲۰۲۲
API یوتیوب آنالیتیکس (جستجوهای هدفمند) و API یوتیوب ریپورتینگ (گزارشهای انبوه) هر دو از یک مقدار جزئیات منبع ترافیک جدید پشتیبانی میکنند:
- در API مربوط به YouTube Analytics API (Targeted Queries)، اگر مقدار بُعد
insightTrafficSourceTypeSUBSCRIBERباشد، مقدارinsightTrafficSourceDetailمیتواند رویpodcastsتنظیم شود که نشان میدهد ترافیک از صفحه مقصد Podcasts ارجاع داده شده است. - در API گزارشدهی یوتیوب (گزارشهای انبوه)، اگر مقدار بُعد
traffic_source_typeبرابر با3باشد، میتوان مقدارtraffic_source_detailرا رویpodcastsتنظیم کرد، که نشان میدهد ترافیک از صفحه مقصد Podcasts ارجاع داده شده است.
۱۱ فوریه ۲۰۲۲
مجموعه مقادیر معتبر برای بُعد gender در تاریخ ۱۱ آگوست ۲۰۲۲ یا بعد از آن تغییر خواهد کرد. این ممکن است یک تغییر ناسازگار با نسخههای قبلی در پیادهسازی API شما باشد. مطابق با بخش « تغییرات ناسازگار با نسخههای قبلی» در شرایط خدمات سرویسهای YouTube API، این تغییر شش ماه قبل از اجرایی شدن اعلام میشود. لطفاً پیادهسازی API خود را قبل از ۱۱ آگوست ۲۰۲۲ بهروزرسانی کنید تا انتقال بدون مشکل به مجموعه مقادیر جدید تضمین شود.
تغییرات خاص اعمال شده عبارتند از:
- در API مربوط به YouTube Analytics (Targeted Queries)، بُعد
genderدر حال حاضر از دو مقدار پشتیبانی میکند:femaleوmale. در تاریخ ۱۱ آگوست ۲۰۲۲ یا بعد از آن، این بُعد از سه مقدار پشتیبانی خواهد کرد:female،maleوuser_specified. - در API گزارشدهی یوتیوب (گزارشهای انبوه)، بُعد
genderدر حال حاضر از سه مقدار پشتیبانی میکند:FEMALE،MALEوGENDER_OTHER. در تاریخ ۱۱ آگوست ۲۰۲۲ یا بعد از آن، مجموعه مقادیر پشتیبانیشده بهFEMALE،MALEوUSER_SPECIFIEDتغییر خواهد کرد.
۹ فوریه ۲۰۲۲
دو معیار برای حذف ترافیک کلیپهای تکرارشونده از ۱۳ دسامبر ۲۰۲۱ بهروزرسانی شدهاند. این تغییر هم بر API یوتیوب آنالیتیکس (پرسوجوهای هدفمند) و هم بر API یوتیوب ریپورتینگ (گزارشهای انبوه) تأثیر میگذارد.
- در API یوتیوب آنالیتیکس (جستجوهای هدفمند)، معیارهای
averageViewDurationوaverageViewPercentageهر دو ترافیک کلیپهای تکرارشونده را از ۱۳ دسامبر ۲۰۲۱ حذف میکنند. - در API گزارشدهی یوتیوب (گزارشهای انبوه)، معیارهای
average_view_duration_secondsوaverage_view_duration_percentageهر دو ترافیک کلیپهای تکرارشونده را از ۱۳ دسامبر ۲۰۲۱ حذف میکنند.
۲ فوریه ۲۰۲۲
این API گزارشدهی یوتیوب (گزارشهای انبوه) از یک مقدار بُعد منبع ترافیک جدید پشتیبانی میکند که نشان میدهد بازدیدها از Live Redirects سرچشمه گرفتهاند:
- در API گزارشدهی یوتیوب (گزارشهای انبوه)، بُعد
traffic_source_typeاز مقدار28پشتیبانی میکند.
برای این نوع منبع ترافیک، بُعد traffic_source_detail شناسه کانالی را مشخص میکند که بیننده از آن ارجاع داده شده است.
۲۳ سپتامبر ۲۰۲۰
این API مربوط به YouTube Analytics (جستجوهای هدفمند) و API مربوط به YouTube Reporting (گزارشهای انبوه) هر دو از یک مقدار بُعد منبع ترافیک جدید پشتیبانی میکنند که نشان میدهد بیننده با کشیدن عمودی انگشت در تجربه مشاهده YouTube Shorts به آن ارجاع داده شده است:
- در API مربوط به YouTube Analytics API (Targeted Queries)، بُعد
insightTrafficSourceTypeاز مقدارSHORTSپشتیبانی میکند. - در API گزارشدهی یوتیوب (گزارشهای انبوه)، بُعد
traffic_source_typeاز مقدار24پشتیبانی میکند.
بُعد جزئیات منبع ترافیک - insightTrafficSourceDetail در API YouTube Analytics یا traffic_source_detail در API گزارشدهی YouTube - برای این نوع منبع ترافیک جدید پر نشده است.
۲۰ ژوئیه ۲۰۲۰
این بهروزرسانی شامل دو تغییر است که بر API یوتیوب آنالیتیکس (جستجوهای هدفمند) تأثیر میگذارند:
- حداکثر اندازه یک گروه گزارشدهی YouTube Analytics از ۲۰۰ به ۵۰۰ نهاد افزایش یافته است.
- پارامتر
filtersدر متدreports.queryفهرستی از فیلترهایی را که باید هنگام بازیابی دادههای YouTube Analytics اعمال شوند، مشخص میکند. این پارامتر از قابلیت تعیین چندین مقدار برای فیلترهایvideo،playlistوchannelپشتیبانی میکند و حداکثر تعداد شناسههایی که میتوان برای این فیلترها تعیین کرد از ۲۰۰ به ۵۰۰ شناسه افزایش یافته است.
۱۳ فوریه ۲۰۲۰
این بهروزرسانی شامل تغییرات زیر در رابطه با API یوتیوب آنالیتیکس (پرسشهای هدفمند) و API گزارشدهی یوتیوب (گزارشهای انبوه) است. میتوانید اطلاعات بیشتر در مورد این تغییرات را در مرکز راهنمایی یوتیوب کسب کنید.
در هر دو API، مجموعه مقادیر جزئیات منبع ترافیک ممکن برای اعلانها در حال تغییر است. در کوئریهای هدفمند ، اعلانها به صورت insightTrafficSourceType=NOTIFICATION گزارش میشوند. در گزارشهای انبوه ، اعلانها به صورت traffic_source_type=17 گزارش میشوند.
مقادیر جدید، اعلانهای مربوط به ویدیوهای آپلود شده و پخش زنده را که قبلاً به عنوان uploaded گزارش میشدند، به دو دسته تقسیم میکنند:
-
uploaded_push- بازدیدها از اعلانهای ارسالی به مشترکین هنگام آپلود ویدیو سرچشمه میگیرند -
uploaded_other- بازدیدها از اعلانهای غیر فشاری، مانند اعلانهای ایمیل یا صندوق ورودی، که هنگام آپلود ویدیو برای مشترکین ارسال میشود، سرچشمه میگیرند.
این مقادیر برای محدوده زمانی شروع شده از ۱۳ ژانویه ۲۰۲۰ (۲۰۲۰-۰۱-۱۳) برگردانده میشوند.
همچنین، به عنوان یادآوری، این مقادیر خود اعلانها را نشان نمیدهند، بلکه منابع ترافیکی را نشان میدهند که باعث بازدیدهای خاص YouTube شدهاند. برای مثال، اگر یک ردیف گزارش views=3 ، traffic_source_type=17 ( NOTIFICATION ) و traffic_source_detail=uploaded_push را نشان دهد، این ردیف نشان میدهد که سه بازدید ناشی از کلیک بینندگان بر روی اعلانهای ارسالی هنگام آپلود ویدیو بوده است.
۱۵ اکتبر ۲۰۱۹
این بهروزرسانی شامل تغییرات زیر در رابطه با API یوتیوب آنالیتیکس (جستجوهای هدفمند) است:
توجه: این یک اطلاعیه منسوخ شده است.
یوتیوب پشتیبانی از ابعاد
7DayTotalsو30DayTotalsرا حذف میکند. شما همچنان میتوانید دادهها را با استفاده از این ابعاد تا 15 آوریل 2020 بازیابی کنید. در آن تاریخ یا بعد از آن، تلاش برای بازیابی گزارشها با استفاده از ابعاد7DayTotalsیا30DayTotalsبا خطا مواجه خواهد شد.توجه داشته باشید که کاربران میتوانند با استفاده از بعد
dayو جمعآوری یا استخراج دادهها در دورههای هفت یا سی روزه، برخی از دادهها را برای این ابعاد بازتولید کنند. برای مثال:- تعداد بازدیدها برای یک دوره هفت روزه را میتوان با جمع کردن تعداد بازدیدها از هر روز آن دوره محاسبه کرد.
- درصد بیننده برای یک دوره هفت روزه را میتوان با ضرب تعداد بازدیدهای هر روز در درصد بیننده آن روز محاسبه کرد تا تعداد بینندگانی که هنگام تماشای ویدیو در آن روز وارد سیستم شدهاند، به دست آید. سپس، میتوان تعداد بینندگان وارد شده را برای کل دوره جمع کرد و بر تعداد کل بازدیدها برای آن دوره تقسیم کرد تا درصد بیننده برای کل دوره به دست آید.
- تعداد بینندگان منحصر به فرد برای یک دوره هفت روزه قابل محاسبه نیست زیرا یک بیننده میتواند در روزهای مختلف به عنوان یک بیننده منحصر به فرد محاسبه شود. با این حال، ممکن است بتوانید از بُعد
monthبه جای بُعد30DayTotalsبرای برونیابی دادهها در مورد تعداد بینندگان منحصر به فرد در یک دوره 30 روزه استفاده کنید. توجه داشته باشید که بُعدmonthبه ماههای تقویمی اشاره دارد در حالی که بُعد30DayTotalsدورههای 30 روزه را بر اساس تاریخ شروع و پایان مشخص شده محاسبه میکند.
۲۷ ژوئن ۲۰۱۹
این بهروزرسانی شامل تغییرات زیر در رابطه با API یوتیوب آنالیتیکس (جستجوهای هدفمند) است:
از آنجایی که نسخه ۱ این API اکنون کاملاً منسوخ شده است، مستندات بهروزرسانی شده و ارجاعات به آن نسخه، از جمله اطلاعیه منسوخ شدن و راهنمای مهاجرت که نحوه بهروزرسانی به نسخه ۲ را توضیح میدهد، حذف شدهاند.
۱ نوامبر ۲۰۱۸
این بهروزرسانی شامل تغییرات زیر در رابطه با API یوتیوب آنالیتیکس (جستجوهای هدفمند) است:
نسخه ۱ این API اکنون منسوخ شده است. اگر هنوز این کار را انجام ندادهاید، لطفاً در اسرع وقت کلاینتهای API خود را برای استفاده از نسخه ۲ API بهروزرسانی کنید تا اختلالات سرویس به حداقل برسد. برای جزئیات بیشتر به راهنمای مهاجرت مراجعه کنید.
توجه داشته باشید که برنامهی این منسوخ شدن در ابتدا در تاریخ ۲۶ آوریل ۲۰۱۸ اعلام شده بود.
۱۷ سپتامبر ۲۰۱۸
این بهروزرسانی شامل تغییرات زیر در رابطه با API یوتیوب آنالیتیکس (جستجوهای هدفمند) است:
بخش جدید ناشناسسازی دادهها در سند مرور کلی مدل داده توضیح میدهد که برخی از دادههای YouTube Analytics زمانی محدود میشوند که معیارها به آستانه خاصی نرسند. این میتواند در موارد مختلفی اتفاق بیفتد. در عمل، به این معنی است که یک گزارش ممکن است شامل تمام (یا هیچ) دادههای شما نباشد اگر:
یک ویدیو یا کانال در یک بازه زمانی مشخص، ترافیک محدودی دارد،
یا
شما یک فیلتر یا بُعد، مانند منبع ترافیک یا کشور، را انتخاب کردهاید که مقادیر آن با آستانهی خاصی مطابقت ندارند.
این بخش جدید همچنین شامل بحثی در مورد انواع دادههایی است که ممکن است در گزارشهای YouTube Analytics محدود باشند.
گزارشهای کانال و اسناد گزارشهای مالک محتوا بهروزرسانی شدهاند تا این واقعیت را منعکس کنند که معیارهای
redViewsوestimatedRedMinutesWatchedدیگر برای گزارشهای مکان پخش، منبع ترافیک و نوع دستگاه/سیستم عامل پشتیبانی نمیشوند.
۱۸ ژوئن ۲۰۱۸
این بهروزرسانی شامل تغییرات زیر در API یوتیوب آنالیتیکس (جستجوهای هدفمند) است:
- الزامات دامنه برای روشهای زیر تغییر کرده است:
- درخواستهای ارسالی به متد
reports.queryباید به محدودهیhttps://www.googleapis.com/auth/youtube.readonlyدسترسی داشته باشند. - درخواستها به متد
groupItems.listباید به یکی از موارد زیر دسترسی داشته باشند:- دامنه
https://www.googleapis.com/auth/youtube
یا - دامنه
https://www.googleapis.com/auth/youtube.readonly
و
دامنهhttps://www.googleapis.com/auth/yt-analytics.readonly
گزینه اول از یک محدوده استفاده میکند که اتفاقاً یک محدوده خواندنی-نوشتنی است، در حالی که گزینه دوم از دو محدوده فقط خواندنی استفاده میکند.
- دامنه
- درخواستهای ارسالی به متد
۲۳ مه ۲۰۱۸
این بهروزرسانی شامل تغییرات زیر در API یوتیوب آنالیتیکس (جستجوهای هدفمند) است:
- نمای کلی API شامل یک بخش جدید به نام « معیارهای تجمیعی و موارد حذفشده » است که توضیح میدهد چگونه پاسخهای API دادههای مرتبط با منابع حذفشده، مانند ویدیوها، لیستهای پخش یا کانالها را مدیریت میکنند.
- بخش « بهترین شیوههای مرور کلی API» بهروزرسانی شده است تا به شما یادآوری کند که میتوانید از YouTube Data API برای بازیابی فرادادههای اضافی برای منابع شناساییشده در پاسخهای YouTube Analytics API استفاده کنید. همانطور که در سیاستهای توسعهدهندگان خدمات YouTube API (بخشهای III.E.4.b تا III.E.4.d) ذکر شده است، کلاینتهای API باید پس از 30 روز، فرادادههای ذخیرهشده منابع را از آن API حذف یا بهروزرسانی کنند.
۲۲ مه ۲۰۱۸
این بهروزرسانی شامل تغییرات زیر در رابطه با API گزارشدهی یوتیوب (گزارشهای انبوه) است:
- تغییرات زیر در حال حاضر قرار است از ژوئیه ۲۰۱۸ به اجرا درآیند و سیاستهای جدید به صورت جهانی برای همه گزارشها و مشاغل گزارشگری اعمال میشوند.
After the change, most API reports, including backfill reports, will be available for 60 days from the time that they are generated. However, reports containing historical data will be available for 30 days from the time they are generated.
Prior to this announcement, all API reports have been available for 180 days from the time that they were generated. To be clear, when this policy change goes into effect, historical data reports that are more than 30 days old will also no longer be accessible via the API. All other reports that are more than 60 days old will also no longer be accessible. As such, the documentation now states that reports created prior to the policy change will be available for up to 180 days.
After the change, when you schedule a reporting job, YouTube will generate reports from that day forward and covering the 30-day period prior to the time the job was scheduled. Prior to the change, when you schedule a reporting job, YouTube will generate reports covering the 180-day period prior to the time that the job was scheduled.
The best practices section has been updated to remind you that you can use the YouTube Data API to retrieve additional metadata for resources identified in reports. As noted in the YouTube API Services Developer Policies (sections III.E.4.b through III.E.4.d), API clients must either delete or refresh stored resource metadata from that API after 30 days.
The Report characteristics section has been updated to note that even though report data is not filtered, reports that contain data for a time period on or after June 1, 2018, will not contain any references to YouTube resources that were deleted at least 30 days prior to the date the report was generated.
The historical data section of the API overview has been updated to note that when you schedule a new reporting job, the historical reports are typically posted within a couple of days. Previously, the documentation stated that it could take up to 30 days for such reports to be available.
The backfill data section of the API overview has been updated to more clearly define backfill data as a data set that replaces a previously delivered set.
April 26, 2018
Version 2 of the YouTube Analytics (Targeted Queries) API (v2) is now publicly available. The following list identifies product and documentation changes related to the new API version:
The v2 API is almost identical to the v1 API. However, you will likely need to update your code to reflect the changes listed below. All of these changes are explained in detail in the new migration guide .
- The API's version has changed from
v1tov2. - The base URL for API requests has changed from
https://www.googleapis.com/youtube/analytics/v1tohttps://youtubeanalytics.googleapis.com/v2. - Several parameters for the
reports.querymethod have updated names. Specifically, parameter names that contain hyphens, likeend-datein the v1 API use camel case (endDate) rather than hyphens in the v2 API. This change makes parameter names consistent throughout the API since the API's methods for creating and managing groups already used camel casing for parameter names. - The v2 API does not support batch requests sent to Google's global HTTP batch endpoint (
www.googleapis.com/batch). If you are sending batch requests in the v2 API, you need to use the endpointhttps://youtubeanalytics.googleapis.com/v2instead.
In addition, a few v1 features are not supported in the v2 API:
- The
reports.querymethod no longer supports thealt,quotaUser, anduserIprequest parameters. - The v2 API does not provide a batch endpoint that supports batches comprised of requests to different APIs. (A batch can be comprised of requests to different methods of the same API, however.) This deprecation is not specific to the YouTube Analytics API as Google is deprecating the global batch endpoint across all of its APIs.
- The v2 API does not support the JSON-RPC protocol, which was supported in API v1. Again, this deprecation is not specific to the YouTube Analytics API.
- The API's version has changed from
Note: This is a deprecation announcement.
Version 1 of the API (v1) is now deprecated and will be supported until October 31, 2018. All requests to the v1 API will stop working after that date. As such, please be sure to upgrade to the v2 API no later than October 31, 2018, to avoid any interruption in your ability to access YouTube Analytics data via the API.
February 21, 2018
This update contains the following changes to the YouTube Analytics (Targeted Queries) API:
- Viewer demographic reports, which aggregate viewing statistics based on viewers' age group and gender, no longer support the
youtubeProductdimension, which identifies the YouTube service on which the user activity occurred.
January 18, 2018
This update contains the following changes:
YouTube Reporting API (Bulk Reports)
- The
operating_systemdimension, which identifies the software system of the device on which views occurred, now supports the following value:-
25: KaiOS
-
- The
YouTube Analytics API (Targeted Queries)
- The
operatingSystemdimension supports the dimension valueKAIOS.
- The
December 20, 2017
This update contains two changes related to the YouTube Reporting API:
The API server now supports gzip compression for requests that download reports. Note that gzip compression is not supported for other types of API requests. Enabling gzip compression reduces the bandwidth needed for each API response. And, while your application will need additional CPU time to uncompress API responses, the benefit of consuming fewer network resources usually outweighs that cost.
To receive a gzip-encoded response, set the
Accept-EncodingHTTP request header togzipas shown in the following example:Accept-Encoding: gzip
This functionality is explained in the API overview and in the definition of the
reportresource'sdownloadUrlproperty.The documentation of the
age groupandgenderdimensions has been corrected to show the actual values that the API returns for those dimensions. Note that this is a documentation correction and does not reflect a change in API functionality or behavior. Specifically, the following values have changed:- Values for the
age_groupdimension use uppercase letters, contain underscores between the wordAGEand the numbers in the age group, and use underscores instead of hyphens. As such, values likeage13-17andage18-24have been corrected toAGE_13_17andAGE_18_24, respectively. - Values for the
genderdimension use uppercase letters. Thus, the valuesfemale,male, andgender_otherhave been corrected toFEMALE,MALE, andGENDER_OTHER.
- Values for the
August 10, 2017
On August 10, 2016, this documentation announced the deprecation of the YouTube Analytics API's earnings metric. (At the same time, the API added support for a new metric, named estimatedRevenue , that provides the same data.)
Since the earnings metric was a core metric, it was supported for one year from the date of the announcement. Now that that yearlong period has ended, however, the earnings metric is no longer supported. As a result, API requests that specify the earnings metric now return a 400 HTTP response code. If you haven't already updated your app to use the estimatedRevenue metric instead of the earnings metric, please do so as soon as possible.
The API documentation has been updated to remove remaining references to the earnings metric.
July 6, 2017
This update contains the following changes:
YouTube Analytics API (Targeted Queries)
The API documentation has been updated to reflect the fact that API responses contain data up until the last day in the requested date range for which all metrics being queried are available.
For example, if a request specifies an end date of July 5, 2017, and values for all of the requested metrics are only available through July 3, 2017, that will be the last date for which data is included in the response. (That is true even if data for some of the requested metrics is available for July 4, 2017.)
The
adTypedimension now supports the valuereservedBumperInstream, which refers to a non-skippable video ad of up to 6 seconds that plays before a video can be viewed. The ad format is identical to theauctionBumperInstreamad, but this type refers to ads sold on a reserved rather than an auction basis.
YouTube Reporting API (Bulk Reports)
The
ad_typedimension now supports the value20, which refers to bumper ads sold on a reserved basis. Bumper ads are non-skippable video ads of up to 6 seconds that play before a video can be viewed. Note that the value19for this dimension also refers to bumper ads that are sold on an auction rather than a reserved basis.Reporting jobs for the following YouTube Reporting API reports have been deleted:
-
channel_basic_a1 -
channel_province_a1 -
channel_playback_location_a1 -
channel_traffic_source_a1 -
channel_device_os_a1 -
channel_subtitles_a1 -
channel_combined_a1 -
content_owner_basic_a2 -
content_owner_province_a1 -
content_owner_playback_location_a1 -
content_owner_traffic_source_a1 -
content_owner_device_os_a1 -
content_owner_subtitles_a1 -
content_owner_combined_a1 -
content_owner_asset_basic_a1 -
content_owner_asset_province_a1 -
content_owner_asset_playback_location_a1 -
content_owner_asset_traffic_source_a1 -
content_owner_asset_device_os_a1 -
content_owner_asset_combined_a1
These report types were announced as deprecated on September 15, 2016 , and reports were no longer generated for those report types after December 15, 2016. Previously generated reports were still available for 180 days from the time they were generated. Thus, some reports were accessible as late as June 15, 2017. However, since the reports are no longer available, the jobs associated with the reports are not needed either.
-
May 24, 2017
All reporting jobs for the following YouTube Reporting API reports have been deleted:
-
content_owner_ad_performance_a1 -
content_owner_asset_estimated_earnings_a1 -
content_owner_estimated_earnings_a1
These report types were announced as deprecated on June 22, 2016 , and reports were no longer generated for those report types after September 22, 2016. Previously generated reports were still available for 180 days from the time they were generated. Thus, some reports were accessible as late as March 22, 2017. However, since the reports are no longer available, the jobs associated with the reports are not needed either.
May 22, 2017
This update contains the following changes:
YouTube Reporting API (Bulk Reports)
- The
sharing_servicedimension, which identifies the service that was used to share videos, now supports the following values:-
85: YouTube Music -
86: YouTube Gaming -
87: YouTube Kids -
88: YouTube TV
In addition, the name used to identify value
52has been updated in the documentation to Kakao (Kakao Talk) to more clearly differentiate it from value73(Kakao Story). This change does not reflect any change in API behavior or classification of videos shared with these services. -
- The
YouTube Analytics API (Targeted Queries)
- The
sharingServicedimension now supports the following values:-
YOUTUBE_GAMING -
YOUTUBE_KIDS -
YOUTUBE_MUSIC -
YOUTUBE_TV
-
- The
March 28, 2017
Channel owners who can access revenue data through YouTube Analytics in Creator Studio can now also access that revenue data via the YouTube Analytics API:
The API supports the following revenue-related metrics:
-
adImpressions -
cpm -
estimatedAdRevenue -
estimatedRedPartnerRevenue -
estimatedRevenue -
grossRevenue -
monetizedPlaybacks -
playbackBasedCpm
These metrics are supported for the following reports:
-
Channel owners can also now retrieve an ad performance report , which supports the
adTypedimension as well as the optionaldaydimension.The YouTube Analytics API sample requests guide now includes a section for channel revenue reports .
March 17, 2017
This update contains the following changes:
The YouTube Analytics API supports the
redViewsandestimatedRedMinutesWatchedmetrics, both of which relate to YouTube Red viewership. In fact, the API has actually supported these metrics for some time, and the YouTube Reporting API already supports both metrics as announced on September 15, 2016 .- The
redViewsmetric identifies the number of times that a video was viewed by YouTube Red members. - The
estimatedRedMinutesWatchedmetric identifies the number of minutes that YouTube Red members watched a video.
The channel reports and content owner reports documentation has been updated to show which reports support the two new metrics. They are supported in any reports that already supported the
viewsandestimatedMinutesWatchedmetrics.- The
March 3, 2017
This update contains the following changes:
YouTube Reporting API (Bulk Reports)
The definition of the
datedimension has been corrected to note that the dimension value refers to the period beginning at 12:00 am Pacific time and ending at 11:59 pm Pacific time on the specified day, month, and year. Depending on the time of year, Pacific time is either UTC-7 or UTC-8.Though dates typically represent a 24-hour period, dates when clocks are adjusted forward represent a 23-hour period, and dates when clocks are adjusted backward represent a 25-hour period. (Previously, the documentation stated that each date represented a unique 24-hour period and that Pacific time was always UTC-8.)
Note that this correction does not represent a change in actual API behavior.
- The
operating_systemdimension, which identifies the software system of the device on which views occurred, now supports the following values:-
22: Tizen -
23: Firefox -
24: RealMedia
-
All reporting jobs for the
content_owner_basic_a1report type have been deleted. That report type had been fully deprecated as of August 19, 2016 , but previously generatedcontent_owner_basic_a1reports were still available for 180 days from the time they were generated. Thus, some reports were accessible as late as February 19, 2017. However, since the reports are no longer available, the jobs associated with the reports are not needed either.
YouTube Analytics API (Targeted Queries)
The description of dimensions related to
time periodshas been corrected to note that the dimension value refers to the period beginning at 12:00 am Pacific time and ending at 11:59 pm Pacific time on the specified day, month, and year. Depending on the time of year, Pacific time is either UTC-7 or UTC-8.Though dates typically represent a 24-hour period, dates when clocks are adjusted forward represent a 23-hour period, and dates when clocks are adjusted backward represent a 25-hour period. (Previously, the documentation stated that Pacific time was UTC-8 and did not mention the possibility that a day might not represent a 24-hour period.)
Note that this correction does not represent a change in actual API behavior.
The channel reports documentation has been updated to note that channel reports do not currently contain earnings or ad performance metrics. As a result, the
https://www.googleapis.com/auth/yt-analytics-monetary.readonlyscope does not currently grant access to monetary data in channel reports.- The
operatingSystemdimension supports three new dimension values:-
FIREFOX -
REALMEDIA -
TIZEN
-
February 8, 2017
The YouTube Analytics API now supports the optional include-historical-channel-data parameter. Note that this parameter is only relevant when retrieving content owner reports .
The parameter allows a content owner to indicate that an API response should include channels' watch time and view data from the time period prior to when the channels were linked to the content owner. The default parameter value is false , which means that, by default, the API response only includes watch time and view data from the time that channels were linked to the content owner.
These rules also apply if the API request retrieves data for multiple channels:
- If the parameter value is
false, then the watch time and views data returned for any given channel is based on the date that that channel was linked to the content owner.
It is important to remember that different channels might have been linked to a content owner on different dates. If the API request is retrieving data for multiple channels and the parameter value isfalse, then the API response contains watch time and view data based on the linking date for each respective channel. - If the parameter value is
true, then the response returns watch time and view data for all channels based on the start and end dates specified in the API request.
December 15, 2016
The following YouTube Reporting API reports are no longer supported and have been removed from the documentation. A newer version of each report is available. (The deprecation announcement for these reports was made on September 15, 2016.)
Channel reports
-
channel_basic_a1- Replaced by thechannel_basic_a2report. -
channel_province_a1- Replaced by thechannel_province_a2report. -
channel_playback_location_a1- Replaced by thechannel_playback_location_a2report. -
channel_traffic_source_a1- Replaced by thechannel_traffic_source_a2report. -
channel_device_os_a1- Replaced by thechannel_device_os_a2report. -
channel_subtitles_a1- Replaced by thechannel_subtitles_a2report. -
channel_combined_a1- Replaced by thechannel_combined_a2report.
-
Content owner reports
-
content_owner_basic_a2- Replaced by thecontent_owner_basic_a3report. -
content_owner_province_a1- Replaced by thecontent_owner_province_a2report. -
content_owner_playback_location_a1- Replaced by thecontent_owner_playback_location_a2report. -
content_owner_traffic_source_a1- Replaced by thecontent_owner_traffic_source_a2report. -
content_owner_device_os_a1- Replaced by thecontent_owner_device_os_a2report. -
content_owner_subtitles_a1- Replaced by thecontent_owner_subtitles_a2report. -
content_owner_combined_a1- Replaced by thecontent_owner_combined_a2report. -
content_owner_asset_basic_a1- Replaced by thecontent_owner_asset_basic_a2report. -
content_owner_asset_province_a1- Replaced by thecontent_owner_asset_province_a2report. -
content_owner_asset_playback_location_a1- Replaced by thecontent_owner_asset_playback_location_a2report. -
content_owner_asset_traffic_source_a1- Replaced by thecontent_owner_asset_traffic_source_a2report. -
content_owner_asset_device_os_a1- Replaced by thecontent_owner_asset_device_os_a2report. -
content_owner_asset_combined_a1- Replaced by thecontent_owner_asset_combined_a2report.
-
The list of current report types in the API reference documentation has also been updated.
November 11, 2016
This update contains the following changes:
The YouTube Reporting API supports three new end screen reports as well as new dimensions and metrics for those reports. The reports provide impression and click-through statistics for the end screens that display after a video stops playing.
End screen reports
- The end screen report for channel videos contains statistics for all of a channel's videos.
- The end screen report for content owner videos contains statistics for videos on any of a content owner's channels.
- The end screen report for content owner assets contains statistics for the assets associated with the videos after which the end screens display.
End screen dimensions
-
end_screen_element_type: The type of end screen element associated with the statistics. -
end_screen_element_id: The ID that YouTube uses to uniquely identify the end screen element.
-
End screen metrics
Note: Data for end screen metrics is available as of May 1, 2016.
-
end_screen_element_impressions: The total number of end screen element impressions. One impression is logged for each end screen element that displays. -
end_screen_element_clicks: The number of times that end screen elements were clicked. -
end_screen_element_click_rate: The click-through rate for end screen elements.
-
The following reports are no longer supported and have been removed from the documentation. A newer version of each report is available. (The deprecation announcement for these reports was made on June 22, 2016.)
-
content_owner_ad_performance_a1- Replaced by thecontent_owner_ad_rates_a1report. -
content_owner_estimated_earnings_a1- Replaced by thecontent_owner_estimated_revenue_a1report. -
content_owner_asset_estimated_earnings_a1- Replaced by thecontent_owner_asset_estimated_revenue_a1report.
-
The YouTube Help Center contains more detailed information about adding end screens to your videos .
November 8, 2016
This update contains the following changes to the YouTube Analytics API:
The metrics in the following list are fully deprecated and no longer supported. As announced on August 10, 2016, new metrics referring to the same data are already supported. The table below shows the deprecated metric name and the new metric name:
Deprecated metric New metric adEarningsestimatedAdRevenueimpressionBasedCpmcpmimpressionsadImpressionsredPartnerRevenueestimatedRedPartnerRevenue
October 27, 2016
YouTube now automatically generates a set of system-managed ad revenue reports for content owners that have access to the corresponding reports in the Reports section of YouTube's Creator Studio. The new system-managed API reports are designed to provide programmatic access to data that is also available in the manually downloadable Creator Studio reports.
The system-managed reports overview provides a brief overview of the new reports and explains the process for retrieving them via the API. This process is slightly different from that for retrieving bulk reports for YouTube Analytics since partners do not need to schedule jobs to generate the reports.
The reportType resource's id property has been updated to include a list of the system-managed reports that you can access via the API:
- Monthly, worldwide ad revenue per video
- Daily, per-country ad revenue per video
- Monthly, worldwide ad revenue per asset
- Daily, per-country ad revenue per asset
- Claims (this report does not contain revenue data)
September 27, 2016
Note: This is a deprecation announcement.
The YouTube Analytics API's uniques metric has been deprecated. This is not a core metric and it will be supported until October 31, 2016.
September 15, 2016
This update contains the following YouTube Reporting API changes:
The API supports two new metrics related to YouTube Red viewership:
-
red_views: The number of times that a video was viewed by YouTube Red members. -
red_watch_time_minutes: The number of minutes that YouTube Red members watched a video.
-
The API supports new versions of 20 reports. All of the new versions support the new
red_viewsandred_watch_time_minutesmetrics.For each report, the number in the new report type ID is one number higher than in the old report type ID. (The old versions of these reports are now deprecated as described later in this revision history.) For example, the
channel_basic_ a1report is now deprecated and has been replaced by thechannel_basic_ a2report.The following lists identify the new report type IDs:
Channel video reports
Content owner video reports
Content owner asset reports
Note: This is a deprecation announcement.
Note that if you already have jobs to create any of the older versions of the reports listed above, you need to create new jobs for the renamed reports. In conjunction with the release of the new report versions, the following report versions have been deprecated:
-
channel_basic_a1 -
channel_province_a1 -
channel_playback_location_a1 -
channel_traffic_source_a1 -
channel_device_os_a1 -
channel_subtitles_a1 -
channel_combined_a1 -
content_owner_basic_a2 -
content_owner_province_a1 -
content_owner_playback_location_a1 -
content_owner_traffic_source_a1 -
content_owner_device_os_a1 -
content_owner_subtitles_a1 -
content_owner_combined_a1 -
content_owner_asset_basic_a1 -
content_owner_asset_province_a1 -
content_owner_asset_playback_location_a1 -
content_owner_asset_traffic_source_a1 -
content_owner_asset_device_os_a1 -
content_owner_asset_combined_a1
If you have jobs for any of those reports, you should not expect YouTube to generate new reports for those jobs after December 15, 2016. Generated reports will still be available for 180 days from the time they were generated.
-
August 19, 2016
This update contains the following YouTube Reporting API change:
The
content_owner_basic_a1report has been fully deprecated and removed from the documentation. YouTube will no longer generate new reports of that type, though reports that were already generated will still be available for 180 days from the time they were generated.The
content_owner_basic_a1report's replacement is thecontent_owner_basic_a2report as explained in the revision history entry for May 19, 2016 .
August 11, 2016
This update contains the following changes:
The newly published YouTube API Services Terms of Service ("the Updated Terms"), discussed in detail on the YouTube Engineering and Developers Blog , provides a rich set of updates to the current Terms of Service. In addition to the Updated Terms , which will go into effect as of February 10, 2017, this update includes several supporting documents to help explain the policies that developers must follow.
The full set of new documents is described in the revision history for the Updated Terms . In addition, future changes to the Updated Terms or to those supporting documents will also be explained in that revision history. You can subscribe to an RSS feed listing changes in that revision history from a link in that document.
August 10, 2016
This update includes the following changes:
YouTube Analytics API (Targeted Queries)
Note: This is a deprecation announcement.
The metrics in the following table are being deprecated. At the same time, new metrics referring to the same data are being introduced. In effect, this means that the old metrics are being renamed, though the YouTube Analytics API will support both metric names until the deprecation dates listed in the table.
Old metric name New metric name Support date earningsestimatedRevenueAugust 10, 2017 adEarningsestimatedAdRevenueNovember 4, 2016 redPartnerRevenueestimatedRedPartnerRevenueNovember 4, 2016 impressionBasedCpmcpmNovember 4, 2016 impressionsadImpressionsNovember 4, 2016 Note that the
earningsmetric was a core metric , so it will be supported for one year from the date of this announcement. The other metrics, which were not core metrics, will be supported for three months, until November 4, 2016.For example, until November 4, 2016, an API request can specify the
impressionBasedCpmmetric, thecpmmetric, or both. However, after that date, only thecpmmetric will be supported.- The
insightTrafficSourceTypedimension supports two new dimension values:-
CAMPAIGN_CARD: This traffic source is only supported for content owner reports . It indicates that the views originated from claimed, user-uploaded videos that the content owner used to promote the viewed content. -
END_SCREEN: The data pertains to views that originated from the endscreen of another video.
For both new traffic sources, you can also retrieve a
traffic source detailreport. In both cases, theinsightTrafficSourceDetaildimension identifies the video from which the viewer was referred. -
The
adTypedimension now supports the valueauctionBumperInstream, which refers to a non-skippable video ad of up to 6 seconds that plays before a video can be viewed.
YouTube Reporting API (Bulk Reports)
- The
traffic_source_typedimension now supports the following values:-
19: This traffic source is only supported for content owner reports . It indicates that the views originated from claimed, user-uploaded videos that the content owner used to promote the viewed content. -
20: The data pertains to views that originated from the endscreen of another video.
For both new traffic sources, the
traffic_source_detaildimension identifies the video from which the viewer was referred. -
The API's list of core metrics has been corrected to list
estimated_partner_revenueas a core metric and to remove theearningsfrom that list. (Theearningsmetric has never been supported in the YouTube Reporting API.)The
ad_typedimension now supports the value19that refers to bumper ads, which are non-skippable video ads of up to 6 seconds that play before a video can be viewed.
- The
July 18, 2016
This update includes the following changes:
YouTube Analytics API (Targeted Queries)
- The lists of supported metrics for the following channel reports have been updated to include card metrics. Support for card metrics in these reports was actually added on June 28, 2016, and the revision history entry for that date explains the change in more detail. The reports are:
- Basic user activity for US states
- User activity in US states for specific time periods
- User activity by province
- User activity by subscribed status
- User activity by subscribed status for provinces
- Top videos by state
- Top videos for subscribed or unsubscribed viewers
The lists of filters have been corrected for both channel audience retention reports and content owner audience retention reports to reflect that the
videofilter is required and thegroupfilter is not supported.Previously, the documentation for both reports incorrectly stated that the report could be retrieved using one of those two filters or using neither filter.
- The lists of supported metrics for the following channel reports have been updated to include card metrics. Support for card metrics in these reports was actually added on June 28, 2016, and the revision history entry for that date explains the change in more detail. The reports are:
YouTube Reporting API (Bulk Reports)
- In the API overview , the section that explains how to retrieve a report's download URL has been corrected to state that YouTube does generate downloadable reports for days on which no data was available. Those reports contain a header row but do not contain additional data. This information had already been updated in the Report characteristics section of the same document on April 12, 2016 .
- The list of dimensions in the
content_owner_asset_cards_a1report has been corrected to reflect that the report uses thecard_iddimension. Previously, the documentation incorrectly listed the dimension name ascard_title.
June 28, 2016
The YouTube Analytics API documentation has been updated to reflect support for card metrics in numerous channel and content owner reports. The newly supported metrics are:
The metrics are supported in the following types of reports:
- Basic stats( channels , content owners )
- Time-based( channels , content owners )
- User geography ( channels , content owners )
- User activity by subscribed status ( channels , content owners )
- Top videos ( channels , content owners )
June 22, 2016
This update contains the following YouTube Reporting API changes. The first change pertains to the API in general, and the remaining changes only affect content owner reports :
The Report characteristics section of the API overview has been updated to clarify that reports are available via the API for 180 days from the time that they are generated.
Previously, the documentation stated that reports are available for a period of up to 180 days prior to the date that the API request is sent. While also technically true, the original text was, at best, rather confusing.
The API supports new versions of three reports. Two of those reports also contain new and renamed metrics:
The
content_owner_ad_rates_a1report is the new version of thecontent_owner_ad_performance_a1report. The newly renamed report is identical to the previous version.Two reports that have new versions have been renamed:
- The new version of the
content_owner_estimated_earnings_a1report is namedcontent_owner_estimated_revenue_a1. - The new version of the
content_owner_asset_estimated_earnings_a1report is namedcontent_owner_asset_estimated_revenue_a1.
Both newly renamed reports differ from their predecessors in the following ways:
- They add the new
estimated_partner_red_revenuemetric, which estimates the total earnings from YouTube Red subscriptions. - They add the new
estimated_partner_transaction_revenuemetric, which estimates revenue from transactions, such as paid content and Fan Funding, minus any partner-charged refunds. - They rename the
estimated_partner_ad_sense_revenuemetric toestimated_partner_ad_auction_revenue. - They rename the
estimated_partner_double_click_revenuemetric toestimated_partner_ad_reserved_revenue.
- The new version of the
Note that if you already have jobs to create any of the older versions of these reports, you need to create new jobs for the renamed reports. In conjunction with the release of the new report versions, the
content_owner_ad_performance_a1,content_owner_estimated_earnings_a1, andcontent_owner_asset_estimated_earnings_a1reports have been deprecated.If you have jobs for any of those reports, you should not expect YouTube to generate new reports for those jobs after September 22, 2016. Generated reports will still be available for 180 days from the time they were generated.
The definition of the
reportTyperesource'sidproperty has been updated to reflect the current set of available reports.The names of two metrics have been corrected in the documentation to match the names that appear in reports. This is purely a documentation fix and does not reflect a change in actual report contents:
- The
estimated_partner_adsense_revenuemetric's name has been updated toestimated_partner_ad_sense_revenue. Note, however, that this metric only appears in two reports that are being deprecated with this update. As described above, this metric has been renamedestimated_partner_ad_auction_revenuein newer versions of those reports. - The
estimated_partner_doubleclick_revenuemetric's name has been updated toestimated_partner_double_click_revenue. Again, note that this metric only appears in two reports that are being deprecated with this update. As described above, this metric has been renamedestimated_partner_ad_reserved_revenuein newer versions of those reports.
- The
The dimensions documentation for the Reporting API has been updated to no longer list the
elapsed_video_time_percentageandaudience_retention_typeproperties. These dimensions are not currently supported by any reports available through the API.
May 19, 2016
This update contains the following YouTube Reporting API changes:
The API supports a new version of the user activity report for content owners . The report type ID for the new report is
content_owner_basic_a2. Unlike the previous version of the report,content_owner_basic_a1, the new version supports thelikesanddislikesmetrics.If you already have a job to create the
content_owner_basic_a1report, you still need to create a new job for thecontent_owner_basic_a2report. YouTube is not automatically migrating content owners to the new report version or automatically creating a job to generate the new report version. In some implementations, the appearance of a new, unexpected job could be a breaking change.In conjunction with the release of the new report, the
content_owner_basic_a1report has been deprecated . If you have a job for that report, you should not expect YouTube to generate new reports for that job after August 19, 2016. Generated reports will still be available for 180 days from the time they were generated.The
reportType,job, andreportresources all support a new property that identifies whether the associated resource represents a deprecated report type:The
reportTyperesource'sdeprecateTimeproperty specifies the date and time that the report type will be deprecated. This property only has a value for reports that have been announced as deprecated, and the value represents the date when YouTube will stop generating reports of that type.After a report type is announced as deprecated, YouTube generates reports of that type for another three months. For example, this update on May 19, 2016, announces the deprecation of the
content_owner_basic_a1report. Thus, thedeprecateTimefor that report type specifies a time on August 19, 2016, after which YouTube will stop generating reports of that type.The
jobresource'sexpireTimeproperty specifies the date and time that the job expired or will expire. This property has a value if the report type associated with the job has been deprecated or if reports generated for the job have not been downloaded for a prolonged period of time. The date marks the time after which YouTube no longer generates new reports for the job.The
reportresource'sjobExpireTimeproperty specifies the date and time that the job that is associated with the report either expired or will expire. This property contains the same value as theexpireTimeproperty in thejobresource, as described in the previous item in this list.
The
jobs.createmethod now returns a400HTTP response code (Bad Request) if you try to create a job for a deprecated report. In addition, the method's documentation now lists several other reasons that cause an API request to fail.
۱۲ آوریل ۲۰۱۶
This update contains the following changes, all of which only affect the YouTube Reporting API:
YouTube now generates data covering the 180-day period prior to the time a reporting job was first scheduled. Previously, the Reporting API did not deliver any historical data. This change affects all jobs, including those created prior to this announcement.
Historical reports are posted as soon as they are available, though it takes roughly one month for all of the historical data to be posted for a job. So, a month after scheduling a reporting job, you will have access to around seven months of data. (All of the historical data for jobs created prior to this announcement should be posted within a month of the announcement.)
Note that historical data is only available as of July 1, 2015. As a result, jobs created before December 28, 2015, will have less than 180 days of historical data.
These change are all explained in the new historical data section of the Reporting API overview.
The report characteristics section of the YouTube Reporting API overview has been updated with the following changes:
The documentation now states that reports are available for a period of 180 days after they are generated and, therefore, available for API clients to download. Previously, the documentation stated that reports were available for a period of up to six months prior to the date that the API request is sent.
The documentation has been updated to reflect the fact that the API now generates downloadable reports for days on which no data was available. Those reports will contain header rows but will not contain additional data.
The YouTube Reporting API will soon support a set of automatically generated, system-managed reports that contain ad revenue data or YouTube Red subscription revenue data. The reports will be available to content owners who can already access manually downloadable revenue reports in the YouTube Creator Studio . Thus, the new API functionality will provide programmatic access to that data.
The following API changes are being announced now in preparation for the launch of system-managed reports:
The
jobresource's newsystemManagedproperty indicates whether the resource describes a job that generates system-managed reports. YouTube automatically generates system-managed reports for YouTube content owners, and content owners cannot modify or delete jobs that create those reports.The
jobs.listmethod's newincludeSystemManagedparameter indicates whether the API response should include jobs for system-managed reports. The parameter's default value isfalse.The
jobs.reports.listmethod's newstartTimeAtOrAfterparameter indicates that the API response should only contain reports if the earliest data in the report is on or after the specified date. Similarly, thestartTimeBeforeparameter indicates that the API response should only contain reports if the earliest data in the report is before the specified date.Unlike the method's
createdAfterparameter, which pertains to the time that the report was created, the new parameters pertain to the data in the report.The
reportTyperesource's newsystemManagedproperty indicates whether the resource describes a system-managed report.The
reportTypes.listmethod's newincludeSystemManagedparameter indicates whether the API response should include system-managed reports. The parameter's default value isfalse.
۲۸ مارس ۲۰۱۶
The YouTube Reporting API and YouTube Analytics API now return view statistics for several additional sharing services.
- In the YouTube Reporting API, the
sharing_servicedimension supports these new values:-
82: iOS system activity dialog -
83: Google Inbox -
84: Android Messenger
-
- In the YouTube Analytics API, the
sharingServicedimension supports these new values:-
ANDROID_MESSENGER: Android Messenger -
INBOX: Google Inbox -
IOS_SYSTEM_ACTIVITY_DIALOG: iOS system activity dialog
-
March 16, 2016
This update contains the following changes, which affect both the YouTube Reporting API and the YouTube Analytics API:
YouTube Reporting API
- The
playback_location_typedimension supports two new dimension values:-
7: The data pertains to views that took place on the YouTube home page or home screen, in the user's subscription feed, or in another YouTube browsing feature. -
8: The data pertains to views that took place directly on the YouTube search results page.
-
- The
traffic_source_typedimension now supports18as a dimension value. This value indicates that the video views originated from a page that lists all of the videos in a playlist. This source differs from source type14, which indicates that the views occurred while the video was being played as part of a playlist.
YouTube Analytics API
- The
insightPlaybackLocationTypedimension supports two new dimension values:-
BROWSE: The data pertains to views that took place on the YouTube home page or home screen, in the user's subscription feed, or in another YouTube browsing feature. -
SEARCH: The data pertains to views that took place directly on the YouTube search results page.
-
- The
insightTrafficSourceTypedimension now supportsYT_PLAYLIST_PAGEas a dimension value. This value indicates that the video views originated from a page that lists all of the videos in a playlist. This source differs from thePLAYLISTsource type, which indicates that the views occurred while the video was being played as part of a playlist.
February 8, 2016
The list of metrics supported for the YouTube Analytics API has been updated so that card metrics are no longer listed as supported metrics for that API. (None of that API's reports had been documented as supporting any of the card metrics.)
Note that you can still retrieve card metrics using the YouTube Reporting API, which supports those metrics for numerous channel and content owner reports.
January 6, 2016
The YouTube Reporting API and YouTube Analytics API both now specifically identify views that occur via a Chromecast device.
- In the YouTube Reporting API, the
operating_systemdimension uses the value21to identify views that take place via Chromecast. - In the YouTube Analytics API, the
operatingSystemdimension uses the valueCHROMECASTto identify views that take place via Chromecast.
December 21, 2015
In the documentation, the names of the annotation_clickable_impressions and annotation_closable_impressions metrics have been updated to match the names being returned in the reports. Previously, the names were documented as clickable_annotation_impressions and closable_annotation_impressions .
December 18, 2015
European Union (EU) laws require that certain disclosures must be given to and consents obtained from end users in the EU. Therefore, for end users in the European Union, you must comply with the EU User Consent Policy . We have added a notice of this requirement in our YouTube API Terms of Service .
December 15, 2015
This update contains the following changes, all of which affect the YouTube Analytics API:
The YouTube Analytics API now supports three new playback detail dimensions , which can be used in a variety of channel and content owner reports:
-
liveOrOnDemand: This dimension indicates whether the data in the report describes user activity that occurred during a live broadcast. -
subscribedStatus: This dimension indicates whether the user activity metrics in the data are associated with viewers who were subscribed to the video's or playlist's channel. -
youtubeProduct: This dimension identifies the YouTube property on which the user activity occurred. Possible values include the core YouTube website (or YouTube app), YouTube Gaming, and YouTube Kids.
The documentation has been updated to identify new playback detail reports that are available for channels and content owners . In addition, many other reports have been updated to note that one or more of these dimensions can optionally be used as dimensions and/or filters in those reports.
-
The format of the tables that explain the reports has changed to make it easier for you to identify valid combinations of dimensions, metrics, and filters that can be used to retrieve each report. The table below, which explains the "Device Type" report for channels, shows the new format:
فهرست مطالب Dimensions: مورد نیاز deviceType Use 0 or more day , liveOrOnDemand , subscribedStatus , youtubeProduct Metrics: Use 1 or more views , estimatedMinutesWatched فیلترها: Use 0 or 1 country , province , continent , subContinent Use 0 or 1 video , group Use 0 or more operatingSystem , liveOrOnDemand , subscribedStatus , youtubeProduct The terminology describing required and optional fields is explained in the documentation for channel and content owner reports.
The YouTube Analytics API now automatically drops entities that the API user cannot retrieve data for from filters that support multiple values (
video,playlist, andchannel). Previously, the API server would have just returned an error if the API user could not access data for at least one of the specified items.For example, suppose a user submits an API request in which the
videofilter lists 20 video IDs. The user owns 18 of the videos. However, one videos ID identifies a video owned by another channel, and another ID identifies a video that was deleted and, therefore, no longer exists. In this case, instead of returning an error, the API server now drops the two videos that the user cannot access, and the API response contains data for the 18 videos that the API user owns.If you request data for an empty YouTube Analytics
group, the API now returns an empty data set rather than an error.The YouTube Analytics API's
groupItems.insertmethod now returns an unauthorized (403HTTP response code) error if you try to add an entity to a group but you do not have access to that entity. Previously, the API would have allowed you to add the entity to the group, but later returned an unauthorized error when you tried to retrieve report data for that group.The YouTube Analytics API's
groups.listmethod now supports pagination. If the API response does not contain all available groups, then the response'snextPageTokenparameter specifies a token that can be used to retrieve the next page of results. Set the method'spageTokenparameter to that value to retrieve additional results.
November 10, 2015
This update contains the following changes:
The YouTube Analytics API now supports the
redPartnerRevenuemetric, which reports the total estimated revenue earned from YouTube Red subscriptions for the selected report dimensions. The metric's value reflects earnings from both music and non-music content and is subject to month-end adjustment.The YouTube Analytics API's list of content owner reports has been updated to identify the video reports that support the
redPartnerRevenuemetric:- Basic stats
- Time-based
- User geography
- Top videos – For this report,
redPartnerRevenueis also supported as a sorting metric, which means you can retrieve a list of videos sorted by their YouTube Red earnings.
The top videos report definition for the YouTube Analytics API now reflects that this report also supports the following earnings metrics:
earnings,adEarnings,grossRevenue,monetizedPlaybacks,playbackBasedCpm,impressions, andimpressionBasedCpm.
October 29, 2015
This update contains the following changes:
The documentation for the YouTube Reporting API's
datedimension has been corrected to reflect that dates reference the 24-hour period beginning at 12:00 am Pacific time (UTC-8). Previously, the documentation stated that the date began at 12:00 am (GMT).In addition, the YouTube Analytics API documentation has been updated to note that all date-related dimensions (
day,7DayTotals,30DayTotals, andmonth) refer to dates beginning at 12:00 am Pacific time (UTC-8).The YouTube Reporting API's
jobs.reports.list()method now supports thecreatedAfterquery parameter. If specified, this parameter indicates that the API response should only list reports created after the specified date and time, including new reports with backfilled data. Note that the parameter value pertains to the time that the report is created and not the dates associated with the returned data.The parameter value is a timestamp in RFC3339 UTC "Zulu" format, accurate to microseconds. Example:
"2015-10-02T15:01:23.045678Z".The YouTube Reporting API best practices have also been updated to explain how you can use the
createdAfterparameter to avoid repeatedly processing the same report.The definitions of the
jobresource'screateTimeproperty and thereportresource'sstartTime,endTime, andcreateTimeproperties have all been corrected to note that the property values are accurate to microseconds, not nanoseconds. In addition, all of the definitions now accurately reflect that the property value is a timestamp.
October 8, 2015
This update contains the following changes:
The documentation for the YouTube Analytics API's
sharingServicedimension has been updated to include a list of possible dimension values. The list includes a number of newly supported services.The YouTube Reporting API's
sharing_servicedimension's definition has also been updated to list the newly supported values. The enum values that are greater than59are the new ones in the list.
September 24, 2015
This update contains the following changes:
The new YouTube Reporting API retrieves bulk data reports that contain YouTube Analytics data for a channel or content owner. It is designed for applications that can import large data sets and that provide tools to filter, sort, and mine that data.
Each YouTube Reporting API report contains a predefined set of dimensions and metrics. (YouTube Analytics API reports also use metrics and dimensions.) In a report, each row of data has a unique combination of dimension values. You can aggregate data across rows based on dimension values to calculate metrics for individual videos, countries, live videos, subcribed users, and so forth.
You can use the API to schedule reporting jobs, each of which identifies a report that YouTube should generate. Once you have set up a job, YouTube generates a daily report that can be asynchronously downloaded. Each report contains data for a unique, 24-hour period.
Although they are different APIs, the YouTube Analytics API and the YouTube Reporting API both enable developers to retrieve YouTube Analytics data. Since the APIs both provide access to similar data sets, the documentation for the two APIs is being published as a single set of documentation.
- The Guides tab in the documentation set contains information common to both APIs, including instructions for authorizing API requests.
- The Bulk reports tab contains reference documentation and other content specifically for the YouTube Reporting API.
- The Targeted queries tab contains reference documentation and other content specifically for the YouTube Analytics API.
- The Samples tab lists code samples available for either of the two APIs.
- The Tools tab lists additional resources available to help developers implement either of the two APIs.
August 20, 2015
This update contains the following changes:
The API documentation has been restructured in an effor to make the API easier to understand. As such, these changes do not describe new features:
The documentation now contains one page that lists all available channel reports and another that lists all available content owner reports . Previously, the documentation had separate pages for channel video reports, channel playlist reports, and so forth.
The new data model overview seeks to provide a clearer introduction to how the API works. Specifically, this document tries to better explain how YouTube uses metrics, dimensions, and filters to calculate report values.
The API's
reports.querymethod, which you use to retrieve reports, is now documented separately. The information on that page had previously been on some other pages. The new page is designed to help you more easily identify the information you need to send to retrieve a report.
July 22, 2015
This update contains several changes, all of which only apply to content owners:
The new
adEarningsmetric includes total estimated earnings (net revenue) from all Google-sold advertising sources. It is not a core metric. The API supports theadEarningsmetric for any report that already supported theearningsmetric.In addition, the definition of the
earningsmetric has been corrected to reflect the fact that its value includes total estimated earnings from all Google-sold advertising sources as well as from non-advertising sources. Previously, the definition incorrectly indicated that the metric only included earnings from advertising sources.The
primaryAdGrossRevenuemetric has been deprecated. Instead, use thegrossRevenuemetric to retrieve revenue data.In addition to the deprecated
primaryAdGrossRevenuemetric, ad performance reports no longer support themonetizedPlaybacksandplaybackBasedCpmmetrics. However, several video reports do still support those metrics.
June 1, 2015
This update contains the following changes:
The API now supports two new metrics for video reports,
videosAddedToPlaylistsandvideosRemovedFromPlaylists. The lists of video reports for channels and content owners have both been updated to identify the reports that support the new metrics.-
videosAddedToPlaylists– The number of times that videos in the scope of the query were added to any YouTube playlists. The videos could have been added to the video owner's playlist or to other channels' playlists. -
videosRemovedFromPlaylists– The number of times that videos in the scope of the query were removed from any YouTube playlists. The videos could have been removed from the video owner's playlist or from other channels' playlists.
Both metrics include default playlists like the "Watch Later" playlist. However, they do not count playlists that a video is automatically added to, such as a channel's uploads playlist or a user's watch history. Also note that these metrics reflect the absolute number of additions and deletions. So, if a user adds a video to a playlist, then removes it, and then adds it again, the metrics indicate that the video was added to two playlists and removed from one.
Data for these metrics is available as of October 1, 2014.
-
March 31, 2015
This update contains the following changes:
The
favoritesAddedandfavoritesRemovedmetrics are both deprecated effective as of this announcement. These are both core metrics and subject to the Deprecation Policy set forth in the terms of service .
March 16, 2015
This update contains the following changes:
The new
currencyparameter allows you to retrieve earnings metrics in a currency other than United States dollars (USD). If the parameter is set, then the API converts values for theearnings,grossRevenue,playbackBasedCpm, andimpressionBasedCpmmetrics to the specified currency. The values returned are estimates calculated using exchange rates that change on a daily basis.The parameter value is a three-letter, ISO 4217 currency code. The default value is
USD. The parameter definition contains a list of supported currency codes.
February 25, 2015
This update contains the following changes:
The API now supports the ability to create and manage YouTube Analytics groups as well as the ability to retrieve report data for those groups.
Creating and managing groups
This update introduces the
groupandgroupItemresources for creating and managing groups.- The
groupresource represents an Analytics group, a custom collection of up to 200 channels, videos, playlists, or assets. The API supportslist,insert,update, anddeletemethods for this resource. - The
groupItemresource represents an item in an Analytics group. The API supportslist,insert, anddeletemethods for this resource.
So, for example, you could create a group using the
groups.insertmethod and then add items to that group using thegroupItems.insertmethod.- The
Retrieving report data for a group
The dimensions documentation has been updated to include the
groupdimension, which can be used as a filter for many channel reports and content owner reports . When you use thegroupfilter, the API returns data for all of the items in that group. Note that the API does not currently support the ability to create reports for asset groups.
See the YouTube Help Center for more information about YouTube Analytics groups.
February 13, 2015
This update contains the following changes:
The API no longer supports the
showdimension.
August 28, 2014
This update contains the following changes:
The API now supports the ability to specify multiple values for the
video,playlist,channel, andshowdimensions when those dimensions are used as filters . To specify multiple values, set thefiltersparameter value to a comma-separated list of the video, playlist, channel, or show IDs for which the API response should be filtered. The parameter value can specify up to 200 IDs.If you specify multiple values for the same filter, you can also add that filter to the list of dimensions that you specify for the request. This is true even if the filter is not listed as a supported dimension for a particular report. If you do add the filter to the list of dimensions, then the API also uses the filter values to group results.
See the
filtersparameter definition for complete details about this functionality.
July 16, 2014
This update contains the following changes:
When retrieving a channel report, you can now retrieve data for the authenticated user's channel by setting the value of the
idsparameter tochannel==MINE. (You can also still set theidsparameter tochannel== CHANNEL_IDto retrieve data for the specified channel.)The API now supports playlist reports, which contain statistics related to video views that occur in the context of a playlist. Playlist reports are available for channels and content owners .
All playlist reports support the
viewsandestimatedMinutesWatchedmetrics, and some also support theaverageViewDurationmetric.In addition, all playlist reports support the following new metrics. Note that each of these metrics only reflect playlist views that occurred on the web.
-
playlistStarts: The number of times viewers initiated playback of a playlist. -
viewsPerPlaylistStart: The average number of video views that occurred each time a playlist was initiated. -
averageTimeInPlaylist: The estimated average amount of time, in minutes, that a viewer viewed videos in a playlist after the playlist was initiated.
Any request to retrieve a playlist report must use the
isCuratedfilter, which must be set to1(isCurated==1).-
The API now supports an audience retention report. This report measures a video's ability to retain its audience. The report's new
elapsedVideoTimeRatiodimension measures the amount of the video that has elapsed for the corresponding metric values:The
audienceWatchRatiometric identifies the absolute ratio of viewers watching the video at the given point in the video. The ratio is calculated by comparing the number of times a portion of a video has been watched to the total number of views of the video.Note that a portion of a video could be watched more than once (or not at all) in a given video view. For example, if users rewind and watch the same portion of a video multiple times, then the absolute ratio for that portion of the video the could be greater than
1.The
relativeRetentionPerformancemetric shows how well a video retains viewers during playbacks in comparison to all YouTube videos of similar length. A value of 0 indicates that the video retains viewers worse than any other video of similar length, while a value of 1 indicates that the video retains viewers better than any other video of similar length. A median value of 0.5 indicates that half of the videos of similar length retain viewers better while half retain viewers worse.
You can also use the
audienceTypefilter so that the report only returns data associated with organic views, views from TrueView in-stream ads, or views from TrueView in-display ads. (Organic views are the direct result of user action, such as a search for a video or a click on a suggested video.)The API supports several new metrics related to annotations. The metrics listed below can be retrieved with any reports that previously supported the
annotationClickThroughRateandannotationCloseRatemetrics.-
annotationImpressions: The total number of annotation impressions. -
annotationClickableImpressions: The number of annotations that appeared and could be clicked. -
annotationClosableImpressions: The number of annotations that appeared and could be closed. -
annotationClicks: The total number of clicked annotations. -
annotationCloses: The total number of closed annotations.
All of the new metrics are core metrics and are subject to the Deprecation Policy . However, note that data is available for the new metrics as of July 16, 2013. (Data for the
annotationClickThroughRateandannotationCloseRatemetrics is available as of June 10, 2012.)-
GOOGLE_SEARCHis no longer reported as a separate value for theinsightTrafficSourceTypedimension. Instead, referrals from Google search results are now attributed to theEXT_URLtraffic source type. As a result, it's also no longer possible to retrieve aninsightTrafficSourceDetailreport that sets theinsightTrafficSourceTypefilter toGOOGLE_SEARCH.
January 31, 2014
This update contains the following changes:
The content owner reports document has been updated to reflect that the
subscribersGainedandsubscribersLostmetrics can now be retrieved for content claimed or uploaded by a content owner.The change is visible in the first basic stats report for content owners, which now supports the
claimedStatusanduploaderTypefilters.
January 16, 2014
This update contains the following changes:
The sample requests document has been redesigned to group examples in categories, using a tab format similar to the one recently released for channel and content owner reports. With the new design, examples are grouped into the following categories:
- Basic stats
- Time-based
- Geographic
- Playback location
- Traffic source
- Device/OS
- Demographic
- Social
- Earnings/Ads (for content owner reports only)
The sample requests document now includes new examples for retrieving province-specific data in either channel reports or content owner reports.
Province-specific metrics for US states and Washington DC : This report retrieves a province-by-province breakdown of view counts and other statistics for a channel's videos. The data covers US states and Washington DC The example uses the
provincedimension, and also uses thefiltersparameter to restrict the response to only include results for the United States.Viewer demographics in California (age group and gender) : This report retrieves statistics about the age group and gender of viewers in California who watched a channel's videos or, for content owner reports, a content owner's claimed content. This example uses the
filtersparameter to ensure the response only includes data for a particular province.
The definition of the
provincedimension has been updated to note that whenprovinceis included in thedimensionsparameter value, the request must also restrict data to the United States by includingcountry==USin thefiltersparameter value.
January 6, 2014
This update contains the following changes:
The documents that list the supported channel and content owner reports have been redesigned. Instead of providing a table that lists all possible reports, each document instead groups the reports into categories:
- Basic stats
- Time-based
- Geographic
- Playback location
- Traffic source
- Device/OS
- Demographic
- Social
- ویدیوهای برتر
Each document displays these categories as a list of tabs, and you can click any tab to see the supported reports in that category.
The API now supports three new geographic dimensions:
province,continent, andsubContinent.The
provincedimension lets you retrieve statistics for US states and for the District of Colombia. The API supports two uses for this dimension:The API supports two reports that break statistics down on a state-by-state basis. Both reports are available for channels and content owners .
- The core stats report provides several statistics, including view counts and estimated minutes watched.
- The time-based report provides the same statistics, but aggregates data on a daily, 7-day, 30-day, or monthly basis.
You can use the
filtersquery parameter to restrict a report to only contain statistics for a particular state. Several reports support this type of filtering, including geographic reports, playback location reports, traffic source reports, device reports, operating system reports, demographic reports, and top-video reports.
The
continentdimension specifies a United Nations (UN) statistical region code that identifies a continent. This dimension can only be used as a filter .The
subContinentdimension specifies a United Nations (UN) statistical region code that identifies a sub-region of a continent. This dimension can also only be used as a filter.Since each sub-region is only associated with one continent, there is no need to also use the
continentfilter when you are using thesubContinentfilter. (In fact, the API will return an error if a request uses both dimensions.)
The documentation has been corrected so that the
insightTrafficSourceDetaildimension does not include theinsightTrafficSourceTypevaluePROMOTEDas a valid filter value.
September 30, 2013
This update contains the following changes:
The YouTube Analytics API is now subject to the Deprecation Policy described in the Terms of Service . However, the API's non-core dimensions and non-core metrics are not subject to the Deprecation Policy. The dimensions and metrics pages have been updated to list core dimensions and core metrics. In addition, the definitions on those pages have been updated to explicitly identify core dimensions and metrics.
The API now supports
EXTERNAL_APPas a value for theinsightPlaybackLocationTypedimension. In conjunction with this update, as of September 10, 2013, playbacks are no longer categorized asMOBILEplaybacks, though mobile playbacks that occurred before that date will still be categorized with that value.With this update, mobile playbacks are now classified as either
WATCH,EMBEDDED, orEXTERNAL_APPplaybacks, depending on the type of application where the playbacks occur.The API now supports
PLAYLISTas a value for theinsightTrafficSourceTypedimension. The value indicates that video views were referred from a playlist. Previously, these views would have been classified using the dimension'sYT_OTHER_PAGEcategory.
July 16, 2013
This update contains the following changes:
The API now supports the ability to sort reports by multiple dimensions and metrics. The sample requests document contains a new example, Sorting requests by multiple dimensions/metrics , that demonstrates this functionality. The request retrieves traffic source data and has a
sortparameter value ofday,-views. Results are sorted chronologically, but within the result set for each day, the first row contains data for the traffic source that generated the most views, the second row contains data for the source with that generated the next highest amount of views, and so forth.The API now supports two new dimensions,
deviceTypeandoperatingSystem, which can be used to retrieve data about the devices where viewers are watching your videos. The API supports reports that use either or both dimensions.The
deviceTypereport lets you retrieve view counts and estimated watch time for different types of devices, including desktop, mobile, and tablet devices. You can also use theoperatingSystemfilter to restrict the device type report to only contain statistics for devices running a specific operating system, such as Android or iOS .The
operatingSystemreport lets you retrieve view counts and estimated watch time for different operating systems, such as Android, iOS, Linux, and more. You can also use thedeviceTypefilter to restrict the operating system report to only contain statistics for a specific type of device, such as mobile devices or tablets.
The new device type and operating system reports are available for channels and for content owners .
The sample requests document has been updated to include three device reports for channels and three device reports for content owners.
The
insightPlaybackLocationTypedimension may return the valueYT_OTHER, which identifies views that are not classified using one of the dimension's other values.
May 23, 2013
This update contains the following changes:
The content owner reports document has been updated to reflect that you can sort the top video report in descending order of earnings to identify videos with the highest earnings. This report is the first one listed in the second table of the User activity and earnings reports section.
May 10, 2013
This update contains the following changes:
YouTube no longer identifies experimental API features and services. Instead, we now provide a list of YouTube APIs that are subject to the deprecation policy .
May 6, 2013
This update contains the following changes:
The API now supports the ability to retrieve watch time metrics –
estimatedMinutesWatched,averageViewDuration, andaverageViewPercentage– in conjunction with other metrics, including view metrics, engagement metrics, earnings metrics, and ad performance metrics.The lists of available channel reports and content owner reports have been updated to reflect this change. (The lists are actually shorter now since the watch time metrics can be retrieved as part of other listed reports.)
The Sample API requests document has also been updated.
The reports that use the
insightPlaybackLocationDetailandinsightTrafficSourceDetaildimensions have been enhanced in the following ways:They now support an optional
countryfilter.Content owners can now retrieve these reports using any of the following new
filtercombinations. Note that all of these combinations also support the optionalcountryfilter.Playback location detail
-
channel,insightPlaybackLocationType==EMBEDDED -
show,insightPlaybackLocationType==EMBEDDED -
claimedStatus,insightPlaybackLocationType==EMBEDDED -
uploaderType,insightPlaybackLocationType==EMBEDDED -
uploaderType,claimedStatus,insightPlaybackLocationType==EMBEDDED
-
Traffic source detail
-
channel,insightTrafficSourceType -
show,insightTrafficSourceType -
claimedStatus,insightTrafficSourceType -
uploaderType,insightTrafficSourceType -
uploaderType,claimedStatus,insightTrafficSourceType
-
May 3, 2013
This update contains the following changes:
The new Sample API requests document provides examples that demonstrate how to retrieve many different types of reports using the YouTube Analytics API . Each example includes a brief description of the report that the request retrieves and then shows the dimensions, metrics, filters, and sort parameters for the request.
The
insightTrafficSourceTypedimension now supportsSUBSCRIBERas a valid value. This value identifies video views that were referred from feeds on the YouTube homepage or from YouTube subscription features. If you filter based on this traffic source, theinsightTrafficSourceDetailfield will specify the homepage feed or other page from which views were referred.
March 28, 2013
This update contains the following changes:
The API now supports two new metrics,
annotationClickThroughRateandannotationCloseRate, which are related to viewer interactions with annotations that display during your videos. The lists of channel reports and content owner reports have both been updated to identify the reports that support the new metrics.-
annotationClickThroughRate– The ratio of annotations that viewers clicked to the total number of clickable annotation impressions. -
annotationCloseRate– The ratio of annotations that viewers closed to the total number of annotation impressions.
-
March 21, 2013
This update contains the following changes:
The API now supports earnings and ad performance metrics as well as new ad performance reports. The metrics and the reports are all accessible only to YouTube content partners who participate in the YouTube Partner Program .
The newly supported reports support playback-based ad performance metrics and impression-based ad performance metrics. See the content owner reports documentation for more information about ad performance reports.
The newly supported metrics are listed below. The list of content owner reports has been updated to identify the reports, including the two new reports, that support these metrics.
-
earnings– Total estimated earnings from all Google-sold advertising sources. -
grossRevenue– Estimated gross revenue from Google or DoubleClick partners. -
primaryAdGrossRevenue– Estimated gross revenue, summed and classified under the primary ad type for the video playbacks that the report covers, from Google or DoubleClick partners. -
monetizedPlaybacks– The number of playbacks that showed at least one ad impression. -
playbackBasedCpm– Estimated gross revenue per thousand playbacks. -
impressions– The number of verified ad impressions served. -
impressionBasedCpm– Estimated gross revenue per thousand ad impressions.
Note: See the metric definitions for complete details.
-
Any request that retrieves earnings or ad performance metrics must send an authorization token that grants access using the new
https://www.googleapis.com/auth/yt-analytics-monetary.readonlyscope.
The API documentation has been reorganized so that different types of reports are explained on separate pages. As such, there are now separate pages explaining the different types of channel reports and content owner reports .
February 4, 2013
This update contains the following changes:
The API's reference guide now has an examples section, which includes code samples that demonstrate how to call the API using the Java, JavaScript, Python, and Ruby client libraries. The JavaScript code sample is the same one discussed in detail in the sample application documentation.
November 14, 2012
This update contains the following changes:
The API reference guide now features the APIs Explorer , which enables you to call the API, see the API request, and retrieve real data in the response.
The API supports a number of new reports for both channels and content owners, which are described below. Each report is available as a channel report or a content owner report . The dimensions and metrics pages have also been updated accordingly.
The playback location report specifies the number of video views that took place on different types of pages or applications .
The playback location detail report identifies the embedded players that generated the most views for a specified video. It provides a more fine-grained view than the playback location report by identifying the URLs associated with the top embedded players.
The traffic source report identifies the number of videos views that originated from different types of referrers .
The traffic source detail report identifies the referrers that generated the most views for a specified video and a specified traffic source type. For example, this report could you the related videos that sent the most traffic to a specific video. This report is supported for several traffic sources .
Watch time reports provide the amount of time viewers spent watching your content. The reports can aggregate data for a specific time frame – day, previous seven days, previous 30 days, etc. – or country. If a report aggregates data by either day or country, it can also specify the average length of each video view as well as the average percentage of each video that users watched.
۲ اکتبر ۲۰۱۲
This update contains the following changes:
The YouTube Analytics API is now available to all developers. You can activate the API for your project, without having to first request access, from the Services panel in the APIs console .
The new Getting Started section outlines the prerequisites and basic steps for building an application that uses the YouTube Analytics API .
September 12, 2012
This update contains the following changes:
The new understanding quota usage section provides guidelines for optimizing your API quota usage. The API server calculates a query cost for each request, and that cost is deducted from your API usage quota. Since different types of reports may have greatly different query costs, you should plan to use your quota efficiently, and your application should only request the metrics and data that it actually needs.
The temporal dimensions section has been updated to explain that those dimensions indicate that an Analytics report should aggregate data based on a time period. The API now supports the following additional temporal dimensions:
-
7DayTotals– Data in the report will be aggregated so that each row contains data for a seven-day period. -
30DayTotals– Data in the report will be aggregated so that each row contains data for a 30-day period. -
month– Data in the report will be aggregated by calendar month.
Similarly, the available reports section has been updated to reflect the API's support for reports that use these dimensions.
-
The reporting entity dimensions section has been updated to note that API requests to retrieve content owner reports must filter data using either one of these dimensions (
video,channel, orshow) or a supported combination of theclaimedStatusanduploaderTypedimensions.The API now supports two new sorting options for top-video reports . These reports, which are available as channel reports or content owner reports, contain metrics (views, comments, likes, etc.) on a per-country basis and break down those metrics by video. You can now sort these reports based on the number of users who subscribed to or unsubscribed from a channel from the video's watch page.
The definitions of the
subscribersGainedandsubscribersLostmetrics have been updated to explain that a channel can gain or lose subscribers in several places, including the video watch page, the channel page, and the guide that appears on the YouTube home page. When these metrics appear in a video-specific report, they only include statistics from the specified video's watch page.