|  | 
|  | 1 | +--- | 
|  | 2 | +title: 'Schedule' | 
|  | 3 | +description: "Learn how subscribers can use the Schedule feature in the Inbox component to control when they receive notifications from email, SMS and push channels." | 
|  | 4 | +icon: 'CalendarCheck' | 
|  | 5 | +--- | 
|  | 6 | + | 
|  | 7 | +The **Schedule** feature in the <Method href="/platform/inbox/overview">{`<Inbox />`}</Method> lets subscribers control when they want to receive notifications from email, SMS, and push channels. | 
|  | 8 | + | 
|  | 9 | +By defining their hours of availability from the <Method href="/platform/inbox/overview">{`<Inbox />`}</Method> UI, subscribers can automatically skip notifications outside of their chosen time range. | 
|  | 10 | + | 
|  | 11 | + | 
|  | 12 | + | 
|  | 13 | +<Callout>In-app notifications and notifications from critical workflows are never paused and will always be delivered, regardless of schedule settings.</Callout> | 
|  | 14 | + | 
|  | 15 | +## How scheduling works | 
|  | 16 | + | 
|  | 17 | +The schedule functionality is based on a clear set of rules controlled by the subscriber within the <Method href="/platform/inbox/overview">{`<Inbox />`}</Method>. When a subscriber enables their schedule, they can then manage their availability for each day of the week. | 
|  | 18 | + | 
|  | 19 | +### Daily availability | 
|  | 20 | +For any day that the main schedule is active, there will be two possible states: | 
|  | 21 | + | 
|  | 22 | +- **Day is enabled**: If a day is toggled on, then the subscriber must set a time range. Notifications will only be delivered within these hours. | 
|  | 23 | + | 
|  | 24 | +- **Day is disabled**: If a day is toggled off, then the subscriber will not receive any non-critical notifications for that entire day. | 
|  | 25 | + | 
|  | 26 | +### Automatic timezone handling | 
|  | 27 | + | 
|  | 28 | +The schedule operates in the subscriber's local timezone, detected automatically from their system settings. There is no need for manual configuration. | 
|  | 29 | + | 
|  | 30 | +For example, if a subscriber in Warsaw sets their schedule from 9:00 AM to 5:00 PM, they will receive notifications during those hours in Central European Time (CET). | 
|  | 31 | + | 
|  | 32 | +## Manage Schedule | 
|  | 33 | + | 
|  | 34 | +The schedule UI in the preferences section is designed to be intuitive, giving subscribers several tools to quickly configure their availability. | 
|  | 35 | + | 
|  | 36 | +You can access **Schedule** from the **Preferences** section of the <Method href="/platform/inbox/overview">{`<Inbox />`}</Method> UI. By default, scheduling is turned off, and all notifications will be delivered normally. | 
|  | 37 | + | 
|  | 38 | + | 
|  | 39 | + | 
|  | 40 | +### Enable the main schedule | 
|  | 41 | + | 
|  | 42 | +The entire feature is controlled by a main schedule toggle. When a subscriber turns this on, they can begin configuring individual days. When it's off, all other settings will be inactive, and notifications will be delivered normally. | 
|  | 43 | + | 
|  | 44 | +### Setting daily availability | 
|  | 45 | + | 
|  | 46 | +For each day of the week, the subscriber can: | 
|  | 47 | + | 
|  | 48 | +- Use the toggle next to the day's name to activate or deactivate it. | 
|  | 49 | +- If activated, use the time-selector menus to set a "from" and "to" time. The time pickers are set to 30-minute increments for ease of use. | 
|  | 50 | + | 
|  | 51 | +### Edit or remove schedules | 
|  | 52 | + | 
|  | 53 | +Existing availability can be adjusted at any time. Subscribers can: | 
|  | 54 | +- Change the start and end times for a day. | 
|  | 55 | +- Re-enable a previously disabled day. | 
|  | 56 | +- Clear a schedule entirely to return to unrestricted delivery. | 
|  | 57 | + | 
|  | 58 | +### Copying times to multiple days | 
|  | 59 | + | 
|  | 60 | +To make setup faster, subscribers can configure the time for one day and apply it to others in a few clicks: | 
|  | 61 | + | 
|  | 62 | +1. Set the desired time range for a single day. | 
|  | 63 | +2. Click **Copy times to...** associated with that day. | 
|  | 64 | +3. In the menu that appears, select the other days of the week to apply this schedule to. | 
|  | 65 | +4. Click "Apply." The selected days will automatically be enabled and updated with the new time range. | 
|  | 66 | + | 
|  | 67 | + | 
|  | 68 | + | 
|  | 69 | +### Automatic saving | 
|  | 70 | + | 
|  | 71 | +All changes made in the schedule interface will be saved automatically in the background. The UI updates optimistically, providing a seamless experience without requiring the subscriber to click save. | 
|  | 72 | + | 
|  | 73 | +## Set default schedule for Subscribers | 
|  | 74 | + | 
|  | 75 | +You can provide a default schedule for your subscribers by passing the `defaultSchedule` prop to the <Method href="/platform/inbox/overview">{`<Inbox />`}</Method>. This is useful for pre-configuring a recommended schedule that your subscribers can then customize. | 
|  | 76 | + | 
|  | 77 | +This default schedule only applies if a subscriber has not yet configured their own schedule. Once they make any changes, their custom schedule takes precedence. | 
|  | 78 | + | 
|  | 79 | +```tsx | 
|  | 80 | +import { Inbox } from '@novu/react'; | 
|  | 81 | + | 
|  | 82 | +function InboxWithDefaultSchedule() { | 
|  | 83 | +  return ( | 
|  | 84 | +      <Inbox | 
|  | 85 | +        applicationIdentifier="YOUR_APP_IDENTIFIER" | 
|  | 86 | +        subscriberId="YOUR_SUBSCRIBER_ID" | 
|  | 87 | +        defaultSchedule={{ | 
|  | 88 | +          isEnabled: true, | 
|  | 89 | +          weeklySchedule: { | 
|  | 90 | +            tuesday: { | 
|  | 91 | +              isEnabled: true, | 
|  | 92 | +              hours: [{start: '09:00 AM', end: '07:00 PM'}] | 
|  | 93 | +            } | 
|  | 94 | +          } | 
|  | 95 | +        }} | 
|  | 96 | +      /> | 
|  | 97 | +  ); | 
|  | 98 | +} | 
|  | 99 | + | 
|  | 100 | +export default InboxWithDefaultSchedule; | 
|  | 101 | +``` | 
0 commit comments