@chronary/toolkit 1.7.1 → 1.7.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +12 -0
- package/dist/ai-sdk.cjs +60 -55
- package/dist/ai-sdk.cjs.map +1 -1
- package/dist/ai-sdk.js +60 -55
- package/dist/ai-sdk.js.map +1 -1
- package/dist/index.cjs +60 -55
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +30 -4
- package/dist/index.d.ts +30 -4
- package/dist/index.js +60 -55
- package/dist/index.js.map +1 -1
- package/dist/langchain.cjs +60 -55
- package/dist/langchain.cjs.map +1 -1
- package/dist/langchain.js +60 -55
- package/dist/langchain.js.map +1 -1
- package/dist/mastra.cjs +60 -55
- package/dist/mastra.cjs.map +1 -1
- package/dist/mastra.js +60 -55
- package/dist/mastra.js.map +1 -1
- package/dist/mcp.cjs +62 -57
- package/dist/mcp.cjs.map +1 -1
- package/dist/mcp.js +62 -57
- package/dist/mcp.js.map +1 -1
- package/dist/openai.cjs +60 -55
- package/dist/openai.cjs.map +1 -1
- package/dist/openai.js +60 -55
- package/dist/openai.js.map +1 -1
- package/package.json +3 -3
package/dist/index.cjs
CHANGED
|
@@ -223,6 +223,20 @@ var UpdateCalendarSchema = import_zod.z.object({
|
|
|
223
223
|
var DeleteCalendarSchema = import_zod.z.object({
|
|
224
224
|
calendar_id: import_zod.z.string().describe("Calendar ID to delete")
|
|
225
225
|
});
|
|
226
|
+
var timeOfDay = import_zod.z.string().regex(/^([01]\d|2[0-3]):[0-5]\d$/, "must be HH:MM in 24-hour time");
|
|
227
|
+
var workingHoursDaySchema = import_zod.z.object({
|
|
228
|
+
start: timeOfDay.describe('Start of the working window, HH:MM 24-hour, in the timezone of the availability rules or booking page it belongs to (e.g. "09:00")'),
|
|
229
|
+
end: timeOfDay.describe('End of the working window, HH:MM 24-hour, after start (e.g. "17:00")')
|
|
230
|
+
}).refine((v) => v.end > v.start, "end must be after start").describe("A single day's working hours window");
|
|
231
|
+
var workingHoursSchema = import_zod.z.object({
|
|
232
|
+
mon: workingHoursDaySchema.optional(),
|
|
233
|
+
tue: workingHoursDaySchema.optional(),
|
|
234
|
+
wed: workingHoursDaySchema.optional(),
|
|
235
|
+
thu: workingHoursDaySchema.optional(),
|
|
236
|
+
fri: workingHoursDaySchema.optional(),
|
|
237
|
+
sat: workingHoursDaySchema.optional(),
|
|
238
|
+
sun: workingHoursDaySchema.optional()
|
|
239
|
+
}).refine((v) => Object.keys(v).length > 0, "at least one day must be specified").nullable();
|
|
226
240
|
var ListBookingPagesSchema = import_zod.z.object({
|
|
227
241
|
limit: import_zod.z.number().int().min(1).max(200).default(50).describe("Max results to return"),
|
|
228
242
|
offset: import_zod.z.number().int().min(0).default(0).describe("Pagination offset, at most 10000")
|
|
@@ -231,7 +245,7 @@ var GetBookingPageSchema = import_zod.z.object({
|
|
|
231
245
|
booking_page_id: import_zod.z.string().describe("Booking page ID to fetch (bkp_...)")
|
|
232
246
|
});
|
|
233
247
|
var CreateBookingPageSchema = import_zod.z.object({
|
|
234
|
-
calendar_id: import_zod.z.string().describe("Calendar a booking resolves to
|
|
248
|
+
calendar_id: import_zod.z.string().describe("Calendar ID a booking resolves to."),
|
|
235
249
|
title: import_zod.z.string().min(1).max(200).describe("Meeting title shown on the page."),
|
|
236
250
|
description: import_zod.z.string().max(2e3).optional().describe("Optional description shown to the booker."),
|
|
237
251
|
duration_minutes: import_zod.z.number().int().min(5).max(480).optional().describe("Slot length in minutes (default 30)."),
|
|
@@ -239,7 +253,8 @@ var CreateBookingPageSchema = import_zod.z.object({
|
|
|
239
253
|
window_days: import_zod.z.number().int().min(1).max(365).optional().describe("How far ahead bookings are allowed (default 14)."),
|
|
240
254
|
min_notice_minutes: import_zod.z.number().int().min(0).max(40320).optional().describe("Minimum lead time before a bookable slot (default 0)."),
|
|
241
255
|
timezone: import_zod.z.string().min(1).max(64).optional().describe("IANA timezone for display + working hours (default UTC)."),
|
|
242
|
-
|
|
256
|
+
// Same shape the hosted API validates (#2525).
|
|
257
|
+
availability_constraints: workingHoursSchema.optional().describe('Weekly working hours keyed by day (mon, tue, wed, thu, fri, sat, sun; a day left out takes no bookings), each {"start":"HH:MM","end":"HH:MM"} in 24-hour time with end after start, e.g. {"mon":{"start":"09:00","end":"17:00"}}. Omit/null for any time in the window.'),
|
|
243
258
|
active: import_zod.z.boolean().optional().describe("Whether the page accepts bookings (default true).")
|
|
244
259
|
});
|
|
245
260
|
var DeleteBookingPageSchema = import_zod.z.object({
|
|
@@ -302,7 +317,7 @@ var UpdateEventSchema = import_zod.z.object({
|
|
|
302
317
|
});
|
|
303
318
|
var CancelEventSchema = import_zod.z.object({
|
|
304
319
|
event_id: import_zod.z.string().describe("Event ID to cancel"),
|
|
305
|
-
calendar_id: import_zod.z.string().optional().describe("Calendar ID that owns the event. Optional \u2014 if omitted the calendar is resolved from the event.
|
|
320
|
+
calendar_id: import_zod.z.string().optional().describe("Calendar ID that owns the event. Optional \u2014 if omitted the calendar is resolved from the event."),
|
|
306
321
|
occurrence_start: import_zod.z.string().datetime({ offset: true }).optional().describe("For recurring events only: ISO 8601 start of the single occurrence to cancel. The rest of the series is unaffected.")
|
|
307
322
|
});
|
|
308
323
|
var ConfirmEventSchema = import_zod.z.object({
|
|
@@ -374,7 +389,11 @@ var proposalSlotSchema = import_zod.z.object({
|
|
|
374
389
|
end_time: import_zod.z.string().datetime({ offset: true }).describe("Slot end time (ISO 8601), after start_time"),
|
|
375
390
|
weight: import_zod.z.number().min(0).max(10).default(1).optional().describe("Preference for this slot, 0\u201310 (higher = more preferred). Used to rank candidate slots when the proposal is resolved. Defaults to 1."),
|
|
376
391
|
calendar_id: import_zod.z.string().optional().describe("Calendar to create the event on if this slot is chosen. Defaults to the proposal's top-level calendar_id.")
|
|
377
|
-
})
|
|
392
|
+
}).refine(
|
|
393
|
+
// Same rule as the API (#2538): a slot must end after it starts.
|
|
394
|
+
(v) => new Date(v.end_time).getTime() > new Date(v.start_time).getTime(),
|
|
395
|
+
"end_time must be after start_time"
|
|
396
|
+
);
|
|
378
397
|
var CreateProposalSchema = import_zod.z.object({
|
|
379
398
|
title: import_zod.z.string().min(1).max(500).describe("Short description of what the meeting is about"),
|
|
380
399
|
description: import_zod.z.string().max(5e3).optional().describe("Longer context/agenda"),
|
|
@@ -407,20 +426,6 @@ var ResolveProposalSchema = import_zod.z.object({
|
|
|
407
426
|
var CancelProposalSchema = import_zod.z.object({
|
|
408
427
|
proposal_id: import_zod.z.string().describe("Proposal to cancel")
|
|
409
428
|
});
|
|
410
|
-
var timeOfDay = import_zod.z.string().regex(/^([01]\d|2[0-3]):[0-5]\d$/, "must be HH:MM in 24-hour time");
|
|
411
|
-
var workingHoursDaySchema = import_zod.z.object({
|
|
412
|
-
start: timeOfDay.describe('Start of the working window, HH:MM 24-hour, in the rules timezone (e.g. "09:00")'),
|
|
413
|
-
end: timeOfDay.describe('End of the working window, HH:MM 24-hour, after start (e.g. "17:00")')
|
|
414
|
-
}).refine((v) => v.end > v.start, "end must be after start").describe("A single day's working hours window");
|
|
415
|
-
var workingHoursSchema = import_zod.z.object({
|
|
416
|
-
mon: workingHoursDaySchema.optional(),
|
|
417
|
-
tue: workingHoursDaySchema.optional(),
|
|
418
|
-
wed: workingHoursDaySchema.optional(),
|
|
419
|
-
thu: workingHoursDaySchema.optional(),
|
|
420
|
-
fri: workingHoursDaySchema.optional(),
|
|
421
|
-
sat: workingHoursDaySchema.optional(),
|
|
422
|
-
sun: workingHoursDaySchema.optional()
|
|
423
|
-
}).refine((v) => Object.keys(v).length > 0, "at least one day must be specified").nullable();
|
|
424
429
|
var SetAvailabilityRulesSchema = import_zod.z.object({
|
|
425
430
|
calendar_id: import_zod.z.string().describe("Calendar to configure"),
|
|
426
431
|
buffer_before_minutes: import_zod.z.number().int().min(0).max(120).default(0).describe("Minutes of buffer before each event (0\u2013120)"),
|
|
@@ -495,7 +500,7 @@ var ListWebhookDeliveriesSchema = import_zod.z.object({
|
|
|
495
500
|
});
|
|
496
501
|
var GetWebhookDeliverySchema = import_zod.z.object({
|
|
497
502
|
webhook_id: import_zod.z.string().describe("Webhook subscription the delivery belongs to"),
|
|
498
|
-
delivery_id: import_zod.z.string().describe("Delivery ID (whd_...)
|
|
503
|
+
delivery_id: import_zod.z.string().describe("Delivery ID (whd_...)")
|
|
499
504
|
});
|
|
500
505
|
var SendTestWebhookSchema = import_zod.z.object({
|
|
501
506
|
webhook_id: import_zod.z.string().describe("Webhook subscription to send the test event to"),
|
|
@@ -1019,14 +1024,14 @@ var RAW_TOOL_DEFINITIONS = [
|
|
|
1019
1024
|
name: "create_calendar",
|
|
1020
1025
|
description: 'Create a calendar to hold events and track availability. Calendars are required before creating events \u2014 call this first when setting up a new agent. An agent can have multiple calendars (e.g. "Work", "Personal"). Org-level calendars (no agent_id) can be used as shared resources like meeting rooms.',
|
|
1021
1026
|
schema: CreateCalendarSchema,
|
|
1022
|
-
annotations: { title: "Create Calendar", readOnlyHint: false, destructiveHint:
|
|
1027
|
+
annotations: { title: "Create Calendar", readOnlyHint: false, destructiveHint: true, idempotentHint: false, openWorldHint: false },
|
|
1023
1028
|
execute: createExecutor(createCalendar)
|
|
1024
1029
|
},
|
|
1025
1030
|
{
|
|
1026
1031
|
name: "update_calendar",
|
|
1027
1032
|
description: "Update a calendar's name, timezone, agent status, default reminders, or metadata. Agent keys may only update calendars owned by their agent.",
|
|
1028
1033
|
schema: UpdateCalendarSchema,
|
|
1029
|
-
annotations: { title: "Update Calendar", readOnlyHint: false, destructiveHint:
|
|
1034
|
+
annotations: { title: "Update Calendar", readOnlyHint: false, destructiveHint: true, idempotentHint: true, openWorldHint: false },
|
|
1030
1035
|
execute: createExecutor(updateCalendar)
|
|
1031
1036
|
},
|
|
1032
1037
|
{
|
|
@@ -1041,7 +1046,7 @@ var RAW_TOOL_DEFINITIONS = [
|
|
|
1041
1046
|
name: "create_booking_page",
|
|
1042
1047
|
description: "Create a public booking page (a hosted scheduling link) for a calendar. Returns a booking_url to send to a human; when they pick a slot, a confirmed event is created on the calendar and an event.created webhook fires with a booking_page_id field. Set availability_constraints to restrict to weekly working hours; existing calendar events always block slots.",
|
|
1043
1048
|
schema: CreateBookingPageSchema,
|
|
1044
|
-
annotations: { title: "Create Booking Page", readOnlyHint: false, destructiveHint:
|
|
1049
|
+
annotations: { title: "Create Booking Page", readOnlyHint: false, destructiveHint: true, idempotentHint: false, openWorldHint: false },
|
|
1045
1050
|
execute: createExecutor(createBookingPage)
|
|
1046
1051
|
},
|
|
1047
1052
|
{
|
|
@@ -1076,7 +1081,7 @@ var RAW_TOOL_DEFINITIONS = [
|
|
|
1076
1081
|
},
|
|
1077
1082
|
{
|
|
1078
1083
|
name: "list_org_events",
|
|
1079
|
-
description: "List events across all of the organization's calendars in one call, ordered by start time (an Agent key sees only its agent's calendars). Narrow with `calendar_ids`, `agent_id`, a `start_after`/`start_before` window, `status` and `source`. `q` searches titles (case-insensitive) and needs both window bounds at most 31 days apart.
|
|
1084
|
+
description: "List events across all of the organization's calendars in one call, ordered by start time (an Agent key sees only its agent's calendars). Narrow with `calendar_ids`, `agent_id`, a `start_after`/`start_before` window, `status` and `source`. `q` searches titles (case-insensitive) and needs both window bounds at most 31 days apart. Page with the returned next_cursor.",
|
|
1080
1085
|
schema: ListOrgEventsSchema,
|
|
1081
1086
|
annotations: { title: "List Organization Events", readOnlyHint: true, destructiveHint: false, idempotentHint: true, openWorldHint: false },
|
|
1082
1087
|
untrustedFields: EVENT_UNTRUSTED_FIELDS,
|
|
@@ -1092,16 +1097,16 @@ var RAW_TOOL_DEFINITIONS = [
|
|
|
1092
1097
|
},
|
|
1093
1098
|
{
|
|
1094
1099
|
name: "create_event",
|
|
1095
|
-
description: `Create a booking, appointment, meeting, hold, or any scheduled event on a calendar.
|
|
1100
|
+
description: `Create a booking, appointment, meeting, hold, or any scheduled event on a calendar. Once created, this event blocks the agent's availability during that time and appears in availability queries. Use status="hold" with hold_expires_at to tentatively reserve a slot that auto-releases on TTL.`,
|
|
1096
1101
|
schema: CreateEventSchema,
|
|
1097
|
-
annotations: { title: "Create Event", readOnlyHint: false, destructiveHint:
|
|
1102
|
+
annotations: { title: "Create Event", readOnlyHint: false, destructiveHint: true, idempotentHint: false, openWorldHint: false },
|
|
1098
1103
|
execute: createExecutor(createEvent)
|
|
1099
1104
|
},
|
|
1100
1105
|
{
|
|
1101
1106
|
name: "update_event",
|
|
1102
|
-
description: "Reschedule or edit an event \u2014 change its title, description, start/end times, location, status, reminders, or metadata. Use this to move an appointment to a new time or update its details. Provide only the fields you want to change. Holds cannot be edited
|
|
1107
|
+
description: "Reschedule or edit an event \u2014 change its title, description, start/end times, location, status, reminders, or metadata. Use this to move an appointment to a new time or update its details. Provide only the fields you want to change. Holds cannot be edited; confirm or release them instead. External iCal events are read-only. `calendar_id` is optional \u2014 if omitted it is resolved from the event.",
|
|
1103
1108
|
schema: UpdateEventSchema,
|
|
1104
|
-
annotations: { title: "Update Event", readOnlyHint: false, destructiveHint:
|
|
1109
|
+
annotations: { title: "Update Event", readOnlyHint: false, destructiveHint: true, idempotentHint: true, openWorldHint: false },
|
|
1105
1110
|
untrustedFields: EVENT_UNTRUSTED_FIELDS,
|
|
1106
1111
|
execute: createExecutor(updateEvent)
|
|
1107
1112
|
},
|
|
@@ -1117,7 +1122,7 @@ var RAW_TOOL_DEFINITIONS = [
|
|
|
1117
1122
|
name: "confirm_event",
|
|
1118
1123
|
description: 'Promote a held event to a confirmed booking. The event must currently have status="hold" and its hold_expires_at must not have passed. After confirmation, event.started and event.ended lifecycle webhooks fire at the scheduled times.',
|
|
1119
1124
|
schema: ConfirmEventSchema,
|
|
1120
|
-
annotations: { title: "Confirm Event", readOnlyHint: false, destructiveHint:
|
|
1125
|
+
annotations: { title: "Confirm Event", readOnlyHint: false, destructiveHint: true, idempotentHint: true, openWorldHint: false },
|
|
1121
1126
|
untrustedFields: EVENT_UNTRUSTED_FIELDS,
|
|
1122
1127
|
execute: createExecutor(confirmEvent)
|
|
1123
1128
|
},
|
|
@@ -1133,7 +1138,7 @@ var RAW_TOOL_DEFINITIONS = [
|
|
|
1133
1138
|
name: "create_agent",
|
|
1134
1139
|
description: "Register your agent (AI assistant, human participant, or resource) with Chronary so it can own calendars, events, and webhooks.",
|
|
1135
1140
|
schema: CreateAgentSchema,
|
|
1136
|
-
annotations: { title: "Create Agent", readOnlyHint: false, destructiveHint:
|
|
1141
|
+
annotations: { title: "Create Agent", readOnlyHint: false, destructiveHint: true, idempotentHint: false, openWorldHint: false },
|
|
1137
1142
|
execute: createExecutor(createAgent)
|
|
1138
1143
|
},
|
|
1139
1144
|
{
|
|
@@ -1152,14 +1157,14 @@ var RAW_TOOL_DEFINITIONS = [
|
|
|
1152
1157
|
},
|
|
1153
1158
|
{
|
|
1154
1159
|
name: "update_agent",
|
|
1155
|
-
description: "Update an agent's name, description, metadata, or status (active/paused). Requires an Organization key \u2014 Agent keys cannot mutate agents.",
|
|
1160
|
+
description: "Update an agent's name, description, metadata, or status (active/paused). Setting status on a decommissioned agent restores it and makes its calendars writable again; that is refused with quota_exceeded when the agent, its calendars or their recurring series would put the organization over the plan's agent, calendar or recurring series limit. Requires an Organization key \u2014 Agent keys cannot mutate agents.",
|
|
1156
1161
|
schema: UpdateAgentSchema,
|
|
1157
|
-
annotations: { title: "Update Agent", readOnlyHint: false, destructiveHint:
|
|
1162
|
+
annotations: { title: "Update Agent", readOnlyHint: false, destructiveHint: true, idempotentHint: true, openWorldHint: false },
|
|
1158
1163
|
execute: createExecutor(updateAgent)
|
|
1159
1164
|
},
|
|
1160
1165
|
{
|
|
1161
1166
|
name: "delete_agent",
|
|
1162
|
-
description: "Decommission an agent. This marks the agent as decommissioned and revokes all of its Agent keys. Requires an Organization key \u2014 Agent keys cannot delete agents.",
|
|
1167
|
+
description: "Decommission an agent. This marks the agent as decommissioned and revokes all of its Agent keys. Its calendars and events are kept but stop counting toward the plan's calendar limit, and they are read-only (writes return agent_inactive) until the agent is restored by setting its status again (active or paused). Requires an Organization key \u2014 Agent keys cannot delete agents.",
|
|
1163
1168
|
schema: DeleteAgentSchema,
|
|
1164
1169
|
annotations: { title: "Delete Agent", readOnlyHint: false, destructiveHint: true, idempotentHint: true, openWorldHint: false },
|
|
1165
1170
|
execute: createExecutor(deleteAgent)
|
|
@@ -1183,7 +1188,7 @@ var RAW_TOOL_DEFINITIONS = [
|
|
|
1183
1188
|
name: "create_connection_link",
|
|
1184
1189
|
description: "Request human setup of Google Calendar or Microsoft Outlook for a Chronary calendar. Give setup_url to a human; the agent never receives OAuth credentials, provider calendar names, or event data. When the human finishes, the linked account becomes a Connection, listed under Human calendars in the Chronary console. The secret URL is returned only on first creation. If reused=true and setup_url is null, retain the original URL or cancel this link and create a replacement.",
|
|
1185
1190
|
schema: CreateConnectionLinkSchema,
|
|
1186
|
-
annotations: { title: "Create Human Calendar Setup Link", readOnlyHint: false, destructiveHint:
|
|
1191
|
+
annotations: { title: "Create Human Calendar Setup Link", readOnlyHint: false, destructiveHint: true, idempotentHint: false, openWorldHint: true },
|
|
1187
1192
|
execute: createExecutor(createConnectionLink)
|
|
1188
1193
|
},
|
|
1189
1194
|
{
|
|
@@ -1203,7 +1208,7 @@ var RAW_TOOL_DEFINITIONS = [
|
|
|
1203
1208
|
// ── Calendar context ───────────────────────────────────────────
|
|
1204
1209
|
{
|
|
1205
1210
|
name: "get_calendar_context",
|
|
1206
|
-
description: `Get a calendar's temporal context in a single call: the current event (if one is happening now), the next upcoming event, recent past events, a short upcoming window, and the owning agent's status (idle/working/waiting/error). Use this to answer "what is this agent doing right now?" without
|
|
1211
|
+
description: `Get a calendar's temporal context in a single call: the current event (if one is happening now), the next upcoming event, recent past events, a short upcoming window, and the owning agent's status (idle/working/waiting/error). Use this to answer "what is this agent doing right now?" without listing events separately. Recurring series appear as their occurrences (with recurringEventId); when events overlap, the current event is the most recently started.`,
|
|
1207
1212
|
schema: GetCalendarContextSchema,
|
|
1208
1213
|
annotations: { title: "Get Calendar Context", readOnlyHint: true, destructiveHint: false, idempotentHint: true, openWorldHint: false },
|
|
1209
1214
|
untrustedFields: EVENT_UNTRUSTED_FIELDS,
|
|
@@ -1214,7 +1219,7 @@ var RAW_TOOL_DEFINITIONS = [
|
|
|
1214
1219
|
name: "create_proposal",
|
|
1215
1220
|
description: "Create a scheduling proposal \u2014 send a set of candidate time slots to one or more participant agents so they can accept, decline, or counter-propose. The organizer agent owns the proposal; once every participant responds, the system auto-resolves to the highest-scoring slot (or cancels if all decline). Requires an Organization key and a Developer or Pro plan.",
|
|
1216
1221
|
schema: CreateProposalSchema,
|
|
1217
|
-
annotations: { title: "Create Proposal", readOnlyHint: false, destructiveHint:
|
|
1222
|
+
annotations: { title: "Create Proposal", readOnlyHint: false, destructiveHint: true, idempotentHint: false, openWorldHint: false },
|
|
1218
1223
|
execute: createExecutor(createProposal)
|
|
1219
1224
|
},
|
|
1220
1225
|
{
|
|
@@ -1233,16 +1238,16 @@ var RAW_TOOL_DEFINITIONS = [
|
|
|
1233
1238
|
},
|
|
1234
1239
|
{
|
|
1235
1240
|
name: "respond_to_proposal",
|
|
1236
|
-
description: 'Submit a response (accept / decline / counter) on behalf of one participant agent to an open proposal. An "accept" requires the slot id from the proposal; a "counter" can suggest alternative slots. When all participants have responded the proposal auto-resolves \u2014 no separate resolve call needed in the normal flow. Requires an Organization key and a Developer or Pro plan.',
|
|
1241
|
+
description: 'Submit a response (accept / decline / counter) on behalf of one participant agent to an open proposal. An "accept" requires the slot id from the proposal; a "counter" can suggest alternative slots. When all participants have responded the proposal auto-resolves \u2014 no separate resolve call needed in the normal flow. The result is the saved response plus auto_resolved (confirmed / cancelled / null) and auto_resolve_error: if the auto-resolve fails, the response is still saved and auto_resolve_error says what to do next (usually: resolve the proposal once the cause is fixed). Do not respond again. Requires an Organization key and a Developer or Pro plan.',
|
|
1237
1242
|
schema: RespondToProposalSchema,
|
|
1238
|
-
annotations: { title: "Respond To Proposal", readOnlyHint: false, destructiveHint:
|
|
1243
|
+
annotations: { title: "Respond To Proposal", readOnlyHint: false, destructiveHint: true, idempotentHint: false, openWorldHint: false },
|
|
1239
1244
|
execute: createExecutor(respondToProposal)
|
|
1240
1245
|
},
|
|
1241
1246
|
{
|
|
1242
1247
|
name: "resolve_proposal",
|
|
1243
1248
|
description: 'Force-resolve an open proposal using responses collected so far. Picks the highest-scoring slot among those accepted by the most participants and creates a confirmed calendar event. If every response was "decline", the proposal is cancelled instead. Use when you want to close out a proposal without waiting for every participant. Requires an Organization key and a Developer or Pro plan.',
|
|
1244
1249
|
schema: ResolveProposalSchema,
|
|
1245
|
-
annotations: { title: "Resolve Proposal", readOnlyHint: false, destructiveHint:
|
|
1250
|
+
annotations: { title: "Resolve Proposal", readOnlyHint: false, destructiveHint: true, idempotentHint: true, openWorldHint: false },
|
|
1246
1251
|
execute: createExecutor(resolveProposal)
|
|
1247
1252
|
},
|
|
1248
1253
|
{
|
|
@@ -1257,7 +1262,7 @@ var RAW_TOOL_DEFINITIONS = [
|
|
|
1257
1262
|
name: "set_availability_rules",
|
|
1258
1263
|
description: "Set or replace the availability rules on a calendar \u2014 buffer times before/after events and optional per-day working hours. When these rules are set, every availability query on this calendar automatically applies them (busy-block expansion for buffers, masking outside working hours). Upsert: overwrites any existing rules.",
|
|
1259
1264
|
schema: SetAvailabilityRulesSchema,
|
|
1260
|
-
annotations: { title: "Set Availability Rules", readOnlyHint: false, destructiveHint:
|
|
1265
|
+
annotations: { title: "Set Availability Rules", readOnlyHint: false, destructiveHint: true, idempotentHint: true, openWorldHint: false },
|
|
1261
1266
|
execute: createExecutor(setAvailabilityRules)
|
|
1262
1267
|
},
|
|
1263
1268
|
{
|
|
@@ -1293,7 +1298,7 @@ var RAW_TOOL_DEFINITIONS = [
|
|
|
1293
1298
|
name: "create_webhook",
|
|
1294
1299
|
description: "Create a webhook subscription so the org receives HTTP POST notifications when events occur (e.g. event.created, proposal.confirmed). The signing secret is returned ONCE in this response \u2014 store it to verify the HMAC-SHA256 signature on delivered payloads. Requires an Organization key.",
|
|
1295
1300
|
schema: CreateWebhookSchema,
|
|
1296
|
-
annotations: { title: "Create Webhook", readOnlyHint: false, destructiveHint:
|
|
1301
|
+
annotations: { title: "Create Webhook", readOnlyHint: false, destructiveHint: true, idempotentHint: false, openWorldHint: true },
|
|
1297
1302
|
execute: createExecutor(createWebhook)
|
|
1298
1303
|
},
|
|
1299
1304
|
{
|
|
@@ -1328,16 +1333,16 @@ var RAW_TOOL_DEFINITIONS = [
|
|
|
1328
1333
|
},
|
|
1329
1334
|
{
|
|
1330
1335
|
name: "send_test_webhook",
|
|
1331
|
-
description: "Send a signed sample payload of one event type to a webhook endpoint, to check that it receives and verifies deliveries. The delivery is marked is_test, carries the X-Chronary-Test: 1 header, makes one attempt, does not count toward the monthly delivery quota and is sent even when the endpoint is paused or disabled. The endpoint must subscribe to the event type.
|
|
1336
|
+
description: "Send a signed sample payload of one event type to a webhook endpoint, to check that it receives and verifies deliveries. The delivery is marked is_test, carries the X-Chronary-Test: 1 header, makes one attempt, does not count toward the monthly delivery quota and is sent even when the endpoint is paused or disabled. The endpoint must subscribe to the event type. The outcome is recorded on the returned delivery_id. Limited to 10 per minute. Requires an Organization key.",
|
|
1332
1337
|
schema: SendTestWebhookSchema,
|
|
1333
|
-
annotations: { title: "Send Test Webhook", readOnlyHint: false, destructiveHint:
|
|
1338
|
+
annotations: { title: "Send Test Webhook", readOnlyHint: false, destructiveHint: true, idempotentHint: false, openWorldHint: true },
|
|
1334
1339
|
execute: createExecutor(sendTestWebhook)
|
|
1335
1340
|
},
|
|
1336
1341
|
{
|
|
1337
1342
|
name: "replay_webhook_delivery",
|
|
1338
|
-
description: "Send a failed or dropped webhook delivery again, as a new delivery with a new delivery_id. The stored payload goes out unchanged (same event id), signed with the endpoint's current secret, with an X-Chronary-Replay-Of header naming the original delivery. Only failed or dropped deliveries that are not test events can be replayed, the endpoint must be active, and the payload must still be stored (30 days). The replay follows the normal retry schedule and counts toward the monthly delivery quota.
|
|
1343
|
+
description: "Send a failed or dropped webhook delivery again, as a new delivery with a new delivery_id. The stored payload goes out unchanged (same event id), signed with the endpoint's current secret, with an X-Chronary-Replay-Of header naming the original delivery. Only failed or dropped deliveries that are not test events can be replayed, the endpoint must be active, and the payload must still be stored (30 days). The replay follows the normal retry schedule and counts toward the monthly delivery quota. The outcome is recorded on the returned delivery_id. Limited to 30 per minute. Requires a Developer or Pro plan and an Organization key.",
|
|
1339
1344
|
schema: ReplayWebhookDeliverySchema,
|
|
1340
|
-
annotations: { title: "Replay Webhook Delivery", readOnlyHint: false, destructiveHint:
|
|
1345
|
+
annotations: { title: "Replay Webhook Delivery", readOnlyHint: false, destructiveHint: true, idempotentHint: false, openWorldHint: true },
|
|
1341
1346
|
execute: createExecutor(replayWebhookDelivery)
|
|
1342
1347
|
},
|
|
1343
1348
|
// ── iCal Subscriptions ─────────────────────────────────────────
|
|
@@ -1359,14 +1364,14 @@ var RAW_TOOL_DEFINITIONS = [
|
|
|
1359
1364
|
name: "subscribe_ical",
|
|
1360
1365
|
description: "Link an external iCal feed (e.g. a human's Google Calendar) to an agent's calendar so external events appear in availability calculations. The target calendar must be owned by the specified agent \u2014 create the calendar with that agent_id first (org-level calendars without an agent_id cannot host external iCal subscriptions; create a dedicated per-agent calendar for sync targets).",
|
|
1361
1366
|
schema: SubscribeICalSchema,
|
|
1362
|
-
annotations: { title: "Subscribe iCal", readOnlyHint: false, destructiveHint:
|
|
1367
|
+
annotations: { title: "Subscribe iCal", readOnlyHint: false, destructiveHint: true, idempotentHint: false, openWorldHint: true },
|
|
1363
1368
|
execute: createExecutor(subscribeICal)
|
|
1364
1369
|
},
|
|
1365
1370
|
{
|
|
1366
1371
|
name: "update_ical_subscription",
|
|
1367
1372
|
description: "Update an external iCal feed subscription \u2014 change its label or its feed URL. Changing the URL forces a full re-sync on the next poll.",
|
|
1368
1373
|
schema: UpdateICalSubscriptionSchema,
|
|
1369
|
-
annotations: { title: "Update iCal Subscription", readOnlyHint: false, destructiveHint:
|
|
1374
|
+
annotations: { title: "Update iCal Subscription", readOnlyHint: false, destructiveHint: true, idempotentHint: true, openWorldHint: true },
|
|
1370
1375
|
execute: createExecutor(updateICalSubscription)
|
|
1371
1376
|
},
|
|
1372
1377
|
{
|
|
@@ -1378,23 +1383,23 @@ var RAW_TOOL_DEFINITIONS = [
|
|
|
1378
1383
|
},
|
|
1379
1384
|
{
|
|
1380
1385
|
name: "sync_ical_subscription",
|
|
1381
|
-
description: 'Start an immediate fetch of an external iCal feed instead of waiting for the next scheduled poll. Returns {"status":"syncing"} as soon as the fetch has started;
|
|
1386
|
+
description: 'Start an immediate fetch of an external iCal feed instead of waiting for the next scheduled poll. Returns {"status":"syncing"} as soon as the fetch has started; last_synced_at and last_error on the subscription update when the fetch finishes, usually within a few seconds. A paused feed must be resumed first; one manual sync per feed per minute on paid plans, per 15 minutes on Free.',
|
|
1382
1387
|
schema: SyncICalSubscriptionSchema,
|
|
1383
|
-
annotations: { title: "Sync iCal Subscription", readOnlyHint: false, destructiveHint:
|
|
1388
|
+
annotations: { title: "Sync iCal Subscription", readOnlyHint: false, destructiveHint: true, idempotentHint: true, openWorldHint: true },
|
|
1384
1389
|
execute: createExecutor(syncICalSubscription)
|
|
1385
1390
|
},
|
|
1386
1391
|
{
|
|
1387
1392
|
name: "pause_ical_subscription",
|
|
1388
1393
|
description: "Pause an external iCal feed subscription: scheduled polls skip it and manual syncs are refused until it is resumed. Busy blocks already imported stay. Pausing a paused feed changes nothing. Returns the subscription.",
|
|
1389
1394
|
schema: PauseICalSubscriptionSchema,
|
|
1390
|
-
annotations: { title: "Pause iCal Subscription", readOnlyHint: false, destructiveHint:
|
|
1395
|
+
annotations: { title: "Pause iCal Subscription", readOnlyHint: false, destructiveHint: true, idempotentHint: true, openWorldHint: false },
|
|
1391
1396
|
execute: createExecutor(pauseICalSubscription)
|
|
1392
1397
|
},
|
|
1393
1398
|
{
|
|
1394
1399
|
name: "resume_ical_subscription",
|
|
1395
1400
|
description: "Resume a paused or failing external iCal feed subscription: it returns to scheduled polling and its last_error is cleared. Resuming an active feed changes nothing. Returns the subscription.",
|
|
1396
1401
|
schema: ResumeICalSubscriptionSchema,
|
|
1397
|
-
annotations: { title: "Resume iCal Subscription", readOnlyHint: false, destructiveHint:
|
|
1402
|
+
annotations: { title: "Resume iCal Subscription", readOnlyHint: false, destructiveHint: true, idempotentHint: true, openWorldHint: false },
|
|
1398
1403
|
execute: createExecutor(resumeICalSubscription)
|
|
1399
1404
|
},
|
|
1400
1405
|
// ── Scoped keys ────────────────────────────────────────────────
|
|
@@ -1402,7 +1407,7 @@ var RAW_TOOL_DEFINITIONS = [
|
|
|
1402
1407
|
name: "create_scoped_key",
|
|
1403
1408
|
description: "Create an Agent key (chr_ak_*) that can only act on behalf of a single agent. Use this to self-provision or rotate per-agent credentials. The plaintext key is returned exactly once in the response \u2014 store it immediately, it cannot be retrieved later. Requires an Organization key.",
|
|
1404
1409
|
schema: CreateScopedKeySchema,
|
|
1405
|
-
annotations: { title: "Create Scoped Key", readOnlyHint: false, destructiveHint:
|
|
1410
|
+
annotations: { title: "Create Scoped Key", readOnlyHint: false, destructiveHint: true, idempotentHint: false, openWorldHint: false },
|
|
1406
1411
|
execute: createExecutor(createScopedKey)
|
|
1407
1412
|
},
|
|
1408
1413
|
{
|
|
@@ -1432,7 +1437,7 @@ var RAW_TOOL_DEFINITIONS = [
|
|
|
1432
1437
|
name: "accept_terms",
|
|
1433
1438
|
description: "Re-accept the current Chronary terms of service on behalf of the calling org. Use this when responses carry the Chronary-Terms-Upgrade-Required header \u2014 a material ToS bump otherwise leaves MCP-only agents stuck without a console session. Pass the current tos_version (read it from GET /v1/auth/terms/current). Requires an Organization key (chr_sk_*); Agent keys cannot accept org-wide terms.",
|
|
1434
1439
|
schema: AcceptTermsSchema,
|
|
1435
|
-
annotations: { title: "Accept Terms", readOnlyHint: false, destructiveHint:
|
|
1440
|
+
annotations: { title: "Accept Terms", readOnlyHint: false, destructiveHint: true, idempotentHint: true, openWorldHint: false },
|
|
1436
1441
|
execute: createExecutor(acceptTerms)
|
|
1437
1442
|
},
|
|
1438
1443
|
// ── Usage ──────────────────────────────────────────────────────
|
|
@@ -1460,9 +1465,9 @@ var RAW_TOOL_DEFINITIONS = [
|
|
|
1460
1465
|
},
|
|
1461
1466
|
{
|
|
1462
1467
|
name: "request_upgrade",
|
|
1463
|
-
description: "Ask your human to upgrade this Chronary account to
|
|
1468
|
+
description: "Ask your human to upgrade this Chronary account to the next plan up. Returns approval_url \u2014 give it to your human; only a human can pay. If reused=true a request is already pending \u2014 do not call again; check the status of the request at most once a minute. The link opens the Billing page in the Chronary console.",
|
|
1464
1469
|
schema: RequestUpgradeSchema,
|
|
1465
|
-
annotations: { title: "Request Upgrade", readOnlyHint: false, destructiveHint:
|
|
1470
|
+
annotations: { title: "Request Upgrade", readOnlyHint: false, destructiveHint: true, idempotentHint: true, openWorldHint: false },
|
|
1466
1471
|
execute: createExecutor(requestUpgrade)
|
|
1467
1472
|
},
|
|
1468
1473
|
{
|
|
@@ -1476,7 +1481,7 @@ var RAW_TOOL_DEFINITIONS = [
|
|
|
1476
1481
|
name: "cancel_upgrade_request",
|
|
1477
1482
|
description: "Withdraw a pending upgrade request (for example, the blocker went away). The approval URL stops working. Fails with upgrade_request_not_pending if the request is already completed, declined, canceled, or expired.",
|
|
1478
1483
|
schema: CancelUpgradeRequestSchema,
|
|
1479
|
-
annotations: { title: "Cancel Upgrade Request", readOnlyHint: false, destructiveHint:
|
|
1484
|
+
annotations: { title: "Cancel Upgrade Request", readOnlyHint: false, destructiveHint: true, idempotentHint: true, openWorldHint: false },
|
|
1480
1485
|
execute: createExecutor(cancelUpgradeRequest)
|
|
1481
1486
|
}
|
|
1482
1487
|
];
|