Working example code with oauth1(A) - google script?


I am working for some years now in google-apps-script. The application we develop worked fine with oauth ‘zero’ but this oauth version was deprecated in june by Google. So, we needed to migrate to oauth1, but… the example code (Google/the community provided an oauth1 library named oauth1) gives 401 errors. It proved that the connection ‘remained’, and the error ‘only’ shows up say each 10th time the application runs. For now we decided to neglect the error, but this is a fragile solution…

QUESTION: Is there somewhere a sniplet of functioning authorization code from google script towards twitter working with oauth1(A) or oauth2?

Maybe an idea for the twitter developers community? I guess it would help developing twitter based applications via Googles Script a lot…


  1. The issue which MIGHT cause the 401 error(s): Error 401: Unauthorized
  2. The example code for connecting Google Apps script towards twitter:

My emailaddress:

Thank you in advance!
Iwanjka (Netherlands - Canarian Islands - Malawi)