exponential-sdk 1.0.1 → 1.2.0
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.ts +676 -1
- package/dist/index.js +192 -0
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -227,6 +227,264 @@ interface TrpcClient {
|
|
|
227
227
|
}) => Promise<unknown>;
|
|
228
228
|
};
|
|
229
229
|
};
|
|
230
|
+
actionComment: {
|
|
231
|
+
getComments: {
|
|
232
|
+
query: (input: {
|
|
233
|
+
actionId: string;
|
|
234
|
+
}) => Promise<unknown[]>;
|
|
235
|
+
};
|
|
236
|
+
addComment: {
|
|
237
|
+
mutate: (input: {
|
|
238
|
+
actionId: string;
|
|
239
|
+
content: string;
|
|
240
|
+
}) => Promise<unknown>;
|
|
241
|
+
};
|
|
242
|
+
updateComment: {
|
|
243
|
+
mutate: (input: {
|
|
244
|
+
commentId: string;
|
|
245
|
+
content: string;
|
|
246
|
+
}) => Promise<unknown>;
|
|
247
|
+
};
|
|
248
|
+
deleteComment: {
|
|
249
|
+
mutate: (input: {
|
|
250
|
+
commentId: string;
|
|
251
|
+
}) => Promise<unknown>;
|
|
252
|
+
};
|
|
253
|
+
};
|
|
254
|
+
epic: {
|
|
255
|
+
list: {
|
|
256
|
+
query: (input: {
|
|
257
|
+
workspaceId: string;
|
|
258
|
+
status?: 'OPEN' | 'IN_PROGRESS' | 'DONE' | 'CANCELLED';
|
|
259
|
+
}) => Promise<unknown[]>;
|
|
260
|
+
};
|
|
261
|
+
getById: {
|
|
262
|
+
query: (input: {
|
|
263
|
+
id: string;
|
|
264
|
+
}) => Promise<unknown>;
|
|
265
|
+
};
|
|
266
|
+
create: {
|
|
267
|
+
mutate: (input: {
|
|
268
|
+
workspaceId: string;
|
|
269
|
+
name: string;
|
|
270
|
+
description?: string;
|
|
271
|
+
priority?: 'HIGH' | 'MEDIUM' | 'LOW' | 'NONE';
|
|
272
|
+
startDate?: Date;
|
|
273
|
+
targetDate?: Date;
|
|
274
|
+
}) => Promise<unknown>;
|
|
275
|
+
};
|
|
276
|
+
update: {
|
|
277
|
+
mutate: (input: {
|
|
278
|
+
id: string;
|
|
279
|
+
name?: string;
|
|
280
|
+
description?: string | null;
|
|
281
|
+
status?: 'OPEN' | 'IN_PROGRESS' | 'DONE' | 'CANCELLED';
|
|
282
|
+
priority?: 'HIGH' | 'MEDIUM' | 'LOW' | 'NONE';
|
|
283
|
+
startDate?: Date | null;
|
|
284
|
+
targetDate?: Date | null;
|
|
285
|
+
}) => Promise<unknown>;
|
|
286
|
+
};
|
|
287
|
+
delete: {
|
|
288
|
+
mutate: (input: {
|
|
289
|
+
id: string;
|
|
290
|
+
}) => Promise<unknown>;
|
|
291
|
+
};
|
|
292
|
+
};
|
|
293
|
+
product: {
|
|
294
|
+
product: {
|
|
295
|
+
list: {
|
|
296
|
+
query: (input: {
|
|
297
|
+
workspaceId: string;
|
|
298
|
+
}) => Promise<unknown[]>;
|
|
299
|
+
};
|
|
300
|
+
getById: {
|
|
301
|
+
query: (input: {
|
|
302
|
+
id: string;
|
|
303
|
+
}) => Promise<unknown>;
|
|
304
|
+
};
|
|
305
|
+
getBySlug: {
|
|
306
|
+
query: (input: {
|
|
307
|
+
workspaceId: string;
|
|
308
|
+
slug: string;
|
|
309
|
+
}) => Promise<unknown>;
|
|
310
|
+
};
|
|
311
|
+
create: {
|
|
312
|
+
mutate: (input: {
|
|
313
|
+
workspaceId: string;
|
|
314
|
+
name: string;
|
|
315
|
+
slug: string;
|
|
316
|
+
description?: string;
|
|
317
|
+
icon?: string;
|
|
318
|
+
color?: string;
|
|
319
|
+
}) => Promise<unknown>;
|
|
320
|
+
};
|
|
321
|
+
update: {
|
|
322
|
+
mutate: (input: {
|
|
323
|
+
id: string;
|
|
324
|
+
name?: string;
|
|
325
|
+
description?: string;
|
|
326
|
+
icon?: string;
|
|
327
|
+
color?: string;
|
|
328
|
+
funTicketIds?: boolean;
|
|
329
|
+
}) => Promise<unknown>;
|
|
330
|
+
};
|
|
331
|
+
delete: {
|
|
332
|
+
mutate: (input: {
|
|
333
|
+
id: string;
|
|
334
|
+
}) => Promise<unknown>;
|
|
335
|
+
};
|
|
336
|
+
};
|
|
337
|
+
feature: {
|
|
338
|
+
list: {
|
|
339
|
+
query: (input: {
|
|
340
|
+
productId: string;
|
|
341
|
+
status?: 'IDEA' | 'DEFINED' | 'IN_PROGRESS' | 'SHIPPED' | 'ARCHIVED';
|
|
342
|
+
}) => Promise<unknown[]>;
|
|
343
|
+
};
|
|
344
|
+
getById: {
|
|
345
|
+
query: (input: {
|
|
346
|
+
id: string;
|
|
347
|
+
}) => Promise<unknown>;
|
|
348
|
+
};
|
|
349
|
+
create: {
|
|
350
|
+
mutate: (input: {
|
|
351
|
+
productId: string;
|
|
352
|
+
name: string;
|
|
353
|
+
description?: string;
|
|
354
|
+
vision?: string;
|
|
355
|
+
status?: 'IDEA' | 'DEFINED' | 'IN_PROGRESS' | 'SHIPPED' | 'ARCHIVED';
|
|
356
|
+
effort?: number;
|
|
357
|
+
priority?: number;
|
|
358
|
+
goalId?: number;
|
|
359
|
+
}) => Promise<unknown>;
|
|
360
|
+
};
|
|
361
|
+
update: {
|
|
362
|
+
mutate: (input: {
|
|
363
|
+
id: string;
|
|
364
|
+
name?: string;
|
|
365
|
+
description?: string;
|
|
366
|
+
vision?: string;
|
|
367
|
+
status?: 'IDEA' | 'DEFINED' | 'IN_PROGRESS' | 'SHIPPED' | 'ARCHIVED';
|
|
368
|
+
effort?: number;
|
|
369
|
+
priority?: number;
|
|
370
|
+
goalId?: number | null;
|
|
371
|
+
}) => Promise<unknown>;
|
|
372
|
+
};
|
|
373
|
+
delete: {
|
|
374
|
+
mutate: (input: {
|
|
375
|
+
id: string;
|
|
376
|
+
}) => Promise<unknown>;
|
|
377
|
+
};
|
|
378
|
+
};
|
|
379
|
+
ticket: {
|
|
380
|
+
list: {
|
|
381
|
+
query: (input: {
|
|
382
|
+
productId: string;
|
|
383
|
+
status?: string;
|
|
384
|
+
type?: string;
|
|
385
|
+
featureId?: string;
|
|
386
|
+
epicId?: string;
|
|
387
|
+
cycleId?: string;
|
|
388
|
+
assigneeId?: string;
|
|
389
|
+
}) => Promise<unknown[]>;
|
|
390
|
+
};
|
|
391
|
+
getById: {
|
|
392
|
+
query: (input: {
|
|
393
|
+
id: string;
|
|
394
|
+
}) => Promise<unknown>;
|
|
395
|
+
};
|
|
396
|
+
create: {
|
|
397
|
+
mutate: (input: {
|
|
398
|
+
productId: string;
|
|
399
|
+
title: string;
|
|
400
|
+
body?: string;
|
|
401
|
+
type?: string;
|
|
402
|
+
status?: string;
|
|
403
|
+
priority?: number;
|
|
404
|
+
points?: number;
|
|
405
|
+
branchName?: string;
|
|
406
|
+
prUrl?: string;
|
|
407
|
+
designUrl?: string;
|
|
408
|
+
specUrl?: string;
|
|
409
|
+
links?: Record<string, string>;
|
|
410
|
+
epicId?: string;
|
|
411
|
+
featureId?: string;
|
|
412
|
+
cycleId?: string;
|
|
413
|
+
scopeId?: string;
|
|
414
|
+
assigneeId?: string;
|
|
415
|
+
templateId?: string;
|
|
416
|
+
}) => Promise<unknown>;
|
|
417
|
+
};
|
|
418
|
+
update: {
|
|
419
|
+
mutate: (input: {
|
|
420
|
+
id: string;
|
|
421
|
+
title?: string;
|
|
422
|
+
body?: string;
|
|
423
|
+
type?: string;
|
|
424
|
+
status?: string;
|
|
425
|
+
priority?: number | null;
|
|
426
|
+
points?: number | null;
|
|
427
|
+
branchName?: string | null;
|
|
428
|
+
prUrl?: string | null;
|
|
429
|
+
designUrl?: string | null;
|
|
430
|
+
specUrl?: string | null;
|
|
431
|
+
links?: Record<string, string> | null;
|
|
432
|
+
epicId?: string | null;
|
|
433
|
+
featureId?: string | null;
|
|
434
|
+
cycleId?: string | null;
|
|
435
|
+
scopeId?: string | null;
|
|
436
|
+
assigneeId?: string | null;
|
|
437
|
+
}) => Promise<unknown>;
|
|
438
|
+
};
|
|
439
|
+
delete: {
|
|
440
|
+
mutate: (input: {
|
|
441
|
+
id: string;
|
|
442
|
+
}) => Promise<unknown>;
|
|
443
|
+
};
|
|
444
|
+
search: {
|
|
445
|
+
query: (input: {
|
|
446
|
+
productId: string;
|
|
447
|
+
query?: string;
|
|
448
|
+
excludeTicketId?: string;
|
|
449
|
+
limit?: number;
|
|
450
|
+
}) => Promise<unknown[]>;
|
|
451
|
+
};
|
|
452
|
+
addDependency: {
|
|
453
|
+
mutate: (input: {
|
|
454
|
+
ticketId: string;
|
|
455
|
+
dependsOnId: string;
|
|
456
|
+
}) => Promise<unknown>;
|
|
457
|
+
};
|
|
458
|
+
removeDependency: {
|
|
459
|
+
mutate: (input: {
|
|
460
|
+
ticketId: string;
|
|
461
|
+
dependsOnId: string;
|
|
462
|
+
}) => Promise<unknown>;
|
|
463
|
+
};
|
|
464
|
+
addComment: {
|
|
465
|
+
mutate: (input: {
|
|
466
|
+
ticketId: string;
|
|
467
|
+
content: string;
|
|
468
|
+
}) => Promise<unknown>;
|
|
469
|
+
};
|
|
470
|
+
deleteComment: {
|
|
471
|
+
mutate: (input: {
|
|
472
|
+
id: string;
|
|
473
|
+
}) => Promise<unknown>;
|
|
474
|
+
};
|
|
475
|
+
linkAction: {
|
|
476
|
+
mutate: (input: {
|
|
477
|
+
ticketId: string;
|
|
478
|
+
actionId: string;
|
|
479
|
+
}) => Promise<unknown>;
|
|
480
|
+
};
|
|
481
|
+
unlinkAction: {
|
|
482
|
+
mutate: (input: {
|
|
483
|
+
actionId: string;
|
|
484
|
+
}) => Promise<unknown>;
|
|
485
|
+
};
|
|
486
|
+
};
|
|
487
|
+
};
|
|
230
488
|
}
|
|
231
489
|
declare function isTRPCError(error: unknown): error is TRPCClientError<any>;
|
|
232
490
|
|
|
@@ -360,6 +618,47 @@ declare class ActionsApi {
|
|
|
360
618
|
update(input: ActionUpdateInput): Promise<Action>;
|
|
361
619
|
}
|
|
362
620
|
|
|
621
|
+
interface CommentAuthor {
|
|
622
|
+
id: string;
|
|
623
|
+
name: string | null;
|
|
624
|
+
image: string | null;
|
|
625
|
+
}
|
|
626
|
+
interface ActionComment {
|
|
627
|
+
id: string;
|
|
628
|
+
actionId: string;
|
|
629
|
+
authorId: string;
|
|
630
|
+
content: string;
|
|
631
|
+
createdAt: Date;
|
|
632
|
+
updatedAt: Date;
|
|
633
|
+
author: CommentAuthor;
|
|
634
|
+
}
|
|
635
|
+
interface TicketComment {
|
|
636
|
+
id: string;
|
|
637
|
+
ticketId: string;
|
|
638
|
+
authorId: string;
|
|
639
|
+
content: string;
|
|
640
|
+
createdAt: Date;
|
|
641
|
+
updatedAt: Date;
|
|
642
|
+
author: CommentAuthor;
|
|
643
|
+
}
|
|
644
|
+
|
|
645
|
+
interface ActionCommentAddInput {
|
|
646
|
+
actionId: string;
|
|
647
|
+
content: string;
|
|
648
|
+
}
|
|
649
|
+
interface ActionCommentUpdateInput {
|
|
650
|
+
commentId: string;
|
|
651
|
+
content: string;
|
|
652
|
+
}
|
|
653
|
+
declare class ActionCommentsApi {
|
|
654
|
+
private client;
|
|
655
|
+
constructor(client: TrpcClient);
|
|
656
|
+
list(actionId: string): Promise<ActionComment[]>;
|
|
657
|
+
add(input: ActionCommentAddInput): Promise<ActionComment>;
|
|
658
|
+
update(input: ActionCommentUpdateInput): Promise<ActionComment>;
|
|
659
|
+
delete(commentId: string): Promise<ActionComment>;
|
|
660
|
+
}
|
|
661
|
+
|
|
363
662
|
interface Project {
|
|
364
663
|
id: string;
|
|
365
664
|
name: string;
|
|
@@ -666,6 +965,377 @@ declare class PipelinesApi {
|
|
|
666
965
|
deleteDeal(id: string): Promise<void>;
|
|
667
966
|
}
|
|
668
967
|
|
|
968
|
+
type TicketStatus = 'BACKLOG' | 'NEEDS_REFINEMENT' | 'READY_TO_PLAN' | 'COMMITTED' | 'IN_PROGRESS' | 'BLOCKED' | 'QA' | 'DONE' | 'DEPLOYED' | 'ARCHIVED';
|
|
969
|
+
type TicketType = 'BUG' | 'FEATURE' | 'CHORE' | 'IMPROVEMENT' | 'SPIKE' | 'RESEARCH';
|
|
970
|
+
interface TicketAssignee {
|
|
971
|
+
id: string;
|
|
972
|
+
name: string | null;
|
|
973
|
+
email?: string | null;
|
|
974
|
+
image: string | null;
|
|
975
|
+
}
|
|
976
|
+
interface TicketDependencyEdge {
|
|
977
|
+
id: string;
|
|
978
|
+
number: number | null;
|
|
979
|
+
shortId: string | null;
|
|
980
|
+
title: string;
|
|
981
|
+
status: TicketStatus;
|
|
982
|
+
priority: number | null;
|
|
983
|
+
assignee: TicketAssignee | null;
|
|
984
|
+
}
|
|
985
|
+
interface Ticket {
|
|
986
|
+
id: string;
|
|
987
|
+
productId: string;
|
|
988
|
+
number: number | null;
|
|
989
|
+
shortId: string | null;
|
|
990
|
+
title: string;
|
|
991
|
+
body: string | null;
|
|
992
|
+
type: TicketType;
|
|
993
|
+
status: TicketStatus;
|
|
994
|
+
priority: number | null;
|
|
995
|
+
points: number | null;
|
|
996
|
+
branchName: string | null;
|
|
997
|
+
prUrl: string | null;
|
|
998
|
+
designUrl: string | null;
|
|
999
|
+
specUrl: string | null;
|
|
1000
|
+
links: Record<string, string> | null;
|
|
1001
|
+
epicId: string | null;
|
|
1002
|
+
featureId: string | null;
|
|
1003
|
+
cycleId: string | null;
|
|
1004
|
+
scopeId: string | null;
|
|
1005
|
+
assigneeId: string | null;
|
|
1006
|
+
createdById: string | null;
|
|
1007
|
+
completedAt: Date | null;
|
|
1008
|
+
createdAt: Date;
|
|
1009
|
+
updatedAt: Date;
|
|
1010
|
+
assignee?: TicketAssignee | null;
|
|
1011
|
+
feature?: {
|
|
1012
|
+
id: string;
|
|
1013
|
+
name: string;
|
|
1014
|
+
status?: string;
|
|
1015
|
+
} | null;
|
|
1016
|
+
epic?: {
|
|
1017
|
+
id: string;
|
|
1018
|
+
name: string;
|
|
1019
|
+
status?: string;
|
|
1020
|
+
} | null;
|
|
1021
|
+
cycle?: {
|
|
1022
|
+
id: string;
|
|
1023
|
+
name: string;
|
|
1024
|
+
status?: string;
|
|
1025
|
+
startDate?: Date | null;
|
|
1026
|
+
endDate?: Date | null;
|
|
1027
|
+
} | null;
|
|
1028
|
+
openBlockerCount?: number;
|
|
1029
|
+
isBlocked?: boolean;
|
|
1030
|
+
_count?: {
|
|
1031
|
+
actions?: number;
|
|
1032
|
+
comments?: number;
|
|
1033
|
+
};
|
|
1034
|
+
}
|
|
1035
|
+
interface TicketDetail extends Ticket {
|
|
1036
|
+
product?: {
|
|
1037
|
+
id: string;
|
|
1038
|
+
slug: string;
|
|
1039
|
+
workspaceId: string;
|
|
1040
|
+
name: string;
|
|
1041
|
+
funTicketIds?: boolean;
|
|
1042
|
+
};
|
|
1043
|
+
dependsOn?: TicketDependencyEdge[];
|
|
1044
|
+
requiredFor?: TicketDependencyEdge[];
|
|
1045
|
+
actions?: Array<{
|
|
1046
|
+
id: string;
|
|
1047
|
+
name: string;
|
|
1048
|
+
status: string;
|
|
1049
|
+
completedAt: Date | null;
|
|
1050
|
+
kanbanStatus: string | null;
|
|
1051
|
+
}>;
|
|
1052
|
+
comments?: Array<{
|
|
1053
|
+
id: string;
|
|
1054
|
+
content: string;
|
|
1055
|
+
createdAt: Date;
|
|
1056
|
+
updatedAt: Date;
|
|
1057
|
+
author: TicketAssignee;
|
|
1058
|
+
}>;
|
|
1059
|
+
}
|
|
1060
|
+
|
|
1061
|
+
interface TicketListOptions {
|
|
1062
|
+
productId: string;
|
|
1063
|
+
status?: TicketStatus;
|
|
1064
|
+
type?: TicketType;
|
|
1065
|
+
featureId?: string;
|
|
1066
|
+
epicId?: string;
|
|
1067
|
+
cycleId?: string;
|
|
1068
|
+
assigneeId?: string;
|
|
1069
|
+
}
|
|
1070
|
+
interface TicketCreateInput {
|
|
1071
|
+
productId: string;
|
|
1072
|
+
title: string;
|
|
1073
|
+
body?: string;
|
|
1074
|
+
type?: TicketType;
|
|
1075
|
+
status?: TicketStatus;
|
|
1076
|
+
/** 0–4; lower is higher priority. */
|
|
1077
|
+
priority?: number;
|
|
1078
|
+
points?: number;
|
|
1079
|
+
branchName?: string;
|
|
1080
|
+
prUrl?: string;
|
|
1081
|
+
designUrl?: string;
|
|
1082
|
+
specUrl?: string;
|
|
1083
|
+
links?: Record<string, string>;
|
|
1084
|
+
epicId?: string;
|
|
1085
|
+
featureId?: string;
|
|
1086
|
+
cycleId?: string;
|
|
1087
|
+
scopeId?: string;
|
|
1088
|
+
assigneeId?: string;
|
|
1089
|
+
templateId?: string;
|
|
1090
|
+
}
|
|
1091
|
+
interface TicketUpdateInput {
|
|
1092
|
+
id: string;
|
|
1093
|
+
title?: string;
|
|
1094
|
+
body?: string;
|
|
1095
|
+
type?: TicketType;
|
|
1096
|
+
status?: TicketStatus;
|
|
1097
|
+
priority?: number | null;
|
|
1098
|
+
points?: number | null;
|
|
1099
|
+
branchName?: string | null;
|
|
1100
|
+
prUrl?: string | null;
|
|
1101
|
+
designUrl?: string | null;
|
|
1102
|
+
specUrl?: string | null;
|
|
1103
|
+
links?: Record<string, string> | null;
|
|
1104
|
+
epicId?: string | null;
|
|
1105
|
+
featureId?: string | null;
|
|
1106
|
+
cycleId?: string | null;
|
|
1107
|
+
scopeId?: string | null;
|
|
1108
|
+
assigneeId?: string | null;
|
|
1109
|
+
}
|
|
1110
|
+
interface TicketCommentAddInput {
|
|
1111
|
+
ticketId: string;
|
|
1112
|
+
content: string;
|
|
1113
|
+
}
|
|
1114
|
+
interface TicketSearchOptions {
|
|
1115
|
+
productId: string;
|
|
1116
|
+
query?: string;
|
|
1117
|
+
excludeTicketId?: string;
|
|
1118
|
+
limit?: number;
|
|
1119
|
+
}
|
|
1120
|
+
declare class TicketsApi {
|
|
1121
|
+
private client;
|
|
1122
|
+
constructor(client: TrpcClient);
|
|
1123
|
+
list(options: TicketListOptions): Promise<Ticket[]>;
|
|
1124
|
+
get(id: string): Promise<TicketDetail>;
|
|
1125
|
+
create(input: TicketCreateInput): Promise<Ticket>;
|
|
1126
|
+
update(input: TicketUpdateInput): Promise<Ticket>;
|
|
1127
|
+
delete(id: string): Promise<{
|
|
1128
|
+
success: boolean;
|
|
1129
|
+
}>;
|
|
1130
|
+
search(options: TicketSearchOptions): Promise<TicketDependencyEdge[]>;
|
|
1131
|
+
/** Mark `ticketId` as blocked by `dependsOnId`. */
|
|
1132
|
+
addDependency(ticketId: string, dependsOnId: string): Promise<{
|
|
1133
|
+
id: string;
|
|
1134
|
+
dependsOn: TicketDependencyEdge;
|
|
1135
|
+
}>;
|
|
1136
|
+
removeDependency(ticketId: string, dependsOnId: string): Promise<{
|
|
1137
|
+
success: boolean;
|
|
1138
|
+
}>;
|
|
1139
|
+
addComment(input: TicketCommentAddInput): Promise<TicketComment>;
|
|
1140
|
+
deleteComment(id: string): Promise<{
|
|
1141
|
+
success: boolean;
|
|
1142
|
+
}>;
|
|
1143
|
+
/** Attach an existing action to a ticket. */
|
|
1144
|
+
linkAction(ticketId: string, actionId: string): Promise<Action>;
|
|
1145
|
+
/** Detach an action from whatever ticket it's linked to. */
|
|
1146
|
+
unlinkAction(actionId: string): Promise<Action>;
|
|
1147
|
+
}
|
|
1148
|
+
|
|
1149
|
+
interface Product {
|
|
1150
|
+
id: string;
|
|
1151
|
+
workspaceId: string;
|
|
1152
|
+
name: string;
|
|
1153
|
+
slug: string;
|
|
1154
|
+
description: string | null;
|
|
1155
|
+
icon: string | null;
|
|
1156
|
+
color: string | null;
|
|
1157
|
+
funTicketIds: boolean;
|
|
1158
|
+
ticketCounter: number;
|
|
1159
|
+
createdById: string | null;
|
|
1160
|
+
createdAt: Date;
|
|
1161
|
+
updatedAt: Date;
|
|
1162
|
+
_count?: {
|
|
1163
|
+
features?: number;
|
|
1164
|
+
tickets?: number;
|
|
1165
|
+
researches?: number;
|
|
1166
|
+
retrospectives?: number;
|
|
1167
|
+
};
|
|
1168
|
+
}
|
|
1169
|
+
|
|
1170
|
+
interface ProductCreateInput {
|
|
1171
|
+
workspaceId: string;
|
|
1172
|
+
name: string;
|
|
1173
|
+
/** Kebab-case slug; must match `/^[a-z0-9-]+$/`. */
|
|
1174
|
+
slug: string;
|
|
1175
|
+
description?: string;
|
|
1176
|
+
icon?: string;
|
|
1177
|
+
color?: string;
|
|
1178
|
+
}
|
|
1179
|
+
interface ProductUpdateInput {
|
|
1180
|
+
id: string;
|
|
1181
|
+
name?: string;
|
|
1182
|
+
description?: string;
|
|
1183
|
+
icon?: string;
|
|
1184
|
+
color?: string;
|
|
1185
|
+
funTicketIds?: boolean;
|
|
1186
|
+
}
|
|
1187
|
+
declare class ProductsApi {
|
|
1188
|
+
private client;
|
|
1189
|
+
constructor(client: TrpcClient);
|
|
1190
|
+
list(workspaceId: string): Promise<Product[]>;
|
|
1191
|
+
get(id: string): Promise<Product>;
|
|
1192
|
+
getBySlug(workspaceId: string, slug: string): Promise<Product>;
|
|
1193
|
+
/**
|
|
1194
|
+
* Resolve a product reference (slug or CUID) to a full Product. Falls back
|
|
1195
|
+
* to slug lookup if the bare CUID lookup fails — callers can pass either.
|
|
1196
|
+
*/
|
|
1197
|
+
resolve(workspaceId: string, slugOrId: string): Promise<Product>;
|
|
1198
|
+
create(input: ProductCreateInput): Promise<Product>;
|
|
1199
|
+
update(input: ProductUpdateInput): Promise<Product>;
|
|
1200
|
+
delete(id: string): Promise<{
|
|
1201
|
+
success: boolean;
|
|
1202
|
+
}>;
|
|
1203
|
+
}
|
|
1204
|
+
|
|
1205
|
+
type FeatureStatus = 'IDEA' | 'DEFINED' | 'IN_PROGRESS' | 'SHIPPED' | 'ARCHIVED';
|
|
1206
|
+
type FeatureScopeStatus = 'PLANNED' | 'IN_PROGRESS' | 'SHIPPED' | 'DEPRECATED';
|
|
1207
|
+
interface FeatureScope {
|
|
1208
|
+
id: string;
|
|
1209
|
+
featureId: string;
|
|
1210
|
+
version: string;
|
|
1211
|
+
status: FeatureScopeStatus;
|
|
1212
|
+
summary: string | null;
|
|
1213
|
+
displayOrder: number;
|
|
1214
|
+
createdAt: Date;
|
|
1215
|
+
updatedAt: Date;
|
|
1216
|
+
}
|
|
1217
|
+
interface Feature {
|
|
1218
|
+
id: string;
|
|
1219
|
+
productId: string;
|
|
1220
|
+
name: string;
|
|
1221
|
+
description: string | null;
|
|
1222
|
+
vision: string | null;
|
|
1223
|
+
status: FeatureStatus;
|
|
1224
|
+
effort: number | null;
|
|
1225
|
+
priority: number | null;
|
|
1226
|
+
goalId: number | null;
|
|
1227
|
+
createdById: string | null;
|
|
1228
|
+
createdAt: Date;
|
|
1229
|
+
updatedAt: Date;
|
|
1230
|
+
goal?: {
|
|
1231
|
+
id: number;
|
|
1232
|
+
title: string;
|
|
1233
|
+
period: string | null;
|
|
1234
|
+
} | null;
|
|
1235
|
+
scopes?: FeatureScope[];
|
|
1236
|
+
_count?: {
|
|
1237
|
+
scopes?: number;
|
|
1238
|
+
userStories?: number;
|
|
1239
|
+
tickets?: number;
|
|
1240
|
+
};
|
|
1241
|
+
}
|
|
1242
|
+
|
|
1243
|
+
interface FeatureListOptions {
|
|
1244
|
+
productId: string;
|
|
1245
|
+
status?: FeatureStatus;
|
|
1246
|
+
}
|
|
1247
|
+
interface FeatureCreateInput {
|
|
1248
|
+
productId: string;
|
|
1249
|
+
name: string;
|
|
1250
|
+
description?: string;
|
|
1251
|
+
vision?: string;
|
|
1252
|
+
status?: FeatureStatus;
|
|
1253
|
+
effort?: number;
|
|
1254
|
+
/** 0–4; lower is higher priority. */
|
|
1255
|
+
priority?: number;
|
|
1256
|
+
goalId?: number;
|
|
1257
|
+
}
|
|
1258
|
+
interface FeatureUpdateInput {
|
|
1259
|
+
id: string;
|
|
1260
|
+
name?: string;
|
|
1261
|
+
description?: string;
|
|
1262
|
+
vision?: string;
|
|
1263
|
+
status?: FeatureStatus;
|
|
1264
|
+
effort?: number;
|
|
1265
|
+
priority?: number;
|
|
1266
|
+
goalId?: number | null;
|
|
1267
|
+
}
|
|
1268
|
+
declare class FeaturesApi {
|
|
1269
|
+
private client;
|
|
1270
|
+
constructor(client: TrpcClient);
|
|
1271
|
+
list(options: FeatureListOptions): Promise<Feature[]>;
|
|
1272
|
+
get(id: string): Promise<Feature>;
|
|
1273
|
+
create(input: FeatureCreateInput): Promise<Feature>;
|
|
1274
|
+
update(input: FeatureUpdateInput): Promise<Feature>;
|
|
1275
|
+
delete(id: string): Promise<{
|
|
1276
|
+
success: boolean;
|
|
1277
|
+
}>;
|
|
1278
|
+
}
|
|
1279
|
+
|
|
1280
|
+
type EpicStatus = 'OPEN' | 'IN_PROGRESS' | 'DONE' | 'CANCELLED';
|
|
1281
|
+
type EpicPriority = 'HIGH' | 'MEDIUM' | 'LOW' | 'NONE';
|
|
1282
|
+
interface Epic {
|
|
1283
|
+
id: string;
|
|
1284
|
+
workspaceId: string;
|
|
1285
|
+
name: string;
|
|
1286
|
+
description: string | null;
|
|
1287
|
+
status: EpicStatus;
|
|
1288
|
+
priority: EpicPriority;
|
|
1289
|
+
startDate: Date | null;
|
|
1290
|
+
targetDate: Date | null;
|
|
1291
|
+
ownerId: string | null;
|
|
1292
|
+
createdAt: Date;
|
|
1293
|
+
updatedAt: Date;
|
|
1294
|
+
owner?: {
|
|
1295
|
+
id: string;
|
|
1296
|
+
name: string | null;
|
|
1297
|
+
email: string | null;
|
|
1298
|
+
image: string | null;
|
|
1299
|
+
} | null;
|
|
1300
|
+
_count?: {
|
|
1301
|
+
actions?: number;
|
|
1302
|
+
tickets?: number;
|
|
1303
|
+
};
|
|
1304
|
+
}
|
|
1305
|
+
|
|
1306
|
+
interface EpicListOptions {
|
|
1307
|
+
workspaceId: string;
|
|
1308
|
+
status?: EpicStatus;
|
|
1309
|
+
}
|
|
1310
|
+
interface EpicCreateInput {
|
|
1311
|
+
workspaceId: string;
|
|
1312
|
+
name: string;
|
|
1313
|
+
description?: string;
|
|
1314
|
+
priority?: EpicPriority;
|
|
1315
|
+
startDate?: Date;
|
|
1316
|
+
targetDate?: Date;
|
|
1317
|
+
}
|
|
1318
|
+
interface EpicUpdateInput {
|
|
1319
|
+
id: string;
|
|
1320
|
+
name?: string;
|
|
1321
|
+
description?: string | null;
|
|
1322
|
+
status?: EpicStatus;
|
|
1323
|
+
priority?: EpicPriority;
|
|
1324
|
+
startDate?: Date | null;
|
|
1325
|
+
targetDate?: Date | null;
|
|
1326
|
+
}
|
|
1327
|
+
declare class EpicsApi {
|
|
1328
|
+
private client;
|
|
1329
|
+
constructor(client: TrpcClient);
|
|
1330
|
+
list(options: EpicListOptions): Promise<Epic[]>;
|
|
1331
|
+
get(id: string): Promise<Epic>;
|
|
1332
|
+
create(input: EpicCreateInput): Promise<Epic>;
|
|
1333
|
+
update(input: EpicUpdateInput): Promise<Epic>;
|
|
1334
|
+
delete(id: string): Promise<{
|
|
1335
|
+
success: boolean;
|
|
1336
|
+
}>;
|
|
1337
|
+
}
|
|
1338
|
+
|
|
669
1339
|
interface ExponentialConfig {
|
|
670
1340
|
apiUrl: string;
|
|
671
1341
|
token: string;
|
|
@@ -692,14 +1362,19 @@ declare class ExponentialClient {
|
|
|
692
1362
|
private config;
|
|
693
1363
|
private client;
|
|
694
1364
|
actions: ActionsApi;
|
|
1365
|
+
actionComments: ActionCommentsApi;
|
|
695
1366
|
projects: ProjectsApi;
|
|
696
1367
|
workspaces: WorkspacesApi;
|
|
697
1368
|
contacts: ContactsApi;
|
|
698
1369
|
pipelines: PipelinesApi;
|
|
1370
|
+
tickets: TicketsApi;
|
|
1371
|
+
products: ProductsApi;
|
|
1372
|
+
features: FeaturesApi;
|
|
1373
|
+
epics: EpicsApi;
|
|
699
1374
|
constructor(config: {
|
|
700
1375
|
token: string;
|
|
701
1376
|
apiUrl: string;
|
|
702
1377
|
});
|
|
703
1378
|
}
|
|
704
1379
|
|
|
705
|
-
export { type Action, type ActionCreateInput, type ActionOutput, type ActionStatus, type ActionUpdateInput, type ActionsListOutput, type AddInteractionInput, type Contact, type ContactCreateInput, type ContactInteraction, type ContactListOutput, type ContactUpdateInput, type ContactsListOptions, type Deal, type DealActivity, type DealCreateInput, type DealMoveInput, type DealUpdateInput, ExponentialClient, type ExponentialConfig, type InteractionDirection, type InteractionType, type KanbanStatus, type Pipeline, type PipelineStage, type Priority, type Project, type ProjectOutput, type ProjectsListOutput, type Workspace, type WorkspaceOutput, type WorkspacesListOutput, clearConfig, createConfigStore, getConfigPath, isAuthenticated, isTRPCError, loadConfig, saveConfig };
|
|
1380
|
+
export { type Action, type ActionComment, type ActionCommentAddInput, type ActionCommentUpdateInput, type ActionCreateInput, type ActionOutput, type ActionStatus, type ActionUpdateInput, type ActionsListOutput, type AddInteractionInput, type CommentAuthor, type Contact, type ContactCreateInput, type ContactInteraction, type ContactListOutput, type ContactUpdateInput, type ContactsListOptions, type Deal, type DealActivity, type DealCreateInput, type DealMoveInput, type DealUpdateInput, type Epic, type EpicCreateInput, type EpicListOptions, type EpicPriority, type EpicStatus, type EpicUpdateInput, ExponentialClient, type ExponentialConfig, type Feature, type FeatureCreateInput, type FeatureListOptions, type FeatureScope, type FeatureScopeStatus, type FeatureStatus, type FeatureUpdateInput, type InteractionDirection, type InteractionType, type KanbanStatus, type Pipeline, type PipelineStage, type Priority, type Product, type ProductCreateInput, type ProductUpdateInput, type Project, type ProjectOutput, type ProjectsListOutput, type Ticket, type TicketAssignee, type TicketComment, type TicketCommentAddInput, type TicketCreateInput, type TicketDependencyEdge, type TicketDetail, type TicketListOptions, type TicketSearchOptions, type TicketStatus, type TicketType, type TicketUpdateInput, type Workspace, type WorkspaceOutput, type WorkspacesListOutput, clearConfig, createConfigStore, getConfigPath, isAuthenticated, isTRPCError, loadConfig, saveConfig };
|
package/dist/index.js
CHANGED
|
@@ -85,6 +85,29 @@ var ActionsApi = class {
|
|
|
85
85
|
}
|
|
86
86
|
};
|
|
87
87
|
|
|
88
|
+
// src/actionComments.ts
|
|
89
|
+
var ActionCommentsApi = class {
|
|
90
|
+
constructor(client) {
|
|
91
|
+
this.client = client;
|
|
92
|
+
}
|
|
93
|
+
async list(actionId) {
|
|
94
|
+
return await this.client.actionComment.getComments.query({
|
|
95
|
+
actionId
|
|
96
|
+
});
|
|
97
|
+
}
|
|
98
|
+
async add(input) {
|
|
99
|
+
return await this.client.actionComment.addComment.mutate(input);
|
|
100
|
+
}
|
|
101
|
+
async update(input) {
|
|
102
|
+
return await this.client.actionComment.updateComment.mutate(input);
|
|
103
|
+
}
|
|
104
|
+
async delete(commentId) {
|
|
105
|
+
return await this.client.actionComment.deleteComment.mutate({
|
|
106
|
+
commentId
|
|
107
|
+
});
|
|
108
|
+
}
|
|
109
|
+
};
|
|
110
|
+
|
|
88
111
|
// src/projects.ts
|
|
89
112
|
var ProjectsApi = class {
|
|
90
113
|
constructor(client) {
|
|
@@ -168,6 +191,165 @@ var PipelinesApi = class {
|
|
|
168
191
|
}
|
|
169
192
|
};
|
|
170
193
|
|
|
194
|
+
// src/tickets.ts
|
|
195
|
+
var TicketsApi = class {
|
|
196
|
+
constructor(client) {
|
|
197
|
+
this.client = client;
|
|
198
|
+
}
|
|
199
|
+
async list(options) {
|
|
200
|
+
return await this.client.product.ticket.list.query(options);
|
|
201
|
+
}
|
|
202
|
+
async get(id) {
|
|
203
|
+
return await this.client.product.ticket.getById.query({
|
|
204
|
+
id
|
|
205
|
+
});
|
|
206
|
+
}
|
|
207
|
+
async create(input) {
|
|
208
|
+
return await this.client.product.ticket.create.mutate(input);
|
|
209
|
+
}
|
|
210
|
+
async update(input) {
|
|
211
|
+
return await this.client.product.ticket.update.mutate(input);
|
|
212
|
+
}
|
|
213
|
+
async delete(id) {
|
|
214
|
+
return await this.client.product.ticket.delete.mutate({ id });
|
|
215
|
+
}
|
|
216
|
+
async search(options) {
|
|
217
|
+
return await this.client.product.ticket.search.query(
|
|
218
|
+
options
|
|
219
|
+
);
|
|
220
|
+
}
|
|
221
|
+
/** Mark `ticketId` as blocked by `dependsOnId`. */
|
|
222
|
+
async addDependency(ticketId, dependsOnId) {
|
|
223
|
+
return await this.client.product.ticket.addDependency.mutate({
|
|
224
|
+
ticketId,
|
|
225
|
+
dependsOnId
|
|
226
|
+
});
|
|
227
|
+
}
|
|
228
|
+
async removeDependency(ticketId, dependsOnId) {
|
|
229
|
+
return await this.client.product.ticket.removeDependency.mutate({
|
|
230
|
+
ticketId,
|
|
231
|
+
dependsOnId
|
|
232
|
+
});
|
|
233
|
+
}
|
|
234
|
+
async addComment(input) {
|
|
235
|
+
return await this.client.product.ticket.addComment.mutate(
|
|
236
|
+
input
|
|
237
|
+
);
|
|
238
|
+
}
|
|
239
|
+
async deleteComment(id) {
|
|
240
|
+
return await this.client.product.ticket.deleteComment.mutate({
|
|
241
|
+
id
|
|
242
|
+
});
|
|
243
|
+
}
|
|
244
|
+
/** Attach an existing action to a ticket. */
|
|
245
|
+
async linkAction(ticketId, actionId) {
|
|
246
|
+
return await this.client.product.ticket.linkAction.mutate({
|
|
247
|
+
ticketId,
|
|
248
|
+
actionId
|
|
249
|
+
});
|
|
250
|
+
}
|
|
251
|
+
/** Detach an action from whatever ticket it's linked to. */
|
|
252
|
+
async unlinkAction(actionId) {
|
|
253
|
+
return await this.client.product.ticket.unlinkAction.mutate({
|
|
254
|
+
actionId
|
|
255
|
+
});
|
|
256
|
+
}
|
|
257
|
+
};
|
|
258
|
+
|
|
259
|
+
// src/products.ts
|
|
260
|
+
var ProductsApi = class {
|
|
261
|
+
constructor(client) {
|
|
262
|
+
this.client = client;
|
|
263
|
+
}
|
|
264
|
+
async list(workspaceId) {
|
|
265
|
+
return await this.client.product.product.list.query({
|
|
266
|
+
workspaceId
|
|
267
|
+
});
|
|
268
|
+
}
|
|
269
|
+
async get(id) {
|
|
270
|
+
return await this.client.product.product.getById.query({ id });
|
|
271
|
+
}
|
|
272
|
+
async getBySlug(workspaceId, slug) {
|
|
273
|
+
return await this.client.product.product.getBySlug.query({
|
|
274
|
+
workspaceId,
|
|
275
|
+
slug
|
|
276
|
+
});
|
|
277
|
+
}
|
|
278
|
+
/**
|
|
279
|
+
* Resolve a product reference (slug or CUID) to a full Product. Falls back
|
|
280
|
+
* to slug lookup if the bare CUID lookup fails — callers can pass either.
|
|
281
|
+
*/
|
|
282
|
+
async resolve(workspaceId, slugOrId) {
|
|
283
|
+
const looksLikeId = /^c[a-z0-9]{20,}$/.test(slugOrId);
|
|
284
|
+
if (looksLikeId) {
|
|
285
|
+
try {
|
|
286
|
+
return await this.get(slugOrId);
|
|
287
|
+
} catch {
|
|
288
|
+
}
|
|
289
|
+
}
|
|
290
|
+
return await this.getBySlug(workspaceId, slugOrId);
|
|
291
|
+
}
|
|
292
|
+
async create(input) {
|
|
293
|
+
return await this.client.product.product.create.mutate(input);
|
|
294
|
+
}
|
|
295
|
+
async update(input) {
|
|
296
|
+
return await this.client.product.product.update.mutate(input);
|
|
297
|
+
}
|
|
298
|
+
async delete(id) {
|
|
299
|
+
return await this.client.product.product.delete.mutate({ id });
|
|
300
|
+
}
|
|
301
|
+
};
|
|
302
|
+
|
|
303
|
+
// src/features.ts
|
|
304
|
+
var FeaturesApi = class {
|
|
305
|
+
constructor(client) {
|
|
306
|
+
this.client = client;
|
|
307
|
+
}
|
|
308
|
+
async list(options) {
|
|
309
|
+
return await this.client.product.feature.list.query({
|
|
310
|
+
productId: options.productId,
|
|
311
|
+
status: options.status
|
|
312
|
+
});
|
|
313
|
+
}
|
|
314
|
+
async get(id) {
|
|
315
|
+
return await this.client.product.feature.getById.query({ id });
|
|
316
|
+
}
|
|
317
|
+
async create(input) {
|
|
318
|
+
return await this.client.product.feature.create.mutate(input);
|
|
319
|
+
}
|
|
320
|
+
async update(input) {
|
|
321
|
+
return await this.client.product.feature.update.mutate(input);
|
|
322
|
+
}
|
|
323
|
+
async delete(id) {
|
|
324
|
+
return await this.client.product.feature.delete.mutate({ id });
|
|
325
|
+
}
|
|
326
|
+
};
|
|
327
|
+
|
|
328
|
+
// src/epics.ts
|
|
329
|
+
var EpicsApi = class {
|
|
330
|
+
constructor(client) {
|
|
331
|
+
this.client = client;
|
|
332
|
+
}
|
|
333
|
+
async list(options) {
|
|
334
|
+
return await this.client.epic.list.query({
|
|
335
|
+
workspaceId: options.workspaceId,
|
|
336
|
+
status: options.status
|
|
337
|
+
});
|
|
338
|
+
}
|
|
339
|
+
async get(id) {
|
|
340
|
+
return await this.client.epic.getById.query({ id });
|
|
341
|
+
}
|
|
342
|
+
async create(input) {
|
|
343
|
+
return await this.client.epic.create.mutate(input);
|
|
344
|
+
}
|
|
345
|
+
async update(input) {
|
|
346
|
+
return await this.client.epic.update.mutate(input);
|
|
347
|
+
}
|
|
348
|
+
async delete(id) {
|
|
349
|
+
return await this.client.epic.delete.mutate({ id });
|
|
350
|
+
}
|
|
351
|
+
};
|
|
352
|
+
|
|
171
353
|
// src/config.ts
|
|
172
354
|
import Conf from "conf";
|
|
173
355
|
var schema = {
|
|
@@ -251,17 +433,27 @@ var ExponentialClient = class {
|
|
|
251
433
|
this.config = config;
|
|
252
434
|
this.client = createClient(this.config);
|
|
253
435
|
this.actions = new ActionsApi(this.client);
|
|
436
|
+
this.actionComments = new ActionCommentsApi(this.client);
|
|
254
437
|
this.projects = new ProjectsApi(this.client);
|
|
255
438
|
this.workspaces = new WorkspacesApi(this.client);
|
|
256
439
|
this.contacts = new ContactsApi(this.client);
|
|
257
440
|
this.pipelines = new PipelinesApi(this.client);
|
|
441
|
+
this.tickets = new TicketsApi(this.client);
|
|
442
|
+
this.products = new ProductsApi(this.client);
|
|
443
|
+
this.features = new FeaturesApi(this.client);
|
|
444
|
+
this.epics = new EpicsApi(this.client);
|
|
258
445
|
}
|
|
259
446
|
client;
|
|
260
447
|
actions;
|
|
448
|
+
actionComments;
|
|
261
449
|
projects;
|
|
262
450
|
workspaces;
|
|
263
451
|
contacts;
|
|
264
452
|
pipelines;
|
|
453
|
+
tickets;
|
|
454
|
+
products;
|
|
455
|
+
features;
|
|
456
|
+
epics;
|
|
265
457
|
};
|
|
266
458
|
export {
|
|
267
459
|
ExponentialClient,
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/client.ts","../src/actions.ts","../src/projects.ts","../src/workspaces.ts","../src/contacts.ts","../src/pipelines.ts","../src/config.ts","../src/index.ts"],"sourcesContent":["import { createTRPCClient, httpBatchLink, TRPCClientError } from '@trpc/client';\nimport superjson from 'superjson';\n\ntype ActionInput = {\n assigneeId?: string;\n};\n\ntype KanbanInput = {\n projectId?: string;\n assigneeId?: string;\n kanbanStatus?: 'BACKLOG' | 'TODO' | 'IN_PROGRESS' | 'IN_REVIEW' | 'DONE' | 'CANCELLED';\n};\n\ntype TodayInput = {\n workspaceId?: string;\n};\n\ntype DateRangeInput = {\n startDate: Date;\n endDate: Date;\n workspaceId?: string;\n};\n\ntype ProjectInput = {\n include?: {\n actions?: boolean;\n };\n workspaceId?: string;\n};\n\ntype ActionStatus = 'ACTIVE' | 'COMPLETED' | 'CANCELLED' | 'DELETED' | 'DRAFT';\ntype ActionKanbanStatus = 'BACKLOG' | 'TODO' | 'IN_PROGRESS' | 'IN_REVIEW' | 'DONE' | 'CANCELLED';\ntype ActionPriority = 'Quick' | 'Scheduled' | '1st Priority' | '2nd Priority' | '3rd Priority' | '4th Priority' | '5th Priority' | 'Errand' | 'Remember' | 'Watch' | 'Someday Maybe';\n\ntype ActionCreateInput = {\n name: string;\n description?: string;\n projectId?: string;\n workspaceId?: string;\n dueDate?: Date;\n scheduledStart?: Date;\n scheduledEnd?: Date;\n duration?: number;\n priority?: ActionPriority;\n status?: ActionStatus;\n epicId?: string;\n effortEstimate?: number;\n blockedByIds?: string[];\n};\n\ntype ActionUpdateInput = {\n id: string;\n name?: string;\n description?: string;\n projectId?: string;\n workspaceId?: string | null;\n dueDate?: Date | null;\n scheduledStart?: Date | null;\n scheduledEnd?: Date | null;\n duration?: number | null;\n priority?: ActionPriority;\n status?: ActionStatus;\n kanbanStatus?: ActionKanbanStatus;\n epicId?: string | null;\n effortEstimate?: number | null;\n blockedByIds?: string[];\n};\n\nexport interface TrpcClient {\n action: {\n getAll: { query: (input?: ActionInput) => Promise<unknown[]> };\n getKanbanActions: { query: (input?: KanbanInput) => Promise<unknown[]> };\n getToday: { query: (input?: TodayInput) => Promise<unknown[]> };\n getByDateRange: { query: (input: DateRangeInput) => Promise<unknown[]> };\n getProjectActions: { query: (input: { projectId: string; assigneeId?: string }) => Promise<unknown[]> };\n create: { mutate: (input: ActionCreateInput) => Promise<unknown> };\n update: { mutate: (input: ActionUpdateInput) => Promise<unknown> };\n };\n project: {\n getAll: { query: (input?: ProjectInput) => Promise<unknown[]> };\n };\n workspace: {\n list: { query: () => Promise<unknown[]> };\n };\n crmApi: {\n contactList: { query: (input: { workspaceId: string; search?: string; tags?: string[]; organizationId?: string; limit?: number; cursor?: string }) => Promise<unknown> };\n contactGet: { query: (input: { id: string; includeInteractions?: boolean }) => Promise<unknown> };\n contactCreate: { mutate: (input: { workspaceId: string; firstName?: string; lastName?: string; email?: string | null; phone?: string; linkedIn?: string; telegram?: string; twitter?: string; github?: string; bluesky?: string; about?: string; profileType?: string; skills?: string[]; tags?: string[]; organizationId?: string }) => Promise<unknown> };\n contactUpdate: { mutate: (input: { id: string; firstName?: string; lastName?: string; email?: string | null; phone?: string | null; linkedIn?: string | null; telegram?: string | null; twitter?: string | null; github?: string | null; bluesky?: string | null; about?: string; profileType?: string; skills?: string[]; tags?: string[]; organizationId?: string | null }) => Promise<unknown> };\n contactDelete: { mutate: (input: { id: string }) => Promise<unknown> };\n contactAddInteraction: { mutate: (input: { contactId: string; type: string; direction: string; subject?: string; notes?: string; metadata?: unknown }) => Promise<unknown> };\n pipelineGet: { query: (input: { workspaceId: string }) => Promise<unknown> };\n pipelineGetStages: { query: (input: { workspaceId: string }) => Promise<unknown[]> };\n dealList: { query: (input: { workspaceId: string }) => Promise<unknown[]> };\n dealGet: { query: (input: { id: string }) => Promise<unknown> };\n dealCreate: { mutate: (input: { workspaceId: string; stageId: string; title: string; description?: string; value?: number; currency?: string; probability?: number; expectedCloseDate?: Date; contactId?: string; organizationId?: string; assignedToId?: string }) => Promise<unknown> };\n dealUpdate: { mutate: (input: { id: string; title?: string; description?: string | null; value?: number | null; currency?: string; probability?: number | null; expectedCloseDate?: Date | null; contactId?: string | null; organizationId?: string | null; assignedToId?: string | null }) => Promise<unknown> };\n dealMove: { mutate: (input: { id: string; stageId: string; stageOrder: number }) => Promise<unknown> };\n dealDelete: { mutate: (input: { id: string }) => Promise<unknown> };\n };\n}\n\nexport function createClient(config: { token: string; apiUrl: string }): TrpcClient {\n const apiUrl = config.apiUrl.replace(/\\/+$/, '');\n\n return createTRPCClient<any>({\n links: [\n httpBatchLink({\n url: `${apiUrl}/api/trpc`,\n headers() {\n return {\n Authorization: `Bearer ${config.token}`,\n };\n },\n transformer: superjson,\n }),\n ],\n }) as unknown as TrpcClient;\n}\n\nexport function isTRPCError(error: unknown): error is TRPCClientError<any> {\n return error instanceof TRPCClientError;\n}\n\nexport { TRPCClientError };\n","import type { TrpcClient } from './client.js';\nimport type { Action, KanbanStatus, Priority } from './types/action.js';\n\nexport interface ActionsListOptions {\n projectId?: string;\n status?: KanbanStatus;\n assigneeId?: string;\n}\n\nexport interface ActionsKanbanOptions {\n projectId?: string;\n status?: KanbanStatus;\n assigneeId?: string;\n}\n\nexport type ActionStatus = 'ACTIVE' | 'COMPLETED' | 'CANCELLED' | 'DELETED' | 'DRAFT';\n\nexport interface ActionCreateInput {\n name: string;\n description?: string;\n projectId?: string;\n workspaceId?: string;\n dueDate?: Date;\n scheduledStart?: Date;\n scheduledEnd?: Date;\n duration?: number;\n priority?: Priority;\n status?: ActionStatus;\n epicId?: string;\n effortEstimate?: number;\n blockedByIds?: string[];\n}\n\nexport interface ActionUpdateInput {\n id: string;\n name?: string;\n description?: string;\n projectId?: string;\n workspaceId?: string | null;\n dueDate?: Date | null;\n scheduledStart?: Date | null;\n scheduledEnd?: Date | null;\n duration?: number | null;\n priority?: Priority;\n status?: ActionStatus;\n kanbanStatus?: KanbanStatus;\n epicId?: string | null;\n effortEstimate?: number | null;\n blockedByIds?: string[];\n}\n\nexport class ActionsApi {\n constructor(private client: TrpcClient) {}\n\n async list(options: ActionsListOptions = {}): Promise<Action[]> {\n const { projectId, status, assigneeId } = options;\n let actions: Action[];\n\n if (projectId) {\n actions = await this.client.action.getProjectActions.query({\n projectId,\n assigneeId,\n }) as Action[];\n } else if (status) {\n actions = await this.client.action.getKanbanActions.query({\n kanbanStatus: status,\n assigneeId,\n }) as Action[];\n } else {\n actions = await this.client.action.getAll.query({\n assigneeId,\n }) as Action[];\n }\n\n // Match CLI behavior: hide completed/cancelled unless status specified\n if (!status) {\n actions = actions.filter(action =>\n action.status !== 'COMPLETED' &&\n action.status !== 'CANCELLED' &&\n action.kanbanStatus !== 'DONE' &&\n action.kanbanStatus !== 'CANCELLED'\n );\n }\n\n return actions;\n }\n\n async getToday(workspaceId?: string): Promise<Action[]> {\n return await this.client.action.getToday.query({\n workspaceId,\n }) as Action[];\n }\n\n async getByDateRange(start: Date, end: Date, workspaceId?: string): Promise<Action[]> {\n return await this.client.action.getByDateRange.query({\n startDate: start,\n endDate: end,\n workspaceId,\n }) as Action[];\n }\n\n async getKanban(options: ActionsKanbanOptions = {}): Promise<Action[]> {\n const { projectId, status, assigneeId } = options;\n\n return await this.client.action.getKanbanActions.query({\n projectId,\n kanbanStatus: status,\n assigneeId,\n }) as Action[];\n }\n\n async getProjectActions(projectId: string, assigneeId?: string): Promise<Action[]> {\n return await this.client.action.getProjectActions.query({\n projectId,\n assigneeId,\n }) as Action[];\n }\n\n async create(input: ActionCreateInput): Promise<Action> {\n return await this.client.action.create.mutate(input) as Action;\n }\n\n async update(input: ActionUpdateInput): Promise<Action> {\n return await this.client.action.update.mutate(input) as Action;\n }\n}\n","import type { TrpcClient } from './client.js';\nimport type { Project } from './types/project.js';\n\nexport interface ProjectsListOptions {\n workspaceId?: string;\n includeActions?: boolean;\n}\n\nexport class ProjectsApi {\n constructor(private client: TrpcClient) {}\n\n async list(options: ProjectsListOptions = {}): Promise<Project[]> {\n const { workspaceId, includeActions } = options;\n\n return await this.client.project.getAll.query({\n workspaceId,\n include: includeActions ? { actions: true } : undefined,\n }) as Project[];\n }\n}\n","import type { TrpcClient } from './client.js';\nimport type { Workspace } from './types/workspace.js';\n\nexport class WorkspacesApi {\n constructor(private client: TrpcClient) {}\n\n async list(): Promise<Workspace[]> {\n return await this.client.workspace.list.query() as Workspace[];\n }\n}\n","import type { TrpcClient } from './client.js';\nimport type { Contact, ContactInteraction, ContactListOutput, InteractionType, InteractionDirection } from './types/contact.js';\n\nexport interface ContactsListOptions {\n workspaceId: string;\n search?: string;\n tags?: string[];\n organizationId?: string;\n limit?: number;\n cursor?: string;\n}\n\nexport interface ContactCreateInput {\n workspaceId: string;\n firstName?: string;\n lastName?: string;\n email?: string | null;\n phone?: string;\n linkedIn?: string;\n telegram?: string;\n twitter?: string;\n github?: string;\n bluesky?: string;\n about?: string;\n profileType?: string;\n skills?: string[];\n tags?: string[];\n organizationId?: string;\n}\n\nexport interface ContactUpdateInput {\n id: string;\n firstName?: string;\n lastName?: string;\n email?: string | null;\n phone?: string | null;\n linkedIn?: string | null;\n telegram?: string | null;\n twitter?: string | null;\n github?: string | null;\n bluesky?: string | null;\n about?: string;\n profileType?: string;\n skills?: string[];\n tags?: string[];\n organizationId?: string | null;\n}\n\nexport interface AddInteractionInput {\n contactId: string;\n type: InteractionType;\n direction: InteractionDirection;\n subject?: string;\n notes?: string;\n metadata?: Record<string, unknown>;\n}\n\nexport class ContactsApi {\n constructor(private client: TrpcClient) {}\n\n async list(options: ContactsListOptions): Promise<ContactListOutput> {\n return await this.client.crmApi.contactList.query(options) as ContactListOutput;\n }\n\n async get(id: string, options?: { includeInteractions?: boolean }): Promise<Contact> {\n return await this.client.crmApi.contactGet.query({\n id,\n includeInteractions: options?.includeInteractions,\n }) as Contact;\n }\n\n async create(input: ContactCreateInput): Promise<Contact> {\n return await this.client.crmApi.contactCreate.mutate(input) as Contact;\n }\n\n async update(input: ContactUpdateInput): Promise<Contact> {\n return await this.client.crmApi.contactUpdate.mutate(input) as Contact;\n }\n\n async delete(id: string): Promise<void> {\n await this.client.crmApi.contactDelete.mutate({ id });\n }\n\n async addInteraction(input: AddInteractionInput): Promise<ContactInteraction> {\n return await this.client.crmApi.contactAddInteraction.mutate(input) as ContactInteraction;\n }\n}\n","import type { TrpcClient } from './client.js';\nimport type { Pipeline, PipelineStage, Deal } from './types/pipeline.js';\n\nexport interface DealCreateInput {\n workspaceId: string;\n stageId: string;\n title: string;\n description?: string;\n value?: number;\n currency?: string;\n probability?: number;\n expectedCloseDate?: Date;\n contactId?: string;\n organizationId?: string;\n assignedToId?: string;\n}\n\nexport interface DealUpdateInput {\n id: string;\n title?: string;\n description?: string | null;\n value?: number | null;\n currency?: string;\n probability?: number | null;\n expectedCloseDate?: Date | null;\n contactId?: string | null;\n organizationId?: string | null;\n assignedToId?: string | null;\n}\n\nexport interface DealMoveInput {\n id: string;\n stageId: string;\n stageOrder: number;\n}\n\nexport class PipelinesApi {\n constructor(private client: TrpcClient) {}\n\n async get(workspaceId: string): Promise<Pipeline | null> {\n return await this.client.crmApi.pipelineGet.query({ workspaceId }) as Pipeline | null;\n }\n\n async getStages(workspaceId: string): Promise<PipelineStage[]> {\n return await this.client.crmApi.pipelineGetStages.query({ workspaceId }) as PipelineStage[];\n }\n\n async listDeals(workspaceId: string): Promise<Deal[]> {\n return await this.client.crmApi.dealList.query({ workspaceId }) as Deal[];\n }\n\n async getDeal(id: string): Promise<Deal> {\n return await this.client.crmApi.dealGet.query({ id }) as Deal;\n }\n\n async createDeal(input: DealCreateInput): Promise<Deal> {\n return await this.client.crmApi.dealCreate.mutate(input) as Deal;\n }\n\n async updateDeal(input: DealUpdateInput): Promise<Deal> {\n return await this.client.crmApi.dealUpdate.mutate(input) as Deal;\n }\n\n async moveDeal(input: DealMoveInput): Promise<Deal> {\n return await this.client.crmApi.dealMove.mutate(input) as Deal;\n }\n\n async deleteDeal(id: string): Promise<void> {\n await this.client.crmApi.dealDelete.mutate({ id });\n }\n}\n","import Conf from 'conf';\n\nexport interface ExponentialConfig {\n apiUrl: string;\n token: string;\n tokenExpiry?: string;\n defaultWorkspaceId?: string;\n defaultWorkspaceSlug?: string;\n}\n\nconst schema = {\n apiUrl: {\n type: 'string' as const,\n default: '',\n },\n token: {\n type: 'string' as const,\n default: '',\n },\n tokenExpiry: {\n type: 'string' as const,\n default: '',\n },\n defaultWorkspaceId: {\n type: 'string' as const,\n default: '',\n },\n defaultWorkspaceSlug: {\n type: 'string' as const,\n default: '',\n },\n};\n\nfunction createStore(projectName: string) {\n return new Conf<ExponentialConfig>({\n projectName,\n schema,\n });\n}\n\nfunction readConfig(store: Conf<ExponentialConfig>): ExponentialConfig {\n return {\n apiUrl: store.get('apiUrl'),\n token: store.get('token'),\n tokenExpiry: store.get('tokenExpiry'),\n defaultWorkspaceId: store.get('defaultWorkspaceId'),\n defaultWorkspaceSlug: store.get('defaultWorkspaceSlug'),\n };\n}\n\nfunction writeConfig(store: Conf<ExponentialConfig>, values: Partial<ExponentialConfig>): void {\n if (values.apiUrl !== undefined) store.set('apiUrl', values.apiUrl);\n if (values.token !== undefined) store.set('token', values.token);\n if (values.tokenExpiry !== undefined) store.set('tokenExpiry', values.tokenExpiry);\n if (values.defaultWorkspaceId !== undefined) store.set('defaultWorkspaceId', values.defaultWorkspaceId);\n if (values.defaultWorkspaceSlug !== undefined) store.set('defaultWorkspaceSlug', values.defaultWorkspaceSlug);\n}\n\nconst defaultStore = createStore('exponential-sdk');\n\nexport function createConfigStore(options?: { projectName?: string }) {\n const store = createStore(options?.projectName ?? 'exponential-sdk');\n\n return {\n loadConfig: () => readConfig(store),\n saveConfig: (values: Partial<ExponentialConfig>) => writeConfig(store, values),\n clearConfig: () => store.clear(),\n isAuthenticated: () => {\n const cfg = readConfig(store);\n return Boolean(cfg.token && cfg.apiUrl);\n },\n getConfigPath: () => store.path,\n };\n}\n\nexport function loadConfig(): ExponentialConfig {\n return readConfig(defaultStore);\n}\n\nexport function saveConfig(values: Partial<ExponentialConfig>): void {\n writeConfig(defaultStore, values);\n}\n\nexport function clearConfig(): void {\n defaultStore.clear();\n}\n\nexport function isAuthenticated(): boolean {\n const cfg = readConfig(defaultStore);\n return Boolean(cfg.token && cfg.apiUrl);\n}\n\nexport function getConfigPath(): string {\n return defaultStore.path;\n}\n","import { createClient, isTRPCError, TRPCClientError, type TrpcClient } from './client.js';\nimport { ActionsApi } from './actions.js';\nimport { ProjectsApi } from './projects.js';\nimport { WorkspacesApi } from './workspaces.js';\nimport { ContactsApi } from './contacts.js';\nimport { PipelinesApi } from './pipelines.js';\n\nexport class ExponentialClient {\n private client: TrpcClient;\n actions: ActionsApi;\n projects: ProjectsApi;\n workspaces: WorkspacesApi;\n contacts: ContactsApi;\n pipelines: PipelinesApi;\n\n constructor(private config: { token: string; apiUrl: string }) {\n this.client = createClient(this.config);\n this.actions = new ActionsApi(this.client);\n this.projects = new ProjectsApi(this.client);\n this.workspaces = new WorkspacesApi(this.client);\n this.contacts = new ContactsApi(this.client);\n this.pipelines = new PipelinesApi(this.client);\n }\n}\n\nexport {\n createConfigStore,\n loadConfig,\n saveConfig,\n clearConfig,\n isAuthenticated,\n getConfigPath,\n} from './config.js';\n\nexport type { ExponentialConfig } from './config.js';\nexport type {\n Action,\n ActionOutput,\n ActionsListOutput,\n KanbanStatus,\n Priority,\n} from './types/action.js';\nexport type {\n ActionCreateInput,\n ActionUpdateInput,\n ActionStatus,\n} from './actions.js';\nexport type { Project, ProjectOutput, ProjectsListOutput } from './types/project.js';\nexport type { Workspace, WorkspaceOutput, WorkspacesListOutput } from './types/workspace.js';\nexport type {\n Contact,\n ContactInteraction,\n ContactListOutput,\n InteractionType,\n InteractionDirection,\n} from './types/contact.js';\nexport type {\n ContactCreateInput,\n ContactUpdateInput,\n AddInteractionInput,\n ContactsListOptions,\n} from './contacts.js';\nexport type {\n Pipeline,\n PipelineStage,\n Deal,\n DealActivity,\n} from './types/pipeline.js';\nexport type {\n DealCreateInput,\n DealUpdateInput,\n DealMoveInput,\n} from './pipelines.js';\nexport { isTRPCError, TRPCClientError };\n"],"mappings":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C/C;AAAA,EAdQ;AAAA,EACR;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAUF;","names":[]}
|
|
1
|
+
{"version":3,"sources":["../src/client.ts","../src/actions.ts","../src/actionComments.ts","../src/projects.ts","../src/workspaces.ts","../src/contacts.ts","../src/pipelines.ts","../src/tickets.ts","../src/products.ts","../src/features.ts","../src/epics.ts","../src/config.ts","../src/index.ts"],"sourcesContent":["import { createTRPCClient, httpBatchLink, TRPCClientError } from '@trpc/client';\nimport superjson from 'superjson';\n\ntype ActionInput = {\n assigneeId?: string;\n};\n\ntype KanbanInput = {\n projectId?: string;\n assigneeId?: string;\n kanbanStatus?: 'BACKLOG' | 'TODO' | 'IN_PROGRESS' | 'IN_REVIEW' | 'DONE' | 'CANCELLED';\n};\n\ntype TodayInput = {\n workspaceId?: string;\n};\n\ntype DateRangeInput = {\n startDate: Date;\n endDate: Date;\n workspaceId?: string;\n};\n\ntype ProjectInput = {\n include?: {\n actions?: boolean;\n };\n workspaceId?: string;\n};\n\ntype ActionStatus = 'ACTIVE' | 'COMPLETED' | 'CANCELLED' | 'DELETED' | 'DRAFT';\ntype ActionKanbanStatus = 'BACKLOG' | 'TODO' | 'IN_PROGRESS' | 'IN_REVIEW' | 'DONE' | 'CANCELLED';\ntype ActionPriority = 'Quick' | 'Scheduled' | '1st Priority' | '2nd Priority' | '3rd Priority' | '4th Priority' | '5th Priority' | 'Errand' | 'Remember' | 'Watch' | 'Someday Maybe';\n\ntype ActionCreateInput = {\n name: string;\n description?: string;\n projectId?: string;\n workspaceId?: string;\n dueDate?: Date;\n scheduledStart?: Date;\n scheduledEnd?: Date;\n duration?: number;\n priority?: ActionPriority;\n status?: ActionStatus;\n epicId?: string;\n effortEstimate?: number;\n blockedByIds?: string[];\n};\n\ntype ActionUpdateInput = {\n id: string;\n name?: string;\n description?: string;\n projectId?: string;\n workspaceId?: string | null;\n dueDate?: Date | null;\n scheduledStart?: Date | null;\n scheduledEnd?: Date | null;\n duration?: number | null;\n priority?: ActionPriority;\n status?: ActionStatus;\n kanbanStatus?: ActionKanbanStatus;\n epicId?: string | null;\n effortEstimate?: number | null;\n blockedByIds?: string[];\n};\n\nexport interface TrpcClient {\n action: {\n getAll: { query: (input?: ActionInput) => Promise<unknown[]> };\n getKanbanActions: { query: (input?: KanbanInput) => Promise<unknown[]> };\n getToday: { query: (input?: TodayInput) => Promise<unknown[]> };\n getByDateRange: { query: (input: DateRangeInput) => Promise<unknown[]> };\n getProjectActions: { query: (input: { projectId: string; assigneeId?: string }) => Promise<unknown[]> };\n create: { mutate: (input: ActionCreateInput) => Promise<unknown> };\n update: { mutate: (input: ActionUpdateInput) => Promise<unknown> };\n };\n project: {\n getAll: { query: (input?: ProjectInput) => Promise<unknown[]> };\n };\n workspace: {\n list: { query: () => Promise<unknown[]> };\n };\n crmApi: {\n contactList: { query: (input: { workspaceId: string; search?: string; tags?: string[]; organizationId?: string; limit?: number; cursor?: string }) => Promise<unknown> };\n contactGet: { query: (input: { id: string; includeInteractions?: boolean }) => Promise<unknown> };\n contactCreate: { mutate: (input: { workspaceId: string; firstName?: string; lastName?: string; email?: string | null; phone?: string; linkedIn?: string; telegram?: string; twitter?: string; github?: string; bluesky?: string; about?: string; profileType?: string; skills?: string[]; tags?: string[]; organizationId?: string }) => Promise<unknown> };\n contactUpdate: { mutate: (input: { id: string; firstName?: string; lastName?: string; email?: string | null; phone?: string | null; linkedIn?: string | null; telegram?: string | null; twitter?: string | null; github?: string | null; bluesky?: string | null; about?: string; profileType?: string; skills?: string[]; tags?: string[]; organizationId?: string | null }) => Promise<unknown> };\n contactDelete: { mutate: (input: { id: string }) => Promise<unknown> };\n contactAddInteraction: { mutate: (input: { contactId: string; type: string; direction: string; subject?: string; notes?: string; metadata?: unknown }) => Promise<unknown> };\n pipelineGet: { query: (input: { workspaceId: string }) => Promise<unknown> };\n pipelineGetStages: { query: (input: { workspaceId: string }) => Promise<unknown[]> };\n dealList: { query: (input: { workspaceId: string }) => Promise<unknown[]> };\n dealGet: { query: (input: { id: string }) => Promise<unknown> };\n dealCreate: { mutate: (input: { workspaceId: string; stageId: string; title: string; description?: string; value?: number; currency?: string; probability?: number; expectedCloseDate?: Date; contactId?: string; organizationId?: string; assignedToId?: string }) => Promise<unknown> };\n dealUpdate: { mutate: (input: { id: string; title?: string; description?: string | null; value?: number | null; currency?: string; probability?: number | null; expectedCloseDate?: Date | null; contactId?: string | null; organizationId?: string | null; assignedToId?: string | null }) => Promise<unknown> };\n dealMove: { mutate: (input: { id: string; stageId: string; stageOrder: number }) => Promise<unknown> };\n dealDelete: { mutate: (input: { id: string }) => Promise<unknown> };\n };\n actionComment: {\n getComments: { query: (input: { actionId: string }) => Promise<unknown[]> };\n addComment: { mutate: (input: { actionId: string; content: string }) => Promise<unknown> };\n updateComment: { mutate: (input: { commentId: string; content: string }) => Promise<unknown> };\n deleteComment: { mutate: (input: { commentId: string }) => Promise<unknown> };\n };\n epic: {\n list: { query: (input: { workspaceId: string; status?: 'OPEN' | 'IN_PROGRESS' | 'DONE' | 'CANCELLED' }) => Promise<unknown[]> };\n getById: { query: (input: { id: string }) => Promise<unknown> };\n create: { mutate: (input: { workspaceId: string; name: string; description?: string; priority?: 'HIGH' | 'MEDIUM' | 'LOW' | 'NONE'; startDate?: Date; targetDate?: Date }) => Promise<unknown> };\n update: { mutate: (input: { id: string; name?: string; description?: string | null; status?: 'OPEN' | 'IN_PROGRESS' | 'DONE' | 'CANCELLED'; priority?: 'HIGH' | 'MEDIUM' | 'LOW' | 'NONE'; startDate?: Date | null; targetDate?: Date | null }) => Promise<unknown> };\n delete: { mutate: (input: { id: string }) => Promise<unknown> };\n };\n product: {\n product: {\n list: { query: (input: { workspaceId: string }) => Promise<unknown[]> };\n getById: { query: (input: { id: string }) => Promise<unknown> };\n getBySlug: { query: (input: { workspaceId: string; slug: string }) => Promise<unknown> };\n create: { mutate: (input: { workspaceId: string; name: string; slug: string; description?: string; icon?: string; color?: string }) => Promise<unknown> };\n update: { mutate: (input: { id: string; name?: string; description?: string; icon?: string; color?: string; funTicketIds?: boolean }) => Promise<unknown> };\n delete: { mutate: (input: { id: string }) => Promise<unknown> };\n };\n feature: {\n list: { query: (input: { productId: string; status?: 'IDEA' | 'DEFINED' | 'IN_PROGRESS' | 'SHIPPED' | 'ARCHIVED' }) => Promise<unknown[]> };\n getById: { query: (input: { id: string }) => Promise<unknown> };\n create: { mutate: (input: { productId: string; name: string; description?: string; vision?: string; status?: 'IDEA' | 'DEFINED' | 'IN_PROGRESS' | 'SHIPPED' | 'ARCHIVED'; effort?: number; priority?: number; goalId?: number }) => Promise<unknown> };\n update: { mutate: (input: { id: string; name?: string; description?: string; vision?: string; status?: 'IDEA' | 'DEFINED' | 'IN_PROGRESS' | 'SHIPPED' | 'ARCHIVED'; effort?: number; priority?: number; goalId?: number | null }) => Promise<unknown> };\n delete: { mutate: (input: { id: string }) => Promise<unknown> };\n };\n ticket: {\n list: { query: (input: { productId: string; status?: string; type?: string; featureId?: string; epicId?: string; cycleId?: string; assigneeId?: string }) => Promise<unknown[]> };\n getById: { query: (input: { id: string }) => Promise<unknown> };\n create: { mutate: (input: { productId: string; title: string; body?: string; type?: string; status?: string; priority?: number; points?: number; branchName?: string; prUrl?: string; designUrl?: string; specUrl?: string; links?: Record<string, string>; epicId?: string; featureId?: string; cycleId?: string; scopeId?: string; assigneeId?: string; templateId?: string }) => Promise<unknown> };\n update: { mutate: (input: { id: string; title?: string; body?: string; type?: string; status?: string; priority?: number | null; points?: number | null; branchName?: string | null; prUrl?: string | null; designUrl?: string | null; specUrl?: string | null; links?: Record<string, string> | null; epicId?: string | null; featureId?: string | null; cycleId?: string | null; scopeId?: string | null; assigneeId?: string | null }) => Promise<unknown> };\n delete: { mutate: (input: { id: string }) => Promise<unknown> };\n search: { query: (input: { productId: string; query?: string; excludeTicketId?: string; limit?: number }) => Promise<unknown[]> };\n addDependency: { mutate: (input: { ticketId: string; dependsOnId: string }) => Promise<unknown> };\n removeDependency: { mutate: (input: { ticketId: string; dependsOnId: string }) => Promise<unknown> };\n addComment: { mutate: (input: { ticketId: string; content: string }) => Promise<unknown> };\n deleteComment: { mutate: (input: { id: string }) => Promise<unknown> };\n linkAction: { mutate: (input: { ticketId: string; actionId: string }) => Promise<unknown> };\n unlinkAction: { mutate: (input: { actionId: string }) => Promise<unknown> };\n };\n };\n}\n\nexport function createClient(config: { token: string; apiUrl: string }): TrpcClient {\n const apiUrl = config.apiUrl.replace(/\\/+$/, '');\n\n return createTRPCClient<any>({\n links: [\n httpBatchLink({\n url: `${apiUrl}/api/trpc`,\n headers() {\n return {\n Authorization: `Bearer ${config.token}`,\n };\n },\n transformer: superjson,\n }),\n ],\n }) as unknown as TrpcClient;\n}\n\nexport function isTRPCError(error: unknown): error is TRPCClientError<any> {\n return error instanceof TRPCClientError;\n}\n\nexport { TRPCClientError };\n","import type { TrpcClient } from './client.js';\nimport type { Action, KanbanStatus, Priority } from './types/action.js';\n\nexport interface ActionsListOptions {\n projectId?: string;\n status?: KanbanStatus;\n assigneeId?: string;\n}\n\nexport interface ActionsKanbanOptions {\n projectId?: string;\n status?: KanbanStatus;\n assigneeId?: string;\n}\n\nexport type ActionStatus = 'ACTIVE' | 'COMPLETED' | 'CANCELLED' | 'DELETED' | 'DRAFT';\n\nexport interface ActionCreateInput {\n name: string;\n description?: string;\n projectId?: string;\n workspaceId?: string;\n dueDate?: Date;\n scheduledStart?: Date;\n scheduledEnd?: Date;\n duration?: number;\n priority?: Priority;\n status?: ActionStatus;\n epicId?: string;\n effortEstimate?: number;\n blockedByIds?: string[];\n}\n\nexport interface ActionUpdateInput {\n id: string;\n name?: string;\n description?: string;\n projectId?: string;\n workspaceId?: string | null;\n dueDate?: Date | null;\n scheduledStart?: Date | null;\n scheduledEnd?: Date | null;\n duration?: number | null;\n priority?: Priority;\n status?: ActionStatus;\n kanbanStatus?: KanbanStatus;\n epicId?: string | null;\n effortEstimate?: number | null;\n blockedByIds?: string[];\n}\n\nexport class ActionsApi {\n constructor(private client: TrpcClient) {}\n\n async list(options: ActionsListOptions = {}): Promise<Action[]> {\n const { projectId, status, assigneeId } = options;\n let actions: Action[];\n\n if (projectId) {\n actions = await this.client.action.getProjectActions.query({\n projectId,\n assigneeId,\n }) as Action[];\n } else if (status) {\n actions = await this.client.action.getKanbanActions.query({\n kanbanStatus: status,\n assigneeId,\n }) as Action[];\n } else {\n actions = await this.client.action.getAll.query({\n assigneeId,\n }) as Action[];\n }\n\n // Match CLI behavior: hide completed/cancelled unless status specified\n if (!status) {\n actions = actions.filter(action =>\n action.status !== 'COMPLETED' &&\n action.status !== 'CANCELLED' &&\n action.kanbanStatus !== 'DONE' &&\n action.kanbanStatus !== 'CANCELLED'\n );\n }\n\n return actions;\n }\n\n async getToday(workspaceId?: string): Promise<Action[]> {\n return await this.client.action.getToday.query({\n workspaceId,\n }) as Action[];\n }\n\n async getByDateRange(start: Date, end: Date, workspaceId?: string): Promise<Action[]> {\n return await this.client.action.getByDateRange.query({\n startDate: start,\n endDate: end,\n workspaceId,\n }) as Action[];\n }\n\n async getKanban(options: ActionsKanbanOptions = {}): Promise<Action[]> {\n const { projectId, status, assigneeId } = options;\n\n return await this.client.action.getKanbanActions.query({\n projectId,\n kanbanStatus: status,\n assigneeId,\n }) as Action[];\n }\n\n async getProjectActions(projectId: string, assigneeId?: string): Promise<Action[]> {\n return await this.client.action.getProjectActions.query({\n projectId,\n assigneeId,\n }) as Action[];\n }\n\n async create(input: ActionCreateInput): Promise<Action> {\n return await this.client.action.create.mutate(input) as Action;\n }\n\n async update(input: ActionUpdateInput): Promise<Action> {\n return await this.client.action.update.mutate(input) as Action;\n }\n}\n","import type { TrpcClient } from './client.js';\nimport type { ActionComment } from './types/comment.js';\n\nexport interface ActionCommentAddInput {\n actionId: string;\n content: string;\n}\n\nexport interface ActionCommentUpdateInput {\n commentId: string;\n content: string;\n}\n\nexport class ActionCommentsApi {\n constructor(private client: TrpcClient) {}\n\n async list(actionId: string): Promise<ActionComment[]> {\n return await this.client.actionComment.getComments.query({\n actionId,\n }) as ActionComment[];\n }\n\n async add(input: ActionCommentAddInput): Promise<ActionComment> {\n return await this.client.actionComment.addComment.mutate(input) as ActionComment;\n }\n\n async update(input: ActionCommentUpdateInput): Promise<ActionComment> {\n return await this.client.actionComment.updateComment.mutate(input) as ActionComment;\n }\n\n async delete(commentId: string): Promise<ActionComment> {\n return await this.client.actionComment.deleteComment.mutate({\n commentId,\n }) as ActionComment;\n }\n}\n","import type { TrpcClient } from './client.js';\nimport type { Project } from './types/project.js';\n\nexport interface ProjectsListOptions {\n workspaceId?: string;\n includeActions?: boolean;\n}\n\nexport class ProjectsApi {\n constructor(private client: TrpcClient) {}\n\n async list(options: ProjectsListOptions = {}): Promise<Project[]> {\n const { workspaceId, includeActions } = options;\n\n return await this.client.project.getAll.query({\n workspaceId,\n include: includeActions ? { actions: true } : undefined,\n }) as Project[];\n }\n}\n","import type { TrpcClient } from './client.js';\nimport type { Workspace } from './types/workspace.js';\n\nexport class WorkspacesApi {\n constructor(private client: TrpcClient) {}\n\n async list(): Promise<Workspace[]> {\n return await this.client.workspace.list.query() as Workspace[];\n }\n}\n","import type { TrpcClient } from './client.js';\nimport type { Contact, ContactInteraction, ContactListOutput, InteractionType, InteractionDirection } from './types/contact.js';\n\nexport interface ContactsListOptions {\n workspaceId: string;\n search?: string;\n tags?: string[];\n organizationId?: string;\n limit?: number;\n cursor?: string;\n}\n\nexport interface ContactCreateInput {\n workspaceId: string;\n firstName?: string;\n lastName?: string;\n email?: string | null;\n phone?: string;\n linkedIn?: string;\n telegram?: string;\n twitter?: string;\n github?: string;\n bluesky?: string;\n about?: string;\n profileType?: string;\n skills?: string[];\n tags?: string[];\n organizationId?: string;\n}\n\nexport interface ContactUpdateInput {\n id: string;\n firstName?: string;\n lastName?: string;\n email?: string | null;\n phone?: string | null;\n linkedIn?: string | null;\n telegram?: string | null;\n twitter?: string | null;\n github?: string | null;\n bluesky?: string | null;\n about?: string;\n profileType?: string;\n skills?: string[];\n tags?: string[];\n organizationId?: string | null;\n}\n\nexport interface AddInteractionInput {\n contactId: string;\n type: InteractionType;\n direction: InteractionDirection;\n subject?: string;\n notes?: string;\n metadata?: Record<string, unknown>;\n}\n\nexport class ContactsApi {\n constructor(private client: TrpcClient) {}\n\n async list(options: ContactsListOptions): Promise<ContactListOutput> {\n return await this.client.crmApi.contactList.query(options) as ContactListOutput;\n }\n\n async get(id: string, options?: { includeInteractions?: boolean }): Promise<Contact> {\n return await this.client.crmApi.contactGet.query({\n id,\n includeInteractions: options?.includeInteractions,\n }) as Contact;\n }\n\n async create(input: ContactCreateInput): Promise<Contact> {\n return await this.client.crmApi.contactCreate.mutate(input) as Contact;\n }\n\n async update(input: ContactUpdateInput): Promise<Contact> {\n return await this.client.crmApi.contactUpdate.mutate(input) as Contact;\n }\n\n async delete(id: string): Promise<void> {\n await this.client.crmApi.contactDelete.mutate({ id });\n }\n\n async addInteraction(input: AddInteractionInput): Promise<ContactInteraction> {\n return await this.client.crmApi.contactAddInteraction.mutate(input) as ContactInteraction;\n }\n}\n","import type { TrpcClient } from './client.js';\nimport type { Pipeline, PipelineStage, Deal } from './types/pipeline.js';\n\nexport interface DealCreateInput {\n workspaceId: string;\n stageId: string;\n title: string;\n description?: string;\n value?: number;\n currency?: string;\n probability?: number;\n expectedCloseDate?: Date;\n contactId?: string;\n organizationId?: string;\n assignedToId?: string;\n}\n\nexport interface DealUpdateInput {\n id: string;\n title?: string;\n description?: string | null;\n value?: number | null;\n currency?: string;\n probability?: number | null;\n expectedCloseDate?: Date | null;\n contactId?: string | null;\n organizationId?: string | null;\n assignedToId?: string | null;\n}\n\nexport interface DealMoveInput {\n id: string;\n stageId: string;\n stageOrder: number;\n}\n\nexport class PipelinesApi {\n constructor(private client: TrpcClient) {}\n\n async get(workspaceId: string): Promise<Pipeline | null> {\n return await this.client.crmApi.pipelineGet.query({ workspaceId }) as Pipeline | null;\n }\n\n async getStages(workspaceId: string): Promise<PipelineStage[]> {\n return await this.client.crmApi.pipelineGetStages.query({ workspaceId }) as PipelineStage[];\n }\n\n async listDeals(workspaceId: string): Promise<Deal[]> {\n return await this.client.crmApi.dealList.query({ workspaceId }) as Deal[];\n }\n\n async getDeal(id: string): Promise<Deal> {\n return await this.client.crmApi.dealGet.query({ id }) as Deal;\n }\n\n async createDeal(input: DealCreateInput): Promise<Deal> {\n return await this.client.crmApi.dealCreate.mutate(input) as Deal;\n }\n\n async updateDeal(input: DealUpdateInput): Promise<Deal> {\n return await this.client.crmApi.dealUpdate.mutate(input) as Deal;\n }\n\n async moveDeal(input: DealMoveInput): Promise<Deal> {\n return await this.client.crmApi.dealMove.mutate(input) as Deal;\n }\n\n async deleteDeal(id: string): Promise<void> {\n await this.client.crmApi.dealDelete.mutate({ id });\n }\n}\n","import type { TrpcClient } from './client.js';\nimport type { TicketComment } from './types/comment.js';\nimport type {\n Ticket,\n TicketDetail,\n TicketDependencyEdge,\n TicketStatus,\n TicketType,\n} from './types/ticket.js';\nimport type { Action } from './types/action.js';\n\nexport interface TicketListOptions {\n productId: string;\n status?: TicketStatus;\n type?: TicketType;\n featureId?: string;\n epicId?: string;\n cycleId?: string;\n assigneeId?: string;\n}\n\nexport interface TicketCreateInput {\n productId: string;\n title: string;\n body?: string;\n type?: TicketType;\n status?: TicketStatus;\n /** 0–4; lower is higher priority. */\n priority?: number;\n points?: number;\n branchName?: string;\n prUrl?: string;\n designUrl?: string;\n specUrl?: string;\n links?: Record<string, string>;\n epicId?: string;\n featureId?: string;\n cycleId?: string;\n scopeId?: string;\n assigneeId?: string;\n templateId?: string;\n}\n\nexport interface TicketUpdateInput {\n id: string;\n title?: string;\n body?: string;\n type?: TicketType;\n status?: TicketStatus;\n priority?: number | null;\n points?: number | null;\n branchName?: string | null;\n prUrl?: string | null;\n designUrl?: string | null;\n specUrl?: string | null;\n links?: Record<string, string> | null;\n epicId?: string | null;\n featureId?: string | null;\n cycleId?: string | null;\n scopeId?: string | null;\n assigneeId?: string | null;\n}\n\nexport interface TicketCommentAddInput {\n ticketId: string;\n content: string;\n}\n\nexport interface TicketSearchOptions {\n productId: string;\n query?: string;\n excludeTicketId?: string;\n limit?: number;\n}\n\nexport class TicketsApi {\n constructor(private client: TrpcClient) {}\n\n async list(options: TicketListOptions): Promise<Ticket[]> {\n return await this.client.product.ticket.list.query(options) as Ticket[];\n }\n\n async get(id: string): Promise<TicketDetail> {\n return await this.client.product.ticket.getById.query({\n id,\n }) as TicketDetail;\n }\n\n async create(input: TicketCreateInput): Promise<Ticket> {\n return await this.client.product.ticket.create.mutate(input) as Ticket;\n }\n\n async update(input: TicketUpdateInput): Promise<Ticket> {\n return await this.client.product.ticket.update.mutate(input) as Ticket;\n }\n\n async delete(id: string): Promise<{ success: boolean }> {\n return await this.client.product.ticket.delete.mutate({ id }) as {\n success: boolean;\n };\n }\n\n async search(options: TicketSearchOptions): Promise<TicketDependencyEdge[]> {\n return await this.client.product.ticket.search.query(\n options,\n ) as TicketDependencyEdge[];\n }\n\n /** Mark `ticketId` as blocked by `dependsOnId`. */\n async addDependency(\n ticketId: string,\n dependsOnId: string,\n ): Promise<{ id: string; dependsOn: TicketDependencyEdge }> {\n return await this.client.product.ticket.addDependency.mutate({\n ticketId,\n dependsOnId,\n }) as { id: string; dependsOn: TicketDependencyEdge };\n }\n\n async removeDependency(\n ticketId: string,\n dependsOnId: string,\n ): Promise<{ success: boolean }> {\n return await this.client.product.ticket.removeDependency.mutate({\n ticketId,\n dependsOnId,\n }) as { success: boolean };\n }\n\n async addComment(input: TicketCommentAddInput): Promise<TicketComment> {\n return await this.client.product.ticket.addComment.mutate(\n input,\n ) as TicketComment;\n }\n\n async deleteComment(id: string): Promise<{ success: boolean }> {\n return await this.client.product.ticket.deleteComment.mutate({\n id,\n }) as { success: boolean };\n }\n\n /** Attach an existing action to a ticket. */\n async linkAction(ticketId: string, actionId: string): Promise<Action> {\n return await this.client.product.ticket.linkAction.mutate({\n ticketId,\n actionId,\n }) as Action;\n }\n\n /** Detach an action from whatever ticket it's linked to. */\n async unlinkAction(actionId: string): Promise<Action> {\n return await this.client.product.ticket.unlinkAction.mutate({\n actionId,\n }) as Action;\n }\n}\n","import type { TrpcClient } from './client.js';\nimport type { Product } from './types/product.js';\n\nexport interface ProductCreateInput {\n workspaceId: string;\n name: string;\n /** Kebab-case slug; must match `/^[a-z0-9-]+$/`. */\n slug: string;\n description?: string;\n icon?: string;\n color?: string;\n}\n\nexport interface ProductUpdateInput {\n id: string;\n name?: string;\n description?: string;\n icon?: string;\n color?: string;\n funTicketIds?: boolean;\n}\n\nexport class ProductsApi {\n constructor(private client: TrpcClient) {}\n\n async list(workspaceId: string): Promise<Product[]> {\n return await this.client.product.product.list.query({\n workspaceId,\n }) as Product[];\n }\n\n async get(id: string): Promise<Product> {\n return await this.client.product.product.getById.query({ id }) as Product;\n }\n\n async getBySlug(workspaceId: string, slug: string): Promise<Product> {\n return await this.client.product.product.getBySlug.query({\n workspaceId,\n slug,\n }) as Product;\n }\n\n /**\n * Resolve a product reference (slug or CUID) to a full Product. Falls back\n * to slug lookup if the bare CUID lookup fails — callers can pass either.\n */\n async resolve(workspaceId: string, slugOrId: string): Promise<Product> {\n // Heuristic: CUIDs from Prisma start with 'c' and are 25 chars; otherwise\n // try slug first. We try both to stay forgiving.\n const looksLikeId = /^c[a-z0-9]{20,}$/.test(slugOrId);\n if (looksLikeId) {\n try {\n return await this.get(slugOrId);\n } catch {\n // fall through to slug\n }\n }\n return await this.getBySlug(workspaceId, slugOrId);\n }\n\n async create(input: ProductCreateInput): Promise<Product> {\n return await this.client.product.product.create.mutate(input) as Product;\n }\n\n async update(input: ProductUpdateInput): Promise<Product> {\n return await this.client.product.product.update.mutate(input) as Product;\n }\n\n async delete(id: string): Promise<{ success: boolean }> {\n return await this.client.product.product.delete.mutate({ id }) as {\n success: boolean;\n };\n }\n}\n","import type { TrpcClient } from './client.js';\nimport type { Feature, FeatureStatus } from './types/feature.js';\n\nexport interface FeatureListOptions {\n productId: string;\n status?: FeatureStatus;\n}\n\nexport interface FeatureCreateInput {\n productId: string;\n name: string;\n description?: string;\n vision?: string;\n status?: FeatureStatus;\n effort?: number;\n /** 0–4; lower is higher priority. */\n priority?: number;\n goalId?: number;\n}\n\nexport interface FeatureUpdateInput {\n id: string;\n name?: string;\n description?: string;\n vision?: string;\n status?: FeatureStatus;\n effort?: number;\n priority?: number;\n goalId?: number | null;\n}\n\nexport class FeaturesApi {\n constructor(private client: TrpcClient) {}\n\n async list(options: FeatureListOptions): Promise<Feature[]> {\n return await this.client.product.feature.list.query({\n productId: options.productId,\n status: options.status,\n }) as Feature[];\n }\n\n async get(id: string): Promise<Feature> {\n return await this.client.product.feature.getById.query({ id }) as Feature;\n }\n\n async create(input: FeatureCreateInput): Promise<Feature> {\n return await this.client.product.feature.create.mutate(input) as Feature;\n }\n\n async update(input: FeatureUpdateInput): Promise<Feature> {\n return await this.client.product.feature.update.mutate(input) as Feature;\n }\n\n async delete(id: string): Promise<{ success: boolean }> {\n return await this.client.product.feature.delete.mutate({ id }) as {\n success: boolean;\n };\n }\n}\n","import type { TrpcClient } from './client.js';\nimport type { Epic, EpicPriority, EpicStatus } from './types/epic.js';\n\nexport interface EpicListOptions {\n workspaceId: string;\n status?: EpicStatus;\n}\n\nexport interface EpicCreateInput {\n workspaceId: string;\n name: string;\n description?: string;\n priority?: EpicPriority;\n startDate?: Date;\n targetDate?: Date;\n}\n\nexport interface EpicUpdateInput {\n id: string;\n name?: string;\n description?: string | null;\n status?: EpicStatus;\n priority?: EpicPriority;\n startDate?: Date | null;\n targetDate?: Date | null;\n}\n\nexport class EpicsApi {\n constructor(private client: TrpcClient) {}\n\n async list(options: EpicListOptions): Promise<Epic[]> {\n return await this.client.epic.list.query({\n workspaceId: options.workspaceId,\n status: options.status,\n }) as Epic[];\n }\n\n async get(id: string): Promise<Epic> {\n return await this.client.epic.getById.query({ id }) as Epic;\n }\n\n async create(input: EpicCreateInput): Promise<Epic> {\n return await this.client.epic.create.mutate(input) as Epic;\n }\n\n async update(input: EpicUpdateInput): Promise<Epic> {\n return await this.client.epic.update.mutate(input) as Epic;\n }\n\n async delete(id: string): Promise<{ success: boolean }> {\n return await this.client.epic.delete.mutate({ id }) as {\n success: boolean;\n };\n }\n}\n","import Conf from 'conf';\n\nexport interface ExponentialConfig {\n apiUrl: string;\n token: string;\n tokenExpiry?: string;\n defaultWorkspaceId?: string;\n defaultWorkspaceSlug?: string;\n}\n\nconst schema = {\n apiUrl: {\n type: 'string' as const,\n default: '',\n },\n token: {\n type: 'string' as const,\n default: '',\n },\n tokenExpiry: {\n type: 'string' as const,\n default: '',\n },\n defaultWorkspaceId: {\n type: 'string' as const,\n default: '',\n },\n defaultWorkspaceSlug: {\n type: 'string' as const,\n default: '',\n },\n};\n\nfunction createStore(projectName: string) {\n return new Conf<ExponentialConfig>({\n projectName,\n schema,\n });\n}\n\nfunction readConfig(store: Conf<ExponentialConfig>): ExponentialConfig {\n return {\n apiUrl: store.get('apiUrl'),\n token: store.get('token'),\n tokenExpiry: store.get('tokenExpiry'),\n defaultWorkspaceId: store.get('defaultWorkspaceId'),\n defaultWorkspaceSlug: store.get('defaultWorkspaceSlug'),\n };\n}\n\nfunction writeConfig(store: Conf<ExponentialConfig>, values: Partial<ExponentialConfig>): void {\n if (values.apiUrl !== undefined) store.set('apiUrl', values.apiUrl);\n if (values.token !== undefined) store.set('token', values.token);\n if (values.tokenExpiry !== undefined) store.set('tokenExpiry', values.tokenExpiry);\n if (values.defaultWorkspaceId !== undefined) store.set('defaultWorkspaceId', values.defaultWorkspaceId);\n if (values.defaultWorkspaceSlug !== undefined) store.set('defaultWorkspaceSlug', values.defaultWorkspaceSlug);\n}\n\nconst defaultStore = createStore('exponential-sdk');\n\nexport function createConfigStore(options?: { projectName?: string }) {\n const store = createStore(options?.projectName ?? 'exponential-sdk');\n\n return {\n loadConfig: () => readConfig(store),\n saveConfig: (values: Partial<ExponentialConfig>) => writeConfig(store, values),\n clearConfig: () => store.clear(),\n isAuthenticated: () => {\n const cfg = readConfig(store);\n return Boolean(cfg.token && cfg.apiUrl);\n },\n getConfigPath: () => store.path,\n };\n}\n\nexport function loadConfig(): ExponentialConfig {\n return readConfig(defaultStore);\n}\n\nexport function saveConfig(values: Partial<ExponentialConfig>): void {\n writeConfig(defaultStore, values);\n}\n\nexport function clearConfig(): void {\n defaultStore.clear();\n}\n\nexport function isAuthenticated(): boolean {\n const cfg = readConfig(defaultStore);\n return Boolean(cfg.token && cfg.apiUrl);\n}\n\nexport function getConfigPath(): string {\n return defaultStore.path;\n}\n","import { createClient, isTRPCError, TRPCClientError, type TrpcClient } from './client.js';\nimport { ActionsApi } from './actions.js';\nimport { ActionCommentsApi } from './actionComments.js';\nimport { ProjectsApi } from './projects.js';\nimport { WorkspacesApi } from './workspaces.js';\nimport { ContactsApi } from './contacts.js';\nimport { PipelinesApi } from './pipelines.js';\nimport { TicketsApi } from './tickets.js';\nimport { ProductsApi } from './products.js';\nimport { FeaturesApi } from './features.js';\nimport { EpicsApi } from './epics.js';\n\nexport class ExponentialClient {\n private client: TrpcClient;\n actions: ActionsApi;\n actionComments: ActionCommentsApi;\n projects: ProjectsApi;\n workspaces: WorkspacesApi;\n contacts: ContactsApi;\n pipelines: PipelinesApi;\n tickets: TicketsApi;\n products: ProductsApi;\n features: FeaturesApi;\n epics: EpicsApi;\n\n constructor(private config: { token: string; apiUrl: string }) {\n this.client = createClient(this.config);\n this.actions = new ActionsApi(this.client);\n this.actionComments = new ActionCommentsApi(this.client);\n this.projects = new ProjectsApi(this.client);\n this.workspaces = new WorkspacesApi(this.client);\n this.contacts = new ContactsApi(this.client);\n this.pipelines = new PipelinesApi(this.client);\n this.tickets = new TicketsApi(this.client);\n this.products = new ProductsApi(this.client);\n this.features = new FeaturesApi(this.client);\n this.epics = new EpicsApi(this.client);\n }\n}\n\nexport {\n createConfigStore,\n loadConfig,\n saveConfig,\n clearConfig,\n isAuthenticated,\n getConfigPath,\n} from './config.js';\n\nexport type { ExponentialConfig } from './config.js';\nexport type {\n Action,\n ActionOutput,\n ActionsListOutput,\n KanbanStatus,\n Priority,\n} from './types/action.js';\nexport type {\n ActionCreateInput,\n ActionUpdateInput,\n ActionStatus,\n} from './actions.js';\nexport type { Project, ProjectOutput, ProjectsListOutput } from './types/project.js';\nexport type { Workspace, WorkspaceOutput, WorkspacesListOutput } from './types/workspace.js';\nexport type {\n Contact,\n ContactInteraction,\n ContactListOutput,\n InteractionType,\n InteractionDirection,\n} from './types/contact.js';\nexport type {\n ContactCreateInput,\n ContactUpdateInput,\n AddInteractionInput,\n ContactsListOptions,\n} from './contacts.js';\nexport type {\n Pipeline,\n PipelineStage,\n Deal,\n DealActivity,\n} from './types/pipeline.js';\nexport type {\n DealCreateInput,\n DealUpdateInput,\n DealMoveInput,\n} from './pipelines.js';\nexport type {\n ActionComment,\n TicketComment,\n CommentAuthor,\n} from './types/comment.js';\nexport type {\n ActionCommentAddInput,\n ActionCommentUpdateInput,\n} from './actionComments.js';\nexport type { Product } from './types/product.js';\nexport type { ProductCreateInput, ProductUpdateInput } from './products.js';\nexport type {\n Feature,\n FeatureScope,\n FeatureScopeStatus,\n FeatureStatus,\n} from './types/feature.js';\nexport type {\n FeatureCreateInput,\n FeatureUpdateInput,\n FeatureListOptions,\n} from './features.js';\nexport type {\n Ticket,\n TicketDetail,\n TicketAssignee,\n TicketDependencyEdge,\n TicketStatus,\n TicketType,\n} from './types/ticket.js';\nexport type {\n TicketListOptions,\n TicketCreateInput,\n TicketUpdateInput,\n TicketCommentAddInput,\n TicketSearchOptions,\n} from './tickets.js';\nexport type { Epic, EpicStatus, EpicPriority } from './types/epic.js';\nexport type {\n EpicCreateInput,\n EpicUpdateInput,\n EpicListOptions,\n} from './epics.js';\nexport { isTRPCError, TRPCClientError };\n"],"mappings":";AAAA,SAAS,kBAAkB,eAAe,uBAAuB;AACjE,OAAO,eAAe;AAiJf,SAAS,aAAa,QAAuD;AAClF,QAAM,SAAS,OAAO,OAAO,QAAQ,QAAQ,EAAE;AAE/C,SAAO,iBAAsB;AAAA,I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