YouTube 报告 API content_owner_ad_revenue_raw_a1表缺失



我正在使用Retrieve_Report下载数据分析。然后,它返回了可用报告类型的列表,如下所示:

 name reporting type: content_owner_basic_a3
 name reporting type: content_owner_estimated_revenue_a1
 name reporting type: content_owner_asset_province_a2
 name reporting type: content_owner_asset_playback_location_a2
 name reporting type: content_owner_asset_basic_a2
 name reporting type: content_owner_asset_demographics_a1
 name reporting type: content_owner_demographics_a1
 name reporting type: content_owner_asset_cards_a1
 name reporting type: content_owner_cards_a1
 name reporting type: content_owner_asset_traffic_source_a2
 name reporting type: content_owner_asset_sharing_service_a1
 name reporting type: content_owner_traffic_source_a2
 name reporting type: content_owner_device_os_a2
 name reporting type: content_owner_playlist_combined_a1
 name reporting type: content_owner_playback_location_a2
 name reporting type: content_owner_subtitles_a2
 name reporting type: content_owner_playlist_device_os_a1
 name reporting type: content_owner_end_screens_a1
 name reporting type: content_owner_annotations_a1
 name reporting type: content_owner_ad_rates_a1
 name reporting type: content_owner_playlist_basic_a1
 name reporting type: content_owner_sharing_service_a1
 name reporting type: content_owner_asset_end_screens_a1
 name reporting type: content_owner_asset_device_os_a2
 name reporting type: content_owner_province_a2
 name reporting type: content_owner_playlist_traffic_source_a1
 name reporting type: content_owner_playlist_playback_location_a1
 name reporting type: content_owner_asset_estimated_revenue_a1
 name reporting type: content_owner_combined_a2
 name reporting type: content_owner_asset_annotations_a1
 name reporting type: content_owner_asset_combined_a2
 name reporting type: content_owner_playlist_province_a1

问题是Retrieve_Report似乎无法获得名为 content_owner_ad_revenue_raw_a1content_owner_video_metadata_a2/content_owner_video_metadata_a1 的报告类型。有什么方法可以从这些报告类型下载数据?

这些是系统管理的报告。

您需要将includeSystemManaged=True作为参数添加到.list()。在您链接的代码示例的上下文中,修改第 152-158 行,如下所示:

try:
    # If the user has not specified a job ID or report URL, retrieve a list
    # of available jobs and prompt the user to select one.
    if not args.job_id and not args.report_url:
      if list_reporting_jobs(youtube_reporting,
                             onBehalfOfContentOwner=args.content_owner
                             includeSystemManaged=True):
        args.job_id = get_job_id_from_user()

如果直接调用 list() 函数,

youtube_reporting.jobs().list(onBehalfOfContentOwner={your_content_owner_id}, includeSystemManaged=True).execute()

相关内容

  • 没有找到相关文章

最新更新