Aller au contenu principal
Was this helpful?

PrimeCal Reservations Availability v2

primecal_reservations_availability_list_v2 returns reservation slots in canonical UTC while preserving the caller's logical timezone in a top-level timezone field.

Request Parameters

FieldTypeRequiredNotes
resourceTypeIdnumberYesScoped resource type to evaluate.
resourceIdnumberNoLimits the result to one concrete resource.
datestringNoLocal-day alias in YYYY-MM-DD format.
fromstringNoISO 8601 timestamp. Required when date is omitted.
tostringNoISO 8601 timestamp. Defaults to from + 1 day.
userTimezonestringNoOptional IANA timezone override for logical slot generation.

Timezone Rules

  • Response timestamps always end in Z.
  • Every response includes timezone.
  • userTimezone changes logical day boundaries and slot generation only.
  • When date is used, PrimeCal expands that local day in the requested logical timezone and then returns the resulting UTC slot timestamps.

Example Any-Resource Request

{
"resourceTypeId": 13,
"from": "2032-04-20T00:00:00.000Z",
"to": "2032-04-21T00:00:00.000Z",
"userTimezone": "Europe/Budapest"
}

Example Response

{
"organisation": {
"id": 9,
"name": "North Clinic",
"slug": "north-clinic",
"color": "#0ea5e9"
},
"resourceType": {
"id": 13,
"name": "Consultation Room"
},
"mode": "any",
"timezone": "Europe/Budapest",
"from": "2032-04-20T00:00:00.000Z",
"to": "2032-04-21T00:00:00.000Z",
"resources": [{ "id": 40, "name": "Room A", "capacity": 1 }],
"slots": [
{
"startTime": "2032-04-20T07:00:00.000Z",
"endTime": "2032-04-20T07:30:00.000Z",
"available": true,
"availableQuantity": 1,
"resourceIds": [40]
}
]
}

DST Guidance

  • Prefer userTimezone for local-day reasoning around DST boundaries.
  • PrimeCal computes slot boundaries in the logical timezone first, then converts them to UTC.
  • Clients should not add or subtract offsets manually.

Screenshot Placeholder

TODO: add Chrome MCP screenshot of a reservation availability response and the corresponding UI under docs/assets/agents/.