Skip to content

Conversation

@bokelley
Copy link
Contributor

@bokelley bokelley commented Jan 3, 2026

Summary

  • When a Slack channel is linked to a regional chapter or event, existing channel members are automatically synced to the chapter
  • When a user's Slack account is linked to their WorkOS account, their channel memberships are checked and they're added to any chapters/events whose channels they belong to

Changes

  • server/src/slack/client.ts: Add getUserChannels() function to fetch a user's channel memberships via Slack API
  • server/src/slack/sync.ts: Add syncUserToChaptersFromSlackChannels() for syncing user to chapters on account link
  • server/src/routes/admin/slack.ts: Integrate chapter sync into manual and auto-link endpoints
  • server/src/routes/committees.ts: Auto-sync on channel link in committee create/update endpoints; add 'event' to VALID_COMMITTEE_TYPES

Test plan

  • Build passes
  • All tests pass (144/144)
  • Typecheck passes
  • Local server starts successfully
  • Working groups API returns chapters correctly

🤖 Generated with Claude Code

When a Slack channel is linked to a regional chapter or event:
- Existing channel members are automatically synced to the chapter

When a user's Slack account is linked to their WorkOS account:
- Their channel memberships are checked
- They're added to any chapters/events whose channels they belong to

Changes:
- Add getUserChannels() to fetch a user's channel memberships
- Add syncUserToChaptersFromSlackChannels() for account linking sync
- Auto-sync on channel link in committee create/update endpoints
- Add 'event' to VALID_COMMITTEE_TYPES in committees.ts

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <[email protected]>
@bokelley bokelley merged commit b5d2d0a into main Jan 3, 2026
6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants