如何使用 Youtube Analytics API 来获取指标“收益"? [英] How to use the Youtube Analytics API to get the metric "earnings"?

查看:18
本文介绍了如何使用 Youtube Analytics API 来获取指标“收益"?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我是 Youtube 合作伙伴,我在 Youtube 上通过视频获利.已经通过与我的 Google Adsense 帐户相关联的某些渠道每月收到少量款项.

I am a Youtube Partner and I have monetized videos on Youtube. Already receive a small monthly amount through some channels that have associated with my Google Adsense account.

现在,我想生成一份报告,收集从每个渠道收到的货币价值和观看次数.我在Google Code上做了以下问题,因为我认为API有问题,但碰巧我使用的API不正确.请参阅下面的链接.

Now, I would like to generate a report gathering the monetary values and views received from each channel. I did the following question on Google Code, because I thought there was some problem in the API, but it happened that I was using the API incorrectly. See the link below.

http://code.google.com/p/gdata-issues/issues/detail?id=4826#makechanges

现在,我仍然无法使其工作,因为我不知道在从上面的链接获得的响应中在哪里可以找到请求的数据.

Now, I still could not make it work because I do not know where to find the requested data in the response I got from the link above.

在哪里可以找到这个 CMS_ID?我有多个频道,所以我需要让每个频道都被接受为 Youtube 内容管理器才能使用 API 并检索收益?Stack Overflow 上的某个人已经设法使用收入"指标来使用 Youtube Analytics API?

Where do I find this CMS_ID? I have more than one channel, so I need to have each accepted as a Youtube Content Manager to use the API and retrieve the gains? Someone here on Stack Overflow already managed to use the Youtube Analytics API using the metric "earnings"?

我的代码在 Python 中基于 Google 此处的示例:

My code is in Python based on the example from Google here:

https://developers.google.com/youtube/analytics/v1/code_samples/python

我正在使用以下范围:

YOUTUBE_SCOPES = ["https://www.googleapis.com/auth/youtube.readonly",  
                      "https://www.googleapis.com/auth/yt-analytics.readonly", 
                      "https://www.googleapis.com/auth/youtubepartner",
                      "https://www.googleapis.com/auth/yt-analytics-monetary.readonly"]

推荐答案

目前,只有当这些报告通过内容所有者的上下文运行时,才能在 YouTube Analytics API 报告中检索货币信息,如中所述文档.

As of right now, it's only possible to retrieve monetary information in YouTube Analytics API reports when those reports are run via the context of a content owner, as described in the documentation.

可以有一个选择加入 Google AdSense 广告的获利频道,而该频道没有由内容所有者管理,在这种情况下,您将无法通过 YouTube 分析 API 获取这些指标.

It is possible to have a monetized channel that is opted in for Google AdSense ads without having that channel managed by a content owner, in which case you would not be able to get those metrics via the YouTube Analytics API.

让我们使用您之前打开的问题跟踪向非内容所有者开放此类报告的请求,因为这是比 Stack Overflow 更适合功能请求的地方.

Let's use the issue you previously opened to track the request to open up this type of report to non-content owners as well, as that's a more appropriate place for feature requests than Stack Overflow.

这篇关于如何使用 Youtube Analytics API 来获取指标“收益"?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