This repository hosts examples of the agent auth capabilities of Scalekit.
Note: This project is a work in progress.
Scalekit Agent Auth handles the full OAuth lifecycle — authorization, token storage, and automatic refresh — so AI agents can act on behalf of users in Gmail, Google Calendar, Slack, Notion, and other connectors.
| Language | Use Case | Connector(s) | File |
|---|---|---|---|
| Python | AI Email Triage & Draft Replies | Gmail | python/email_triage_agent.py |
| Python | Meeting Scheduler | Google Calendar + Gmail | python/meeting_scheduler_agent.py |
| Python | Daily Briefing / Morning Digest | Gmail + Google Calendar | python/daily_briefing_agent.py |
cp .env.example .env
# Edit .env with your values from app.scalekit.com → Developers → Settings → API Credentialscd python
python3 -m venv .venv
source .venv/bin/activate
pip install -r requirements.txtpython email_triage_agent.py
python meeting_scheduler_agent.py
python daily_briefing_agent.pyAll scripts require a one-time connection setup in the Scalekit Dashboard before running.
- Go to Scalekit Dashboard → Agent Auth → Connections
- Click + Create Connection
- Select the connector and set the Connection Name exactly as shown below:
| Connector | Connection Name |
|---|---|
| Gmail | gmail |
| Google Calendar | googlecalendar |
- Click Save
The Connection Name must match the
connection_namevalue in the script exactly.
The first time you run a script, the user hasn't authorized access yet. The script will print an authorization link and wait:
Authorize access here: https://your-env.scalekit.dev/magicLink/...
Press Enter after completing authorization...
- Open the link in your browser
- Sign in with the Google account you want to connect
- Grant the requested permissions
- Return to the terminal and press Enter
On all subsequent runs, Scalekit uses the stored token (auto-refreshed as needed) and skips the authorization step entirely.