Go Bookshelf Tutorial OAuth Error

51 views
Skip to first unread message

Chris Lewis

unread,
Jun 20, 2017, 7:31:51 PM6/20/17
to Google App Engine
https://cloud.google.com/go/getting-started/tutorial-app

I am attempting to follow this tutorial and have been unable to get the storage and OAuth2 portions working. I continually receive a 401 Unauthorized response when attempting to upload a file or login.

Then, I add my Client ID and Secret and I get a "can't find client id" error.

Any idease?

Chris Lewis

unread,
Jun 20, 2017, 11:12:07 PM6/20/17
to Google App Engine
could not parse book from form: could not upload file: Post https://www.googleapis.com/upload/storage/v1/b/statrecruit-application/o?alt=json&projection=full&uploadType=multipart: oauth2: cannot fetch token: 401 Unauthorized
Response: {
  "error" : "invalid_client",
  "error_description" : "The OAuth client was not found."
}

Yannick (Cloud Platform Support)

unread,
Jun 21, 2017, 12:31:19 PM6/21/17
to Google App Engine
Hello Chris. I tried following the tutorial's instructions and did not encounter any issues following the instructions. I was able to reproduce the invalid_client error by supplying an incorrect client id or client secret.

You say you had errors uploading files even before un-commenting the "OAuthConfig" line. The uploading and viewing of files worked properly for me without authentication in place.

You might want to double-check that the bucket and client ID you are using belong to the same GCP project that you are logged in to on your machine or deploying to.
Reply all
Reply to author
Forward
0 new messages