A NocoBase plugin that connects NocoBase's built-in AI employees to a user's Gmail and Google Calendar via user-consented OAuth. Built to explore NocoBase's plugin system, AI tool registration API, and what it actually takes to wire a real OAuth flow into a low-code platform.
aiManager.toolsManager so any AI employee can list/read/send emails and list/create/update/delete calendar events on behalf of the user it's chatting withuserId, so employee A only ever touches user A's Google accountflowchart TD
OAUTH["Google OAuth consent"]
PLUGIN["plugin.ts OAuth callback"]
STORE[("DB: googleConnections encrypted refresh token")]
SERVICES["gmail.ts / calendar.ts"]
TOKEN["ensureFreshAccessToken"]
REST["REST endpoints /api/googleTools:*"]
AI["AI tools toolsManager.registerTools"]
OAUTH -->|"code + state"| PLUGIN
PLUGIN -->|"save tokens"| STORE
STORE -->|"read token"| TOKEN
TOKEN -->|"refresh if expiring"| STORE
TOKEN --> SERVICES
SERVICES --> REST
SERVICES --> AI
.tgz you drop into ./storage/plugins/ — no source build required to installPurely exploratory — a sandbox for learning NocoBase's extension model and seeing how far its AI employee system can reach into real external APIs.
Technologies Used