You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
Andrea Spacca 82493d6dcb add GDrive provider support (#118) 5 years ago
..
abusiveexperiencereport/v1 add GDrive provider support (#118) 5 years ago
acceleratedmobilepageurl/v1 add GDrive provider support (#118) 5 years ago
adexchangebuyer add GDrive provider support (#118) 5 years ago
adexchangebuyer2/v2beta1 add GDrive provider support (#118) 5 years ago
adexchangeseller add GDrive provider support (#118) 5 years ago
adexperiencereport/v1 add GDrive provider support (#118) 5 years ago
admin add GDrive provider support (#118) 5 years ago
adsense add GDrive provider support (#118) 5 years ago
adsensehost/v4.1 add GDrive provider support (#118) 5 years ago
analytics add GDrive provider support (#118) 5 years ago
analyticsreporting/v4 add GDrive provider support (#118) 5 years ago
androiddeviceprovisioning/v1 add GDrive provider support (#118) 5 years ago
androidenterprise/v1 add GDrive provider support (#118) 5 years ago
androidmanagement/v1 add GDrive provider support (#118) 5 years ago
androidpublisher add GDrive provider support (#118) 5 years ago
appengine add GDrive provider support (#118) 5 years ago
appsactivity/v1 add GDrive provider support (#118) 5 years ago
appstate/v1 add GDrive provider support (#118) 5 years ago
bigquery/v2 add GDrive provider support (#118) 5 years ago
bigquerydatatransfer/v1 add GDrive provider support (#118) 5 years ago
blogger add GDrive provider support (#118) 5 years ago
books/v1 add GDrive provider support (#118) 5 years ago
calendar/v3 add GDrive provider support (#118) 5 years ago
chat/v1 add GDrive provider support (#118) 5 years ago
civicinfo/v2 add GDrive provider support (#118) 5 years ago
classroom/v1 add GDrive provider support (#118) 5 years ago
cloudbilling/v1 add GDrive provider support (#118) 5 years ago
cloudbuild/v1 add GDrive provider support (#118) 5 years ago
clouddebugger/v2 add GDrive provider support (#118) 5 years ago
clouderrorreporting/v1beta1 add GDrive provider support (#118) 5 years ago
cloudfunctions add GDrive provider support (#118) 5 years ago
cloudiot add GDrive provider support (#118) 5 years ago
cloudkms/v1 add GDrive provider support (#118) 5 years ago
cloudmonitoring/v2beta2 add GDrive provider support (#118) 5 years ago
cloudresourcemanager add GDrive provider support (#118) 5 years ago
cloudshell add GDrive provider support (#118) 5 years ago
cloudtasks/v2beta2 add GDrive provider support (#118) 5 years ago
cloudtrace add GDrive provider support (#118) 5 years ago
clouduseraccounts add GDrive provider support (#118) 5 years ago
composer/v1beta1 add GDrive provider support (#118) 5 years ago
compute add GDrive provider support (#118) 5 years ago
consumersurveys/v2 add GDrive provider support (#118) 5 years ago
container add GDrive provider support (#118) 5 years ago
content add GDrive provider support (#118) 5 years ago
customsearch/v1 add GDrive provider support (#118) 5 years ago
dataflow/v1b3 add GDrive provider support (#118) 5 years ago
dataproc add GDrive provider support (#118) 5 years ago
datastore add GDrive provider support (#118) 5 years ago
deploymentmanager add GDrive provider support (#118) 5 years ago
dfareporting add GDrive provider support (#118) 5 years ago
dialogflow add GDrive provider support (#118) 5 years ago
digitalassetlinks/v1 add GDrive provider support (#118) 5 years ago
discovery/v1 add GDrive provider support (#118) 5 years ago
dlp add GDrive provider support (#118) 5 years ago
dns add GDrive provider support (#118) 5 years ago
doubleclickbidmanager/v1 add GDrive provider support (#118) 5 years ago
doubleclicksearch/v2 add GDrive provider support (#118) 5 years ago
drive add GDrive provider support (#118) 5 years ago
examples add GDrive provider support (#118) 5 years ago
firebasedynamiclinks/v1 add GDrive provider support (#118) 5 years ago
firebaseremoteconfig/v1 add GDrive provider support (#118) 5 years ago
firebaserules/v1 add GDrive provider support (#118) 5 years ago
firestore/v1beta1 add GDrive provider support (#118) 5 years ago
fitness/v1 add GDrive provider support (#118) 5 years ago
fusiontables add GDrive provider support (#118) 5 years ago
games/v1 add GDrive provider support (#118) 5 years ago
gamesconfiguration/v1configuration add GDrive provider support (#118) 5 years ago
gamesmanagement/v1management add GDrive provider support (#118) 5 years ago
genomics add GDrive provider support (#118) 5 years ago
gensupport add GDrive provider support (#118) 5 years ago
gmail/v1 add GDrive provider support (#118) 5 years ago
google-api-go-generator add GDrive provider support (#118) 5 years ago
googleapi add GDrive provider support (#118) 5 years ago
groupsmigration/v1 add GDrive provider support (#118) 5 years ago
groupssettings/v1 add GDrive provider support (#118) 5 years ago
iam/v1 add GDrive provider support (#118) 5 years ago
iamcredentials/v1 add GDrive provider support (#118) 5 years ago
identitytoolkit/v3 add GDrive provider support (#118) 5 years ago
integration-tests/storage add GDrive provider support (#118) 5 years ago
internal add GDrive provider support (#118) 5 years ago
iterator add GDrive provider support (#118) 5 years ago
jobs/v2 add GDrive provider support (#118) 5 years ago
kgsearch/v1 add GDrive provider support (#118) 5 years ago
language add GDrive provider support (#118) 5 years ago
lib/codereview add GDrive provider support (#118) 5 years ago
licensing/v1 add GDrive provider support (#118) 5 years ago
logging add GDrive provider support (#118) 5 years ago
manufacturers/v1 add GDrive provider support (#118) 5 years ago
mirror/v1 add GDrive provider support (#118) 5 years ago
ml/v1 add GDrive provider support (#118) 5 years ago
monitoring/v3 add GDrive provider support (#118) 5 years ago
oauth2 add GDrive provider support (#118) 5 years ago
option add GDrive provider support (#118) 5 years ago
oslogin add GDrive provider support (#118) 5 years ago
pagespeedonline add GDrive provider support (#118) 5 years ago
partners/v2 add GDrive provider support (#118) 5 years ago
people/v1 add GDrive provider support (#118) 5 years ago
photoslibrary/v1 add GDrive provider support (#118) 5 years ago
playcustomapp/v1 add GDrive provider support (#118) 5 years ago
playmoviespartner/v1 add GDrive provider support (#118) 5 years ago
plus/v1 add GDrive provider support (#118) 5 years ago
plusdomains/v1 add GDrive provider support (#118) 5 years ago
poly/v1 add GDrive provider support (#118) 5 years ago
prediction add GDrive provider support (#118) 5 years ago
proximitybeacon/v1beta1 add GDrive provider support (#118) 5 years ago
pubsub add GDrive provider support (#118) 5 years ago
qpxexpress/v1 add GDrive provider support (#118) 5 years ago
redis/v1beta1 add GDrive provider support (#118) 5 years ago
replicapool add GDrive provider support (#118) 5 years ago
replicapoolupdater/v1beta1 add GDrive provider support (#118) 5 years ago
reseller/v1 add GDrive provider support (#118) 5 years ago
resourceviews add GDrive provider support (#118) 5 years ago
runtimeconfig add GDrive provider support (#118) 5 years ago
safebrowsing/v4 add GDrive provider support (#118) 5 years ago
script/v1 add GDrive provider support (#118) 5 years ago
searchconsole/v1 add GDrive provider support (#118) 5 years ago
servicebroker add GDrive provider support (#118) 5 years ago
serviceconsumermanagement/v1 add GDrive provider support (#118) 5 years ago
servicecontrol/v1 add GDrive provider support (#118) 5 years ago
servicemanagement/v1 add GDrive provider support (#118) 5 years ago
serviceusage add GDrive provider support (#118) 5 years ago
serviceuser/v1 add GDrive provider support (#118) 5 years ago
sheets/v4 add GDrive provider support (#118) 5 years ago
siteverification/v1 add GDrive provider support (#118) 5 years ago
slides/v1 add GDrive provider support (#118) 5 years ago
sourcerepo/v1 add GDrive provider support (#118) 5 years ago
spanner/v1 add GDrive provider support (#118) 5 years ago
spectrum/v1explorer add GDrive provider support (#118) 5 years ago
speech add GDrive provider support (#118) 5 years ago
sqladmin add GDrive provider support (#118) 5 years ago
storage add GDrive provider support (#118) 5 years ago
storagetransfer/v1 add GDrive provider support (#118) 5 years ago
streetviewpublish/v1 add GDrive provider support (#118) 5 years ago
support/bundler add GDrive provider support (#118) 5 years ago
surveys/v2 add GDrive provider support (#118) 5 years ago
tagmanager add GDrive provider support (#118) 5 years ago
taskqueue add GDrive provider support (#118) 5 years ago
tasks/v1 add GDrive provider support (#118) 5 years ago
testing/v1 add GDrive provider support (#118) 5 years ago
texttospeech/v1beta1 add GDrive provider support (#118) 5 years ago
toolresults add GDrive provider support (#118) 5 years ago
tpu add GDrive provider support (#118) 5 years ago
tracing/v2 add GDrive provider support (#118) 5 years ago
translate/v2 add GDrive provider support (#118) 5 years ago
transport add GDrive provider support (#118) 5 years ago
urlshortener/v1 add GDrive provider support (#118) 5 years ago
vault/v1 add GDrive provider support (#118) 5 years ago
videointelligence add GDrive provider support (#118) 5 years ago
vision add GDrive provider support (#118) 5 years ago
webfonts/v1 add GDrive provider support (#118) 5 years ago
webmasters/v3 add GDrive provider support (#118) 5 years ago
websecurityscanner/v1alpha add GDrive provider support (#118) 5 years ago
youtube/v3 add GDrive provider support (#118) 5 years ago
youtubeanalytics add GDrive provider support (#118) 5 years ago
youtubereporting/v1 add GDrive provider support (#118) 5 years ago
.gitignore add GDrive provider support (#118) 5 years ago
.hgtags add GDrive provider support (#118) 5 years ago
.travis.yml add GDrive provider support (#118) 5 years ago
AUTHORS add GDrive provider support (#118) 5 years ago
CONTRIBUTING.md add GDrive provider support (#118) 5 years ago
CONTRIBUTORS add GDrive provider support (#118) 5 years ago
GettingStarted.md add GDrive provider support (#118) 5 years ago
LICENSE add GDrive provider support (#118) 5 years ago
NOTES add GDrive provider support (#118) 5 years ago
README.md add GDrive provider support (#118) 5 years ago
TODO add GDrive provider support (#118) 5 years ago
api-list.json add GDrive provider support (#118) 5 years ago
key.json.enc add GDrive provider support (#118) 5 years ago

README.md

Google APIs Client Library for Go

Getting Started

$ go get google.golang.org/api/tasks/v1
$ go get google.golang.org/api/moderator/v1
$ go get google.golang.org/api/urlshortener/v1
... etc ...

and using:

package main

import (
	"net/http"

	"google.golang.org/api/urlshortener/v1"
)

func main() {
	svc, err := urlshortener.New(http.DefaultClient)
	// ...
}

Status

Build Status GoDoc

These are auto-generated Go libraries from the Google Discovery Service’s JSON description files of the available “new style” Google APIs.

Due to the auto-generated nature of this collection of libraries, complete APIs or specific versions can appear or go away without notice. As a result, you should always locally vendor any API(s) that your code relies upon.

These client libraries are officially supported by Google. However, the libraries are considered complete and are in maintenance mode. This means that we will address critical bugs and security issues but will not add any new features.

If you’re working with Google Cloud Platform APIs such as Datastore or Pub/Sub, consider using the Cloud Client Libraries for Go instead. These are the new and idiomatic Go libraries targeted specifically at Google Cloud Platform Services.

The generator itself and the code it produces are beta. Some APIs are alpha/beta, and indicated as such in the import path (e.g., “google.golang.org/api/someapi/v1alpha”).

Application Default Credentials Example

Application Default Credentials provide a simplified way to obtain credentials for authenticating with Google APIs.

The Application Default Credentials authenticate as the application itself, which make them great for working with Google Cloud APIs like Storage or Datastore. They are the recommended form of authentication when building applications that run on Google Compute Engine or Google App Engine.

Default credentials are provided by the golang.org/x/oauth2/google package. To use them, add the following import:

import "golang.org/x/oauth2/google"

Some credentials types require you to specify scopes, and service entry points may not inject them. If you encounter this situation you may need to specify scopes as follows:

import (
        "golang.org/x/net/context"
        "golang.org/x/oauth2/google"
        "google.golang.org/api/compute/v1"
)

func main() {
        // Use oauth2.NoContext if there isn't a good context to pass in.
        ctx := context.Background()

        client, err := google.DefaultClient(ctx, compute.ComputeScope)
        if err != nil {
                //...
        }
        computeService, err := compute.New(client)
        if err != nil {
                //...
        }
}

If you need a oauth2.TokenSource, use the DefaultTokenSource function:

ts, err := google.DefaultTokenSource(ctx, scope1, scope2, ...)
if err != nil {
        //...
}
client := oauth2.NewClient(ctx, ts)

See also: golang.org/x/oauth2/google package documentation.