Questions tagged [google-api-go-client]

54 questions
1
vote
2 answers

How do I use a client ID for OAuth2 on App Engine in Go?

I have some fairly simple Go code running in AppEngine that should be using OAuth2 to fetch the list of files from the user's account. It seems to initialize the service OK but when it tries to fetch the file list, I get this error: OAuthError:…
quikchange
  • 564
  • 2
  • 6
  • 14
1
vote
1 answer

Permission denied accessing Bigquery with Go from GAE using the API key

I am trying to access data stored in Bigquery through an app I am developing on Google App Engine. However each time I make a request I receive the error "permission denied". I have added the application as a member of the API team for the…
1
vote
2 answers

Invalid Upload Request

I'm getting the following response, when trying to upload data to BigQuery using the Google API Client libraries for Go. { "error": { "errors": [ { "domain": "global", "reason": "badRequest", "message": "Invalid Upload Request" …
laslowh
  • 8,482
  • 5
  • 34
  • 45
0
votes
0 answers

Not able to Download google drive file through golang api

// Download a file from Google Drive. func downloadFile(service *drive.Service, fileID, filePath string) error { resp, err := service.Files.Get(fileID).Download() if err != nil { return err } defer resp.Body.Close() out,…
0
votes
0 answers

Disable service account key with google API client

Google Cloud's IAM allows you to activate/deactivate service account keys, so you can safely deactivate and remove a key once you're sure it hasn't broken anything in your systems. In my case, I'm working on a project that implements an API that…
beni0888
  • 1,050
  • 1
  • 12
  • 40
0
votes
0 answers

googlesheet api authenticate without redirect_uri?

I want to use the googlesheet API for reading/updating sheets in a Golang desktop app. I have already created an oauth2 client ID selecting the desktop app option. This generates me a credentials file with a redirect_uri value, and that's my…
sigz
  • 89
  • 1
  • 8
0
votes
1 answer

Golang and google api - post request syntax while using oauth for devices status update

I am trying to change the status of the chromeos device. My "get" request works with getting the device ID from the serial number. However, I am not able to figure out how to pass the payload in golang google sdk/api, since it is a "post"…
0
votes
0 answers

Go googleapis/google-api-go-client gmail, blank response on some requests?

func Callback(w http.ResponseWriter, r *http.Request){ ctx := context.Background() state := r.FormValue("state") code := r.FormValue("code") client := getClient(state, code) srv, err := gmail.NewService(ctx,…
0
votes
1 answer

Context Canceled when using Go with BigQuery

I am trying to insert a record to biqquery & here the code which does the insert. func (s *Storage) Insert(w *warehouse.WarehouseRecord) error { event, err := w.Marshal() if err != nil { return err } logger.Info("inserting record…
0
votes
1 answer

golang spanner test library crashes after a while

Spanner GO library crashes after few mins perhaps after this query (although this has been successful earlier) Version cloud.google.com/go/spanner v1.11.0 2021/02/01 00:45:32.564971 spannertest.inmem: Querying: SELECT * FROM tenant_config…
manpatha
  • 489
  • 4
  • 11
0
votes
0 answers

Transcript long audio with google speech to text

I need to translate a video to text with google speech to text I use google speech to text for lon audio, my video's duration is more than 1 minute and maximum can be 10min, but always i have this error that i can't understand thrown in…
aaaaaa
  • 9
  • 2
0
votes
1 answer

How to fork and modify the Google API Go Client SDK to resolve Slides API Range issue?

I'm using the "Google APIs Client Library for Go" ( https://github.com/googleapis/google-api-go-client ) and it has an issue supporting the Slides API where a zero-based index request property is required but the struct definition indicates…
Grokify
  • 15,092
  • 6
  • 60
  • 81
0
votes
3 answers

How to send service account token in request to Google Cloud Functions

I'm running simple function in Google Cloud Functions to update DNS records (see code here). Currently I create service account with roles/dns.admin privileges and assign that to the function. I'm then relying for Functions' beta support for…
0
votes
1 answer

Is it possible to use the Google Classroom Go API to comment on things?

I'm wondering if there's a way to comment on a Google Classroom assignment/post through the Google Classroom API (specifically the Go client). I've searched the docs but couldn't find anything.
W. Reyna
  • 724
  • 2
  • 7
  • 24
0
votes
1 answer

Batch requests to GCP Compute using Golang client library

Is it possible to perform batch requests using the Google API Client Library for Go? More precisely, I'd like to delete some disks; it would be great if I could avoid a request for each disk. The batch request feature I'm referring…
dyp
  • 38,334
  • 13
  • 112
  • 177