Skip to content

Calendars

Calendars contain events and generate iCal feed URLs. They can be org-level (shared) or owned by a specific agent.

Create an org-level calendar or an agent-owned calendar:

POST /v1/calendars
POST /v1/agents/:agent_id/calendars
FieldTypeRequiredDescription
namestringYes1–255 characters
timezonestringYesIANA timezone (e.g., America/New_York)
metadataobjectNoKey-value pairs, max 16KB JSON
Terminal window
curl -X POST https://api.chronary.ai/v1/agents/agt_a1b2c3d4/calendars \
-H "Authorization: Bearer chr_sk_test_your_key_here" \
-H "Content-Type: application/json" \
-d '{
"name": "Sales Meetings",
"timezone": "America/New_York"
}'
{
"id": "cal_x1y2z3",
"org_id": "org_abc",
"agent_id": "agt_a1b2c3d4",
"name": "Sales Meetings",
"timezone": "America/New_York",
"metadata": {},
"ical_url": "https://api.chronary.ai/ical/abc123def456.ics",
"created_at": "2026-04-04T12:00:00Z",
"updated_at": "2026-04-04T12:00:00Z"
}
StatusTypeCause
429quota_exceededCalendar limit reached on your plan

GET /v1/calendars
GET /v1/agents/:agent_id/calendars
ParameterTypeDefaultDescription
includestringSet to all to include agent-owned calendars (org-level endpoint only)
limitinteger501–200
offsetinteger0Pagination offset
Terminal window
# List all org calendars including agent-owned
curl "https://api.chronary.ai/v1/calendars?include=all" \
-H "Authorization: Bearer chr_sk_test_your_key_here"
# List calendars for a specific agent
curl "https://api.chronary.ai/v1/agents/agt_a1b2c3d4/calendars" \
-H "Authorization: Bearer chr_sk_test_your_key_here"
{
"data": [
{
"id": "cal_x1y2z3",
"name": "Sales Meetings",
"timezone": "America/New_York",
"ical_url": "https://api.chronary.ai/ical/abc123def456.ics",
...
}
],
"total": 5,
"limit": 50,
"offset": 0
}

GET /v1/calendars/:id
Terminal window
curl https://api.chronary.ai/v1/calendars/cal_x1y2z3 \
-H "Authorization: Bearer chr_sk_test_your_key_here"
StatusTypeCause
404not_foundCalendar not found

PATCH /v1/calendars/:id
FieldTypeDescription
namestring1–255 characters
timezonestringIANA timezone identifier
metadataobjectReplaces existing metadata

At least one field must be provided.

Terminal window
curl -X PATCH https://api.chronary.ai/v1/calendars/cal_x1y2z3 \
-H "Authorization: Bearer chr_sk_test_your_key_here" \
-H "Content-Type: application/json" \
-d '{ "name": "Sales Meetings (Q2)" }'
StatusTypeCause
404not_foundCalendar not found

DELETE /v1/calendars/:id

Returns 204 No Content. Deleting a calendar removes all its events.

Terminal window
curl -X DELETE https://api.chronary.ai/v1/calendars/cal_x1y2z3 \
-H "Authorization: Bearer chr_sk_test_your_key_here"
StatusTypeCause
404not_foundCalendar not found