User sessions (self-booking)

User sessions (self-booking)

What it is

User sessions is the candidate-facing self-booking app in 3B Onboarding (b3o). It shows a candidate (a Contact) a calendar of genuinely available slots for an interview, session or onboarding appointment, lets them book the slot that suits them, review their existing bookings, and cancel a booking they no longer need, all from one screen. What the candidate can book, when, where and for how long is defined entirely on the Session records you configure, not in code.

The screen has two tabs. Book lists the sessions the candidate can still book and opens a slot picker for the chosen one, already on the day of the next available slot. Calendar is a simple list of the candidate's upcoming bookings (soonest first, the next one highlighted with its date, time, location and session leader); tapping a booking opens it with a Cancel option. When there is nothing left to book but the candidate already has an upcoming booking, the app opens on the Calendar tab so they see their confirmation instead of an empty "no pending invitations" message. The empty Calendar message and the "Your next booking" heading are overridable labels (no-bookings-msg, next-booking-lbl; Custom Labels SB_no_bookings_msg, SB_next_booking_lbl).

It is used across every vertical b3o serves: Healthcare (registration interviews, occupational-health appointments, induction slots), Education (safeguarding interviews, DBS appointments), and Blue-collar/Misc (site inductions, trade tests, kit-collection appointments). The same app drives all of them.

The problem it solves

Booking an interview or onboarding session with a candidate normally means a chain of emails: the recruiter offers times, the candidate replies, a slot is already gone, they go again. It does not scale when you are onboarding hundreds of workers a week, and it produces no clean record of who is booked for what.

