@chronary/toolkit 1.6.3 → 1.7.1

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/dist/index.d.cts CHANGED
@@ -1,6 +1,6 @@
1
1
  import { T as ToolDefinition, b as ToolResult } from './base-BL0efzXv.cjs';
2
2
  export { B as BaseToolkit, C as ChronaryToolkitConfig, L as ListToolkit, M as MapToolkit, c as TOOL_NAMES, a as ToolAnnotations, d as ToolName } from './base-BL0efzXv.cjs';
3
- export { M as MCP_SERVER_INSTRUCTIONS } from './instructions-CQAfBjV3.cjs';
3
+ export { M as MCP_SERVER_INSTRUCTIONS } from './instructions-BJQzbMAM.cjs';
4
4
  import { z } from 'zod';
5
5
  import '@chronary/sdk';
6
6
 
@@ -141,6 +141,7 @@ declare const CreateEventSchema: z.ZodObject<{
141
141
  hold_expires_at: z.ZodOptional<z.ZodString>;
142
142
  hold_priority: z.ZodOptional<z.ZodNumber>;
143
143
  recurrence_rule: z.ZodOptional<z.ZodString>;
144
+ timezone: z.ZodOptional<z.ZodString>;
144
145
  }, z.core.$strip>;
145
146
  declare const UpdateEventSchema: z.ZodObject<{
146
147
  event_id: z.ZodString;
@@ -158,6 +159,7 @@ declare const UpdateEventSchema: z.ZodObject<{
158
159
  metadata: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
159
160
  reminders: z.ZodOptional<z.ZodNullable<z.ZodArray<z.ZodNumber>>>;
160
161
  recurrence_rule: z.ZodOptional<z.ZodNullable<z.ZodString>>;
162
+ timezone: z.ZodOptional<z.ZodNullable<z.ZodString>>;
161
163
  }, z.core.$strip>;
162
164
  declare const CancelEventSchema: z.ZodObject<{
163
165
  event_id: z.ZodString;
package/dist/index.d.ts CHANGED
@@ -1,6 +1,6 @@
1
1
  import { T as ToolDefinition, b as ToolResult } from './base-BL0efzXv.js';
2
2
  export { B as BaseToolkit, C as ChronaryToolkitConfig, L as ListToolkit, M as MapToolkit, c as TOOL_NAMES, a as ToolAnnotations, d as ToolName } from './base-BL0efzXv.js';
3
- export { M as MCP_SERVER_INSTRUCTIONS } from './instructions-CQAfBjV3.js';
3
+ export { M as MCP_SERVER_INSTRUCTIONS } from './instructions-BJQzbMAM.js';
4
4
  import { z } from 'zod';
5
5
  import '@chronary/sdk';
6
6
 
@@ -141,6 +141,7 @@ declare const CreateEventSchema: z.ZodObject<{
141
141
  hold_expires_at: z.ZodOptional<z.ZodString>;
142
142
  hold_priority: z.ZodOptional<z.ZodNumber>;
143
143
  recurrence_rule: z.ZodOptional<z.ZodString>;
144
+ timezone: z.ZodOptional<z.ZodString>;
144
145
  }, z.core.$strip>;
145
146
  declare const UpdateEventSchema: z.ZodObject<{
146
147
  event_id: z.ZodString;
@@ -158,6 +159,7 @@ declare const UpdateEventSchema: z.ZodObject<{
158
159
  metadata: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
159
160
  reminders: z.ZodOptional<z.ZodNullable<z.ZodArray<z.ZodNumber>>>;
160
161
  recurrence_rule: z.ZodOptional<z.ZodNullable<z.ZodString>>;
162
+ timezone: z.ZodOptional<z.ZodNullable<z.ZodString>>;
161
163
  }, z.core.$strip>;
162
164
  declare const CancelEventSchema: z.ZodObject<{
163
165
  event_id: z.ZodString;
package/dist/index.js CHANGED
@@ -171,7 +171,7 @@ var ListCalendarsSchema = z.object({
171
171
  agent_id: z.string().optional().describe("Filter to calendars owned by this agent. Organization keys only \u2014 Agent keys are always limited to their own agent and ignore this."),
172
172
  include: z.enum(["all"]).optional().describe('Pass "all" to include calendars across all agents (Organization keys only)'),
173
173
  limit: z.number().int().min(1).max(200).default(50).describe("Max results to return"),
174
- offset: z.number().int().min(0).default(0).describe("Pagination offset")
174
+ offset: z.number().int().min(0).default(0).describe("Pagination offset, at most 10000")
175
175
  });
176
176
  var GetCalendarSchema = z.object({
177
177
  calendar_id: z.string().describe("Calendar ID to fetch")
@@ -195,7 +195,7 @@ var DeleteCalendarSchema = z.object({
195
195
  });
196
196
  var ListBookingPagesSchema = z.object({
197
197
  limit: z.number().int().min(1).max(200).default(50).describe("Max results to return"),
198
- offset: z.number().int().min(0).default(0).describe("Pagination offset")
198
+ offset: z.number().int().min(0).default(0).describe("Pagination offset, at most 10000")
199
199
  });
200
200
  var GetBookingPageSchema = z.object({
201
201
  booking_page_id: z.string().describe("Booking page ID to fetch (bkp_...)")
@@ -223,7 +223,7 @@ var ListEventsSchema = z.object({
223
223
  status: z.enum(["confirmed", "tentative", "cancelled", "hold"]).optional().describe("Filter by event status"),
224
224
  source: z.enum(["internal", "external_ical"]).optional().describe('Filter by source: "internal" (created via the API) or "external_ical" (synced from an iCal subscription)'),
225
225
  limit: z.number().int().min(1).max(200).default(50).describe("Max results to return"),
226
- offset: z.number().int().min(0).default(0).describe("Pagination offset"),
226
+ offset: z.number().int().min(0).default(0).describe("Pagination offset, at most 10000"),
227
227
  expand: z.boolean().default(false).describe("Expand recurring series into individual occurrence instances within the window. Requires both start_after and start_before (max 366 days apart). Instances carry recurringEventId + originalStartTime.")
228
228
  });
229
229
  var ListOrgEventsSchema = z.object({
@@ -236,7 +236,7 @@ var ListOrgEventsSchema = z.object({
236
236
  q: z.string().optional().describe("Case-insensitive title search. Requires start_after and start_before at most 31 days apart"),
237
237
  expand: z.boolean().default(false).describe("Expand recurring series into individual occurrences within the window. Requires both start_after and start_before (max 366 days apart)."),
238
238
  limit: z.number().int().min(1).max(100).default(50).describe("Max results to return (1-100)"),
239
- offset: z.number().int().min(0).default(0).describe("Pagination offset")
239
+ offset: z.number().int().min(0).default(0).describe("Pagination offset, at most 10000")
240
240
  });
241
241
  var GetEventSchema = z.object({
242
242
  event_id: z.string().describe("Event ID to retrieve"),
@@ -253,7 +253,8 @@ var CreateEventSchema = z.object({
253
253
  reminders: z.array(z.number().int().min(1).max(40320)).max(5).nullable().optional().describe("Reminder offsets in minutes before start_time (e.g. [10, 1440]). Each fires an event.reminder webhook and shows as an alarm in the iCal feed. Omit or null to inherit the calendar default (then the system default of 10 min); [] for no reminders."),
254
254
  hold_expires_at: z.string().datetime({ offset: true }).optional().describe('Required when status="hold". ISO 8601 timestamp 30s-15min in the future. Auto-releases the hold when reached.'),
255
255
  hold_priority: z.number().int().min(0).max(100).optional().describe('Only valid with status="hold". Higher-priority overlapping holds pre-empt lower-priority ones. Defaults to 0.'),
256
- recurrence_rule: z.string().max(256).optional().describe('Make this a recurring series (RFC 5545 RRULE subset, no "RRULE:" prefix), e.g. "FREQ=WEEKLY;BYDAY=MO,WE;COUNT=12". Supports FREQ=DAILY/WEEKLY/MONTHLY/YEARLY, INTERVAL, COUNT (max 730) or UNTIL, BYDAY (weekly list or monthly ordinal like 2TU/-1FR), BYMONTHDAY (1-28 or -1). start_time must match the rule pattern; expansion is UTC-only. Not allowed with status="hold". Free plan: 1 recurring series, must end within 90 days.')
256
+ recurrence_rule: z.string().max(256).optional().describe('Make this a recurring series (RFC 5545 RRULE subset, no "RRULE:" prefix), e.g. "FREQ=WEEKLY;BYDAY=MO,WE;COUNT=12". Supports FREQ=DAILY/WEEKLY/MONTHLY/YEARLY, INTERVAL, COUNT (max 730) or UNTIL, BYDAY (weekly list or monthly ordinal like 2TU/-1FR), BYMONTHDAY (1-28 or -1). start_time must match the rule pattern (in timezone when set, else UTC). Not allowed with status="hold". Free plan: 1 recurring series, must end within 90 days.'),
257
+ timezone: z.string().max(64).optional().describe('IANA time zone the recurring series repeats in, e.g. "America/Los_Angeles". A weekly 16:00 then stays 16:00 local across daylight-saving changes; BYDAY and a date-only UNTIL are read in this zone. Omit for UTC.')
257
258
  });
258
259
  var UpdateEventSchema = z.object({
259
260
  event_id: z.string().describe("Event ID to update"),
@@ -266,7 +267,8 @@ var UpdateEventSchema = z.object({
266
267
  status: z.enum(["confirmed", "tentative", "cancelled"]).optional().describe("New event status"),
267
268
  metadata: z.record(z.string(), z.unknown()).optional().describe("Replacement metadata object"),
268
269
  reminders: z.array(z.number().int().min(1).max(40320)).max(5).nullable().optional().describe("Reminder offsets in minutes before start_time. Omit to leave unchanged, null to inherit the calendar default, [] for no reminders."),
269
- recurrence_rule: z.string().max(256).nullable().optional().describe("Set/change the recurring series rule (RFC 5545 RRULE subset, full-series semantics), or null to make the event a one-off. Changing the rule or start_time resets cancelled occurrences.")
270
+ recurrence_rule: z.string().max(256).nullable().optional().describe("Set/change the recurring series rule (RFC 5545 RRULE subset, full-series semantics), or null to make the event a one-off. Changing the rule, start_time or timezone keeps each cancelled occurrence on its local date; the response lists any that no longer match in droppedExdates."),
271
+ timezone: z.string().max(64).nullable().optional().describe('Set or change the IANA time zone the series repeats in (e.g. "America/Los_Angeles"), or null for UTC. Validated together with recurrence_rule and start_time, so a UTC-stored series can move to local time in one call (e.g. timezone + BYDAY=TU).')
270
272
  });
271
273
  var CancelEventSchema = z.object({
272
274
  event_id: z.string().describe("Event ID to cancel"),
@@ -288,7 +290,7 @@ var ListAgentsSchema = z.object({
288
290
  type: z.enum(["ai", "human", "resource"]).optional().describe("Filter by agent type"),
289
291
  status: z.enum(["active", "paused", "decommissioned"]).optional().describe("Filter by status"),
290
292
  limit: z.number().int().min(1).max(200).default(50).describe("Max results to return"),
291
- offset: z.number().int().min(0).default(0).describe("Pagination offset")
293
+ offset: z.number().int().min(0).default(0).describe("Pagination offset, at most 10000")
292
294
  });
293
295
  var GetAgentSchema = z.object({
294
296
  agent_id: z.string().describe("Agent ID to fetch")
@@ -356,7 +358,7 @@ var ListProposalsSchema = z.object({
356
358
  status: z.enum(["pending", "resolving", "confirmed", "expired", "cancelled"]).optional().describe("Filter by proposal status"),
357
359
  organizer_agent_id: z.string().optional().describe("Filter by organizer agent"),
358
360
  limit: z.number().int().min(1).max(200).optional().describe("Max results (default 50)"),
359
- offset: z.number().int().min(0).optional().describe("Pagination offset (default 0)")
361
+ offset: z.number().int().min(0).optional().describe("Pagination offset, at most 10000 (default 0)")
360
362
  });
361
363
  var GetProposalSchema = z.object({
362
364
  proposal_id: z.string().describe("Proposal to fetch")
@@ -430,7 +432,7 @@ var AcceptTermsSchema = z.object({
430
432
  });
431
433
  var ListWebhooksSchema = z.object({
432
434
  limit: z.number().int().min(1).max(100).default(20).describe("Max results to return"),
433
- offset: z.number().int().min(0).default(0).describe("Pagination offset")
435
+ offset: z.number().int().min(0).default(0).describe("Pagination offset, at most 10000")
434
436
  });
435
437
  var GetWebhookSchema = z.object({
436
438
  webhook_id: z.string().describe("Webhook subscription to fetch")
@@ -451,7 +453,7 @@ var DeleteWebhookSchema = z.object({
451
453
  var ListWebhookDeliveriesSchema = z.object({
452
454
  webhook_id: z.string().describe("Webhook subscription whose deliveries to list"),
453
455
  limit: z.number().int().min(1).max(100).default(20).describe("Max results to return"),
454
- offset: z.number().int().min(0).default(0).describe("Pagination offset. Cannot be combined with cursor"),
456
+ offset: z.number().int().min(0).default(0).describe("Pagination offset, at most 10000. Cannot be combined with cursor"),
455
457
  status: z.enum(WEBHOOK_DELIVERY_STATUSES).optional().describe("Filter to a single delivery status"),
456
458
  include_payload: z.boolean().optional().describe("Include the full event payload sent on each delivery"),
457
459
  event_type: z.string().max(100).regex(/^[a-z_]+\.(?:[a-z_]+)?$/).optional().describe("An exact event type (event.created), or a prefix ending in a dot (event.) for a whole group"),
@@ -477,7 +479,7 @@ var ListICalSubscriptionsSchema = z.object({
477
479
  agent_id: z.string().describe("Agent ID whose iCal subscriptions to list"),
478
480
  status: z.enum(["active", "error", "paused"]).optional().describe("Filter by subscription status"),
479
481
  limit: z.number().int().min(1).max(200).default(50).describe("Max results to return"),
480
- offset: z.number().int().min(0).default(0).describe("Pagination offset")
482
+ offset: z.number().int().min(0).default(0).describe("Pagination offset, at most 10000")
481
483
  });
482
484
  var GetICalSubscriptionSchema = z.object({
483
485
  subscription_id: z.string().describe("iCal subscription ID to fetch")
@@ -1180,7 +1182,7 @@ var RAW_TOOL_DEFINITIONS = [
1180
1182
  // ── Scheduling proposals ───────────────────────────────────────
1181
1183
  {
1182
1184
  name: "create_proposal",
1183
- 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. Pro plan only.",
1185
+ 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.",
1184
1186
  schema: CreateProposalSchema,
1185
1187
  annotations: { title: "Create Proposal", readOnlyHint: false, destructiveHint: false, idempotentHint: false, openWorldHint: false },
1186
1188
  execute: createExecutor(createProposal)
@@ -1201,21 +1203,21 @@ var RAW_TOOL_DEFINITIONS = [
1201
1203
  },
1202
1204
  {
1203
1205
  name: "respond_to_proposal",
1204
- 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. Pro plan only.',
1206
+ 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.',
1205
1207
  schema: RespondToProposalSchema,
1206
1208
  annotations: { title: "Respond To Proposal", readOnlyHint: false, destructiveHint: false, idempotentHint: false, openWorldHint: false },
1207
1209
  execute: createExecutor(respondToProposal)
1208
1210
  },
1209
1211
  {
1210
1212
  name: "resolve_proposal",
1211
- 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. Pro plan only.',
1213
+ 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.',
1212
1214
  schema: ResolveProposalSchema,
1213
1215
  annotations: { title: "Resolve Proposal", readOnlyHint: false, destructiveHint: false, idempotentHint: true, openWorldHint: false },
1214
1216
  execute: createExecutor(resolveProposal)
1215
1217
  },
1216
1218
  {
1217
1219
  name: "cancel_proposal",
1218
- description: 'Cancel an open proposal. Fires a proposal.cancelled webhook with reason="organizer_cancelled". Requires an Organization key. Pro plan only.',
1220
+ description: 'Cancel an open proposal. Fires a proposal.cancelled webhook with reason="organizer_cancelled". Requires an Organization key. Works on every plan, so an org that dropped to Free can still cancel proposals it made on a paid plan.',
1219
1221
  schema: CancelProposalSchema,
1220
1222
  annotations: { title: "Cancel Proposal", readOnlyHint: false, destructiveHint: true, idempotentHint: true, openWorldHint: false },
1221
1223
  execute: createExecutor(cancelProposal)
@@ -1464,7 +1466,7 @@ Typical flow: create_agent -> create_calendar -> create_event / get_availability
1464
1466
 
1465
1467
  When checking availability, always inspect availability_state and warnings before treating returned slots as complete. Human-calendar setup requires a human to open setup_url and consent; agents never receive provider credentials or calendar contents.
1466
1468
 
1467
- Organization keys (chr_sk_) can use every tool; Agent keys (chr_ak_) are limited to their own agent and cannot use org-only tools such as create_agent or find_meeting_time. Scoped keys, cross-agent availability, webhook delivery replay and secret rotation require a Developer or Pro plan; scheduling proposals and temporal holds require Pro.
1469
+ Organization keys (chr_sk_) can use every tool; Agent keys (chr_ak_) are limited to their own agent and cannot use org-only tools such as create_agent or find_meeting_time. Scoped keys, cross-agent availability, scheduling proposals, temporal holds, webhook delivery replay and secret rotation require a Developer or Pro plan.
1468
1470
 
1469
1471
  If you hit a plan limit, don't retry in a loop: call get_billing, then request_upgrade, and give approval_url to your human. Agents cannot pay; a human completes checkout.
1470
1472