问题标签 [google-api-nodejs-client]
For questions regarding programming in ECMAScript (JavaScript/JS) and its various dialects/implementations (excluding ActionScript). Note JavaScript is NOT the same as Java! Please include all relevant tags on your question; e.g., [node.js], [jquery], [json], [reactjs], [angular], [ember.js], [vue.js], [typescript], [svelte], etc.
node.js - 通过节点客户端调用 Google API 时出现“套接字挂断”错误
0.7
下面的代码在此处使用 Google 的 nodejs 客户端版本调用 Google Analytics Reporting API 。socket hang up
它会在某些执行时返回错误,但并非总是如此。这会是谷歌服务器端的错误吗?有没有简单的调试方法?顺便说一句,我连续打了几个电话,不确定是否是由速率限制引起的。
javascript - Bundling google-api-nodejs-client with browserify doesn't work
I'm trying to build a client-side application with google-api-nodejs-client using browserify. Looks like inside it is trying to read some mime-type info using fs module and fails to do it in browser.
Did anybody use this API for client side development?
google-api-nodejs-client - Gmail API 和 Google API 节点客户端出现错误 500 backendError
我正在尝试将新的Gmail API与Google API Node client一起使用。我从开发者控制台创建了一个新项目,设置了一个新的“服务帐户”客户端 ID,并启用了对 API 的访问。
作为概念证明,我只是想在我的收件箱中列出线程。当我为API 资源管理器启用 OAuth 2.0 切换并输入我的电子邮件地址时,请求成功并且我看到带有数据的 JSON 响应。
现在我尝试在 Node 中做同样的事情:
首先,我打印authorize()
调用的结果,看起来它返回了一个令牌,所以我认为我已经正确设置了所有 OAuth 内容:
然后我尝试实际使用 API,但出现错误:
在这一点上,我不知道还能尝试什么。我认为OAuth 工作正常,因为我没有收到任何身份验证错误。我还认为API 本身正在运行,我的帐户也很好,因为我可以通过 API Explorer 使用它。我也没有看到任何迹象表明 Node 库有问题。简而言之,我不知道问题是什么。有任何想法吗?
node.js - 谷歌云存储 API 和 Node.js
我正在尝试使用 node.js 客户端库来访问 googleAPI ( https://github.com/google/google-api-nodejs-client )。我正在尝试使用谷歌云存储 API 插入存储桶和对象。我可以成功列出我项目存储的存储桶。也可以从存储中检索特定的桶。但无法插入桶或对象。
执行 API 调用的代码:
这是日志中显示的内容:
任何指示什么是“必需”,如何提供?
javascript - 重命名 Google Cloud Storage 中的文件?
您可以重命名 Google Cloud Storage 中的文件吗?
我让用户上传照片,但我想让他们能够编辑照片,至少通过更改他们上传照片的名称。我通过 Node.js 使用 Javascript。
谢谢!
javascript - 使用 nodejs 谷歌日历 API 插入事件返回 400:“缺少结束时间”
我正在尝试使用服务帐户通过 Google 日历 API 插入事件。目标是拥有一个所有用户都可以查看的日历:服务器到服务器设置。
到目前为止,我可以正确调用日历 API 并在所述日历上列出事件:
这会正确返回列出日历上所有不同对象的 JSON 对象。googleCal.events.list
但是,当我尝试在调用下方直接插入事件时:
返回以下400
内容:
我该如何解决这个问题?授权显然有效——我知道是因为我已经用完了当天未经授权的请求,而且我可以列出所有事件。我还指定了一个endTime
. 为什么谷歌日历 API 告诉我我没有?
oauth-2.0 - OAuth 2.0 Scope for Google Apps users' names with google-api-nodejs-client
I'm trying to use Google's 'google-api-nodejs-client' package (https://github.com/google/google-api-nodejs-client) to handle OAuth 2.0 authentication.
I've modified the example in examples/oauth2.js to console.log the entire profile object.
What scope can I use to correctly extract users' 'givenName' and 'familyName' if they're authenticating using a Google Apps account? Using the following scope:
returns the following response once authenticated:
node.js - 如何跟踪googleapis节点媒体上传进度?
在他们的 google-api-nodejs-client 文档中,他们说:
对 API 的每个请求都会返回一个请求对象,允许您跟踪请求的进度或有关请求的一般信息。
但你是怎么做到的呢?例如,假设我使用以下方法将视频上传到 youtube:
如何使用request object
来生成——比如说——进度条?
node.js - 在 AngularJs 和 Nodejs 中制作弹出表单
我是 Angular 和 Node 的新手,所以我不太了解。
我有一个 Angular 单页,我想创建一个在单击按钮时出现的弹出表单,然后通过 rest 将信息发送到节点。但我不知道该怎么做。你怎么能这样??