User sessions removes the coordinator from the loop. The candidate is shown only slots that are real and still free (capacity that has not been used up, times that do not clash with the session leader's own calendar, times inside the booking window you allow), books in one click, and the booking is written straight back into Salesforce. When the session has a session leader, a calendar Event is dropped onto that leader's calendar automatically so their diary stays accurate. And because a booking can be requested as part of a Document Pack, a completed booking feeds the onboarding progress tracking automatically (see User documents).

Who uses it

How it is surfaced

Place the app wherever your candidates live. The same experience is delivered in each case.

Placement What to use
Visualforce page The managed Self Booking Console Visualforce page (SelfBookingConsole) hosts the app directly. Use this when you want a standalone URL to hand out by email or SMS, or to iframe into another system.
Lightning App Builder / record page / Community page The native Self Booking Console Lightning component. Its placement targets are Lightning record pages and Community/Experience pages. Drop it on a Contact record page for internal staff, or on an Experience Builder page for authenticated community candidates.
3B Portals The b3p__Portal_Block.Sessions portal block (web component tag self-booking), in the Onboarding category. Drag it onto a Portals page; the block exposes theme and label settings as configurable traits.
Digital Experience Embed the Self Booking Console Visualforce page in an Experience Cloud page for community or guest candidates.

Two further native components are for administrators, not candidates, and go on the b3o__Session__c record page:

Runtime parameters

However it is placed, the app accepts these inputs. On the Visualforce page they are URL parameters; on the native component and the Portals block they are configurable properties/traits.

Parameter Purpose
user-id (Contact Id) The candidate being booked. In a Community/Digital Experience this resolves automatically from the logged-in user's Contact; for internal placements pass the Contact Id explicitly.
session-key Guest session key for the contact. Required for 3B Portals guest access; see Access below.
Presentation: theme-type, hide-theme-switch, hide-current-user Light/dark theme, whether to show the theme toggle, and whether to show the current-user header.
Label overrides (Portals block) Every visible label and message (Book, Calendar, Invitations, Location, Time, the cancel-confirmation prompt, the various error messages, and so on) can be overridden per placement for wording or language.

When a booking finishes, the app signals the surrounding page so an embedding onboarding shell (for example User documents) can refresh its progress view without a reload.

Booking models

Every Session (b3o__Session__c) uses one of two Record Types, which decide where the bookable slots come from.

Record Type Developer name How slots are produced
Based on Set Schedule Based_on_Set_Schedule You (or the Session Schedule Manager) pre-create fixed b3o__Session_Schedule__c slots on the session. The app shows the ones that are still Open and hides any that are Fully Booked. Use this when you have specific published times and rooms.
Based on Calendar Availability Based_on_Calendar_Availability The app generates slots on the fly from the session's weekday availability windows, session length, booking window and buffer, then removes any slot that overlaps an Event on the session leader's calendar (an all-day event blocks the whole day). A fresh b3o__Session_Schedule__c slot is created at the moment the candidate books. Use this when you want to expose an interviewer's live availability without hand-building slots.

Open sessions vs invited sessions

Independently of the record type, a session is either open or invitation-only, controlled by b3o__Is_Open_Session__c:

Configuration

All behaviour lives on the three session objects. There is no separate metadata definition to author for this app.

b3o__Session__c (the session/interview definition)

One record per bookable session or interview type. The weekday, length, buffer and days-limit fields below only drive slot generation for the Based on Calendar Availability record type; for Based on Set Schedule the slots come from the child b3o__Session_Schedule__c records instead.

Field Type What it does
Record Type (none) Selects the booking model (see above).
Name Text The session title shown to the candidate.
b3o__Description__c Rich text (HTML) Longer description shown to the candidate before they book.
b3o__Short_Description__c Text area Short summary of the session.
b3o__Is_Open_Session__c Checkbox If checked, no prior invitation is required and any eligible candidate can book. If unchecked, only invited candidates see it.
b3o__Session_Leader__c Lookup (User) The interviewer/host. Their calendar availability is respected (calendar-availability model), and the booking Event is written onto their calendar. Leave blank if you do not want a calendar Event created.
b3o__Site__c Lookup (Site) The location. The site's public name is shown to the candidate and stamped onto the invitation.
b3o__Session_Length_in_Minutes__c Number (default 60) Length of each generated slot, in minutes (calendar-availability model).
b3o__Days_Limit__c Number (default 14, required) Booking horizon for calendar-availability sessions, in days. Set-schedule sessions use the greater of this value and 30 days. Up to 999 days is supported.
b3o__Minutes_Buffer_Before_Booking__c Number Minimum notice before a slot may be booked for either session type. The app hides slots that start within this window and the server rejects bookings for them (1440 minutes = 1 day).
b3o__Monday_Start__c / b3o__Monday_End__c … b3o__Sunday_Start__c / b3o__Sunday_End__c Time The daily availability window for each weekday (calendar-availability model). Leave a day's pair blank to make that day unavailable. Slots are generated between Start and End for each day.
b3o__Booking_Confirmation_Message__c Rich text (HTML) Message shown to the candidate after they have successfully booked. Use it for joining instructions, what to bring, or a location note.

b3o__Session_Schedule__c (a bookable slot)

Child of the session (master-detail). For set-schedule sessions you create these yourself (or via the Session Schedule Manager). For calendar-availability sessions one is created automatically at booking time with a single opening, so you do not pre-create them.

Field Type What it does
b3o__Session__c Master-detail (Session) The parent session.
b3o__Start_Time__c Date/Time (required) The slot's start (stored in UTC).
b3o__End_Time__c Date/Time The slot's end (stored in UTC).
b3o__Openings__c Number (required) Capacity: how many candidates may book this slot. Set to 1 for a one-to-one interview, higher for a group induction.
b3o__Booked__c Number (auto-calculated) The number of confirmed bookings on the slot, maintained automatically as invitations are booked and cancelled.
b3o__Status__c Formula (text) Open while b3o__Booked__c is below b3o__Openings__c, otherwise Fully Booked. The app only offers Open slots and hides Fully Booked ones.
b3o__Session_Name__c Text area Optional label/name for the slot.

b3o__Session_Invitation__c (a candidate's booking)

Links a Contact to a session (and the chosen slot). For invited sessions this record exists before the candidate books (the invitation); for open sessions it is created when they book. Booking sets the times and clears any revoked/cancelled flags; cancelling sets b3o__Cancelled__c, clears the slot link and booking times (freeing the slot) and deletes the session leader's upcoming calendar event.

Field Type What it does
b3o__Contact__c Master-detail (Contact) The candidate.
b3o__Session__c Master-detail (Session) The session being booked.
b3o__Session_Schedule__c Lookup (Session Schedule) The specific slot the candidate chose.
b3o__Invitation_Status__c Formula (text) Derived state: Revoked if the invitation was revoked, Cancelled if the candidate cancelled, Invited if it has no booking time yet, Booked once a booking time is set.
b3o__Cancelled__c Checkbox Set when the candidate cancels their booking. Cancelled invitations drop out of the candidate's list.
b3o__Revoke_Invitation__c Checkbox Set by an admin to withdraw an invitation. Revoked invitations are hidden from the candidate.
b3o__Start_Time__c / b3o__End_Time__c Date/Time The booked start/end (stored in UTC).
b3o__Booking_Start_Time__c / b3o__Booking_End_Time__c Formula (date/time) The absolute booking start/end, taken from the linked schedule when present, otherwise from the invitation's own times. Use these for reporting.
b3o__Booking_Time_Text__c Text The exact time the candidate saw at the moment of booking, as a human-readable string. Use this in confirmation emails so the candidate sees the same wording they booked.
b3o__Booking_Timezone__c Text The timezone identifier the candidate was viewing in when they booked. Combine with the UTC times to render the correct offset in notifications.
b3o__Self_Booking_Timestamp__c Date/Time When the self-booking happened.
b3o__Public_Message__c Text area A message visible to the candidate/invitee on this invitation.
b3o__Site__c Formula (text) The session's site public name, surfaced on the invitation for convenience.
b3o__Source_of_Booking__c Text Records which page/context the candidate booked from.

Portals block traits (sample)

The b3p__Portal_Block.Sessions block exposes its inputs as configurable traits in the 3B Portals builder. The Contact Id trait defaults to the portal's resolved contact, and every visible string can be overridden:

[
  { "label": "Contact Id",         "type": "text", "name": "user-id",           "default": "{{contactUser.Id}}" },
  { "label": "Theme Type",         "type": "text", "name": "theme-type",        "default": "light" },
  { "label": "Hide Theme Switch",  "type": "text", "name": "hide-theme-switch", "default": "true" },
  { "label": "Hide Current User",  "type": "text", "name": "hide-current-user", "default": "false" },
  { "label": "Book Button Label",  "type": "text", "name": "book-btn-lbl",      "default": "Book" },
  { "label": "Invitations Label",  "type": "text", "name": "invitations-lbl",   "default": "Invitations" },
  { "label": "Cancel Confirmation Message", "type": "text", "name": "cancel-confirm-msg", "default": "Are you sure you want to cancel?" }
]

Timezones

Booking is timezone-sensitive and this app always works in the candidate's own local timezone, not the recruiter's Salesforce timezone. All slot times travel to and from Salesforce in UTC and are converted to the candidate's local zone for display and for the calendar-clash calculation. At booking, the app records both the machine time (UTC, on b3o__Start_Time__c / b3o__End_Time__c) and exactly what the candidate saw (b3o__Booking_Time_Text__c and b3o__Booking_Timezone__c), so a confirmation email can reproduce the precise local time and offset the candidate agreed to.

From Version 10, Session Schedule Manager and Invitations Schedule Manager correctly show bookings near a UTC day boundary. For example, a local Monday morning booking stored as Sunday night UTC no longer disappears from the calendar.

Access and the guest/session model

User sessions is a session app. Two access modes:

Grant object and field access for internal/admin users (Session, Session Schedule, Session Invitation and their fields) on the Onboarding_Admin_Full_Permission permission set. Any new objects or fields you add for this app must be granted there too.