Library http://golang.org/x/oauth2 There is a ClientID, ClientSecret and access token which I get with my hands. It is necessary to implement the function
buildOAuthHTTPClient(scope string) (*http.Client, error)
There is an implementation only with receipt via the browser.
config := &oauth2.Config{ ClientID: cfg.Installed.ClientID, ClientSecret: cfg.Installed.ClientSecret, Scopes: []string{scope}, Endpoint: oauth2.Endpoint{ AuthURL: cfg.Installed.AuthURI, TokenURL: cfg.Installed.TokenURI, }, RedirectURL: redirectUri, } config.Client(oauth2.NoContext, token)
Who already dealt with this library help please.