I'm trying to download some reports using Google Sheets.
So basically I'm using UrlFetchAppto do the job and it does when the response is received within 1 minute. If the response is taking more than a minute then the request times out and the reports are not downloaded.
This is the options that I'm sending with UrlFetchApp:
var options = {
"method" : "post",
"header" : "someHeaders",
"muteHttpExceptions" : true,
"followRedirects" : false,
"Content-Encoding" : "gzip",
"payload" : "somePayload"
}
and then a simple call of .fetch().
Is there a way to increase the timeout or any workaround for it?
Although it's not publicly documented, I realized by testing that fetch functions for UrlFetchApp [1] have a 1 minute timeout. There's a Feature Request open to extend or allow to configure the UrlFetchApp timeout [2].
[1] https://developers.google.com/apps-script/reference/url-fetch/url-fetch-app
[2] https://issuetracker.google.com/issues/36761852
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With