403 error when making an SQL query for a Fusion Table

南笙酒味 提交于 2019-11-28 08:41:07

问题


I've been trying to migrate my project to new API, but I get the following error when trying out an SQL query such as the following:

https://www.googleapis.com/fusiontables/v1/query?sql=SELECT * FROM 1KxVV0wQXhxhMScSDuqr-0Ebf0YEt4m4xzVplKd4&key=myKey

Here is what gets returned:

{
 "error": {
  "errors": [
   {
    "domain": "usageLimits",
    "reason": "accessNotConfigured",
    "message": "Access Not Configured"
   }
  ],
  "code": 403,
  "message": "Access Not Configured"
 }
}

The following query does work, though: https://www.googleapis.com/fusiontables/v1/tables/1bTX-w0Lt6nT8jq4R0q2pwFvuN_X5iPDOKHWFhw/columns?key=myKey

What am I doing wrong?


回答1:


You also need to make sure the Fusion Table is Exportable.

File → About this table
       → Edit table information
         → Check the "Allow download" checkbox



回答2:


I started a new project in the API console and using the new API key fixed it, strangely.



来源:https://stackoverflow.com/questions/11273278/403-error-when-making-an-sql-query-for-a-fusion-table

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!