Closed donfiftyidaho closed 3 years ago
I solved this so closing it. The problem was that I was saving my refresh token in a JSON file and the Lambda was resetting after 15 minutes and my updated token was gone and the token was now back to the original one in the function zip file. Refactored to save to a DB table and everything works great.
I am working with an AWS Lambda that connects to the QBO API. Here is a gist of the oauth service I wrote >>
intuit-oauth version: 3.0.2
Node.js version 12
To get the OAuth started I get a fresh refresh token from the QBO playground and store that in a json file. After that it keeps getting renewed. I don't think the refresh token is the problem since it works fine locally and I can see it in the log output.
When I run test locally it works perfectly every time, but only once after I deploy it to AWS. After the one success and then waiting around 15 minutes to run a test on AWS Lambda I get this error: