我正在尝试在我的TeamDrive google上动态创建一个简单文件夹的脚本。
我在我的云端硬盘上成功完成了这项操作,但在我的TeamDrive上却没有。 这似乎就像我没有看到它们一样。
我的代码:
$TeamDriveList = new Google_Service_Drive_TeamDriveList($client);
print_r($TeamDriveList);
结果:
Google_Service_Drive_TeamDriveList Object ( [collection_key:protected] => teamDrives [kind] => [nextPageToken] => [teamDrivesType:protected] => Google_Service_Drive_TeamDrive [teamDrivesDataType:protected] => array [internal_gapi_mappings:protected] => Array ( ) [modelData:protected] => Array ( ) [processed:protected] => Array ( ) )
如果我正在尝试使用Google控制台测试,我会看到:
200
{
"kind": "drive#teamDriveList",
"teamDrives": [
{
"kind": "drive#teamDrive",
"id": "0AB0TME2EwUCRUk9PVA"
},
{
"kind": "drive#teamDrive",
"id": "0AD2eQbRih1DZUk9PVA"
}
]
}
当然我的PHP代码不正确。