在桌面应用程序中使用 Google OAuthUtil

发布于 2024-12-07 22:41:04 字数 170 浏览 7 评论 0原文

我正在构建一个与 Google 通讯录交互的桌面应用程序。我一直在尝试使用谷歌提供的 OAuthUtil 来验证应用程序,但无法让它工作...

它似乎只适合 web 应用程序,因为您必须提供回调 url,我认为因为函数 OAuthUtil.GetUnauthorizedRequestToken 返回空白...

I am building a Desktop application that interacts with Google Contacts. I have been trying to authenticate the application using google supplied OAuthUtil, but cant get it to work...

it seems it is only suitable for webapplication because of the callback url you have to provide, I think that because the function OAuthUtil.GetUnauthorizedRequestToken returns void...

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

捂风挽笑 2024-12-14 22:41:04

我对 C# 不太熟悉,或者我会尝试编写一些示例代码。但是,查看他们的文档时,您必须打开网络浏览器并检测您发送的任何回调。当您检测到回调时,您将重定向到客户端程序。
http://code.google.com/apis/accounts/docs/OAuthForInstalledApps.html

他们似乎正在努力向他们的服务器发出 REST 请求,这样你就不必拥有网络浏览器了。 http://sites.google.com/site/oauthgoog/UXFedLogin /nobrowser/input-capable-devices

即使对于没有网络浏览器的东西,他们当前的建议是提供一个 pin,然后让用户在设备上注册网络浏览器。
http://sites.google.com/site/oauthgoog/UXFedLogin/nobrowser

I'm not that familiar with C# or I'd try and write some example code. However, looking at their docs you have to open a web browser and detect whatever callback you sent. When you detect the callback you then redirect to the client program.
http://code.google.com/apis/accounts/docs/OAuthForInstalledApps.html

It seems they're working on being able to make a REST request to their servers so that you don't have to have a web browser. http://sites.google.com/site/oauthgoog/UXFedLogin/nobrowser/input-capable-devices

Even for things, without a web browser they're current suggestion is to provide a pin, which you then have the user register on a device with a web browser.
http://sites.google.com/site/oauthgoog/UXFedLogin/nobrowser

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文