Skip to content

Conversation

@bokelley
Copy link
Contributor

@bokelley bokelley commented Jan 3, 2026

Summary

  • Add new Addie admin tool manage_organization_domains with actions: list, add, remove, set_primary
  • Update domain API routes to always sync to WorkOS first (WorkOS is now the source of truth)
  • Remove optional sync_to_workos parameter - all domain changes now require WorkOS sync
  • Add domain format validation to both API and Addie tool

Background

Addie reported she couldn't manage verified domains for organizations. This adds a tool that allows her to list, add, remove, and set primary domains.

Key design decision: WorkOS is the source of truth. All domain add/remove operations sync to WorkOS first, then update the local DB. This ensures new user signups with matching email domains are auto-associated with the correct organization.

Test plan

  • Typecheck passes
  • All tests pass
  • Code review completed

🤖 Generated with Claude Code

- Add new Addie admin tool `manage_organization_domains` with actions:
  list, add, remove, set_primary
- Update domain API routes to always sync to WorkOS first (WorkOS is
  now the source of truth for domain management)
- Remove optional `sync_to_workos` parameter - all domain changes now
  require WorkOS sync for proper user auto-association
- Add domain format validation (regex) to both API and Addie tool
- Clarify that "primary domain" is a local concept for enrichment

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

Co-Authored-By: Claude Opus 4.5 <[email protected]>
@bokelley bokelley merged commit 4ab2e14 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