Skip to main content

Data Model

Source: equa-server/modules/persistence/src/schema.ts (lines 1-2101) Entity count: 92 entities (90 tables + 2 view entities) Database: PostgreSQL

Domain Partitioning

Source: Confluence KnowledgeBase — Entity Domain Partitioning (by Christopher Johnson)
There are two main entity types: Individuals and Organizations. Intrinsic data is partitioned across domains: Organizations do not have Site Access data — the site is only accessed through individuals. Database schema mapping:
  • Organizations: All intrinsic data stored in the organizations table (the deprecated organization_details table previously stored profile data)
  • Individuals: users table (access data), profiles table (profile data, may be renamed to user_profiles), and a planned user_accounts table for account data
Multi-tenancy is achieved through organization foreign keys on business entities. Cross-domain references use standard TypeORM @ManyToOne / @OneToMany relations.

Entity Summary by Domain

Users and Authentication (10 entities)

Organizations (7 entities)

Cap Table and Securities (14 entities)

ESOP and Vesting (7 entities)

Convertible Instruments (4 entities)

Agreements and Documents (5 entities)

Files and Data Room (4 entities)

Google Drive Integration (4 entities)

Roles and Permissions (5 entities)

Referrals and Rewards (4 entities)

Financial and Blockchain (5 entities)

Activity and Audit (3 entities)

Other (8 entities)

View Entities (2)

Entities in allEntities Not Yet Documented Above

The following 10 entities exist in schema.ts allEntities array but are not categorized in the domain tables above:

Base Classes

All entities extend one of these base classes which provide common fields:

Indexes

Unique Constraints