Skip to content

Database Schema

FluentBooking stores all data in custom WordPress tables prefixed with fcal_. The schema below is parsed directly from the CREATE TABLE statements inside database/Migrations/, so the columns, types, and defaults reflect what is installed at activation.

Tables

TableModelColumnsIndexes
fcal_bookingsBooking427
fcal_calendarsCalendar196
fcal_calendar_eventsCalendarSlot235
fcal_metaAvailability70
fcal_booking_activityBookingActivity100
fcal_booking_hostsBookingHost63
fcal_booking_metaBookingMeta60
fcal_metaMeta70
fcal_ordersOrder270
fcal_order_itemsOrderItems120
fcal_transactionsTransactions170

Entity Relationship Diagram

fcal_bookings (Booking)

Migration source: fluent-booking/database/Migrations/BookingMigrator.php

ColumnTypeNullableDefaultDescription
idBIGINT(20) UNSIGNED NOT NULL PRIMARY KEYYesPrimary key for the row.
hashVARCHAR(192)YesRandom hash used as a public, non-enumerable booking identifier.
calendar_idBIGINT(20) UNSIGNEDNoForeign key to fcal_calendars.
event_idBIGINT(20) UNSIGNEDNoForeign key to fcal_calendar_events (the CalendarSlot model).
group_idBIGINT(20) UNSIGNEDYesShared group ID for bookings created together (group / collective).
fcrm_idBIGINT(20) UNSIGNEDYesOptional FluentCRM contact ID for the booker.
parent_idBIGINT(20) UNSIGNEDYesParent row used for rescheduled or grouped bookings.
host_user_idBIGINT(20) UNSIGNEDYesWordPress user ID of the host that owns the booking.
person_user_idBIGINT(20) UNSIGNEDYesWordPress user ID of the attendee, if they were logged in.
person_contact_idBIGINT(20) UNSIGNEDYesFluentCRM contact ID for the attendee, when available.
person_time_zoneVARCHAR(100)YesIANA timezone of the attendee at the time of booking.
start_timeTIMESTAMPYesBooking start time in UTC.
end_timeTIMESTAMPYesBooking end time in UTC.
slot_minutesINT(11) UNSIGNEDNoLength of the booked slot in minutes.
first_nameVARCHAR(192)YesAttendee first name.
last_nameVARCHAR(192)YesAttendee last name.
emailVARCHAR(192)YesAttendee email address.
messageTEXTYesFree-form message submitted by the attendee.
internal_noteTEXTYesInternal note visible only to hosts and admins.
phoneVARCHAR(100)YesAttendee phone number (when collected).
countryVARCHAR(100)YesAttendee country code (when collected).
ip_addressVARCHAR(192)YesIP address recorded when the booking was created.
browserVARCHAR(192)YesBrowser detected when the booking was created.
deviceVARCHAR(192)YesDevice detected when the booking was created.
other_infoLONGTEXTYesSerialized custom-field answers and miscellaneous attendee data.
location_detailsLONGTEXTYesSerialized location data (Zoom link, address, custom location).
cancelled_byBIGINT(20) UNSIGNEDYesUser ID of the person who cancelled the booking, if any.
statusVARCHAR(20)NoscheduledLifecycle status (scheduled, cancelled, completed, rejected, pending).
sourceVARCHAR(20)NowebHow the booking was created (web, api, etc.).
booking_typeVARCHAR(20)NoschedulingInternal booking subtype.
event_typeVARCHAR(20)Nosinglesingle or group event.
payment_statusVARCHAR(20)YesPayment lifecycle status (pending, paid, refunded).
payment_methodVARCHAR(20)YesSelected payment method slug.
source_urlTEXTYesReferring URL where the booking originated.
source_idBIGINT(20) UNSIGNEDYesGeneric foreign key for the source record (form ID, etc.).
utm_sourceVARCHAR(192)Yes``Marketing UTM source value.
utm_mediumVARCHAR(192)Yes``Marketing UTM medium value.
utm_campaignVARCHAR(192)Yes``Marketing UTM campaign value.
utm_termVARCHAR(192)Yes``Marketing UTM term value.
utm_contentVARCHAR(192)Yes``Marketing UTM content value.
created_atTIMESTAMPYesCreation timestamp maintained by the ORM.
updated_atTIMESTAMPYesUpdate timestamp maintained by the ORM.

