我一直在尝试使用Google Drive API使Fusiontable公开可读,并且无法使其工作.我可以使用OAuth 2.0 Playground为其他Google云端硬盘文档插入公共共享权限,但对于Fusiontables,我收到HTTP 500错误,"内部错误".请注意,我已尝试在"Drive API v2"和"Fusion Tables API v1"下包含所有可用范围.
我知道谷歌不再开发和支持Fusiontables,但我想知道是否有人找到了允许他们解决这个问题的解决方法?我还没有尝试过遗留/弃用的API版本.
以下是实际的API请求格式以及OAuth Playground对Fusiontable权限插入(HTTP 500)的响应,然后是Doc权限插入(HTTP 200).请求之间的唯一区别是请求URI中的fusiontable_id或document_id:
请求:
POST /drive/v2/files/<fusiontable_id or document_id>/permissions HTTP/1.1
Host: www.googleapis.com
Content-length: 33
Content-type: application/json
Authorization: Bearer <access_token>
{"role":"reader","type":"anyone"}
Run Code Online (Sandbox Code Playgroud)
融合响应:
HTTP/1.1 500 Internal Server Error
Content-length: 180
X-xss-protection: 1; mode=block
X-content-type-options: nosniff
Expires: Tue, 04 Nov 2014 23:51:58 GMT
Vary: Origin,Referer,X-Origin
Server: GSE
Cache-control: private, max-age=0
Date: Tue, 04 Nov 2014 23:51:58 GMT
X-frame-options: SAMEORIGIN
Content-type: application/json; charset=UTF-8
{
"error": {
"code": 500,
"message": "Internal Error",
"errors": …Run Code Online (Sandbox Code Playgroud)