Wanted to raise something else we ran into with connection status. When a connection is already ACTIVE and the provider later revokes the grant, it never leaves ACTIVE. Your docs say it should move to FAILED when credentials stop working, but we haven’t seen that happen.
We tested it directly. Created a Todoist connection, then revoked Maton’s access from inside Todoist. Gateway calls started 401ing right away, and three days later the connection still showed ACTIVE. We also looked at every non-ACTIVE status returned to our account over 16 days, about 6,100 observations, and never saw a live connection flip to FAILED. Only PENDING, plus one FAILED from an auth that never completed.
The problem for us is that ACTIVE is the only health signal we get, so we end up telling users an app is connected when it’s actually dead. And since the docs say to check for an ACTIVE connection before creating one, Reconnect ends up doing nothing.
Sorry about that. The connection status is misleading, it only indicates whether the app connection was successfully authorized or refreshed so when it fails to refresh, you should see it being marked failed. We don’t account for the upstream 401s but we’ll add it to the roadmap to account for it. Meanwhile, you may have to look at the upstream status code and determine whether the connection can be used or not.