Summary
Add a shared tool-runtime time context/advisory helper for tools whose side effects depend on the user's local time: email, calendars, agent mailbox, send/message tools, wait/scheduler/autonomy/watch tools, and future proactive tools.
This is the implementation fan-out from #17459. The policy direction is: surface time/contact-window facts to the agent and tool result; do not silently suppress, delay, or rewrite tool calls in the control plane.
Motivation
Quiet-hours enforcement in the control plane hides important runtime facts from the agent. For time-sensitive operations the agent should see:
- current time in the user's timezone
- configured/user timezone
- whether the action appears inside a normal contact window
- advisory text when it is outside that window
The agent can then decide whether to proceed, ask for confirmation, defer, or explain urgency.
Proposed shape
Add a small shared context/helper available to tool handlers, e.g.:
ToolRuntimeTimeContext(
now=<aware datetime>,
user_timezone="America/Los_Angeles",
contact_window=("08:00", "23:00"),
within_contact_window=True | False,
advisory="It is 02:14 in the user's timezone; this may be outside their normal contact window. Ask/consider deferring unless urgent.",
)
Tools can include the advisory in returned JSON/result text when relevant. For example:
{
"sent": false,
"time_context": {
"now": "2026-04-29T02:14:00-07:00",
"user_timezone": "America/Los_Angeles",
"contact_window": ["08:00", "23:00"],
"within_contact_window": false,
"advisory": "This is outside the user's normal contact window. Consider asking or deferring unless urgent."
}
}
Initial tool surface
Acceptance criteria
Related
Parent: #17459
Depends on/aligns with: #10421, #15872, #10061
Summary
Add a shared tool-runtime time context/advisory helper for tools whose side effects depend on the user's local time: email, calendars, agent mailbox, send/message tools, wait/scheduler/autonomy/watch tools, and future proactive tools.
This is the implementation fan-out from #17459. The policy direction is: surface time/contact-window facts to the agent and tool result; do not silently suppress, delay, or rewrite tool calls in the control plane.
Motivation
Quiet-hours enforcement in the control plane hides important runtime facts from the agent. For time-sensitive operations the agent should see:
The agent can then decide whether to proceed, ask for confirmation, defer, or explain urgency.
Proposed shape
Add a small shared context/helper available to tool handlers, e.g.:
Tools can include the advisory in returned JSON/result text when relevant. For example:
{ "sent": false, "time_context": { "now": "2026-04-29T02:14:00-07:00", "user_timezone": "America/Los_Angeles", "contact_window": ["08:00", "23:00"], "within_contact_window": false, "advisory": "This is outside the user's normal contact window. Consider asking or deferring unless urgent." } }Initial tool surface
Acceptance criteria
nowand configured user timezone consistently.Related
Parent: #17459
Depends on/aligns with: #10421, #15872, #10061