Open-Source Wikis

/

Cal.com

/

Primitives

calcom/cal.com

Primitives

The handful of Prisma models you need to understand before you can read most code in Cal.diy. Every domain in packages/features/ orbits these.

Pages

Why these

The 100 models in packages/prisma/schema.prisma aren't equally important. Most are leaf tables (Notification, Watchlist, Holiday, WhitelistEntry, ...). The six listed above appear across at least three different feature directories and are central to the booking flow. New contributors should be able to read code that mentions them without flipping back to the schema.

Where the canonical types live

packages/prisma/schema.prisma                  # source of truth
packages/prisma/generated/prisma               # generated TS client
packages/prisma/zod/                           # generated Zod schemas
packages/types/{Booking,Event,EventBusyDate,EventManager,VideoApiAdapter}.d.ts
                                               # hand-written types layered on top

How they relate

graph TD
    User --> EventType[EventType]
    User --> Schedule[Schedule]
    User --> Credential[Credential]
    User --> Membership[Membership]
    EventType --> Schedule
    EventType --> Booking[Booking]
    EventType --> Host[Host]
    Booking --> BookingReference[BookingReference]
    Booking --> Attendee[Attendee]
    User --> SelectedCalendar[SelectedCalendar]
    User --> DestinationCalendar[DestinationCalendar]
    Schedule --> Availability[Availability]
    Credential --> EventType
    Credential --> SelectedCalendar
    Credential --> DestinationCalendar

Built by Factory AutoWiki from public repository content. It is a generated preview for codebase exploration, not source-maintained documentation.

Primitives – Cal.com wiki | Factory