@superdurable/connector-clickup 0.1.1 → 0.1.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/README.md CHANGED
@@ -16,7 +16,7 @@ Install Node.js 22 or 24 and Dex TypeScript SDK 1.28.0 or later. Create a person
16
16
  | `newAddCommentStep` | `POST /task/{taskId}/comment` | `added` |
17
17
  | `newFindMemberByEmailStep` | `GET /team` | `found` |
18
18
 
19
- Unwired optional branches fail the Flow. `createTask` and `addComment` record a Dex heartbeat before their unkeyed write, then read back after an unconfirmed attempt. A result becomes uncertain when read back cannot identify exactly one earlier write. The other mutations repeat safely using absolute changes or tag membership.
19
+ Unwired optional branches fail the Flow. `createTask` and `addComment` send behind the SDK single-dispatch fence, whose Dex heartbeat counts each possible send. After an unknown outcome the next attempt reads the write back, by its saved ID or by name or text, and sends again only while possible sends stay within the Step's send cap (three by default); several matches, or no match at the cap, select uncertain. Only HTTP 400, 401, 403, 404, 411, 413, 414, 415, and 422 select a refusal branch. The other mutations repeat safely using absolute changes or tag membership, and retry every other unknown outcome.
20
20
 
21
21
  Task writes reject duplicate assignee or custom field IDs, non-JSON custom field values, and invalid status names before contacting ClickUp. Tags must be unique names of 1–100 UTF-8 bytes without surrounding whitespace, slashes, control characters, or dot segments (`.` and `..`). `updateTaskTags` bounds the entire write and read-back sequence to 25 seconds.
22
22
 
@@ -27,4 +27,4 @@ npm ci
27
27
  npm run check
