Gmail is one of the six sources with both an open-source ingest skill and a paid webhook receiver.Documentation Index
Fetch the complete documentation index at: https://docs.mycelium-ai.co/llms.txt
Use this file to discover all available pages before exploring further.
Open-source ingest skill
Pull email threads by label or search query intoExternal Inputs/Gmail/<label>/<YYYY-MM-DD>.md. Uses Gmail API with OAuth 2.0. Requires gmail.readonly scope.
Webhook receiver (paid runtime)
Real-time push via Gmail push notifications (Google Cloud Pub/Sub).Authorization: Bearer header. The receiver validates the JWT against Google’s public keys.
Setup
- Enable the Gmail API and create a Pub/Sub topic in Google Cloud.
- Create a push subscription pointing to
https://runtime.myceliumai.co/webhooks/gmail/{your_tenant_id}. - Add the Pub/Sub service account as a subscriber.
- Set
GMAIL_PUBSUB_AUDIENCE_{TENANT_ID}andGMAIL_WATCH_EMAIL_{TENANT_ID}in the runtime env. - Run
POST https://gmail.googleapis.com/gmail/v1/users/me/watchwith the Pub/Sub topic to start the watch. Watches expire every 7 days; the runtime renews automatically.
Events ingested
| Gmail event | Memory category | Notes |
|---|---|---|
| New message | fact | Sender, subject, body excerpt, thread id |
| Label change | fact | Applied labels captured as tags |
| Thread reply | decision | Thread resolution promoted to decision |