我对此很陌生。因此,请耐心等待我的用语和解释。
我想知道这是Google的限制或问题,还是我使用不正确?
我正在从v2beta迁移到v3,以进行权限/列表调用。我看到v2beta结果更加详细。我注意到有很多缺少的字段,我感兴趣的特定字段是“域”。当我运行v3代码(后端代码)时,它包含域,但数据为空,我正在使用fields = *。我使用v2 API进行了验证,并填充了域值
如您所见,使用fields = *
的v3没有域{
"kind": "drive#permissionList",
"permissions": [
{
"kind": "drive#permission",
"id": "####################",
"type": "user",
"emailAddress": "#########",
"role": "organizer",
"displayName": "Admin User",
"teamDrivePermissionDetails": [
{
"teamDrivePermissionType": "member",
"role": "organizer",
"inherited": false
}
],
"permissionDetails": [
{
"permissionType": "member",
"role": "organizer",
"inherited": false
}
],
"deleted": false
}
]
}
对于v2
{
"kind": "drive#permissionList",
"etag": "\"##########/#############\"",
"selfLink": "https://www.googleapis.com/drive/v2/files/########/permissions?supportsTeamDrives=true",
"items": [
{
"kind": "drive#permission",
"etag": "\"################\"",
"id": "##############",
"selfLink": "https://www.googleapis.com/drive/v2/files/#############/permissions/#############",
"name": "Admin User",
"emailAddress": "###############",
"domain": "<the value is correct, just hidden>",
"role": "organizer",
"type": "user",
"teamDrivePermissionDetails": [
{
"teamDrivePermissionType": "member",
"role": "organizer",
"inherited": false
}
],
"permissionDetails": [
{
"permissionType": "member",
"role": "organizer",
"inherited": false
}
],
"deleted": false
}
]
}
我想念什么?请帮忙!!!预先感谢。
我已经用 “尝试API” https://developers.google.com/drive/api/v3/reference/permissions/list 和 https://developers.google.com/drive/api/v2/reference/permissions/list
根据权限资源https://developers.google.com/drive/api/v3/reference/permissions#resource,域应该存在。但这不是。