Connect Gemini
Which steps apply depends on how you use Gemini: the consumer app (Spark), Gemini Enterprise through your organization, or the Antigravity CLI. Pick the one that matches you below.
Gemini app (Spark)
- Go to gemini.google.com → Settings & help → Connected apps → Custom apps for Spark → Add a custom app.
- Paste
https://mailinapp.com/api/mcpas the server URL. - Approve MailInApp's consent screen when Gemini opens it — sign in if needed, pick which account to connect as if you belong to more than one, choose your scopes (see Scopes & permissions), and approve.
That's it — nothing to submit or review, the same as connecting Claude or ChatGPT. If you don't see Custom apps for Spark as an option, it's a Google eligibility gate rather than anything on MailInApp's end: Google currently restricts custom Spark apps to US-based, 18+, personal Google accounts, with "Keep Activity" turned on and the Gemini app set to English. Outside those constraints the option doesn't appear at all.
Gemini Enterprise (through your organization)
If your company uses Gemini Enterprise, you can't add MailInApp yourself the way you would in the consumer app — it's off by default behind an org policy, and turning it on is a one-time setup your Workspace admin does, not you. Send your admin these details:
- Authorization URL:
https://mailinapp.com/oauth/authorize - Token URL:
https://mailinapp.com/oauth/token - Scopes: any combination from Scopes & permissions, space-separated.
- PKCE: on (S256).
- Client id / secret: email [email protected] with the redirect URI your Gemini Enterprise tenant uses, and we'll issue one for your admin to enter.
Once your admin has this set up, connecting and using MailInApp through Gemini Enterprise works the same as any other assistant — sign in, pick your account, choose scopes, approve.
Antigravity CLI
If you use Antigravity CLI (the successor to Gemini CLI) rather than the Gemini app, add MailInApp to its config file instead of a settings screen. Add an entry to mcp_config.json (or .agents/mcp_config.json):
{
"mcpServers": {
"mailinapp": {
"url": "https://mailinapp.com/api/mcp"
}
}
}
Antigravity CLI opens the same OAuth consent screen as every other client the first time it connects.
If a connection stops working
- No "Add a custom app" option under Connected Apps — this is Google's own eligibility gate, not MailInApp's: Spark's custom-app feature requires a US-based, 18+, personal Google account, "Keep Activity" turned on, and the Gemini app set to English. The option won't appear at all outside those constraints, regardless of anything on MailInApp's side.
- Enterprise connection rejected by your admin's config — the client id/secret MailInApp issued is tied to the exact redirect URI your tenant supplied at setup. If that URI changes, have your admin email [email protected] with the new one rather than reusing the old client.
- Antigravity CLI reports a connection error — check that
mcp_config.jsonis valid JSON and theurlfield reads exactlyhttps://mailinapp.com/api/mcp; a malformedmcpServersobject is the most common cause. - You changed teams, or a teammate revoked your access — like every other platform, a Gemini connector token is re-validated against your live account membership on every call, so losing access to a company disables that connection's calls immediately, without you needing to do anything on Gemini's side.
Revoking
Regardless of which Gemini surface you connected through, Connections in the MailInApp dashboard (/dashboard/connections) lists it alongside every other assistant with a one-click Revoke — the token stops working on its next call.