28
28
  ```
29
29
 
30
- Run `npm run test:integration` against a local `dexcli dev` with `DEX_FLOW_SERVICE_ADDRESS` set. The integration test runs the example through a real Dex Worker and Client against a local HTTP fixture. The Go recorded conformance suite checks 82 scenarios covering each operation's branches, retries, transport failure, request shape, idempotency key, unsafe tag paths, input validation, and uncertain read back. Live ClickUp authorization and provider behavior have not been verified.
30
+ Run `npm run test:integration` against a local `dexcli dev` with `DEX_FLOW_SERVICE_ADDRESS` set. The integration test runs the example through a real Dex Worker and Client against a local HTTP fixture. The Go recorded conformance suite checks 89 scenarios covering each operation's branches, retries, transport failure, request shape, idempotency key, unsafe tag paths, input validation, read-back by ID and by name, resends below the send cap, and uncertainty at the cap. Live ClickUp authorization and provider behavior have not been verified.
@@ -1,16 +1,18 @@
1
1
  {
2
2
  "connectorId": "clickup",
3
- "releaseTag": "connectors/clickup/go/v0.23.0",
3
+ "releaseTag": "connectors/clickup/go/v0.23.1",
4
4
  "package": {
5
5
  "ecosystem": "npm",
6
6
  "name": "@superdurable/connector-clickup",
7
- "version": "0.1.1"
7
+ "version": "0.1.3"
8
8
  },
9
9
  "factories": [
10
10
  {
11
11
  "name": "newSearchTasksStep",
12
12
  "kind": "query",
13
13
  "operationId": "searchTasks",
14
+ "inputType": "SearchTasksInput",
15
+ "description": "Search one Workspace's tasks by List, Folder, Space, status, assignee, tag, and update time, returning one page of up to 100 tasks and the next page number.",
14
16
  "fields": {
15
17
  "stepType": "stepType",
16
18
  "annotations": "annotations",
@@ -43,12 +45,104 @@
43
45
  "field": "defect",
44
46
  "optional": true
45
47
  }
46
- ]
48
+ ],
49
+ "inputSchema": {
50
+ "additionalProperties": false,
51
+ "description": "SearchTasksInput filters one Workspace's tasks. Every non-empty filter narrows the search, and the values of one list filter are alternatives.",
52
+ "properties": {
53
+ "areSubtasksIncluded": {
54
+ "description": "AreSubtasksIncluded also returns subtasks; ClickUp excludes them by default.",
55
+ "type": "boolean"
56
+ },
57
+ "assigneeIds": {
58
+ "description": "AssigneeIDs keeps tasks assigned to any of these user IDs.",
59
+ "items": {
60
+ "type": "integer"
61
+ },
62
+ "type": "array"
63
+ },
64
+ "folderIds": {
65
+ "description": "FolderIDs keeps tasks of Lists in these Folders.",
66
+ "items": {
67
+ "type": "string"
68
+ },
69
+ "type": "array"
70
+ },
71
+ "isClosedIncluded": {
72
+ "description": "IsClosedIncluded also returns tasks in a closed status; ClickUp excludes them by default.",
73
+ "type": "boolean"
74
+ },
75
+ "isReverse": {
76
+ "description": "IsReverse reverses ClickUp's order.",
77
+ "type": "boolean"
78
+ },
79
+ "listIds": {
80
+ "description": "ListIDs keeps tasks of these Lists.",
81
+ "items": {
82
+ "type": "string"
83
+ },
84
+ "type": "array"
85
+ },
86
+ "orderBy": {
87
+ "description": "OrderBy is created, updated, due_date, or id; empty uses ClickUp's default order by creation.",
88
+ "enum": [
89
+ "created",
90
+ "due_date",
91
+ "id",
92
+ "updated"
93
+ ],
94
+ "type": "string"
95
+ },
96
+ "page": {
97
+ "description": "Page is the zero-based page to read; continue with SearchTasksOutput.NextPage.",
98
+ "type": "integer"
99
+ },
100
+ "spaceIds": {
101
+ "description": "SpaceIDs keeps tasks of these Spaces.",
102
+ "items": {
103
+ "type": "string"
104
+ },
105
+ "type": "array"
106
+ },
107
+ "statuses": {
108
+ "description": "Statuses keeps tasks in these status names, such as in progress.",
109
+ "items": {
110
+ "type": "string"
111
+ },
112
+ "type": "array"
113
+ },
114
+ "tags": {
115
+ "description": "Tags keeps tasks with any of these tag names.",
116
+ "items": {
117
+ "type": "string"
118
+ },
119
+ "type": "array"
120
+ },
121
+ "updatedAfter": {
122
+ "description": "UpdatedAfter keeps tasks updated after this time, for polling changes since a checkpoint.",
123
+ "format": "date-time",
124
+ "type": [
125
+ "string",
126
+ "null"
127
+ ]
128
+ },
129
+ "workspaceId": {
130
+ "description": "WorkspaceID is the Workspace (ClickUp API team) ID, the first number in a ClickUp web address.",
131
+ "type": "string"
132
+ }
133
+ },
134
+ "required": [
135
+ "workspaceId"
136
+ ],
137
+ "type": "object"
138
+ }
47
139
  },
48
140
  {
49
141
  "name": "newGetTaskStep",
50
142
  "kind": "query",
51
143
  "operationId": "getTask",
144
+ "inputType": "GetTaskInput",
145
+ "description": "Read one task by ID or custom task ID with its status, priority, dates, assignees, tags, List, Markdown description, and custom field values.",
52
146
  "fields": {
53
147
  "stepType": "stepType",
54
148
  "annotations": "annotations",
@@ -81,12 +175,36 @@
81
175
  "field": "defect",
82
176
  "optional": true
83
177
  }
84
- ]
178
+ ],
179
+ "inputSchema": {
180
+ "additionalProperties": false,
181
+ "description": "GetTaskInput names one task.",
182
+ "properties": {
183
+ "isCustomTaskId": {
184
+ "description": "IsCustomTaskID reads TaskID as the Workspace's custom task ID; it requires WorkspaceID.",
185
+ "type": "boolean"
186
+ },
187
+ "taskId": {
188
+ "description": "TaskID is ClickUp's task ID, the code after /t/ in the task's web address, or a custom task ID such as DEV-123 when IsCustomTaskID is set.",
189
+ "type": "string"
190
+ },
191
+ "workspaceId": {
192
+ "description": "WorkspaceID is the Workspace of a custom task ID; leave it empty for an ordinary task ID.",
193
+ "type": "string"
194
+ }
195
+ },
196
+ "required": [
197
+ "taskId"
198
+ ],
199
+ "type": "object"
200
+ }
85
201
  },
86
202
  {
87
203
  "name": "newCreateTaskStep",
88
204
  "kind": "mutation",
89
205
  "operationId": "createTask",
206
+ "inputType": "CreateTaskInput",
207
+ "description": "Create one task in a List with a name, Markdown description, status, priority, due time, assignees, tags, parent task, and custom field values. ClickUp has no idempotency key, so the Step runs with sync durability and counts each send in a Dex heartbeat checkpoint. After an unknown outcome the next attempt reads the task back, by ID or among the List's tasks with the same name and parent, and resends only while the send cap allows.",
90
208
  "fields": {
91
209
  "stepType": "stepType",
92
210
  "annotations": "annotations",
@@ -119,12 +237,108 @@
119
237
  "field": "defect",
120
238
  "optional": true
121
239
  }
122
- ]
240
+ ],
241
+ "inputSchema": {
242
+ "$defs": {
243
+ "CustomFieldInput": {
244
+ "additionalProperties": false,
245
+ "description": "CustomFieldInput sets one custom field on a new task.",
246
+ "properties": {
247
+ "id": {
248
+ "description": "ID is the custom field's ID, from getTask or ClickUp's Get Accessible Custom Fields.",
249
+ "type": "string"
250
+ },
251
+ "value": {
252
+ "description": "Value is the JSON value ClickUp expects for the field's type, such as \"text\", 5, or an option ID."
253
+ }
254
+ },
255
+ "required": [
256
+ "id",
257
+ "value"
258
+ ],
259
+ "type": "object"
260
+ }
261
+ },
262
+ "additionalProperties": false,
263
+ "description": "CreateTaskInput is one task to create in a List.",
264
+ "properties": {
265
+ "assigneeIds": {
266
+ "description": "AssigneeIDs are the users to assign, such as a findMemberByEmail result's ID.",
267
+ "items": {
268
+ "type": "integer"
269
+ },
270
+ "type": "array"
271
+ },
272
+ "customFields": {
273
+ "description": "CustomFields set custom field values; ClickUp ignores fields that do not apply to the task.",
274
+ "items": {
275
+ "$ref": "#/$defs/CustomFieldInput"
276
+ },
277
+ "type": "array"
278
+ },
279
+ "dueAt": {
280
+ "description": "DueAt is the due date and time; nil sets none.",
281
+ "format": "date-time",
282
+ "type": [
283
+ "string",
284
+ "null"
285
+ ]
286
+ },
287
+ "isCreatorNotified": {
288
+ "description": "IsCreatorNotified also notifies the token's user; assignees and watchers are always notified.",
289
+ "type": "boolean"
290
+ },
291
+ "listId": {
292
+ "description": "ListID is the List to create the task in, the number after /li/ in the List's web address.",
293
+ "type": "string"
294
+ },
295
+ "markdownDescription": {
296
+ "description": "MarkdownDescription is the description in Markdown, at most MaxDescriptionBytes; empty sets none.",
297
+ "type": "string"
298
+ },
299
+ "name": {
300
+ "description": "Name is the task name. A retried attempt finds its earlier task by this name, so a name that carries the application's own request key, such as [REQ-1042], makes reconciliation unambiguous.",
301
+ "type": "string"
302
+ },
303
+ "parentTaskId": {
304
+ "description": "ParentTaskID creates a subtask of this task, which must be in the same List; empty creates a task.",
305
+ "type": "string"
306
+ },
307
+ "priority": {
308
+ "description": "Priority is 1 urgent through 4 low; zero sets no priority.",
309
+ "enum": [
310
+ 1,
311
+ 2,
312
+ 3,
313
+ 4
314
+ ],
315
+ "type": "integer"
316
+ },
317
+ "status": {
318
+ "description": "Status is a status name of the List's workflow, such as in progress; empty uses the List's first status.",
319
+ "type": "string"
320
+ },
321
+ "tags": {
322
+ "description": "Tags are tag names of the List's Space to add.",
323
+ "items": {
324
+ "type": "string"
325
+ },
326
+ "type": "array"
327
+ }
328
+ },
329
+ "required": [
330
+ "listId",
331
+ "name"
332
+ ],
333
+ "type": "object"
334
+ }
123
335
  },
124
336
  {
125
337
  "name": "newUpdateTaskStep",
126
338
  "kind": "mutation",
127
339
  "operationId": "updateTask",
340
+ "inputType": "UpdateTaskInput",
341
+ "description": "Change one task's name, Markdown description, status, priority, or due time, and add or remove assignees; every change is an absolute value or a set membership, so a repeated update leaves the same task.",
128
342
  "fields": {
129
343
  "stepType": "stepType",
130
344
  "annotations": "annotations",
@@ -157,12 +371,72 @@
157
371
  "field": "defect",
158
372
  "optional": true
159
373
  }
160
- ]
374
+ ],
375
+ "inputSchema": {
376
+ "additionalProperties": false,
377
+ "description": "UpdateTaskInput changes one task. Only set fields change; every change is an absolute value or a set membership, so a repeated update leaves the same task.",
378
+ "properties": {
379
+ "addAssigneeIds": {
380
+ "description": "AddAssigneeIDs assigns these users; an existing assignee stays assigned.",
381
+ "items": {
382
+ "type": "integer"
383
+ },
384
+ "type": "array"
385
+ },
386
+ "dueAt": {
387
+ "description": "DueAt sets the due date and time; nil keeps it.",
388
+ "format": "date-time",
389
+ "type": [
390
+ "string",
391
+ "null"
392
+ ]
393
+ },
394
+ "markdownDescription": {
395
+ "description": "MarkdownDescription replaces the description with Markdown when set; a pointer to \"\" clears it.",
396
+ "type": "string"
397
+ },
398
+ "name": {
399
+ "description": "Name renames the task when set.",
400
+ "type": "string"
401
+ },
402
+ "priority": {
403
+ "description": "Priority sets 1 urgent through 4 low; zero keeps the current priority.",
404
+ "enum": [
405
+ 1,
406
+ 2,
407
+ 3,
408
+ 4
409
+ ],
410
+ "type": "integer"
411
+ },
412
+ "removeAssigneeIds": {
413
+ "description": "RemoveAssigneeIDs unassigns these users; a user who is not assigned is ignored.",
414
+ "items": {
415
+ "type": "integer"
416
+ },
417
+ "type": "array"
418
+ },
419
+ "status": {
420
+ "description": "Status moves the task to a status name of its List's workflow, such as in progress; empty keeps it.",
421
+ "type": "string"
422
+ },
423
+ "taskId": {
424
+ "description": "TaskID is ClickUp's task ID.",
425
+ "type": "string"
426
+ }
427
+ },
428
+ "required": [
429
+ "taskId"
430
+ ],
431
+ "type": "object"
432
+ }
161
433
  },
162
434
  {
163
435
  "name": "newUpdateTaskTagsStep",
164
436
  "kind": "mutation",
165
437
  "operationId": "updateTaskTags",
438
+ "inputType": "UpdateTaskTagsInput",
439
+ "description": "Add tags to and remove tags from one task, then read the task's tags back; adding a present tag or removing an absent one changes nothing, so a repeated update is safe.",
166
440
  "fields": {
167
441
  "stepType": "stepType",
168
442
  "annotations": "annotations",
@@ -195,12 +469,42 @@
195
469
  "field": "defect",
196
470
  "optional": true
197
471
  }
198
- ]
472
+ ],
473
+ "inputSchema": {
474
+ "additionalProperties": false,
475
+ "description": "UpdateTaskTagsInput adds tags to and removes tags from one task.",
476
+ "properties": {
477
+ "addTags": {
478
+ "description": "AddTags are tag names to add; a tag the task already has stays.",
479
+ "items": {
480
+ "type": "string"
481
+ },
482
+ "type": "array"
483
+ },
484
+ "removeTags": {
485
+ "description": "RemoveTags are tag names to remove from the task; the tag stays in the Space.",
486
+ "items": {
487
+ "type": "string"
488
+ },
489
+ "type": "array"
490
+ },
491
+ "taskId": {
492
+ "description": "TaskID is ClickUp's task ID.",
493
+ "type": "string"
494
+ }
495
+ },
496
+ "required": [
497
+ "taskId"
498
+ ],
499
+ "type": "object"
500
+ }
199
501
  },
200
502
  {
201
503
  "name": "newAddCommentStep",
202
504
  "kind": "mutation",
203
505
  "operationId": "addComment",
506
+ "inputType": "AddCommentInput",
507
+ "description": "Add one plain-text comment, authored by the token's user, to a task. ClickUp has no idempotency key, so the Step runs with sync durability and counts each send in a Dex heartbeat checkpoint. After an unknown outcome the next attempt reads the task's comments back, by ID or by text, and resends only while the send cap allows.",
204
508
  "fields": {
205
509
  "stepType": "stepType",
206
510
  "annotations": "annotations",
@@ -233,12 +537,37 @@
233
537
  "field": "defect",
234
538
  "optional": true
235
539
  }
236
- ]
540
+ ],
541
+ "inputSchema": {
542
+ "additionalProperties": false,
543
+ "description": "AddCommentInput is one plain-text comment to add to a task.",
544
+ "properties": {
545
+ "isCreatorNotified": {
546
+ "description": "IsCreatorNotified also notifies the token's user; assignees and watchers are always notified.",
547
+ "type": "boolean"
548
+ },
549
+ "taskId": {
550
+ "description": "TaskID is ClickUp's task ID.",
551
+ "type": "string"
552
+ },
553
+ "text": {
554
+ "description": "Text is the comment's plain text, at most MaxCommentBytes; ClickUp shows it as written.",
555
+ "type": "string"
556
+ }
557
+ },
558
+ "required": [
559
+ "taskId",
560
+ "text"
561
+ ],
562
+ "type": "object"
563
+ }
237
564
  },
238
565
  {
239
566
  "name": "newFindMemberByEmailStep",
240
567
  "kind": "query",
241
568
  "operationId": "findMemberByEmail",
569
+ "inputType": "FindMemberByEmailInput",
570
+ "description": "Find the member of one Workspace whose email address equals the given address, returning the numeric user ID that task assignees use.",
242
571
  "fields": {
243
572
  "stepType": "stepType",
244
573
  "annotations": "annotations",
@@ -271,7 +600,26 @@
271
600
  "field": "defect",
272
601
  "optional": true
273
602
  }
274
- ]
603
+ ],
604
+ "inputSchema": {
605
+ "additionalProperties": false,
606
+ "description": "FindMemberByEmailInput names one Workspace and one email address.",
607
+ "properties": {
608
+ "email": {
609
+ "description": "Email is one bare email address, compared without regard to case.",
610
+ "type": "string"
611
+ },
612
+ "workspaceId": {
613
+ "description": "WorkspaceID is the Workspace (ClickUp API team) ID, the first number in a ClickUp web address.",
614
+ "type": "string"
615
+ }
616
+ },
617
+ "required": [
618
+ "email",
619
+ "workspaceId"
620
+ ],
621
+ "type": "object"
622
+ }
275
623
  }
276
624
  ]
277
625
  }
@@ -1,9 +1,60 @@
1
1
  // src/generated/models.ts
2
2
  import { z } from "zod";
3
+ import { SecretString } from "@superdurable/connectors-sdk";
4
+ var goTimeJSONPattern = /^(\d{4})-(\d{2})-(\d{2})T(\d{1,2}):(\d{2}):(\d{2})(?:[.,](\d+))?(Z|([+-])(\d{2}):(\d{2}))$/;
5
+ function isGoTimeJSON(value) {
6
+ const match = goTimeJSONPattern.exec(value);
7
+ if (!match) return false;
8
+ const [, yearText, monthText, dayText, hourText, minuteText, secondText, , zone, , zoneHourText, zoneMinuteText] = match;
9
+ const year = Number(yearText);
10
+ const month = Number(monthText);
11
+ const day = Number(dayText);
12
+ const isLeap = year % 4 === 0 && (year % 100 !== 0 || year % 400 === 0);
13
+ const monthDays = [31, isLeap ? 29 : 28, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31];
14
+ return month >= 1 && month <= 12 && day >= 1 && day <= monthDays[month - 1] && Number(hourText) <= 23 && Number(minuteText) <= 59 && Number(secondText) <= 59 && (zone === "Z" || Number(zoneHourText) <= 24 && Number(zoneMinuteText) <= 60);
15
+ }
16
+ function canonicalGoTimeJSON(value) {
17
+ const match = goTimeJSONPattern.exec(value);
18
+ const [, year, month, day, hour, minute, second, fraction, zone, sign, zoneHour, zoneMinute] = match;
19
+ const clock = year + "-" + month + "-" + day + "T" + hour.padStart(2, "0") + ":" + minute + ":" + second;
20
+ const digits = (fraction ?? "").slice(0, 9).replace(/0+$/, "");
21
+ const offsetMinutes = zone === "Z" ? 0 : (Number(zoneHour) * 60 + Number(zoneMinute)) * (sign === "+" ? 1 : -1);
22
+ if (Math.abs(offsetMinutes) >= 1440) return value;
23
+ const offset = offsetMinutes === 0 ? "Z" : (offsetMinutes > 0 ? "+" : "-") + String(Math.floor(Math.abs(offsetMinutes) / 60)).padStart(2, "0") + ":" + String(Math.abs(offsetMinutes) % 60).padStart(2, "0");
24
+ return clock + (digits ? "." + digits : "") + offset;
25
+ }
26
+ var GoTimeJSONSchema = z.string().refine(isGoTimeJSON, "invalid Go time.Time JSON timestamp").transform(canonicalGoTimeJSON);
3
27
  var ConfigSchema = z.object({
4
28
  "maxResponseBytes": z.number().int().optional(),
5
29
  "webhookMaxBodyBytes": z.number().int().optional()
6
30
  });
31
+ var CredentialMaterialError = class extends TypeError {
32
+ constructor(message) {
33
+ super(message);
34
+ this.name = "CredentialMaterialError";
35
+ }
36
+ };
37
+ var sdkCredentialDecodingFailureMessages = /* @__PURE__ */ new Set([
38
+ "project credential decoding failed",
39
+ "shared project credential decoding failed",
40
+ "project credential decoding failed: this connector version does not support shared credentials"
41
+ ]);
42
+ function isCredentialMaterialError(error) {
43
+ return error instanceof CredentialMaterialError || error instanceof TypeError && sdkCredentialDecodingFailureMessages.has(error.message);
44
+ }
45
+ function decodeCredentials(value) {
46
+ if (!value || typeof value !== "object" || Array.isArray(value)) throw new CredentialMaterialError("credential fields are invalid");
47
+ const fields = value;
48
+ const allowed = /* @__PURE__ */ new Set(["api_token", "webhook_secret"]);
49
+ if (Object.keys(fields).some((key) => !allowed.has(key))) throw new CredentialMaterialError("stored credential does not match the connector credential fields");
50
+ if (fields["api_token"] != null && !(typeof fields["api_token"] === "string")) throw new CredentialMaterialError("credential api_token has an invalid type");
51
+ if (fields["webhook_secret"] != null && !(typeof fields["webhook_secret"] === "string")) throw new CredentialMaterialError("credential webhook_secret has an invalid type");
52
+ const credentials = {};
53
+ if (!fields["api_token"]) throw new CredentialMaterialError("credential api_token is required");
54
+ credentials.apiToken = new SecretString(fields["api_token"] ?? "");
55
+ credentials.webhookSecret = new SecretString(fields["webhook_secret"] ?? "");
56
+ return credentials;
57
+ }
7
58
  var SearchTasksInputSchema = z.strictObject({
8
59
  "workspaceId": z.string(),
9
60
  "listIds": z.array(z.string()).optional(),
@@ -12,7 +63,7 @@ var SearchTasksInputSchema = z.strictObject({
12
63
  "statuses": z.array(z.string()).optional(),
13
64
  "assigneeIds": z.array(z.number().int()).optional(),
14
65
  "tags": z.array(z.string()).optional(),
15
- "updatedAfter": z.iso.datetime({ offset: true }).nullable().optional(),
66
+ "updatedAfter": GoTimeJSONSchema.nullable().optional(),
16
67
  "isClosedIncluded": z.boolean().optional(),
17
68
  "areSubtasksIncluded": z.boolean().optional(),
18
69
  "orderBy": z.string().optional(),
@@ -41,11 +92,11 @@ var TaskSchema = z.strictObject({
41
92
  "status": TaskStatusSchema,
42
93
  "priority": z.number().int().optional(),
43
94
  "priorityName": z.string().optional(),
44
- "dueAt": z.iso.datetime({ offset: true }).nullable().optional(),
45
- "startAt": z.iso.datetime({ offset: true }).nullable().optional(),
46
- "createdAt": z.iso.datetime({ offset: true }).optional(),
47
- "updatedAt": z.iso.datetime({ offset: true }).optional(),
48
- "closedAt": z.iso.datetime({ offset: true }).nullable().optional(),
95
+ "dueAt": GoTimeJSONSchema.nullable().optional(),
96
+ "startAt": GoTimeJSONSchema.nullable().optional(),
97
+ "createdAt": GoTimeJSONSchema.optional(),
98
+ "updatedAt": GoTimeJSONSchema.optional(),
99
+ "closedAt": GoTimeJSONSchema.nullable().optional(),
49
100
  "isArchived": z.boolean().optional(),
50
101
  "creator": UserSchema.optional(),
51
102
  "assignees": z.array(UserSchema).nullable(),
@@ -80,7 +131,7 @@ var CreateTaskInputSchema = z.strictObject({
80
131
  "markdownDescription": z.string().optional(),
81
132
  "status": z.string().optional(),
82
133
  "priority": z.number().int().optional(),
83
- "dueAt": z.iso.datetime({ offset: true }).nullable().optional(),
134
+ "dueAt": GoTimeJSONSchema.nullable().optional(),
84
135
  "assigneeIds": z.array(z.number().int()).optional(),
85
136
  "tags": z.array(z.string()).optional(),
86
137
  "parentTaskId": z.string().optional(),
@@ -99,7 +150,7 @@ var UpdateTaskInputSchema = z.strictObject({
99
150
  "markdownDescription": z.string().optional(),
100
151
  "status": z.string().optional(),
101
152
  "priority": z.number().int().optional(),
102
- "dueAt": z.iso.datetime({ offset: true }).nullable().optional(),
153
+ "dueAt": GoTimeJSONSchema.nullable().optional(),
103
154
  "addAssigneeIds": z.array(z.number().int()).optional(),
104
155
  "removeAssigneeIds": z.array(z.number().int()).optional()
105
156
  });
@@ -124,7 +175,7 @@ var AddCommentInputSchema = z.strictObject({
124
175
  var AddCommentOutputSchema = z.strictObject({
125
176
  "taskId": z.string(),
126
177
  "commentId": z.string().optional(),
127
- "createdAt": z.iso.datetime({ offset: true }).nullable().optional(),
178
+ "createdAt": GoTimeJSONSchema.nullable().optional(),
128
179
  "wasAlreadyApplied": z.boolean().optional()
129
180
  });
130
181
  var FindMemberByEmailInputSchema = z.strictObject({
@@ -208,10 +259,12 @@ var CreateTaskDefinition = {
208
259
  { id: "created", description: "ClickUp created the task; a retried attempt that found its own earlier task in the List reports it instead of creating another." },
209
260
  { id: "notFound", description: "The List does not exist or the connection cannot see it; nothing was created.", optional: true },
210
261
  { id: "providerRejected", description: "ClickUp conclusively rejected the task, such as an unknown status, assignee, or custom field value, or missing permission; nothing was created.", optional: true },
211
- { id: "uncertain", description: "An earlier attempt sent the create but its outcome cannot be confirmed and the List shows no single matching task, so the task may exist; the connector never sends it again.", optional: true },
262
+ { id: "uncertain", description: "Earlier attempts sent the create up to the send cap, ClickUp accepted it without a usable task ID, or read-back after a possible send cannot confirm a single matching task, including a List that is now missing, so the task may exist; the connector does not send it again.", optional: true },
212
263
  { id: "defect", description: "Local input, connection configuration, or connector definition is invalid.", optional: true }
213
264
  ],
214
- stepDefaults: { executeMethodTimeoutMs: 3e4, executeDurability: "sync", executeRetry: { initialIntervalMs: 1e3, backoffCoefficient: 2, maximumIntervalMs: 6e4, maximumAttempts: 5, totalDurationMs: 3e5 } }
265
+ stepDefaults: { executeMethodTimeoutMs: 3e4, executeDurability: "sync", executeRetry: { initialIntervalMs: 1e3, backoffCoefficient: 2, maximumIntervalMs: 6e4, maximumAttempts: 5, totalDurationMs: 3e5 } },
266
+ repeatOnUnknown: "limited",
267
+ maxSends: 3
215
268
  };
216
269
  var CreateTaskMetadata = { kind: "mutation", idempotency: "required", authorization: "required" };
217
270
  var UpdateTaskBranch = {
@@ -232,10 +285,11 @@ var UpdateTaskDefinition = {
232
285
  { id: "updated", description: "ClickUp applied every requested change, including when the task already had those values, and the Value holds the task it returned." },
233
286
  { id: "notFound", description: "The task does not exist or the connection cannot see it.", optional: true },
234
287
  { id: "providerRejected", description: "ClickUp conclusively rejected the change, such as a status that is not in the task's List or missing permission.", optional: true },
235
- { id: "invalidResponse", description: "ClickUp returned an invalid or oversized task after the update, so the change may have been applied.", optional: true },
288
+ { id: "invalidResponse", description: "Kept for compatibility and no longer selected: the update is safe to repeat, so an invalid or oversized task after the update retries.", optional: true },
236
289
  { id: "defect", description: "Local input, connection configuration, or connector definition is invalid.", optional: true }
237
290
  ],
238
- stepDefaults: { executeMethodTimeoutMs: 3e4, executeDurability: "async" }
291
+ stepDefaults: { executeMethodTimeoutMs: 3e4, executeDurability: "async" },
292
+ repeatOnUnknown: "safe"
239
293
  };
240
294
  var UpdateTaskMetadata = { kind: "mutation", idempotency: "required", authorization: "required" };
241
295
  var UpdateTaskTagsBranch = {
@@ -256,10 +310,11 @@ var UpdateTaskTagsDefinition = {
256
310
  { id: "updated", description: "ClickUp applied every tag change, and the Value holds the task's tags read back." },
257
311
  { id: "notFound", description: "The task does not exist or the connection cannot see it.", optional: true },
258
312
  { id: "providerRejected", description: "ClickUp conclusively rejected a tag change, such as missing permission; earlier changes in the same Step may have been applied.", optional: true },
259
- { id: "invalidResponse", description: "ClickUp returned an invalid or oversized task when its tags were read back; the tag changes were applied.", optional: true },
313
+ { id: "invalidResponse", description: "Kept for compatibility and no longer selected: the tag changes are safe to repeat, so an invalid or oversized task read back retries.", optional: true },
260
314
  { id: "defect", description: "Local input, connection configuration, or connector definition is invalid.", optional: true }
261
315
  ],
262
- stepDefaults: { executeMethodTimeoutMs: 3e4, executeDurability: "async" }
316
+ stepDefaults: { executeMethodTimeoutMs: 3e4, executeDurability: "async" },
317
+ repeatOnUnknown: "safe"
263
318
  };
264
319
  var UpdateTaskTagsMetadata = { kind: "mutation", idempotency: "required", authorization: "required" };
265
320
  var AddCommentBranch = {
@@ -280,10 +335,12 @@ var AddCommentDefinition = {
280
335
  { id: "added", description: "The comment is on the task; a retried attempt that found its own earlier comment reports it instead of adding another." },
281
336
  { id: "notFound", description: "The task does not exist or the connection cannot see it; nothing was added.", optional: true },
282
337
  { id: "providerRejected", description: "ClickUp conclusively rejected the comment, such as missing permission; nothing was added.", optional: true },
283
- { id: "uncertain", description: "An earlier attempt sent the comment but its outcome cannot be confirmed and the task shows no matching comment, so the comment may exist; the connector never sends it again.", optional: true },
338
+ { id: "uncertain", description: "Earlier attempts sent the comment up to the send cap, ClickUp accepted it without a usable comment ID, or read-back after a possible send cannot confirm a single matching comment, including a task that is now missing, so the comment may exist; the connector does not send it again.", optional: true },
284
339
  { id: "defect", description: "Local input, connection configuration, or connector definition is invalid.", optional: true }
285
340
  ],
286
- stepDefaults: { executeMethodTimeoutMs: 3e4, executeDurability: "sync", executeRetry: { initialIntervalMs: 1e3, backoffCoefficient: 2, maximumIntervalMs: 6e4, maximumAttempts: 5, totalDurationMs: 3e5 } }
341
+ stepDefaults: { executeMethodTimeoutMs: 3e4, executeDurability: "sync", executeRetry: { initialIntervalMs: 1e3, backoffCoefficient: 2, maximumIntervalMs: 6e4, maximumAttempts: 5, totalDurationMs: 3e5 } },
342
+ repeatOnUnknown: "limited",
343
+ maxSends: 3
287
344
  };
288
345
  var AddCommentMetadata = { kind: "mutation", idempotency: "required", authorization: "required" };
289
346
  var FindMemberByEmailBranch = {
@@ -343,6 +400,9 @@ function newProjectConnection(project, connectionName, createClient) {
343
400
 
344
401
  export {
345
402
  ConfigSchema,
403
+ CredentialMaterialError,
404
+ isCredentialMaterialError,
405
+ decodeCredentials,
346
406
  SearchTasksInputSchema,
347
407
  TaskStatusSchema,
348
408
  UserSchema,