質問

Googleの予測APIにアクセスするであろう.NETサービスアプリケーションを構築しようとしています。

このアプリケーションはサービス(ユーザーの操作なし)であるため、Google APIを自動的に認証する方法が知りたい(ログインするブラウザを開き、「Authorize」を押す)ことができます。 。

試したもの:

役に立ちましたか?

解決

I've written a sample app (in Python & Java, sorry not available in C#) which authenticates once, stores the OAuth credentials and related data on the server (Google App Engine) and from that point forward reuses those shared credentials, refreshing the access token when needed, without requiring end users to see the OAuth allow/deny dialog, or any other aspect of OAuth.

This still requires the application administrator to execute the OAuth dialog but that's a one-time event. If for some reason you want to reset the stored server credentials, the initialization step can be re-executed on demand via a special URL, however, this reset function is protected so that only the application administrator can make that request, not an end user.

ライセンス: CC-BY-SA帰属
所属していません StackOverflow
scroll top