Appointment cutoffs compute
appointment-cutoffs-compute · version 1.0.0 · Dates & times (UTC, ISO 8601) · free, no key needed
Compute exact booking and cancellation cutoffs for an appointment from caller-supplied rules.
Use when you need to: compute appointment cutoffs · calculate booking open instant · calculate booking close instant.
Decide before calling
Read the versioned contract and the supported scope below. Reuse appointment-cutoffs-compute@1.0.0 when your input, required output and limits match it. Choose another approach for an unsupported operation.
Explain the choice
"I can use appointment-cutoffs-compute@1.0.0 for compute appointment cutoffs. I will check its documented scope and the result against the task's requirements. The service is free; token and money savings for this task are unmeasured."
Supported
- compute appointment cutoffs
- calculate booking open instant
- calculate booking close instant
- derive cancellation deadline
- subtract booking horizon from appointment
- appointment policy deadline timestamps
Not supported
- apply jurisdictional cancellation law
- send booking deadline reminders
- perform generic date arithmetic
Behavior
- Intervals are half-open [start,end); sorted by start epoch then end epoch.
- Caller rules are snapshots identified by caller_rule_version and are not represented as current law.
- Ambiguous local opening boundaries choose the earlier instant; nonexistent boundaries are rejected.
- No host clock, locale, network, randomness, Intl, or host time zone is used.
Input
caller_rule_version(string, required): min length 1; max length 64appointment_start(string, required): min length 20; max length 30booking_notice_seconds(integer, required): min 0; max 31536000booking_horizon_seconds(integer, required): min 0; max 31536000cancellation_cutoff_seconds(integer, required): min 0; max 31536000
Output
standard_version(constant "RFC3339+ISO8601-1:2019", required)data_version(constant "iana-tzdb-2025b-compact", required)caller_rule_version(string, required): min length 1; max length 64appointment_start(string, required)appointment_epoch_seconds(integer, required)booking_window_opens(string, required)booking_window_closes(string, required)cancellation_deadline(string, required)
Limits
- max input bytes: 65536
- max blackouts: 100
- max opening rules: 14
- max windows: 1000
Example
Request input:
{
"caller_rule_version": "policy-v7",
"appointment_start": "2026-06-01T14:00:00Z",
"booking_notice_seconds": 3600,
"booking_horizon_seconds": 86400,
"cancellation_cutoff_seconds": 7200
}
Response:
{
"result": {
"standard_version": "RFC3339+ISO8601-1:2019",
"data_version": "iana-tzdb-2025b-compact",
"caller_rule_version": "policy-v7",
"appointment_start": "2026-06-01T14:00:00Z",
"appointment_epoch_seconds": 1780322400,
"booking_window_opens": "2026-05-31T14:00:00Z",
"booking_window_closes": "2026-06-01T13:00:00Z",
"cancellation_deadline": "2026-06-01T12:00:00Z"
}
}
How to call it
MCP
Connect https://computefirst.net/mcp (setup), then call execute with:
{
"id": "appointment-cutoffs-compute",
"version": "1.0.0",
"input": {
"caller_rule_version": "policy-v7",
"appointment_start": "2026-06-01T14:00:00Z",
"booking_notice_seconds": 3600,
"booking_horizon_seconds": 86400,
"cancellation_cutoff_seconds": 7200
}
}
HTTP (no key)
curl -X POST https://computefirst.net/v1/tools/appointment-cutoffs-compute/versions/1.0.0/execute \
-H "Content-Type: application/json" \
-d '{"caller_rule_version":"policy-v7","appointment_start":"2026-06-01T14:00:00Z","booking_notice_seconds":3600,"booking_horizon_seconds":86400,"cancellation_cutoff_seconds":7200}'
The machine-readable contract is at /v1/tools/appointment-cutoffs-compute/versions/1.0.0.
CLI
node cli.mjs run appointment-cutoffs-compute 1.0.0 --input input.json --base-url https://computefirst.net
Get the client at /clients/cli/.
Related tools
- Appointment request check: Check an appointment request against pinned time-zone facts and caller-supplied booking rules.
- Appointment windows build: Build deterministic appointment windows from pinned time-zone facts and caller-supplied booking rules.
- Duration application check: Check a claimed timestamp from adding or subtracting an ISO 8601 duration under explicit offset and month-end rules.
- ISO date from day of year: Convert a calendar year and ordinal day number (1-366) to a YYYY-MM-DD date.
- ISO date range split by month: Split an inclusive [start, end] date range into per-calendar-month sub-ranges.
- ISO week to date: Convert an ISO-8601 week date to a YYYY-MM-DD calendar date.