我正在开发一个Chrome扩展程序,该程序以谷歌云消息为特色,用于将消息推送到我的chrome扩展的实例。
尝试向GCM Server推送消息时,收到以下失败响应,如下;
> POST /gcm_for_chrome/v1/messages HTTP/1.1
> User-Agent: curl/7.26.0
> Host: www.googleapis.com
> Accept: */*
> Content-Type: application/json
> Content-Length: 133
>
* upload completely sent off: 133 out of 133 bytes
< HTTP/1.1 403 Forbidden
< Content-Type: application/json; charset=UTF-8
< Date: Mon, 15 Apr 2013 19:49:24 GMT
< Expires: Mon, 15 Apr 2013 19:49:24 GMT
< Cache-Control: private, max-age=0
< X-Content-Type-Options: nosniff
< X-Frame-Options: SAMEORIGIN
< X-XSS-Protection: 1; mode=block
< Server: GSE
< Transfer-Encoding: chunked
<
{
"error": {
"errors": [
{
"domain": "usageLimits",
"reason": "accessNotConfigured",
"message": "Access Not Configured"
}
],
"code": 403,
"message": "Access Not Configured"
}
}有人知道如何解决这个问题吗?
提前谢谢你。Burin H.
发布于 2013-05-30 02:46:24
此问题的一个潜在原因是未将API设置为enabled。
为了确保你的应用程序接口是启用的,你可以登录https://code.google.com/apis/console,点击左侧导航栏中的“服务”,并检查谷歌云消息的服务状态。如果您发现它被设置为"Off",这就解释了问题,您可以通过将其设置为"On“来修复它。
https://stackoverflow.com/questions/16030935
复制相似问题