by @lycfyi
Smart Discord sync - automatically detects tokens and permissions to choose the optimal sync method. Use when user asks to sync Discord messages.
Automatically detects available tokens and bot permissions to route to the optimal sync connector.
This skill runs a preflight check before syncing:
.env| Scenario | Connector Used | Reason |
|---|---|---|
| Syncing DMs | discord-user-connector | Bots cannot access DMs |
| Bot token valid + has permissions | discord-bot-connector | Faster, higher rate limits |
| Bot token valid but lacks permissions | discord-user-connector | Fallback |
| Only user token available | discord-user-connector | Only option |
| Only bot token available | discord-bot-connector | Only option (no DMs) |
| No valid tokens | Error | Configuration needed |
# Check for specific server
python ${CLAUDE_PLUGIN_ROOT}/tools/discord_preflight.py --server SERVER_ID
# Check for DM sync
python ${CLAUDE_PLUGIN_ROOT}/tools/discord_preflight.py --dms
# JSON output for programmatic use
python ${CLAUDE_PLUGIN_ROOT}/tools/discord_preflight.py --server SERVER_ID --json
The preflight check returns a recommendation. Execute the recommended skill:
If recommendation is discord-bot-connector:discord-sync:
Skill(skill: "discord-bot-connector:discord-sync")
If recommendation is discord-user-connector:discord-sync:
Skill(skill: "di...