Everyone wants to talk about the reasoning loop. Almost nobody wants to talk about the part where your agent has a Gmail connection that worked on Tuesday and returns 401 on Friday.
I built a chat-based personal agent (Vortex, @VortexEquityBot on Telegram) that touches Gmail, Google Calendar, Sheets, Drive, Excel files and Word documents. Here is the failure list I wish someone had handed me on day one.
1. Refresh tokens go stale and nothing tells you
A connector that has worked for weeks stops working because the refresh token was revoked, or rotated, or the user changed their password. From the agent's side this looks exactly like a model that suddenly cannot follow instructions.
The fix is not better prompting. It is a distinct error state that says "this account needs reconnecting" and a UI where reconnecting is one tap. If your agent cannot tell the difference between "I do not know how to do this" and "I am locked out", you will debug the wrong layer for hours.
2. Scopes change quietly
You ship with read access. Later you want to draft mail. That is a new scope, which means a new consent screen, which means a portion of your users silently lose functionality until they re-authorise.
Design your connectors so that a missing scope degrades to a clear message rather than a mysterious failure. Assume you will add scopes, because you will.
3. Rate limits are not bugs
Some connected services impose their own request limits and daily quotas. They are set by the provider and they apply to you no matter how good your loop is.
The practical rules: read the response headers, back off exponentially, and never let a 429 propagate to the user as a generic error. "This provider is throttling me, retrying shortly" is a completely different message from "something went wrong", and users treat them differently.
4. Pagination is where correctness dies
Listing a mailbox means multiple pages. Listing a Drive folder means multiple pages. A quick local test with three emails does not exercise the pagination branch at all, and that branch is where you will lose the last two hundred results.
Write the test with a mocked second page before you write the feature.
5. Timestamps and timezones
Calendar work is a timezone minefield. An event at 15:00 in a shared calendar, an agent running on UTC, a user in CET, and a recurring event crossing a DST boundary. Store UTC, convert at the edges, and test in a timezone that is not yours.
6. Tokens in logs
You will log requests while debugging. Make sure the access token is not in those logs, because that log will end up in a bug report, a support channel, or a screenshot.
The actual lesson
The clever part of an agent is a weekend. The connections are the project. If you are scoping something like this, budget three times what feels reasonable for OAuth, refresh, retries and edge cases, and treat each connector as a small product with its own failure modes rather than a function you call once.
Happy to go deeper on any of these. The bot is at @VortexEquityBot on Telegram and the site is oxecli.co/vortex if you want to see what the result looks like from the user side.


