QuickBooks API Token refresh process failing periodically #29

Closed
opened 2025-02-13 08:20:11 +00:00 by gtmadev · 0 comments
Owner

The QB Online token refresh process is periodically failing and then resulting in portal accounts losing the QB Online connection. The current process takes place in real-time as requests are made. This process can fail once or twice before "giving up", at which time the active token can't be refreshed. It's not fully apparent why the failures occur as we are seeing a somewhat generic error being logged.

The current plan is to rewrite the refresh process to take place in the background rather than in real-time. The idea is that we can allow retries to happen over a much longer span of time in the event that their is a failure with the refresh. QB Online API tokens have a one hour TTL, so we will likely begin to refresh any token that has reached 40-45 minutes in age. That gives our servers 10-15 minutes to retry and fetch a refreshed token before the current token expires.

The QB Online token refresh process is periodically failing and then resulting in portal accounts losing the QB Online connection. The current process takes place in real-time as requests are made. This process can fail once or twice before "giving up", at which time the active token can't be refreshed. It's not fully apparent why the failures occur as we are seeing a somewhat generic error being logged. The current plan is to rewrite the refresh process to take place in the background rather than in real-time. The idea is that we can allow retries to happen over a much longer span of time in the event that their is a failure with the refresh. QB Online API tokens have a one hour TTL, so we will likely begin to refresh any token that has reached 40-45 minutes in age. That gives our servers 10-15 minutes to retry and fetch a refreshed token before the current token expires.
gtmadev added this to the GoToMyAccounts project 2025-10-27 07:56:43 +00:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: gotomyaccounts/Portal_Web_App#29