google-api-nodejs-client icon indicating copy to clipboard operation
google-api-nodejs-client copied to clipboard

sample code for calendar api batch request

Open blacknell opened this issue 6 years ago • 1 comments

Is your feature request related to a problem? Please describe. I'm struggling to make a large number of API calls and want to batch these up. I can't find any sample code anywhere for how to do this. I've had no problems with the other methods such as calendar.events.insert

Describe the solution you'd like Sample code to show how to batch up a number of events.insert with a .then for each individual sub-request

Describe alternatives you've considered I'm hitting calendar usage errors (not to be confused with api usage errors). I've struggled to get any response or help via stackoverflow

Additional context Add any other context or screenshots about the feature request here.

blacknell avatar Oct 30 '19 22:10 blacknell

Related:

  • https://github.com/googleapis/google-api-nodejs-client/issues/2375

0xdevalias avatar Jul 01 '22 08:07 0xdevalias

Having hit the issue of batching Google apis requests using Node.js myself, I decided to develop a solution that follows the guidelines provided in Google's batching documentation, implementing the multipart/mixed HTTP request/response protocol.

Please have a look and do not hesitate to raise an issue if you find a bug or would like to discuss improvements.

jrmdayn avatar Jan 10 '23 14:01 jrmdayn

This answer does a great job of explaining the current state of the world, but TL;DR: calendar does not support batch requests.

sofisl avatar Feb 02 '23 20:02 sofisl