Specifying Time Ranges in Policies for Visual Agents

This article covers how to use time ranges to specify sections of your policy that should be analyzed only at specific times of day. 
NOTE: The syntax and values of these policy time ranges differ from the Camio query parser's supported time range expressions.

Using Time Ranges

Add a time range to a policy by adding time range tags on the line that you want to restrict to certain times: <TIME_RANGE>{start_time} to {end_time}</TIME_RANGE>. The time range will apply only to that specific line of the policy.

For example, consider the following policy:

No people should be in the pool. <TIME_RANGE>8pm PST to 8am PST</TIME_RANGE>

No running by the pool.

In this example, "No people should be in the pool" will only be in affect from 8pm to 8am PST, while "No running by the pool" will be in affect 24x7. 

Note that the time range tags will be removed when the policy is processed, so it is not recommended to use the tags inside a sentence:

Input Line Processed Line
No people should be in the pool from <TIME_RANGE>8pm PST to 8am PST</TIME_RANGE>. No people should be in the pool from .
No people should be in the pool. <TIME_RANGE>8pm PST to 8am PST</TIME_RANGE> No people should be in the pool.

Time ranges only apply to the line that they are on, and do not apply to sub-bullets.

Input Processed Line at 1 PM Processed Line at 1 AM
  • After hours policy: <TIME_RANGE>8pm PST to 8am PST</TIME_RANGE>
    • No people should be in the pool.
    • No lights should be on.

 

  • No people should be in the pool.
  • No lights should be on.
  • After hours policy:
    • No people should be in the pool.
    • No lights should be on.
  • After hours policy: <TIME_RANGE>8pm PST to 8am PST</TIME_RANGE>
    • No people should be in the pool.  <TIME_RANGE>8pm PST to 8am PST</TIME_RANGE>
    • No lights should be on.  <TIME_RANGE>8pm PST to 8am PST</TIME_RANGE>
 
  • After hours policy:
    • No people should be in the pool.
    • No lights should be on.

Time Format

The following are valid formats for the start and end times. All times are considered to be UTC by default unless a timezone if specified. Please specify the intended timezone on both the start and the end time.

Valid Time Formats
10am
10AM
10 am
10 am PST
10:00am
10:00 -0700
13:00
1:00 pm

Timezones

Timezones should be specified on both the start and end time. Both timezone offsets and timezone abbreviations are accepted, but not timezone IDs.  Please see the supported timezone abbreviations and offsets.

Have more questions? Submit a request

Comments