omniauth-google-oauth2 也可以用于从 google 日历 API 获取日历信息吗?
还可以使用omniauth-google-oauth2来获取日历信息吗 谷歌日历API?
到目前为止我已经设法得到: a)omniauth-google-oauth2 测试 Rails 应用程序致力于“登录” 测试应用程序 1 中的 google” b) OAuth 插件,用于通过 Oauth 日历数据 API 获取日历数据 在测试应用程序 2 中。
问题是我是否可以放弃使用“OAuth Plugin”而只是 使用“omniauth-google-oauth2”也可以(在身份验证后)获取 日历数据?如果是,这将如何运作?是 OAuth 令牌吗 谷歌的身份验证与此相同谷歌日历 API 方面?
Can omniauth-google-oauth2 be used also to get calendar info back from
the google calendar API?
I have managed to so far to get:
a) omniauth-google-oauth2 test rails app working to "sign on with
google" in test app 1
b) OAuth Plugin to get calendar data via the Oauth Calendar Data API
in test app 2.
QUESTION is whether I could drop the use of "OAuth Plugin" and just
use "omniauth-google-oauth2" to also (after authentication) get the
calendar data? If yes, how would this work? Are the OAuth tokens
the same from google for the authentication & google calendar api
aspects?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
是的,它可以用来获取日历数据。
我只使用omniauth-google-oauth2 gem 进行日历访问。
我认为它的工作方式与带有令牌的 oauth 插件相同。
查看此内容以开始使用https://github.com/deafgreatdane/google_oauth_calendar
Yes, it can be used to get calendar data.
I only use the omniauth-google-oauth2 gem for calendar access.
I would assume it works the same way as the oauth plugin with the token.
Check out this to get started https://github.com/deafgreatdane/google_oauth_calendar
对于未来的搜索者:
您只需在
google_oauth2
提供商的范围中包含calendar
即可。更多详情请点击此处。
For future searchers:
You can simply include
calendar
in the scope for yourgoogle_oauth2
provider.More details here.