It started with a small question: how do I send a teammate "the Gmail plugin" so he can install it in Chrome? The answer was that there is no plugin. Vimek Gmail is a Google Workspace add-on written in Apps Script, it installs per Google account, and until today it did one thing: send the open thread to our agent and show the answer. While looking at it I asked for the thing I missed from Copper CRM years ago: open an email and see who this person is, without asking anyone.
What the card shows
One GET /api/v1/vimek/contacts/?email= to the Vimo Swim backend, drawn with plain CardService widgets. No AI on this path.

Pipeline, purchase and tester status, source and campaign, contact details, order and paid flag, deposit, device, owner. Buttons open the CRM, the lead's Slack channel, Chatwoot and WhatsApp.
One line that says no lead has this address, plus newsletter and shop history, and an Add-as-a-lead form prefilled from the email.
Change the pipeline status or append a dated note. Both go through the write endpoints Vimek already uses from Slack, with my Google email as the person who changed it.
The old prompt moved to the bottom of the card. The agent is for questions, the card is for facts.
flowchart LR
G[Gmail message opens] --> A["Apps Script<br/>onGmailMessageOpen"]
A -->|"Api-Key"| B["backend<br/>/vimek/contacts/?email="]
B --> C["CRM lead, deposit,<br/>devices, shop orders"]
A --> D[Card in the side panel]
D -->|"Save status, Add note"| E["PATCH /vimek/leads/id/"]
The backend side is one read-only view that reuses the lead_details helper the agent's tools already had, plus owner, links and the five latest timeline entries. Lead emails are not unique in our CRM, so the newest match wins and the response carries a count of the others. The sender header comes in as Name <addr>, so email.utils.parseaddr runs first. Ten tests, one regenerated OpenAPI file.
Mockup first
Before any code I built a design canvas with five artboards: Gmail with the panel open, the four panel states at the real 320 px width. That hour paid for itself twice. It forced the list of fields, and it showed that a lead has no owner field, which was added to the CRM the same afternoon in another ticket.
Shipping without clasp
The add-on is pushed with clasp, and clasp was not logged in on this Mac. Logging in means a Google OAuth flow in the browser, which I leave to a person. The Apps Script web editor was already signed in, so I used that instead.
The Apps Script editor is Monaco, and the page exposes monaco on window. monaco.editor.getModels() lists the files, model.setValue(code) replaces one, and the Save button writes them. I checked each file with a SHA-256 of getValue() after a reload against the local build. Three files, three matching hashes.
The installed test deployment runs the head code, so the save was live in Gmail at once. That is also where the evening got interesting.
The redirect that lied
The backend pull request was not merged yet, so /vimek/contacts/ did not exist in production. Django's admin lives at the root of that host and catches every unknown path with a redirect to the login page. UrlFetchApp follows redirects by default. My request helper got a 200 with an HTML body, my "tolerant" JSON parser turned that into an empty object, and the card did exactly what it does for an empty answer: it said Not in the CRM for a real lead, with a friendly form to add him again.
| Backend state | HTTP | Old card | New card |
|---|---|---|---|
| Endpoint live, lead found | 200 | Contact card | Contact card |
| Endpoint live, no lead | 200 | Add as a lead | Add as a lead |
| Endpoint missing | 302 | Add as a lead | Red error line, Ask still works |
| Proxy error page | 502 | Crash | Red error line, Ask still works |
"Not found" and "could not look" are two different states. A lookup that cannot answer has to fail loudly, never return an empty result. The fix was three lines: followRedirects: false, a non-JSON body is an error whatever the status, and anything from 300 up is an error with the URL in the message.
The automated security review on the commit was useful too: CRM text is now escaped before it lands in card HTML, only https links get a button, and the lead id a button carries is checked before it goes into a URL.
Two pull requests on the backend, one on the add-on, one evening with Claude Code doing the typing and me doing the clicking. What I would do differently: deploy the backend first and watch the card fail honestly, instead of designing an error path that was friendly enough to be wrong.

Related notes
GitHub Actions billing stopped our CI, and showed where the minutes went
A merge to main did not deploy because every CI job was blocked by billing. The usage report showed that one end-to-end suite on every push used more minutes than the rest of our CI together.
Cleaning 199 GB of duplicates out of Google Photos from inside Chrome
Google Photos has no API to delete photos, so Claude did it in my browser: fingerprint thumbnails in the page, bin RAW files that have a JPEG twin, check every selection against Google's own counter.



