我正在尝试使用Google API Python客户端和Play Dev API从PlayStore获取我的应用程序的所有评论。
现在,如果我打印response
,我得到
<googleapiclient.discovery.Resource object at 0x10302a990>
当我(我认为(我应该得到我的应用程序的所有评论时。不确定我的代码是否错了,或者我只是没有正确获得权限。
谢谢!
代码:
from google.oauth2 import service_account
import googleapiclient.discovery
SCOPES = ['https://www.googleapis.com/auth/androidpublisher']
SERVICE_ACCOUNT_FILE = 'playcreds.json'
credentials = service_account.Credentials.from_service_account_file(
SERVICE_ACCOUNT_FILE, scopes=SCOPES)
playstore = googleapiclient.discovery.build('androidpublisher','v2', credentials=credentials)
response = playstore.reviews()
reviews()
只是服务端点。查看在此处列出APK的类似样本。
而是,您可能想尝试使用此处的适当参数的playstore.reviews().list(...)
。