Indexes

  • fcal_b_parent_id on (parent_id)
  • fcal_b_hash on (hash)
  • fcal_b_calendar_id on (calendar_id)
  • fcal_b_fcrm_id on (fcrm_id)
  • fcal_b_event_id on (event_id)
  • fcal_b_booking_type on (booking_type)
  • fcal_b_start_time on (start_time)

fcal_calendars (Calendar)

Migration source: fluent-booking/database/Migrations/CalendarMigrator.php

ColumnTypeNullableDefaultDescription
idBIGINT(20) UNSIGNED NOT NULL PRIMARY KEYYesPrimary key for the row.
hashVARCHAR(192)YesRandom hash used as a public, non-enumerable booking identifier.
user_idBIGINT(20) UNSIGNEDNoWordPress user ID associated with the row.
account_idBIGINT(20) UNSIGNEDYesForeign key to a related record.
parent_idBIGINT(20) UNSIGNEDYesParent row used for rescheduled or grouped bookings.
titleVARCHAR(192)NoHuman-readable title stored for the record.
slugVARCHAR(192)NoSanitized slug or public identifier.
media_idBIGINT(20) UNSIGNEDYesForeign key to a related record.
descriptionLONGTEXTYesDescription text stored for the record.
settingsLONGTEXTYesSerialized settings payload.
statusVARCHAR(20)NoactiveLifecycle status (scheduled, cancelled, completed, rejected, pending).
typeVARCHAR(20)NosimpleSubtype discriminator.
event_typeVARCHAR(20)Noschedulingsingle or group event.
account_typeVARCHAR(20)NofreeAccount Type stored for this record.
visibilityVARCHAR(20)NopublicVisibility stored for this record.
author_timezoneVARCHAR(192)YesUTCAuthor Timezone stored for this record.
max_book_per_slotINT(10) UNSIGNEDNo1Max Book Per Slot stored for this record.
created_atTIMESTAMPYesCreation timestamp maintained by the ORM.
updated_atTIMESTAMPYesUpdate timestamp maintained by the ORM.

Indexes

  • fcal_c_user_id on (user_id)
  • fcal_c_hash on (hash)
  • fcal_c_status on (status)
  • fcal_c_slug on (slug)
  • fcal_c_event_type on (event_type)
  • fcal_c_type on (type)

fcal_calendar_events (CalendarSlot)

Migration source: fluent-booking/database/Migrations/CalendarSlotsMigrator.php

ColumnTypeNullableDefaultDescription
idBIGINT(20) UNSIGNED NOT NULL PRIMARY KEYYesPrimary key for the row.
hashVARCHAR(192)YesRandom hash used as a public, non-enumerable booking identifier.
user_idBIGINT(20) UNSIGNEDNoWordPress user ID associated with the row.
calendar_idBIGINT(20) UNSIGNEDNoForeign key to fcal_calendars.
durationINT(11) UNSIGNEDNoEvent length in minutes.
titleVARCHAR(192)NoHuman-readable title stored for the record.
slugVARCHAR(192)NoSanitized slug or public identifier.
media_idBIGINT(20) UNSIGNEDYesForeign key to a related record.
descriptionLONGTEXTYesDescription text stored for the record.
settingsLONGTEXTYesSerialized settings payload.
availability_typeVARCHAR(192)YescustomAvailability Type stored for this record.
availability_idBIGINT(20) UNSIGNEDYesForeign key to a related record.
statusVARCHAR(20)NoactiveLifecycle status (scheduled, cancelled, completed, rejected, pending).
typeVARCHAR(20)NofreeSubtype discriminator.
color_schemaVARCHAR(100)NodefaultColor Schema stored for this record.
location_typeVARCHAR(100)No``Location Type stored for this record.
location_headingTEXTYesLocation Heading stored for this record.
location_settingsLONGTEXTYesLocation Settings stored for this record.
event_typeVARCHAR(20)Nosinglesingle or group event.
is_display_spotsBOOLEANNo0Is Display Spots stored for this record.
max_book_per_slotINT(10) UNSIGNEDNo1Max Book Per Slot stored for this record.
created_atTIMESTAMPYesCreation timestamp maintained by the ORM.
updated_atTIMESTAMPYesUpdate timestamp maintained by the ORM.

