Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Auto-generated Google APIs for Go.

License

NotificationsYou must be signed in to change notification settings

googleapis/google-api-go-client

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

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 mainimport ("context""net/http""google.golang.org/api/urlshortener/v1")funcmain() {ctx:=context.Background()svc,err:=urlshortener.NewService(ctx)// ...}

Status

Go Reference

These are auto-generated Go libraries from the Google Discovery Service's JSON description files.

Due to the auto-generated nature of this collection of libraries they may contain breaking changes from one release tothe next. The generator itself and the code it produces are considered beta for this reason.

These client libraries are officially supported by Google. However, the libraries are considered complete and are inmaintenance 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, please use theCloud Client Libraries for Go instead. These are the new and idiomaticGo libraries targeted specifically at Google Cloud Platform Services.

Authorization

By default, each API will useGoogle Application Default Credentialsfor authorization credentials used in calling the API endpoints. This will allow your application to run in manyenvironments without requiring explicit configuration.

// import "google.golang.org/api/sheets/v4"client,err:=sheets.NewService(ctx)

To authorize using aJSON key file, passoption.WithCredentialsFile to theNewServicefunction of the desired package. For example:

client,err:=sheets.NewService(ctx,option.WithCredentialsFile("path/to/keyfile.json"))

You can exert more control over authorization by using thegolang.org/x/oauth2package to create anoauth2.TokenSource. Then passoption.WithTokenSourceto theNewService function:

tokenSource:=...svc,err:=sheets.NewService(ctx,option.WithTokenSource(tokenSource))

More information

For some more information related to all of the generated clients please read through ourpackage documentation.

About

Auto-generated Google APIs for Go.

Topics

Resources

License

Code of conduct

Contributing

Security policy

Stars

Watchers

Forks

Packages

No packages published

[8]ページ先頭

©2009-2025 Movatter.jp