test: Federation flow for company entities
Resolved 💬 3 comments Opened Dec 18, 2025 by evanmcgillivray Closed Feb 12, 2026
Context
We have implemented auto_federate for contacts. Now we need to extend and test federation for company entities.
Current State
process_contact_identifiersextracts emails/phones from contacts' JSONB fields- Companies don't have the same JSONB structure for identifiers
- Companies may share identifiers through:
- URLs (website)
- Contact emails (employees)
- Phone numbers
Tasks
- [ ] Determine what identifiers companies should be federated on
- [ ] Create
process_company_identifiersfunction (if needed) - [ ] Add test: Two companies with same website URL get federated
- [ ] Add test: Two companies with same contact email get federated
- [ ] Verify company federation respects
federated_id.entity_type = 'company'
Questions
- Should company federation be based on URLs primarily?
- Should company contacts (employees) contribute to company federation?
Related
- ADR-017: Unified Identifiers
auto_federateaction in federation-manage edge function
This issue has 3 comments on GitHub. Read the full discussion on GitHub ↗