Indexes

  • fcal_cs_user_id on (user_id)
  • fcal_cs_hash on (hash)
  • fcal_cs_status on (status)
  • fcal_cs_slug on (slug)
  • fcal_cs_type on (type)

fcal_meta (Availability)

Migration source: fluent-booking/database/Migrations/MetaMigrator.php

ColumnTypeNullableDefaultDescription
idBIGINT UNSIGNED NOT NULL PRIMARY KEYYesPrimary key for the row.
object_typeVARCHAR(50)NoPolymorphic object type for the meta row.
object_idBIGINTYesPolymorphic object ID for the meta row.
keyVARCHAR(192)NoMeta key.
valueLONGTEXTYesMeta value (often JSON-encoded).
created_atTIMESTAMPYesCreation timestamp maintained by the ORM.
updated_atTIMESTAMPYesUpdate timestamp maintained by the ORM.

fcal_booking_activity (BookingActivity)

Migration source: fluent-booking/database/Migrations/BookingActivityMigrator.php

ColumnTypeNullableDefaultDescription
idBIGINT UNSIGNED NOT NULL PRIMARY KEYYesPrimary key for the row.
booking_idBIGINT UNSIGNEDNoForeign key to a related record.
parent_idBIGINT UNSIGNEDYesParent row used for rescheduled or grouped bookings.
created_byBIGINT UNSIGNEDYesCreated By stored for this record.
statusVARCHAR(50)YesopenLifecycle status (scheduled, cancelled, completed, rejected, pending).
typeVARCHAR(50)YesactivitySubtype discriminator.
titleVARCHAR(192)YesHuman-readable title stored for the record.
descriptionLONGTEXTYesDescription text stored for the record.
created_atTIMESTAMPYesCreation timestamp maintained by the ORM.
updated_atTIMESTAMPYesUpdate timestamp maintained by the ORM.

fcal_booking_hosts (BookingHost)

Migration source: fluent-booking/database/Migrations/BookingHostMigrator.php

ColumnTypeNullableDefaultDescription
idBIGINT(20) UNSIGNED NOT NULL PRIMARY KEYYesPrimary key for the row.
booking_idBIGINT(20) UNSIGNEDNoForeign key to a related record.
user_idBIGINT(20) UNSIGNEDNoWordPress user ID associated with the row.
statusVARCHAR(20)NoconfirmedLifecycle status (scheduled, cancelled, completed, rejected, pending).
created_atTIMESTAMPYesCreation timestamp maintained by the ORM.
updated_atTIMESTAMPYesUpdate timestamp maintained by the ORM.

Indexes

  • fcal_bu_booking_id on (booking_id)
  • fcal_bu_user_id on (user_id)
  • fcal_bu_status on (status)

fcal_booking_meta (BookingMeta)

Migration source: fluent-booking/database/Migrations/BookingMetaMigrator.php

ColumnTypeNullableDefaultDescription
idBIGINT UNSIGNED NOT NULL PRIMARY KEYYesPrimary key for the row.
booking_idBIGINTYesForeign key to a related record.
meta_keyVARCHAR(192)NoMeta Key stored for this record.
valueLONGTEXTYesMeta value (often JSON-encoded).
created_atTIMESTAMPYesCreation timestamp maintained by the ORM.
updated_atTIMESTAMPYesUpdate timestamp maintained by the ORM.

fcal_meta (Meta)

Migration source: fluent-booking/database/Migrations/MetaMigrator.php

ColumnTypeNullableDefaultDescription
idBIGINT UNSIGNED NOT NULL PRIMARY KEYYesPrimary key for the row.
object_typeVARCHAR(50)NoPolymorphic object type for the meta row.
object_idBIGINTYesPolymorphic object ID for the meta row.
keyVARCHAR(192)NoMeta key.
valueLONGTEXTYesMeta value (often JSON-encoded).
created_atTIMESTAMPYesCreation timestamp maintained by the ORM.
updated_atTIMESTAMPYesUpdate timestamp maintained by the ORM.

fcal_orders (Order)

Migration source: fluent-booking-pro/database/Migrations/BookingOrdersMigrator.php

