Documentation ¶
Overview ¶
Completely courtesy this example: github.com/google/google-api-go-client/examples/debug.go
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( DeviceCodeURL = "https://accounts.google.com/o/oauth2/device/code" TokenPollURL = "https://www.googleapis.com/oauth2/v3/token" DeviceGrantType = "http://oauth.net/grant_type/device/1.0" DeviceCodeScopes = map[string]struct{}{ "profile": struct{}{}, "openid": struct{}{}, "email": struct{}{}, "https://www.googleapis.com/auth/analytics": struct{}{}, "https://www.googleapis.com/auth/analytics.readonly": struct{}{}, "https://www.googleapis.com/auth/calendar": struct{}{}, "https://www.googleapis.com/auth/calendar.readonly": struct{}{}, "https://www.google.com/m8/feeds": struct{}{}, "https://www.googleapis.com/auth/contacts.readonly": struct{}{}, "https://www.googleapis.com/auth/cloudprint": struct{}{}, "https://www.googleapis.com/auth/devstorage.full_control": struct{}{}, "https://www.googleapis.com/auth/devstorage.read_write": struct{}{}, "https://www.googleapis.com/auth/fitness.activity.read": struct{}{}, "https://www.googleapis.com/auth/fitness.activity.write": struct{}{}, "https://www.googleapis.com/auth/fitness.body.read": struct{}{}, "https://www.googleapis.com/auth/fitness.body.write": struct{}{}, "https://www.googleapis.com/auth/fitness.location.read": struct{}{}, "https://www.googleapis.com/auth/fitness.location.write": struct{}{}, "https://www.googleapis.com/auth/fusiontables": struct{}{}, "https://www.googleapis.com/auth/youtube": struct{}{}, "https://www.googleapis.com/auth/youtube.readonly": struct{}{}, "https://www.googleapis.com/auth/youtube.upload": struct{}{}, "https://www.googleapis.com/auth/drive.file": struct{}{}, } )
Functions ¶
func Client ¶
Client accepts the connection details, and makes an oAuth connection
id and secret are the CLIENT ID and CLIENT SECRET which you can generate at the Google Developer Console: http://console.developers.google.com You want an "Installed Application" of type "Other".
Scope defines the access you are requesting, it is specific to the application. Strings are URLs, eg. "https://www.googleapis.com/auth/calendar", typically accessed in Go via the constants in the Go API, eg. directory.AdminDirectoryGroupScope
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.