Out of Office Actions
Three workflow actions manage a HubSpot user’s out-of-office schedule:
| Action | What it does |
|---|---|
| Add User Out of Office | Adds an out-of-office period to a user’s schedule. |
| Clear User Out of Office | Removes all of a user’s out-of-office periods, or the ones in a date range. |
| Read User Out of Office Status | Checks whether a user will be out of office at a given time. |
They change the same schedule shown under Out of office on the user’s working hours page in HubSpot. Round Robin, Advanced Routing, Check Availability and Wait Until Available all use that schedule, so periods you add or clear here affect routing too.
Before you start
Section titled “Before you start”- Install Smart Lead & Ticket Routing in your HubSpot account.
- These actions are available in contact-based workflows.
- Times you choose are read in your HubSpot account’s default time zone. If the time zone can’t be read, UTC is used.
- The actions edit the user’s HubSpot profile directly. Anything else that uses their out-of-office schedule sees the change too.
Relative dates and times
Section titled “Relative dates and times”Add and Clear can use Relative Date/Time instead of fixed dates. You choose a weekday and a time for the start and the end:
- Start Date (Relative) is the next occurrence of that weekday after today. It is never today: choosing Monday on a Monday means next Monday.
- End Date (Relative) is the first occurrence of that weekday on or after the start day. Choosing the same weekday as the start means the same day.
- Start Time (Relative) and End Time (Relative) offer every half hour from 12:00 AM to 11:30 PM, plus 11:59 PM.
For example, with Friday at 5:00 PM to Monday at 9:00 AM, the period runs from the coming Friday evening to the following Monday morning.
Add User Out of Office
Section titled “Add User Out of Office”Adds a new out-of-office period to the user’s schedule. Existing periods are kept. The new period is titled Set by Smart Lead & Ticket Routing in HubSpot.
| Input | Options | Notes |
|---|---|---|
| User | Any HubSpot user | The person to mark as out of office. |
| Date Input Type | Static Date/Time or Relative Date/Time | Decides which date fields are shown. |
| Start Date (Static) and End Date (Static) | Date pickers | Shown for Static Date/Time. Both are required. |
| Start Date (Relative) and End Date (Relative) | Sunday to Saturday | Shown for Relative Date/Time. See Relative dates and times. |
| Start Time (Relative) and End Time (Relative) | Half-hour times | Shown for Relative Date/Time. All four relative fields are required. |
| Output | Meaning |
|---|---|
Success (success) | True when the period was added. |
Start Date (start_date) | When the new period starts, in UTC. |
End Date (end_date) | When the new period ends, in UTC. |
The action does not check for overlapping or duplicate periods. Running it twice for the same dates adds two periods. Make sure the end is after the start, particularly when the start and end use the same weekday.
Example: block a weekly team meeting
Section titled “Example: block a weekly team meeting”In a contact-based workflow that runs before the meeting each week, add Add User Out of Office with:
| Setting | Value |
|---|---|
| User | The rep |
| Date Input Type | Relative Date/Time |
| Start Date (Relative) | Monday |
| Start Time (Relative) | 9:00 AM |
| End Date (Relative) | Monday |
| End Time (Relative) | 11:00 AM |
Routing actions that check Is NOT Out of Office skip the rep during the meeting.
Clear User Out of Office
Section titled “Clear User Out of Office”Removes out-of-office periods from the user’s schedule.
| Input | Options | Notes |
|---|---|---|
| User | Any HubSpot user | The person whose schedule to clear. |
| Clear Type | Clear All, Clear Date Range or Relative Date/Time | Decides what is removed. |
| Start Date and End Date | Date pickers | Shown for Clear Date Range. The start must be before the end. |
| Start Date (Relative), Start Time (Relative), End Date (Relative), End Time (Relative) | Weekdays and half-hour times | Shown for Relative Date/Time. All four are required and the end must be after the start. |
| Clear Type | What is removed |
|---|---|
| Clear All | Every out-of-office period on the user’s schedule, including ones they added themselves in HubSpot. |
| Clear Date Range | Every period that overlaps the range. |
| Relative Date/Time | Every period that overlaps the relative range. |
Overlapping periods are removed entirely, not shortened. A two-week holiday that overlaps a one-day range is removed completely. Periods that only touch the start or end of the range are kept.
| Output | Meaning |
|---|---|
Success (success) | True when the schedule was updated. |
Example: cancel leave when a request is withdrawn
Section titled “Example: cancel leave when a request is withdrawn”If a leave request is withdrawn, add Clear User Out of Office with Clear Type set to Clear Date Range and the dates of the original request. The user becomes eligible for routing again for those dates.
Read User Out of Office Status
Section titled “Read User Out of Office Status”Checks whether the user will be out of office at a chosen time. It does not change anything. To check the user’s current status for routing, use Check Availability instead.
| Input | Options | Notes |
|---|---|---|
| User | Any HubSpot user | The person to check. |
| Time Type | Specific Date & Time or Weekly Recurring Time | Decides which time fields are shown. |
| Specific Date & Time | Date picker | Shown for Specific Date & Time. |
| Day of Week | Sunday to Saturday | Shown for Weekly Recurring Time. |
| Time of Day | Half-hour times | Shown for Weekly Recurring Time. |
Weekly Recurring Time checks the next occurrence of that day and time in your account’s time zone. Unlike the relative dates in Add and Clear, this can be later today if the time hasn’t passed yet.
The user counts as out of office if the check time falls inside any of their out-of-office periods, including the exact start and end. If the user has no out-of-office periods stored, the action uses HubSpot’s current out-of-office flag for them.
| Output | Meaning |
|---|---|
Will be out of Office? (is_out_of_office) | True when the user is out of office at the check time. |
DateTime Checked (resolved_check_time) | The exact time that was checked, in UTC. |
Example: check before booking a Monday call
Section titled “Example: check before booking a Monday call”Before creating a Monday 9:00 AM follow-up for a rep, add Read User Out of Office Status with Time Type set to Weekly Recurring Time, Day of Week set to Monday and Time of Day set to 9:00 AM. Branch on Will be out of Office? and assign the follow-up to someone else when it is true.
Troubleshooting
Section titled “Troubleshooting”The action isn’t in the workflow action list. These actions are only available in contact-based workflows.
The action failed straight away. A required field for the chosen type is missing, a date is invalid, or the start is not before the end. Check the workflow history for the message.
The times are a few hours out. Relative and weekly times use your HubSpot account’s default time zone. Check it in HubSpot’s Account Defaults settings.
Clearing a range removed a longer holiday. Any period that overlaps the range is removed in full. Add the remaining part back with Add User Out of Office.
Success is false. The action couldn’t read or update the user’s schedule. Check the workflow history for the error.
Related guides
Section titled “Related guides”- Round Robin Action - skip users who are out of office in a rotation.
- Check Availability - check a person, team or record owner’s current status.
- Wait Until Available - pause until somebody is back.
- All routing action guides - choose the action for your workflow.