ColumnTypeNullableDefaultDescription
idBIGINT UNSIGNED NOT NULL PRIMARY KEYYesPrimary key for the row.
statusVARCHAR(20)NodraftLifecycle status (scheduled, cancelled, completed, rejected, pending).
parent_idBIGINT UNSIGNEDNoParent row used for rescheduled or grouped bookings.
order_numberVARCHAR(255)No``Order Number stored for this record.
typeVARCHAR(20)NosaleSubtype discriminator.
customer_idBIGINT UNSIGNEDNoForeign key to a related record.
payment_methodVARCHAR(100)NoSelected payment method slug.
payment_modeVARCHAR(100)NoPayment Mode stored for this record.
payment_method_typeVARCHAR(100)NoPayment Method Type stored for this record.
payment_method_titleVARCHAR(100)NoPayment Method Title stored for this record.
currencyVARCHAR(10)NoCurrency stored for this record.
subtotalDECIMAL(18,9)No0.000000000Subtotal stored for this record.
discount_taxDECIMAL(18,9)No0.000000000Discount Tax stored for this record.
discount_totalDECIMAL(18,9)No0.000000000Discount Total stored for this record.
shipping_taxDECIMAL(18,9)No0.000000000Shipping Tax stored for this record.
shipping_totalDECIMAL(18,9)No0.000000000Shipping Total stored for this record.
tax_totalDECIMAL(18,9)No0.000000000Tax Total stored for this record.
total_amountDECIMAL(18,9)No0.000000000Total Amount stored for this record.
total_paidDECIMAL(18,9)No0.000000000Total Paid stored for this record.
rateDECIMAL(18,9)No1.000000000Rate stored for this record.
noteTEXTNoNote stored for this record.
ip_addressTEXTNoIP address recorded when the booking was created.
completed_atDATETIMEYesTimestamp column.
refunded_atDATETIMEYesTimestamp column.
uuidVARCHAR(100)NoUuid stored for this record.
created_atTIMESTAMPYesCreation timestamp maintained by the ORM.
updated_atTIMESTAMPYesUpdate timestamp maintained by the ORM.

fcal_order_items (OrderItems)

Migration source: fluent-booking-pro/database/Migrations/OrdersItemsMigrator.php

ColumnTypeNullableDefaultDescription
idBIGINT(20) UNSIGNED NOT NULL PRIMARY KEYYesPrimary key for the row.
order_idBIGINT UNSIGNEDNo0Foreign key to a related record.
booking_idBIGINT UNSIGNEDNo0Foreign key to a related record.
item_nameTEXTNoItem Name stored for this record.
typeVARCHAR(255)YesSubtype discriminator.
quantityINTNo0Quantity stored for this record.
item_priceDECIMAL(18,9)No0.000000000Item Price stored for this record.
item_totalDECIMAL(18,9)No0.000000000Item Total stored for this record.
rateDECIMAL(18,9)No1.000000000Rate stored for this record.
line_metaTEXTYesLine Meta stored for this record.
created_atTIMESTAMPYesCreation timestamp maintained by the ORM.
updated_atTIMESTAMPYesUpdate timestamp maintained by the ORM.

fcal_transactions (Transactions)

Migration source: fluent-booking-pro/database/Migrations/BookingTransactionsMigrator.php

ColumnTypeNullableDefaultDescription
idBIGINT(20) UNSIGNED NOT NULL PRIMARY KEYYesPrimary key for the row.
object_idBIGINT UNSIGNEDNo0Polymorphic object ID for the meta row.
object_typeVARCHAR(100)No``Polymorphic object type for the meta row.
transaction_typevarchar(255)Yesone_timeTransaction Type stored for this record.
subscription_idint(11)YesForeign key to a related record.
card_last_4int(4)YesCard Last 4 stored for this record.
card_brandvarchar(255)YesCard Brand stored for this record.
vendor_charge_idVARCHAR(192)No``Foreign key to a related record.
payment_methodVARCHAR(100)No``Selected payment method slug.
payment_method_typeVARCHAR(100)No``Payment Method Type stored for this record.
statusVARCHAR(20)No``Lifecycle status (scheduled, cancelled, completed, rejected, pending).
totalDECIMAL(18,9)No0.000000000Total stored for this record.
rateDECIMAL(10,5)No1.00000Rate stored for this record.
uuidVARCHAR(100)No``Uuid stored for this record.
metajsonYesSerialized meta payload.
created_atTIMESTAMPYesCreation timestamp maintained by the ORM.
updated_atTIMESTAMPYesUpdate timestamp maintained by the ORM.