@composio/core 0.16.0 → 0.18.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.
Files changed (51) hide show
  1. package/dist/{CustomTool-Bk38kFp0.d.mts → CustomTool-BKhHv2hJ.d.mts} +1 -1
  2. package/dist/{CustomTool-l-j5HtEf.mjs → CustomTool-C4tv-GL1.mjs} +1 -1
  3. package/dist/FileToolModifier.utils.neutral-D_YkHwZP.mjs +188 -0
  4. package/dist/{Telemetry-DuGJSwUt.mjs → Telemetry-CBtSnWrm.mjs} +27 -11
  5. package/dist/cancellation-jUVItfHw.mjs +704 -0
  6. package/dist/{composio-DSs-1AhC.d.mts → composio-CldtZUyC.d.mts} +254 -247
  7. package/dist/{BaseProvider-D7p2OPEx.d.mts → customTool.types-DC5fPOOi.d.mts} +2954 -82
  8. package/dist/docs/reference/sdk-reference/typescript/session-files.mdx +1 -1
  9. package/dist/{errors-BcEUHZbq.mjs → errors-DyZt79fi.mjs} +3 -0
  10. package/dist/experimental/index.d.mts +2 -2
  11. package/dist/experimental/index.mjs +1 -1
  12. package/dist/{fileUtils.node-BQ0fWge3.mjs → fileUtils.node-BwpUOF0s.mjs} +4 -4
  13. package/dist/index.d.mts +105 -7
  14. package/dist/index.mjs +94 -116
  15. package/dist/models/Files.node.mjs +2 -2
  16. package/dist/{sensitiveFileUploadPaths-BVEt0peg.mjs → sensitiveFileUploadPaths-B0w8dqpv.mjs} +23 -6
  17. package/dist/ssrfGuard.node-DlxO8uzr.mjs +307 -0
  18. package/dist/{types-B4k-qoOf.d.mts → types-BgsRW-XH.d.mts} +2 -2
  19. package/dist/utils/config-defaults/ConfigDefaults.node.d.mts +1 -1
  20. package/dist/utils/config-defaults/ConfigDefaults.workerd.d.mts +1 -1
  21. package/dist/utils/modifiers/FileToolModifier.node.d.mts +1 -1
  22. package/dist/utils/modifiers/FileToolModifier.node.mjs +57 -101
  23. package/dist/utils/modifiers/FileToolModifier.workerd.d.mts +1 -1
  24. package/dist/utils/modifiers/FileToolModifier.workerd.mjs +1 -1
  25. package/dist/utils/ssrfGuard.node.d.mts +25 -6
  26. package/dist/utils/ssrfGuard.node.mjs +2 -152
  27. package/dist/utils/ssrfGuard.workerd.d.mts +13 -1
  28. package/dist/utils/ssrfGuard.workerd.mjs +13 -1
  29. package/package.json +8 -4
  30. package/src/errors/ToolErrors.ts +1 -0
  31. package/src/errors/ValidationErrors.ts +2 -0
  32. package/src/index.ts +6 -0
  33. package/src/models/RemoteFile.ts +7 -2
  34. package/src/models/ToolRouterSession.ts +36 -8
  35. package/src/models/ToolRouterSessionFileMount.ts +14 -8
  36. package/src/models/Tools.ts +102 -39
  37. package/src/provider/BaseProvider.ts +53 -1
  38. package/src/provider/OpenAIProvider.ts +43 -15
  39. package/src/services/telemetry/TelemetryService.ts +27 -12
  40. package/src/types/provider.types.ts +15 -0
  41. package/src/utils/fileUtils.node.ts +8 -2
  42. package/src/utils/jsonSchema.ts +505 -27
  43. package/src/utils/modifiers/FileToolModifier.node.ts +85 -181
  44. package/src/utils/modifiers/FileToolModifier.utils.neutral.ts +199 -0
  45. package/src/utils/pinnedDispatcher.node.ts +118 -0
  46. package/src/utils/sensitiveFileUploadPaths.ts +36 -9
  47. package/src/utils/ssrfGuard.node.ts +100 -11
  48. package/src/utils/ssrfGuard.workerd.ts +16 -0
  49. package/dist/FileToolModifier.utils.neutral-B5rT711M.mjs +0 -72
  50. package/dist/cancellation-NVtGf3St.mjs +0 -364
  51. package/dist/customTool.types-cGHcIBX-.d.mts +0 -2859
@@ -1,5 +1,9 @@
1
- import { z as z$1 } from "zod/v3";
1
+ import { Composio } from "@composio/client";
2
+ import z, { z as z$1 } from "zod/v3";
3
+ import { z as z$2 } from "zod/v4";
2
4
  import { CustomCreateResponse, GenerateURLResponse, McpCreateResponse } from "@composio/client/resources/mcp";
5
+ import { ConnectedAccountUpdateStatusParams as UpdateConnectedAccountParams } from "@composio/client/resources/connected-accounts";
6
+ import { SessionCreateParams, SessionCreateResponse } from "@composio/client/resources/tool-router/session/session.mjs";
3
7
  //#region src/types/tool.types.d.ts
4
8
  /**
5
9
  * Toolkit is the collection of tools,
@@ -12,12 +16,12 @@ declare const ToolkitSchema: z$1.ZodObject<{
12
16
  name: z$1.ZodString;
13
17
  logo: z$1.ZodOptional<z$1.ZodString>;
14
18
  }, "strip", z$1.ZodTypeAny, {
15
- name: string;
16
19
  slug: string;
20
+ name: string;
17
21
  logo?: string | undefined;
18
22
  }, {
19
- name: string;
20
23
  slug: string;
24
+ name: string;
21
25
  logo?: string | undefined;
22
26
  }>;
23
27
  type Toolkit = z$1.infer<typeof ToolkitSchema>;
@@ -214,12 +218,12 @@ declare const ToolSchema: z$1.ZodObject<{
214
218
  name: z$1.ZodString;
215
219
  logo: z$1.ZodOptional<z$1.ZodString>;
216
220
  }, "strip", z$1.ZodTypeAny, {
217
- name: string;
218
221
  slug: string;
222
+ name: string;
219
223
  logo?: string | undefined;
220
224
  }, {
221
- name: string;
222
225
  slug: string;
226
+ name: string;
223
227
  logo?: string | undefined;
224
228
  }>>;
225
229
  version: z$1.ZodOptional<z$1.ZodString>;
@@ -228,13 +232,8 @@ declare const ToolSchema: z$1.ZodObject<{
228
232
  scopes: z$1.ZodOptional<z$1.ZodArray<z$1.ZodString, "many">>;
229
233
  isNoAuth: z$1.ZodOptional<z$1.ZodBoolean>;
230
234
  }, "strip", z$1.ZodTypeAny, {
231
- name: string;
232
235
  slug: string;
233
- toolkit?: {
234
- name: string;
235
- slug: string;
236
- logo?: string | undefined;
237
- } | undefined;
236
+ name: string;
238
237
  description?: string | undefined;
239
238
  inputParameters?: {
240
239
  type: "object";
@@ -271,23 +270,28 @@ declare const ToolSchema: z$1.ZodObject<{
271
270
  definitions?: Record<string, JSONSchemaProperty> | undefined;
272
271
  } | undefined;
273
272
  tags?: string[] | undefined;
273
+ toolkit?: {
274
+ slug: string;
275
+ name: string;
276
+ logo?: string | undefined;
277
+ } | undefined;
274
278
  version?: string | undefined;
275
279
  isDeprecated?: boolean | undefined;
276
280
  availableVersions?: string[] | undefined;
277
281
  scopes?: string[] | undefined;
278
282
  isNoAuth?: boolean | undefined;
279
283
  }, {
280
- name: string;
281
284
  slug: string;
282
- toolkit?: {
283
- name: string;
284
- slug: string;
285
- logo?: string | undefined;
286
- } | undefined;
285
+ name: string;
287
286
  description?: string | undefined;
288
287
  inputParameters?: unknown;
289
288
  outputParameters?: unknown;
290
289
  tags?: string[] | undefined;
290
+ toolkit?: {
291
+ slug: string;
292
+ name: string;
293
+ logo?: string | undefined;
294
+ } | undefined;
291
295
  version?: string | undefined;
292
296
  isDeprecated?: boolean | undefined;
293
297
  availableVersions?: string[] | undefined;
@@ -439,12 +443,12 @@ declare const ToolListResponseSchema: z$1.ZodObject<{
439
443
  name: z$1.ZodString;
440
444
  logo: z$1.ZodOptional<z$1.ZodString>;
441
445
  }, "strip", z$1.ZodTypeAny, {
442
- name: string;
443
446
  slug: string;
447
+ name: string;
444
448
  logo?: string | undefined;
445
449
  }, {
446
- name: string;
447
450
  slug: string;
451
+ name: string;
448
452
  logo?: string | undefined;
449
453
  }>>;
450
454
  version: z$1.ZodOptional<z$1.ZodString>;
@@ -453,13 +457,8 @@ declare const ToolListResponseSchema: z$1.ZodObject<{
453
457
  scopes: z$1.ZodOptional<z$1.ZodArray<z$1.ZodString, "many">>;
454
458
  isNoAuth: z$1.ZodOptional<z$1.ZodBoolean>;
455
459
  }, "strip", z$1.ZodTypeAny, {
456
- name: string;
457
460
  slug: string;
458
- toolkit?: {
459
- name: string;
460
- slug: string;
461
- logo?: string | undefined;
462
- } | undefined;
461
+ name: string;
463
462
  description?: string | undefined;
464
463
  inputParameters?: {
465
464
  type: "object";
@@ -496,23 +495,28 @@ declare const ToolListResponseSchema: z$1.ZodObject<{
496
495
  definitions?: Record<string, JSONSchemaProperty> | undefined;
497
496
  } | undefined;
498
497
  tags?: string[] | undefined;
498
+ toolkit?: {
499
+ slug: string;
500
+ name: string;
501
+ logo?: string | undefined;
502
+ } | undefined;
499
503
  version?: string | undefined;
500
504
  isDeprecated?: boolean | undefined;
501
505
  availableVersions?: string[] | undefined;
502
506
  scopes?: string[] | undefined;
503
507
  isNoAuth?: boolean | undefined;
504
508
  }, {
505
- name: string;
506
509
  slug: string;
507
- toolkit?: {
508
- name: string;
509
- slug: string;
510
- logo?: string | undefined;
511
- } | undefined;
510
+ name: string;
512
511
  description?: string | undefined;
513
512
  inputParameters?: unknown;
514
513
  outputParameters?: unknown;
515
514
  tags?: string[] | undefined;
515
+ toolkit?: {
516
+ slug: string;
517
+ name: string;
518
+ logo?: string | undefined;
519
+ } | undefined;
516
520
  version?: string | undefined;
517
521
  isDeprecated?: boolean | undefined;
518
522
  availableVersions?: string[] | undefined;
@@ -523,13 +527,8 @@ declare const ToolListResponseSchema: z$1.ZodObject<{
523
527
  totalPages: z$1.ZodNumber;
524
528
  }, "strip", z$1.ZodTypeAny, {
525
529
  items: {
526
- name: string;
527
530
  slug: string;
528
- toolkit?: {
529
- name: string;
530
- slug: string;
531
- logo?: string | undefined;
532
- } | undefined;
531
+ name: string;
533
532
  description?: string | undefined;
534
533
  inputParameters?: {
535
534
  type: "object";
@@ -566,6 +565,11 @@ declare const ToolListResponseSchema: z$1.ZodObject<{
566
565
  definitions?: Record<string, JSONSchemaProperty> | undefined;
567
566
  } | undefined;
568
567
  tags?: string[] | undefined;
568
+ toolkit?: {
569
+ slug: string;
570
+ name: string;
571
+ logo?: string | undefined;
572
+ } | undefined;
569
573
  version?: string | undefined;
570
574
  isDeprecated?: boolean | undefined;
571
575
  availableVersions?: string[] | undefined;
@@ -576,17 +580,17 @@ declare const ToolListResponseSchema: z$1.ZodObject<{
576
580
  nextCursor?: string | null | undefined;
577
581
  }, {
578
582
  items: {
579
- name: string;
580
583
  slug: string;
581
- toolkit?: {
582
- name: string;
583
- slug: string;
584
- logo?: string | undefined;
585
- } | undefined;
584
+ name: string;
586
585
  description?: string | undefined;
587
586
  inputParameters?: unknown;
588
587
  outputParameters?: unknown;
589
588
  tags?: string[] | undefined;
589
+ toolkit?: {
590
+ slug: string;
591
+ name: string;
592
+ logo?: string | undefined;
593
+ } | undefined;
590
594
  version?: string | undefined;
591
595
  isDeprecated?: boolean | undefined;
592
596
  availableVersions?: string[] | undefined;
@@ -640,22 +644,22 @@ declare const ToolListParamsSchema: z$1.ZodObject<{
640
644
  authConfigIds: z$1.ZodOptional<z$1.ZodArray<z$1.ZodString, "many">>;
641
645
  important: z$1.ZodOptional<z$1.ZodBoolean>;
642
646
  }, "strip", z$1.ZodTypeAny, {
643
- tools?: string[] | undefined;
644
- toolkits?: string[] | undefined;
645
- authConfigIds?: string[] | undefined;
646
647
  tags?: string[] | undefined;
647
648
  scopes?: string[] | undefined;
649
+ tools?: string[] | undefined;
650
+ toolkits?: string[] | undefined;
648
651
  limit?: number | undefined;
649
652
  search?: string | undefined;
653
+ authConfigIds?: string[] | undefined;
650
654
  important?: boolean | undefined;
651
655
  }, {
652
- tools?: string[] | undefined;
653
- toolkits?: string[] | undefined;
654
- authConfigIds?: string[] | undefined;
655
656
  tags?: string[] | undefined;
656
657
  scopes?: string[] | undefined;
658
+ tools?: string[] | undefined;
659
+ toolkits?: string[] | undefined;
657
660
  limit?: number | undefined;
658
661
  search?: string | undefined;
662
+ authConfigIds?: string[] | undefined;
659
663
  important?: boolean | undefined;
660
664
  }>;
661
665
  type BaseParams = {
@@ -718,26 +722,26 @@ declare const CustomAuthParamsSchema: z$1.ZodObject<{
718
722
  name: z$1.ZodString;
719
723
  value: z$1.ZodUnion<[z$1.ZodString, z$1.ZodNumber]>;
720
724
  }, "strip", z$1.ZodTypeAny, {
721
- value: string | number;
722
725
  name: string;
726
+ value: string | number;
723
727
  in: "query" | "header";
724
728
  }, {
725
- value: string | number;
726
729
  name: string;
730
+ value: string | number;
727
731
  in: "query" | "header";
728
732
  }>, "many">;
729
733
  }, "strip", z$1.ZodTypeAny, {
730
734
  parameters: {
731
- value: string | number;
732
735
  name: string;
736
+ value: string | number;
733
737
  in: "query" | "header";
734
738
  }[];
735
739
  baseURL?: string | undefined;
736
740
  body?: Record<string, unknown> | undefined;
737
741
  }, {
738
742
  parameters: {
739
- value: string | number;
740
743
  name: string;
744
+ value: string | number;
741
745
  in: "query" | "header";
742
746
  }[];
743
747
  baseURL?: string | undefined;
@@ -791,26 +795,26 @@ declare const ToolExecuteParamsSchema: z$1.ZodObject<{
791
795
  name: z$1.ZodString;
792
796
  value: z$1.ZodUnion<[z$1.ZodString, z$1.ZodNumber]>;
793
797
  }, "strip", z$1.ZodTypeAny, {
794
- value: string | number;
795
798
  name: string;
799
+ value: string | number;
796
800
  in: "query" | "header";
797
801
  }, {
798
- value: string | number;
799
802
  name: string;
803
+ value: string | number;
800
804
  in: "query" | "header";
801
805
  }>, "many">;
802
806
  }, "strip", z$1.ZodTypeAny, {
803
807
  parameters: {
804
- value: string | number;
805
808
  name: string;
809
+ value: string | number;
806
810
  in: "query" | "header";
807
811
  }[];
808
812
  baseURL?: string | undefined;
809
813
  body?: Record<string, unknown> | undefined;
810
814
  }, {
811
815
  parameters: {
812
- value: string | number;
813
816
  name: string;
817
+ value: string | number;
814
818
  in: "query" | "header";
815
819
  }[];
816
820
  baseURL?: string | undefined;
@@ -2799,14 +2803,13 @@ declare const ToolExecuteParamsSchema: z$1.ZodObject<{
2799
2803
  dangerouslySkipVersionCheck: z$1.ZodOptional<z$1.ZodBoolean>;
2800
2804
  text: z$1.ZodOptional<z$1.ZodString>;
2801
2805
  }, "strip", z$1.ZodTypeAny, {
2802
- userId?: string | undefined;
2803
2806
  version?: string | undefined;
2804
2807
  allowTracing?: boolean | undefined;
2805
2808
  connectedAccountId?: string | undefined;
2806
2809
  customAuthParams?: {
2807
2810
  parameters: {
2808
- value: string | number;
2809
2811
  name: string;
2812
+ value: string | number;
2810
2813
  in: "query" | "header";
2811
2814
  }[];
2812
2815
  baseURL?: string | undefined;
@@ -3227,17 +3230,17 @@ declare const ToolExecuteParamsSchema: z$1.ZodObject<{
3227
3230
  };
3228
3231
  } | undefined;
3229
3232
  arguments?: Record<string, unknown> | undefined;
3233
+ userId?: string | undefined;
3230
3234
  dangerouslySkipVersionCheck?: boolean | undefined;
3231
3235
  text?: string | undefined;
3232
3236
  }, {
3233
- userId?: string | undefined;
3234
3237
  version?: string | undefined;
3235
3238
  allowTracing?: boolean | undefined;
3236
3239
  connectedAccountId?: string | undefined;
3237
3240
  customAuthParams?: {
3238
3241
  parameters: {
3239
- value: string | number;
3240
3242
  name: string;
3243
+ value: string | number;
3241
3244
  in: "query" | "header";
3242
3245
  }[];
3243
3246
  baseURL?: string | undefined;
@@ -3658,6 +3661,7 @@ declare const ToolExecuteParamsSchema: z$1.ZodObject<{
3658
3661
  };
3659
3662
  } | undefined;
3660
3663
  arguments?: Record<string, unknown> | undefined;
3664
+ userId?: string | undefined;
3661
3665
  dangerouslySkipVersionCheck?: boolean | undefined;
3662
3666
  text?: string | undefined;
3663
3667
  }>;
@@ -3683,14 +3687,14 @@ declare const ToolExecuteResponseSchema: z$1.ZodObject<{
3683
3687
  logId: z$1.ZodOptional<z$1.ZodString>;
3684
3688
  sessionInfo: z$1.ZodOptional<z$1.ZodUnknown>;
3685
3689
  }, "strip", z$1.ZodTypeAny, {
3686
- error: string | null;
3687
3690
  data: Record<string, unknown>;
3691
+ error: string | null;
3688
3692
  successful: boolean;
3689
3693
  logId?: string | undefined;
3690
3694
  sessionInfo?: unknown;
3691
3695
  }, {
3692
- error: string | null;
3693
3696
  data: Record<string, unknown>;
3697
+ error: string | null;
3694
3698
  successful: boolean;
3695
3699
  logId?: string | undefined;
3696
3700
  sessionInfo?: unknown;
@@ -3705,12 +3709,12 @@ declare const ToolProxyParamsSchema: z$1.ZodObject<{
3705
3709
  name: z$1.ZodString;
3706
3710
  value: z$1.ZodUnion<[z$1.ZodString, z$1.ZodNumber]>;
3707
3711
  }, "strip", z$1.ZodTypeAny, {
3708
- value: string | number;
3709
3712
  name: string;
3713
+ value: string | number;
3710
3714
  in: "query" | "header";
3711
3715
  }, {
3712
- value: string | number;
3713
3716
  name: string;
3717
+ value: string | number;
3714
3718
  in: "query" | "header";
3715
3719
  }>, "many">>;
3716
3720
  connectedAccountId: z$1.ZodOptional<z$1.ZodString>;
@@ -5699,8 +5703,8 @@ declare const ToolProxyParamsSchema: z$1.ZodObject<{
5699
5703
  method: "GET" | "POST" | "PUT" | "DELETE" | "PATCH";
5700
5704
  body?: unknown;
5701
5705
  parameters?: {
5702
- value: string | number;
5703
5706
  name: string;
5707
+ value: string | number;
5704
5708
  in: "query" | "header";
5705
5709
  }[] | undefined;
5706
5710
  connectedAccountId?: string | undefined;
@@ -6123,8 +6127,8 @@ declare const ToolProxyParamsSchema: z$1.ZodObject<{
6123
6127
  method: "GET" | "POST" | "PUT" | "DELETE" | "PATCH";
6124
6128
  body?: unknown;
6125
6129
  parameters?: {
6126
- value: string | number;
6127
6130
  name: string;
6131
+ value: string | number;
6128
6132
  in: "query" | "header";
6129
6133
  }[] | undefined;
6130
6134
  connectedAccountId?: string | undefined;
@@ -28570,6 +28574,15 @@ type ExecuteToolFnOptions = {
28570
28574
  customAuthParams?: CustomAuthParams;
28571
28575
  customConnectionData?: CustomConnectionData;
28572
28576
  };
28577
+ /**
28578
+ * Minimal public contract required to execute model tool calls through a Tool Router session.
28579
+ * {@link ToolRouterSession} satisfies this interface.
28580
+ */
28581
+ interface ToolCallSession {
28582
+ execute(toolSlug: string, arguments_?: Record<string, unknown>): Promise<ToolRouterSessionExecuteResponse>;
28583
+ }
28584
+ /** Direct user execution or execution bound to a Tool Router session. */
28585
+ type ToolCallExecutionTarget = string | ToolCallSession;
28573
28586
  /**
28574
28587
  * This type is used to infer the wrapped tool type from the provider.
28575
28588
  * It checks if the provider has a method `_wrapTool` and infers the return type.
@@ -28797,7 +28810,7 @@ declare const MCPServerSchema: z$1.ZodObject<{
28797
28810
  }>]>;
28798
28811
  }, "strip", z$1.ZodTypeAny, {
28799
28812
  type: "single" | "multi";
28800
- status: "active" | "inactive" | "error";
28813
+ status: "error" | "active" | "inactive";
28801
28814
  id: string;
28802
28815
  createdAt: string;
28803
28816
  updatedAt: string;
@@ -28824,7 +28837,7 @@ declare const MCPServerSchema: z$1.ZodObject<{
28824
28837
  tools: string[];
28825
28838
  toolkits: string[];
28826
28839
  };
28827
- status?: "active" | "inactive" | "error" | undefined;
28840
+ status?: "error" | "active" | "inactive" | undefined;
28828
28841
  }>;
28829
28842
  type MCPServer = z$1.infer<typeof MCPServerSchema>;
28830
28843
  /**
@@ -28864,7 +28877,7 @@ declare const MCPServerListResponseSchema: z$1.ZodObject<{
28864
28877
  }>]>;
28865
28878
  }, "strip", z$1.ZodTypeAny, {
28866
28879
  type: "single" | "multi";
28867
- status: "active" | "inactive" | "error";
28880
+ status: "error" | "active" | "inactive";
28868
28881
  id: string;
28869
28882
  createdAt: string;
28870
28883
  updatedAt: string;
@@ -28891,7 +28904,7 @@ declare const MCPServerListResponseSchema: z$1.ZodObject<{
28891
28904
  tools: string[];
28892
28905
  toolkits: string[];
28893
28906
  };
28894
- status?: "active" | "inactive" | "error" | undefined;
28907
+ status?: "error" | "active" | "inactive" | undefined;
28895
28908
  }>, "many">;
28896
28909
  total: z$1.ZodNumber;
28897
28910
  page: z$1.ZodNumber;
@@ -28899,7 +28912,7 @@ declare const MCPServerListResponseSchema: z$1.ZodObject<{
28899
28912
  }, "strip", z$1.ZodTypeAny, {
28900
28913
  items: {
28901
28914
  type: "single" | "multi";
28902
- status: "active" | "inactive" | "error";
28915
+ status: "error" | "active" | "inactive";
28903
28916
  id: string;
28904
28917
  createdAt: string;
28905
28918
  updatedAt: string;
@@ -28931,7 +28944,7 @@ declare const MCPServerListResponseSchema: z$1.ZodObject<{
28931
28944
  tools: string[];
28932
28945
  toolkits: string[];
28933
28946
  };
28934
- status?: "active" | "inactive" | "error" | undefined;
28947
+ status?: "error" | "active" | "inactive" | undefined;
28935
28948
  }[];
28936
28949
  total: number;
28937
28950
  page: number;
@@ -28946,13 +28959,13 @@ declare const MCPServerUpdateParamsSchema: z$1.ZodObject<{
28946
28959
  toolkits: z$1.ZodOptional<z$1.ZodArray<z$1.ZodString, "many">>;
28947
28960
  allowedTools: z$1.ZodOptional<z$1.ZodArray<z$1.ZodString, "many">>;
28948
28961
  }, "strip", z$1.ZodTypeAny, {
28949
- allowedTools?: string[] | undefined;
28950
28962
  name?: string | undefined;
28951
28963
  toolkits?: string[] | undefined;
28952
- }, {
28953
28964
  allowedTools?: string[] | undefined;
28965
+ }, {
28954
28966
  name?: string | undefined;
28955
28967
  toolkits?: string[] | undefined;
28968
+ allowedTools?: string[] | undefined;
28956
28969
  }>;
28957
28970
  type MCPServerUpdateParams = z$1.infer<typeof MCPServerUpdateParamsSchema>;
28958
28971
  /**
@@ -28991,7 +29004,7 @@ declare const MCPServerCreateResponseSchema: z$1.ZodObject<{
28991
29004
  }>]>;
28992
29005
  }, "strip", z$1.ZodTypeAny, {
28993
29006
  type: "single" | "multi";
28994
- status: "active" | "inactive" | "error";
29007
+ status: "error" | "active" | "inactive";
28995
29008
  id: string;
28996
29009
  createdAt: string;
28997
29010
  updatedAt: string;
@@ -29018,7 +29031,7 @@ declare const MCPServerCreateResponseSchema: z$1.ZodObject<{
29018
29031
  tools: string[];
29019
29032
  toolkits: string[];
29020
29033
  };
29021
- status?: "active" | "inactive" | "error" | undefined;
29034
+ status?: "error" | "active" | "inactive" | undefined;
29022
29035
  }>;
29023
29036
  type MCPServerCreateResponse = z$1.infer<typeof MCPServerCreateResponseSchema>;
29024
29037
  /**
@@ -29213,8 +29226,8 @@ declare const McpRetrieveResponseSchema: z$1.ZodObject<{
29213
29226
  windsurf: string;
29214
29227
  }>;
29215
29228
  }, "strip", z$1.ZodTypeAny, {
29216
- mcpUrl: string;
29217
29229
  name: string;
29230
+ mcpUrl: string;
29218
29231
  id: string;
29219
29232
  commands: {
29220
29233
  claude: string;
@@ -29224,13 +29237,13 @@ declare const McpRetrieveResponseSchema: z$1.ZodObject<{
29224
29237
  status?: string | undefined;
29225
29238
  tools?: string[] | undefined;
29226
29239
  toolkits?: string[] | undefined;
29240
+ authConfigIds?: string[] | undefined;
29227
29241
  createdAt?: string | undefined;
29228
29242
  updatedAt?: string | undefined;
29229
29243
  managedAuthViaComposio?: boolean | undefined;
29230
- authConfigIds?: string[] | undefined;
29231
29244
  }, {
29232
- mcpUrl: string;
29233
29245
  name: string;
29246
+ mcpUrl: string;
29234
29247
  id: string;
29235
29248
  commands: {
29236
29249
  claude: string;
@@ -29240,10 +29253,10 @@ declare const McpRetrieveResponseSchema: z$1.ZodObject<{
29240
29253
  status?: string | undefined;
29241
29254
  tools?: string[] | undefined;
29242
29255
  toolkits?: string[] | undefined;
29256
+ authConfigIds?: string[] | undefined;
29243
29257
  createdAt?: string | undefined;
29244
29258
  updatedAt?: string | undefined;
29245
29259
  managedAuthViaComposio?: boolean | undefined;
29246
- authConfigIds?: string[] | undefined;
29247
29260
  }>;
29248
29261
  declare const ComposioMcpRetrieveResponseSchema: z$1.ZodObject<{
29249
29262
  id: z$1.ZodString;
@@ -29397,6 +29410,13 @@ declare abstract class BaseProvider<TMcpResponse> {
29397
29410
  * @returns {Promise<string>} The result of the tool execution.
29398
29411
  */
29399
29412
  executeTool(toolSlug: string, body: ToolExecuteParams, modifers?: ExecuteToolModifiers): Promise<ToolExecuteResponse>;
29413
+ /** Reject direct-only configuration when execution is bound to a session. */
29414
+ protected assertToolCallExecutionOptions(target: ToolCallExecutionTarget, options?: ExecuteToolFnOptions, modifiers?: ExecuteToolModifiers): void;
29415
+ /**
29416
+ * Execute normalized provider arguments against either the direct tools API or
29417
+ * the Tool Router session that produced the model-visible tools.
29418
+ */
29419
+ protected executeToolForTarget(target: ToolCallExecutionTarget, toolSlug: string, arguments_: Record<string, unknown>, options?: ExecuteToolFnOptions, modifiers?: ExecuteToolModifiers): Promise<ToolExecuteResponse>;
29400
29420
  /**
29401
29421
  * @public
29402
29422
  * @deprecated: Will be removed in a future version, once the `experimental.mcp` flag is stabilized. Use `wrapMcpServers` instead.
@@ -29458,4 +29478,2856 @@ declare abstract class BaseAgenticProvider<TToolCollection, TTool, TMcpResponse>
29458
29478
  */
29459
29479
  type BaseComposioProvider<TToolCollection, TTool, TMcpResponse = McpServerGetResponse> = BaseNonAgenticProvider<TToolCollection, TTool, TMcpResponse> | BaseAgenticProvider<TToolCollection, TTool, TMcpResponse>;
29460
29480
  //#endregion
29461
- export { McpUpdateResponse as $, ExecuteToolModifiers as $t, MCPServer as A, ToolRetrievalOptions as An, Oauth1InitiatedConnectionData as At, MCPToolkitConfig as B, ToolkitVersions as Bn, Oauth2FailedConnectionData as Bt, MCPGenerateURLParams as C, ToolList as Cn, Oauth1ConnectionDataSchema as Ct, MCPInstanceParams as D, ToolListResponseSchema as Dn, Oauth1FailedConnectionDataSchema as Dt, MCPGetServerParamsSchema as E, ToolListResponse as En, Oauth1FailedConnectionData as Et, MCPServerSchema as F, ToolkitSchema as Fn, Oauth2ActiveConnectionDataSchema as Ft, McpListResponse as G, Oauth2InitiatedConnectionDataSchema as Gt, MCPToolkitConfigsArraySchema as H, Oauth2InactiveConnectionData as Ht, MCPServerUpdateParams as I, ToolkitVersion as In, Oauth2ConnectionData as It, McpRetrieveResponseSchema as J, Oauth2RevokedConnectionData as Jt, McpListResponseSchema as K, Oauth2InitiatingConnectionData as Kt, MCPServerUpdateParamsSchema as L, ToolkitVersionParam as Ln, Oauth2ConnectionDataSchema as Lt, MCPServerCreateResponseSchema as M, Toolkit as Mn, Oauth1InitiatingConnectionData as Mt, MCPServerListResponse as N, ToolkitLatestVersion as Nn, Oauth1InitiatingConnectionDataSchema as Nt, MCPMultiAppServer as O, ToolProxyParams as On, Oauth1InactiveConnectionData as Ot, MCPServerListResponseSchema as P, ToolkitLatestVersionSchema as Pn, Oauth2ActiveConnectionData as Pt, McpToolkitConnectionStatus as Q, BeforeFileUploadSource as Qt, MCPSingleAppServer as R, ToolkitVersionParamSchema as Rn, Oauth2ExpiredConnectionData as Rt, MCPCreateMethodResponse as S, ToolExecuteResponseSchema as Sn, Oauth1ConnectionData as St, MCPGetServerParams as T, ToolListParamsSchema as Tn, Oauth1ExpiredConnectionDataSchema as Tt, McpDeleteResponse as U, Oauth2InactiveConnectionDataSchema as Ut, MCPToolkitConfigSchema as V, ToolkitVersionsSchema as Vn, Oauth2FailedConnectionDataSchema as Vt, McpDeleteResponseSchema as W, Oauth2InitiatedConnectionData as Wt, McpServerGetResponse as X, RedirectableAuthSchemeSchema as Xt, McpServerCreateResponse as Y, Oauth2RevokedConnectionDataSchema as Yt, McpServerUrlInfo as Z, AgenticToolOptions as Zt, GenerateURLResponse$1 as _, ToolExecuteMetaParams as _n, CustomOauth1ConnectionDataSchema as _t, ComposioGenerateURLParamsSchema as a, TransformToolSchemaModifier as an, ExecuteToolFnOptions as at, MCPAuthOptions as b, ToolExecuteParamsSchema as bn, Oauth1ActiveConnectionData as bt, ComposioMcpListResponseSchema as c, beforeExecuteMetaModifier as cn, BaseConnectionFields as ct, ConnectionStatus as d, CustomAuthParams as dn, ConnectionDataSchema as dt, MetaToolArguments as en, McpUpdateResponseSchema as et, CustomCreateResponse$1 as f, CustomAuthParamsSchema as fn, ConnectionStatusEnum as ft, GenerateURLParamsSchema as g, Tool as gn, CustomOauth1ConnectionData as gt, GenerateURLParams as h, SchemaModifierOptions as hn, CustomConnectionDataSchema as ht, ComposioCustomCreateResponseSchema as i, ToolOptions as in, ExecuteToolFn as it, MCPServerCreateResponse as j, ToolSchema as jn, Oauth1InitiatedConnectionDataSchema as jt, MCPMultiAppServerSchema as k, ToolProxyParamsSchema as kn, Oauth1InactiveConnectionDataSchema as kt, ComposioMcpRetrieveResponseSchema as l, beforeExecuteModifier as ln, BillcomAuthConnectionDataSchema as lt, CustomCreateResponseValidated as m, JSONSchemaPropertySchema as mn, CustomConnectionData as mt, BaseComposioProvider as n, SessionExecuteMetaModifiers as nn, McpUrlResponseCamelCase as nt, ComposioGenerateURLResponseSchema as o, afterExecuteMetaModifier as on, GlobalExecuteToolFn as ot, CustomCreateResponseSchema as p, JSONSchemaProperty as pn, ConnectionStatuses as pt, McpRetrieveResponse as q, Oauth2InitiatingConnectionDataSchema as qt, BaseNonAgenticProvider as r, SessionMetaToolOptions as rn, McpUserConnectionStatus as rt, ComposioMcpDeleteResponseSchema as s, afterExecuteModifier as sn, Provider as st, BaseAgenticProvider as t, ProviderOptions as tn, McpUrlResponse as tt, ComposioMcpUpdateResponseSchema as u, beforeFileUploadModifier as un, ConnectionData as ut, GenerateURLResponseSchema as v, ToolExecuteMetaParamsSchema as vn, CustomOauth2ConnectionData as vt, MCPGenerateURLParamsSchema as w, ToolListParams as wn, Oauth1ExpiredConnectionData as wt, MCPAuthOptionsSchema as x, ToolExecuteResponse as xn, Oauth1ActiveConnectionDataSchema as xt, GenerateURLResponseValidated as y, ToolExecuteParams as yn, CustomOauth2ConnectionDataSchema as yt, MCPSingleAppServerSchema as z, ToolkitVersionSchema as zn, Oauth2ExpiredConnectionDataSchema as zt };
29481
+ //#region src/types/connectedAccounts.types.d.ts
29482
+ /**
29483
+ * Connected Account create parameters
29484
+ */
29485
+ declare const ConnectedAccountStatuses: {
29486
+ readonly INITIALIZING: "INITIALIZING";
29487
+ readonly INITIATED: "INITIATED";
29488
+ readonly ACTIVE: "ACTIVE";
29489
+ readonly FAILED: "FAILED";
29490
+ readonly EXPIRED: "EXPIRED";
29491
+ readonly INACTIVE: "INACTIVE";
29492
+ readonly REVOKED: "REVOKED";
29493
+ };
29494
+ declare const ConnectedAccountStatusSchema: z$1.ZodEnum<["INITIALIZING", "INITIATED", "ACTIVE", "FAILED", "EXPIRED", "INACTIVE", "REVOKED"]>;
29495
+ type ConnectedAccountStatus = (typeof ConnectedAccountStatuses)[keyof typeof ConnectedAccountStatuses];
29496
+ type ConnectedAccountStatusEnum = z$1.infer<typeof ConnectedAccountStatusSchema>;
29497
+ /**
29498
+ * Sharing model for a connected account.
29499
+ *
29500
+ * - `PRIVATE` (default): only the owning `userId` can use the connection.
29501
+ * - `SHARED`: can be used by other `userId`s, but only when the connection
29502
+ * is explicitly pinned in a tool-router session's config and only when
29503
+ * the requesting `userId` passes the connection's ACL (see
29504
+ * `allowAllUsers` / `allowedUserIds` / `notAllowedUserIds`).
29505
+ */
29506
+ declare const ConnectedAccountTypes: {
29507
+ readonly PRIVATE: "PRIVATE";
29508
+ readonly SHARED: "SHARED";
29509
+ };
29510
+ declare const ConnectedAccountTypeSchema: z$1.ZodEnum<["PRIVATE", "SHARED"]>;
29511
+ type ConnectedAccountType = (typeof ConnectedAccountTypes)[keyof typeof ConnectedAccountTypes];
29512
+ declare const ConnectedAccountAclConfigSchema: z$1.ZodObject<{
29513
+ allowAllUsers: z$1.ZodOptional<z$1.ZodBoolean>;
29514
+ allowedUserIds: z$1.ZodOptional<z$1.ZodArray<z$1.ZodString, "many">>;
29515
+ notAllowedUserIds: z$1.ZodOptional<z$1.ZodArray<z$1.ZodString, "many">>;
29516
+ }, "strip", z$1.ZodTypeAny, {
29517
+ allowAllUsers?: boolean | undefined;
29518
+ allowedUserIds?: string[] | undefined;
29519
+ notAllowedUserIds?: string[] | undefined;
29520
+ }, {
29521
+ allowAllUsers?: boolean | undefined;
29522
+ allowedUserIds?: string[] | undefined;
29523
+ notAllowedUserIds?: string[] | undefined;
29524
+ }>;
29525
+ type ConnectedAccountAclConfig = z$1.infer<typeof ConnectedAccountAclConfigSchema>;
29526
+ /**
29527
+ * Resolved ACL as it appears on responses. All three fields are populated
29528
+ * when the field is visible; the field itself is `undefined` for callers
29529
+ * not authorised to see it.
29530
+ */
29531
+ declare const ConnectedAccountAclConfigResponseSchema: z$1.ZodObject<{
29532
+ allowAllUsers: z$1.ZodBoolean;
29533
+ allowedUserIds: z$1.ZodArray<z$1.ZodString, "many">;
29534
+ notAllowedUserIds: z$1.ZodArray<z$1.ZodString, "many">;
29535
+ }, "strip", z$1.ZodTypeAny, {
29536
+ allowAllUsers: boolean;
29537
+ allowedUserIds: string[];
29538
+ notAllowedUserIds: string[];
29539
+ }, {
29540
+ allowAllUsers: boolean;
29541
+ allowedUserIds: string[];
29542
+ notAllowedUserIds: string[];
29543
+ }>;
29544
+ type ConnectedAccountAclConfigResponse = z$1.infer<typeof ConnectedAccountAclConfigResponseSchema>;
29545
+ /**
29546
+ * Experimental options for SHARED connections, passed at create / link time.
29547
+ *
29548
+ * **Experimental — shape may change in future releases.** Wrapped under a
29549
+ * dedicated `experimental` block on every input and response so the
29550
+ * experimental status is visible at every call site.
29551
+ */
29552
+ declare const ConnectedAccountExperimentalSchema: z$1.ZodObject<{
29553
+ accountType: z$1.ZodOptional<z$1.ZodEnum<["PRIVATE", "SHARED"]>>;
29554
+ aclConfigForShared: z$1.ZodOptional<z$1.ZodObject<{
29555
+ allowAllUsers: z$1.ZodOptional<z$1.ZodBoolean>;
29556
+ allowedUserIds: z$1.ZodOptional<z$1.ZodArray<z$1.ZodString, "many">>;
29557
+ notAllowedUserIds: z$1.ZodOptional<z$1.ZodArray<z$1.ZodString, "many">>;
29558
+ }, "strip", z$1.ZodTypeAny, {
29559
+ allowAllUsers?: boolean | undefined;
29560
+ allowedUserIds?: string[] | undefined;
29561
+ notAllowedUserIds?: string[] | undefined;
29562
+ }, {
29563
+ allowAllUsers?: boolean | undefined;
29564
+ allowedUserIds?: string[] | undefined;
29565
+ notAllowedUserIds?: string[] | undefined;
29566
+ }>>;
29567
+ }, "strip", z$1.ZodTypeAny, {
29568
+ accountType?: "PRIVATE" | "SHARED" | undefined;
29569
+ aclConfigForShared?: {
29570
+ allowAllUsers?: boolean | undefined;
29571
+ allowedUserIds?: string[] | undefined;
29572
+ notAllowedUserIds?: string[] | undefined;
29573
+ } | undefined;
29574
+ }, {
29575
+ accountType?: "PRIVATE" | "SHARED" | undefined;
29576
+ aclConfigForShared?: {
29577
+ allowAllUsers?: boolean | undefined;
29578
+ allowedUserIds?: string[] | undefined;
29579
+ notAllowedUserIds?: string[] | undefined;
29580
+ } | undefined;
29581
+ }>;
29582
+ type ConnectedAccountExperimental = z$1.infer<typeof ConnectedAccountExperimentalSchema>;
29583
+ /**
29584
+ * Resolved experimental block on retrieve / list responses. `accountType`
29585
+ * is always present when the block is; `aclConfigForShared` is only
29586
+ * present when the caller is authorised to see the ACL.
29587
+ */
29588
+ declare const ConnectedAccountExperimentalResponseSchema: z$1.ZodObject<{
29589
+ accountType: z$1.ZodOptional<z$1.ZodEnum<["PRIVATE", "SHARED"]>>;
29590
+ aclConfigForShared: z$1.ZodOptional<z$1.ZodObject<{
29591
+ allowAllUsers: z$1.ZodBoolean;
29592
+ allowedUserIds: z$1.ZodArray<z$1.ZodString, "many">;
29593
+ notAllowedUserIds: z$1.ZodArray<z$1.ZodString, "many">;
29594
+ }, "strip", z$1.ZodTypeAny, {
29595
+ allowAllUsers: boolean;
29596
+ allowedUserIds: string[];
29597
+ notAllowedUserIds: string[];
29598
+ }, {
29599
+ allowAllUsers: boolean;
29600
+ allowedUserIds: string[];
29601
+ notAllowedUserIds: string[];
29602
+ }>>;
29603
+ }, "strip", z$1.ZodTypeAny, {
29604
+ accountType?: "PRIVATE" | "SHARED" | undefined;
29605
+ aclConfigForShared?: {
29606
+ allowAllUsers: boolean;
29607
+ allowedUserIds: string[];
29608
+ notAllowedUserIds: string[];
29609
+ } | undefined;
29610
+ }, {
29611
+ accountType?: "PRIVATE" | "SHARED" | undefined;
29612
+ aclConfigForShared?: {
29613
+ allowAllUsers: boolean;
29614
+ allowedUserIds: string[];
29615
+ notAllowedUserIds: string[];
29616
+ } | undefined;
29617
+ }>;
29618
+ type ConnectedAccountExperimentalResponse = z$1.infer<typeof ConnectedAccountExperimentalResponseSchema>;
29619
+ declare const CreateConnectedAccountParamsSchema: z$1.ZodObject<{
29620
+ authConfig: z$1.ZodObject<{
29621
+ id: z$1.ZodString;
29622
+ }, "strip", z$1.ZodTypeAny, {
29623
+ id: string;
29624
+ }, {
29625
+ id: string;
29626
+ }>;
29627
+ connection: z$1.ZodObject<{
29628
+ data: z$1.ZodOptional<z$1.ZodRecord<z$1.ZodString, z$1.ZodUnknown>>;
29629
+ callbackUrl: z$1.ZodOptional<z$1.ZodString>;
29630
+ userId: z$1.ZodOptional<z$1.ZodString>;
29631
+ }, "strip", z$1.ZodTypeAny, {
29632
+ userId?: string | undefined;
29633
+ data?: Record<string, unknown> | undefined;
29634
+ callbackUrl?: string | undefined;
29635
+ }, {
29636
+ userId?: string | undefined;
29637
+ data?: Record<string, unknown> | undefined;
29638
+ callbackUrl?: string | undefined;
29639
+ }>;
29640
+ }, "strip", z$1.ZodTypeAny, {
29641
+ authConfig: {
29642
+ id: string;
29643
+ };
29644
+ connection: {
29645
+ userId?: string | undefined;
29646
+ data?: Record<string, unknown> | undefined;
29647
+ callbackUrl?: string | undefined;
29648
+ };
29649
+ }, {
29650
+ authConfig: {
29651
+ id: string;
29652
+ };
29653
+ connection: {
29654
+ userId?: string | undefined;
29655
+ data?: Record<string, unknown> | undefined;
29656
+ callbackUrl?: string | undefined;
29657
+ };
29658
+ }>;
29659
+ declare const DefaultCreateConnectedAccountParamsSchema: z$1.ZodType<{
29660
+ auth_config: {
29661
+ id: string;
29662
+ };
29663
+ connection: {
29664
+ state?: z$1.infer<typeof ConnectionDataSchema>;
29665
+ data?: Record<string, unknown>;
29666
+ callback_url?: string;
29667
+ user_id?: string;
29668
+ alias?: string;
29669
+ };
29670
+ }>;
29671
+ declare const CreateConnectedAccountOptionsSchema: z$1.ZodType<{
29672
+ allowMultiple?: boolean;
29673
+ callbackUrl?: string;
29674
+ config?: z$1.infer<typeof ConnectionDataSchema>;
29675
+ alias?: string;
29676
+ }>;
29677
+ type CreateConnectedAccountOptions = z$1.infer<typeof CreateConnectedAccountOptionsSchema>;
29678
+ type CreateConnectedAccountParams = z$1.infer<typeof CreateConnectedAccountParamsSchema>;
29679
+ /**
29680
+ * Connected Account create response
29681
+ */
29682
+ declare const CreateConnectedAccountResponseSchema: z$1.ZodObject<{
29683
+ id: z$1.ZodString;
29684
+ status: z$1.ZodEnum<["INITIALIZING", "INITIATED", "ACTIVE", "FAILED", "EXPIRED", "INACTIVE", "REVOKED"]>;
29685
+ redirectUrl: z$1.ZodNullable<z$1.ZodString>;
29686
+ }, "strip", z$1.ZodTypeAny, {
29687
+ status: "INITIALIZING" | "INITIATED" | "ACTIVE" | "FAILED" | "EXPIRED" | "INACTIVE" | "REVOKED";
29688
+ redirectUrl: string | null;
29689
+ id: string;
29690
+ }, {
29691
+ status: "INITIALIZING" | "INITIATED" | "ACTIVE" | "FAILED" | "EXPIRED" | "INACTIVE" | "REVOKED";
29692
+ redirectUrl: string | null;
29693
+ id: string;
29694
+ }>;
29695
+ type CreateConnectedAccountResponse = z$1.infer<typeof CreateConnectedAccountResponseSchema>;
29696
+ declare const ConnectedAccountAuthConfigSchema: z$1.ZodObject<{
29697
+ id: z$1.ZodString;
29698
+ /** @deprecated Use `connectedAccount.state.authScheme` instead. */
29699
+ authScheme: z$1.ZodOptional<z$1.ZodEnum<["OAUTH2", "OAUTH1", "API_KEY", "BASIC", "BILLCOM_AUTH", "BEARER_TOKEN", "GOOGLE_SERVICE_ACCOUNT", "NO_AUTH", "BASIC_WITH_JWT", "CALCOM_AUTH", "SERVICE_ACCOUNT", "SAML", "DCR_OAUTH", "S2S_OAUTH2"]>>;
29700
+ isComposioManaged: z$1.ZodBoolean;
29701
+ isDisabled: z$1.ZodBoolean;
29702
+ }, "strip", z$1.ZodTypeAny, {
29703
+ id: string;
29704
+ isComposioManaged: boolean;
29705
+ isDisabled: boolean;
29706
+ authScheme?: "OAUTH1" | "OAUTH2" | "API_KEY" | "BASIC" | "BEARER_TOKEN" | "BILLCOM_AUTH" | "GOOGLE_SERVICE_ACCOUNT" | "NO_AUTH" | "BASIC_WITH_JWT" | "CALCOM_AUTH" | "SERVICE_ACCOUNT" | "SAML" | "DCR_OAUTH" | "S2S_OAUTH2" | undefined;
29707
+ }, {
29708
+ id: string;
29709
+ isComposioManaged: boolean;
29710
+ isDisabled: boolean;
29711
+ authScheme?: "OAUTH1" | "OAUTH2" | "API_KEY" | "BASIC" | "BEARER_TOKEN" | "BILLCOM_AUTH" | "GOOGLE_SERVICE_ACCOUNT" | "NO_AUTH" | "BASIC_WITH_JWT" | "CALCOM_AUTH" | "SERVICE_ACCOUNT" | "SAML" | "DCR_OAUTH" | "S2S_OAUTH2" | undefined;
29712
+ }>;
29713
+ type ConnectedAccountAuthConfig = z$1.infer<typeof ConnectedAccountAuthConfigSchema>;
29714
+ declare const ConnectedAccountRetrieveResponseSchema: z$1.ZodType<{
29715
+ id: string;
29716
+ authConfig: z$1.infer<typeof ConnectedAccountAuthConfigSchema>;
29717
+ wordId?: string | null;
29718
+ alias?: string | null;
29719
+ /** @deprecated Use `connectedAccount.state` instead — `data` is a legacy raw credential field. */
29720
+ data?: Record<string, unknown>;
29721
+ /** @deprecated Use `connectedAccount.state` instead — `params` is a legacy raw credential field. */
29722
+ params?: Record<string, unknown>;
29723
+ status: ConnectedAccountStatusEnum;
29724
+ statusReason: string | null;
29725
+ toolkit: {
29726
+ slug: string;
29727
+ };
29728
+ state?: z$1.infer<typeof ConnectionDataSchema>;
29729
+ testRequestEndpoint?: string;
29730
+ isDisabled: boolean;
29731
+ createdAt: string;
29732
+ updatedAt: string;
29733
+ experimental?: ConnectedAccountExperimentalResponse;
29734
+ }>;
29735
+ type ConnectedAccountRetrieveResponse = z$1.infer<typeof ConnectedAccountRetrieveResponseSchema>;
29736
+ /**
29737
+ * Type for list response item that doesn't include params
29738
+ */
29739
+ type ConnectedAccountListResponseItem = Omit<ConnectedAccountRetrieveResponse, 'params'>;
29740
+ declare const ConnectedAccountListParamsSchema: z$1.ZodObject<{
29741
+ authConfigIds: z$1.ZodOptional<z$1.ZodNullable<z$1.ZodArray<z$1.ZodString, "many">>>;
29742
+ cursor: z$1.ZodOptional<z$1.ZodNullable<z$1.ZodString>>;
29743
+ limit: z$1.ZodOptional<z$1.ZodNullable<z$1.ZodNumber>>;
29744
+ orderBy: z$1.ZodOptional<z$1.ZodEnum<["created_at", "updated_at"]>>;
29745
+ statuses: z$1.ZodOptional<z$1.ZodNullable<z$1.ZodArray<z$1.ZodEnum<["INITIALIZING", "INITIATED", "ACTIVE", "FAILED", "EXPIRED", "INACTIVE", "REVOKED"]>, "many">>>;
29746
+ toolkitSlugs: z$1.ZodOptional<z$1.ZodNullable<z$1.ZodArray<z$1.ZodString, "many">>>;
29747
+ userIds: z$1.ZodOptional<z$1.ZodNullable<z$1.ZodArray<z$1.ZodString, "many">>>;
29748
+ /**
29749
+ * Experimental — shape may change in future releases. Filter by sharing
29750
+ * model. Default (omitted) returns PRIVATE only. Pass `'SHARED'` for only
29751
+ * shared accounts, or `'ALL'` for `PRIVATE` + `SHARED`. Kept flat because
29752
+ * the wire is a query string and can't carry nested objects.
29753
+ */
29754
+ accountType: z$1.ZodOptional<z$1.ZodEnum<["PRIVATE", "SHARED", "ALL"]>>;
29755
+ }, "strip", z$1.ZodTypeAny, {
29756
+ limit?: number | null | undefined;
29757
+ authConfigIds?: string[] | null | undefined;
29758
+ userIds?: string[] | null | undefined;
29759
+ cursor?: string | null | undefined;
29760
+ accountType?: "PRIVATE" | "SHARED" | "ALL" | undefined;
29761
+ orderBy?: "created_at" | "updated_at" | undefined;
29762
+ statuses?: ("INITIALIZING" | "INITIATED" | "ACTIVE" | "FAILED" | "EXPIRED" | "INACTIVE" | "REVOKED")[] | null | undefined;
29763
+ toolkitSlugs?: string[] | null | undefined;
29764
+ }, {
29765
+ limit?: number | null | undefined;
29766
+ authConfigIds?: string[] | null | undefined;
29767
+ userIds?: string[] | null | undefined;
29768
+ cursor?: string | null | undefined;
29769
+ accountType?: "PRIVATE" | "SHARED" | "ALL" | undefined;
29770
+ orderBy?: "created_at" | "updated_at" | undefined;
29771
+ statuses?: ("INITIALIZING" | "INITIATED" | "ACTIVE" | "FAILED" | "EXPIRED" | "INACTIVE" | "REVOKED")[] | null | undefined;
29772
+ toolkitSlugs?: string[] | null | undefined;
29773
+ }>;
29774
+ type ConnectedAccountListParams = z$1.infer<typeof ConnectedAccountListParamsSchema>;
29775
+ declare const ConnectedAccountListResponseSchema: z$1.ZodObject<{
29776
+ items: z$1.ZodArray<z$1.ZodType<{
29777
+ id: string;
29778
+ authConfig: z$1.infer<typeof ConnectedAccountAuthConfigSchema>;
29779
+ wordId?: string | null;
29780
+ alias?: string | null;
29781
+ /** @deprecated Use `connectedAccount.state` instead — `data` is a legacy raw credential field. */
29782
+ data?: Record<string, unknown>;
29783
+ /** @deprecated Use `connectedAccount.state` instead — `params` is a legacy raw credential field. */
29784
+ params?: Record<string, unknown>;
29785
+ status: ConnectedAccountStatusEnum;
29786
+ statusReason: string | null;
29787
+ toolkit: {
29788
+ slug: string;
29789
+ };
29790
+ state?: z$1.infer<typeof ConnectionDataSchema>;
29791
+ testRequestEndpoint?: string;
29792
+ isDisabled: boolean;
29793
+ createdAt: string;
29794
+ updatedAt: string;
29795
+ experimental?: ConnectedAccountExperimentalResponse;
29796
+ }, z$1.ZodTypeDef, {
29797
+ id: string;
29798
+ authConfig: z$1.infer<typeof ConnectedAccountAuthConfigSchema>;
29799
+ wordId?: string | null;
29800
+ alias?: string | null;
29801
+ /** @deprecated Use `connectedAccount.state` instead — `data` is a legacy raw credential field. */
29802
+ data?: Record<string, unknown>;
29803
+ /** @deprecated Use `connectedAccount.state` instead — `params` is a legacy raw credential field. */
29804
+ params?: Record<string, unknown>;
29805
+ status: ConnectedAccountStatusEnum;
29806
+ statusReason: string | null;
29807
+ toolkit: {
29808
+ slug: string;
29809
+ };
29810
+ state?: z$1.infer<typeof ConnectionDataSchema>;
29811
+ testRequestEndpoint?: string;
29812
+ isDisabled: boolean;
29813
+ createdAt: string;
29814
+ updatedAt: string;
29815
+ experimental?: ConnectedAccountExperimentalResponse;
29816
+ }>, "many">;
29817
+ nextCursor: z$1.ZodOptional<z$1.ZodNullable<z$1.ZodString>>;
29818
+ totalPages: z$1.ZodNumber;
29819
+ }, "strip", z$1.ZodTypeAny, {
29820
+ items: {
29821
+ id: string;
29822
+ authConfig: z$1.infer<typeof ConnectedAccountAuthConfigSchema>;
29823
+ wordId?: string | null;
29824
+ alias?: string | null;
29825
+ /** @deprecated Use `connectedAccount.state` instead — `data` is a legacy raw credential field. */
29826
+ data?: Record<string, unknown>;
29827
+ /** @deprecated Use `connectedAccount.state` instead — `params` is a legacy raw credential field. */
29828
+ params?: Record<string, unknown>;
29829
+ status: ConnectedAccountStatusEnum;
29830
+ statusReason: string | null;
29831
+ toolkit: {
29832
+ slug: string;
29833
+ };
29834
+ state?: z$1.infer<typeof ConnectionDataSchema>;
29835
+ testRequestEndpoint?: string;
29836
+ isDisabled: boolean;
29837
+ createdAt: string;
29838
+ updatedAt: string;
29839
+ experimental?: ConnectedAccountExperimentalResponse;
29840
+ }[];
29841
+ totalPages: number;
29842
+ nextCursor?: string | null | undefined;
29843
+ }, {
29844
+ items: {
29845
+ id: string;
29846
+ authConfig: z$1.infer<typeof ConnectedAccountAuthConfigSchema>;
29847
+ wordId?: string | null;
29848
+ alias?: string | null;
29849
+ /** @deprecated Use `connectedAccount.state` instead — `data` is a legacy raw credential field. */
29850
+ data?: Record<string, unknown>;
29851
+ /** @deprecated Use `connectedAccount.state` instead — `params` is a legacy raw credential field. */
29852
+ params?: Record<string, unknown>;
29853
+ status: ConnectedAccountStatusEnum;
29854
+ statusReason: string | null;
29855
+ toolkit: {
29856
+ slug: string;
29857
+ };
29858
+ state?: z$1.infer<typeof ConnectionDataSchema>;
29859
+ testRequestEndpoint?: string;
29860
+ isDisabled: boolean;
29861
+ createdAt: string;
29862
+ updatedAt: string;
29863
+ experimental?: ConnectedAccountExperimentalResponse;
29864
+ }[];
29865
+ totalPages: number;
29866
+ nextCursor?: string | null | undefined;
29867
+ }>;
29868
+ type ConnectedAccountListResponse = z$1.infer<typeof ConnectedAccountListResponseSchema>;
29869
+ declare const CreateConnectedAccountLinkOptionsSchema: z$1.ZodObject<{
29870
+ /**
29871
+ * The url to redirect the user to post connecting their account.
29872
+ *
29873
+ * For successful connections, you will get a query param called status=success
29874
+ * And for failed connections you will get a query param called status=failed
29875
+ *
29876
+ * @example https://your-app.com/callback
29877
+ *
29878
+ */
29879
+ callbackUrl: z$1.ZodOptional<z$1.ZodString>;
29880
+ /**
29881
+ * Human-readable alias for the connected account. Must be unique per userId and toolkit within the project.
29882
+ */
29883
+ alias: z$1.ZodOptional<z$1.ZodString>;
29884
+ /**
29885
+ * Whether to allow multiple connected accounts for the same user and auth config.
29886
+ * When `false` (default), `link()` throws `ComposioMultipleConnectedAccountsError`
29887
+ * if the user already has an `ACTIVE` connection on this auth config — matching
29888
+ * the guard on `initiate()`. Pair with `alias` and a session-level
29889
+ * `multiAccount` config to disambiguate at execution time.
29890
+ */
29891
+ allowMultiple: z$1.ZodOptional<z$1.ZodBoolean>;
29892
+ /**
29893
+ * Experimental options for SHARED connections. Pass `accountType: 'SHARED'`
29894
+ * (and optionally `aclConfigForShared`) to create a connection that can
29895
+ * be reached by other `userId`s when pinned in a session.
29896
+ *
29897
+ * Experimental — shape may change in future releases.
29898
+ *
29899
+ * `aclConfigForShared` is only valid when `accountType === 'SHARED'`;
29900
+ * raises `ComposioAclOnlyForSharedError` on a PRIVATE connection. Omit
29901
+ * the inner block (or pass `{}`) to keep the deny-by-default state: only
29902
+ * the creator can use the connection. Grant access by setting
29903
+ * `allowAllUsers: true` or listing user IDs in `allowedUserIds`.
29904
+ * `notAllowedUserIds` always wins over allow.
29905
+ */
29906
+ experimental: z$1.ZodOptional<z$1.ZodObject<{
29907
+ accountType: z$1.ZodOptional<z$1.ZodEnum<["PRIVATE", "SHARED"]>>;
29908
+ aclConfigForShared: z$1.ZodOptional<z$1.ZodObject<{
29909
+ allowAllUsers: z$1.ZodOptional<z$1.ZodBoolean>;
29910
+ allowedUserIds: z$1.ZodOptional<z$1.ZodArray<z$1.ZodString, "many">>;
29911
+ notAllowedUserIds: z$1.ZodOptional<z$1.ZodArray<z$1.ZodString, "many">>;
29912
+ }, "strip", z$1.ZodTypeAny, {
29913
+ allowAllUsers?: boolean | undefined;
29914
+ allowedUserIds?: string[] | undefined;
29915
+ notAllowedUserIds?: string[] | undefined;
29916
+ }, {
29917
+ allowAllUsers?: boolean | undefined;
29918
+ allowedUserIds?: string[] | undefined;
29919
+ notAllowedUserIds?: string[] | undefined;
29920
+ }>>;
29921
+ }, "strip", z$1.ZodTypeAny, {
29922
+ accountType?: "PRIVATE" | "SHARED" | undefined;
29923
+ aclConfigForShared?: {
29924
+ allowAllUsers?: boolean | undefined;
29925
+ allowedUserIds?: string[] | undefined;
29926
+ notAllowedUserIds?: string[] | undefined;
29927
+ } | undefined;
29928
+ }, {
29929
+ accountType?: "PRIVATE" | "SHARED" | undefined;
29930
+ aclConfigForShared?: {
29931
+ allowAllUsers?: boolean | undefined;
29932
+ allowedUserIds?: string[] | undefined;
29933
+ notAllowedUserIds?: string[] | undefined;
29934
+ } | undefined;
29935
+ }>>;
29936
+ }, "strip", z$1.ZodTypeAny, {
29937
+ callbackUrl?: string | undefined;
29938
+ experimental?: {
29939
+ accountType?: "PRIVATE" | "SHARED" | undefined;
29940
+ aclConfigForShared?: {
29941
+ allowAllUsers?: boolean | undefined;
29942
+ allowedUserIds?: string[] | undefined;
29943
+ notAllowedUserIds?: string[] | undefined;
29944
+ } | undefined;
29945
+ } | undefined;
29946
+ alias?: string | undefined;
29947
+ allowMultiple?: boolean | undefined;
29948
+ }, {
29949
+ callbackUrl?: string | undefined;
29950
+ experimental?: {
29951
+ accountType?: "PRIVATE" | "SHARED" | undefined;
29952
+ aclConfigForShared?: {
29953
+ allowAllUsers?: boolean | undefined;
29954
+ allowedUserIds?: string[] | undefined;
29955
+ notAllowedUserIds?: string[] | undefined;
29956
+ } | undefined;
29957
+ } | undefined;
29958
+ alias?: string | undefined;
29959
+ allowMultiple?: boolean | undefined;
29960
+ }>;
29961
+ type CreateConnectedAccountLinkOptions = z$1.infer<typeof CreateConnectedAccountLinkOptionsSchema>;
29962
+ declare const CreateConnectedAccountLinkResponseSchema: z$1.ZodObject<{
29963
+ redirectUrl: z$1.ZodString;
29964
+ }, "strip", z$1.ZodTypeAny, {
29965
+ redirectUrl: string;
29966
+ }, {
29967
+ redirectUrl: string;
29968
+ }>;
29969
+ type CreateConnectedAccountLinkResponse = z$1.infer<typeof CreateConnectedAccountLinkResponseSchema>;
29970
+ declare const ConnectedAccountRefreshOptionsSchema: z$1.ZodObject<{
29971
+ redirectUrl: z$1.ZodOptional<z$1.ZodString>;
29972
+ validateCredentials: z$1.ZodOptional<z$1.ZodBoolean>;
29973
+ }, "strip", z$1.ZodTypeAny, {
29974
+ redirectUrl?: string | undefined;
29975
+ validateCredentials?: boolean | undefined;
29976
+ }, {
29977
+ redirectUrl?: string | undefined;
29978
+ validateCredentials?: boolean | undefined;
29979
+ }>;
29980
+ type ConnectedAccountRefreshOptions = z$1.infer<typeof ConnectedAccountRefreshOptionsSchema>;
29981
+ declare const UpdateConnectedAccountParamsSchema: z$1.ZodObject<{
29982
+ enabled: z$1.ZodBoolean;
29983
+ }, "strip", z$1.ZodTypeAny, {
29984
+ enabled: boolean;
29985
+ }, {
29986
+ enabled: boolean;
29987
+ }>;
29988
+ /**
29989
+ * Params for `composio.connectedAccounts.updateAcl()`. Mirrors the inner
29990
+ * shape of the wire's `acl_config_for_shared` block — the SDK adds the
29991
+ * outer nesting at the boundary, so callers pass the three fields flat.
29992
+ *
29993
+ * PATCH-style semantics — omit a field to leave it unchanged; pass an
29994
+ * empty array to clear an allow/deny list. Raises
29995
+ * `ComposioAclOnlyForSharedError` on a PRIVATE connection.
29996
+ *
29997
+ * Each field is optional, but at least one must be provided — passing an
29998
+ * empty object is rejected as a no-op.
29999
+ */
30000
+ declare const UpdateConnectedAccountAclParamsSchema: z$1.ZodEffects<z$1.ZodObject<{
30001
+ allowAllUsers: z$1.ZodOptional<z$1.ZodBoolean>;
30002
+ allowedUserIds: z$1.ZodOptional<z$1.ZodArray<z$1.ZodString, "many">>;
30003
+ notAllowedUserIds: z$1.ZodOptional<z$1.ZodArray<z$1.ZodString, "many">>;
30004
+ }, "strip", z$1.ZodTypeAny, {
30005
+ allowAllUsers?: boolean | undefined;
30006
+ allowedUserIds?: string[] | undefined;
30007
+ notAllowedUserIds?: string[] | undefined;
30008
+ }, {
30009
+ allowAllUsers?: boolean | undefined;
30010
+ allowedUserIds?: string[] | undefined;
30011
+ notAllowedUserIds?: string[] | undefined;
30012
+ }>, {
30013
+ allowAllUsers?: boolean | undefined;
30014
+ allowedUserIds?: string[] | undefined;
30015
+ notAllowedUserIds?: string[] | undefined;
30016
+ }, {
30017
+ allowAllUsers?: boolean | undefined;
30018
+ allowedUserIds?: string[] | undefined;
30019
+ notAllowedUserIds?: string[] | undefined;
30020
+ }>;
30021
+ type UpdateConnectedAccountAclParams = z$1.infer<typeof UpdateConnectedAccountAclParamsSchema>;
30022
+ //#endregion
30023
+ //#region src/types/connectionRequest.types.d.ts
30024
+ interface ConnectionRequestState {
30025
+ id: string;
30026
+ status?: ConnectedAccountStatus;
30027
+ redirectUrl?: string | null;
30028
+ }
30029
+ interface ConnectionRequest extends ConnectionRequestState {
30030
+ waitForConnection: (timeout?: number) => Promise<ConnectedAccountRetrieveResponse>;
30031
+ toJSON: () => ConnectionRequestState;
30032
+ toString: () => string;
30033
+ }
30034
+ //#endregion
30035
+ //#region src/types/requestOptions.types.d.ts
30036
+ /**
30037
+ * Per-request transport options for cancelling an SDK call.
30038
+ *
30039
+ * For `tools.get` and `tools.execute`, pass `signal` directly in the
30040
+ * options bag (3rd argument) alongside any modifiers or provider options.
30041
+ * For other methods (e.g. `toolkits.get`, `authConfigs.list`), pass as a
30042
+ * trailing argument. Forwarded to the underlying `@composio/client` request.
30043
+ *
30044
+ * If the underlying request is aborted via this signal, the SDK throws a
30045
+ * {@link ComposioRequestCancelledError} so callers can `instanceof`-detect
30046
+ * cancellation without unwrapping nested causes.
30047
+ *
30048
+ * @example Timeout after 5 seconds
30049
+ * ```typescript
30050
+ * await composio.tools.execute(
30051
+ * 'HACKERNEWS_GET_FRONTPAGE',
30052
+ * { userId: 'default', arguments: {} },
30053
+ * { signal: AbortSignal.timeout(5_000) }
30054
+ * );
30055
+ * ```
30056
+ *
30057
+ * @example Combine signal with modifiers
30058
+ * ```typescript
30059
+ * await composio.tools.execute('TOOL', body, {
30060
+ * signal: AbortSignal.timeout(10_000),
30061
+ * beforeExecute: ({ params }) => params,
30062
+ * });
30063
+ * ```
30064
+ */
30065
+ type ComposioRequestOptions = {
30066
+ /**
30067
+ * An `AbortSignal` used to cancel the in-flight HTTP request. When the
30068
+ * signal aborts, the underlying fetch is aborted and the SDK throws a
30069
+ * {@link ComposioRequestCancelledError} (subclass of {@link ComposioError}).
30070
+ */
30071
+ signal?: AbortSignal;
30072
+ };
30073
+ //#endregion
30074
+ //#region src/types/ToolRouterSessionFilesMount.types.d.ts
30075
+ declare const ToolRouterSessionFilesMountListOptionsSchema: z.ZodObject<{
30076
+ path: z.ZodOptional<z.ZodString>;
30077
+ mountId: z.ZodDefault<z.ZodString>;
30078
+ /** Pagination cursor from the previous response nextCursor field */
30079
+ cursor: z.ZodOptional<z.ZodString>;
30080
+ /** Maximum number of files to return per page (1-500) */
30081
+ limit: z.ZodOptional<z.ZodNumber>;
30082
+ }, "strip", z.ZodTypeAny, {
30083
+ mountId: string;
30084
+ path?: string | undefined;
30085
+ limit?: number | undefined;
30086
+ cursor?: string | undefined;
30087
+ }, {
30088
+ path?: string | undefined;
30089
+ limit?: number | undefined;
30090
+ cursor?: string | undefined;
30091
+ mountId?: string | undefined;
30092
+ }>;
30093
+ type ToolRouterSessionFilesMountListOptions = z.input<typeof ToolRouterSessionFilesMountListOptionsSchema>;
30094
+ declare const FileListResponseSchema: z.ZodEffects<z.ZodObject<{
30095
+ items: z.ZodArray<z.ZodObject<{
30096
+ last_modified: z.ZodString;
30097
+ mount_relative_path: z.ZodString;
30098
+ sandbox_mount_prefix: z.ZodString;
30099
+ size: z.ZodNumber;
30100
+ }, "strip", z.ZodTypeAny, {
30101
+ last_modified: string;
30102
+ mount_relative_path: string;
30103
+ sandbox_mount_prefix: string;
30104
+ size: number;
30105
+ }, {
30106
+ last_modified: string;
30107
+ mount_relative_path: string;
30108
+ sandbox_mount_prefix: string;
30109
+ size: number;
30110
+ }>, "many">;
30111
+ next_cursor: z.ZodOptional<z.ZodString>;
30112
+ }, "strip", z.ZodTypeAny, {
30113
+ items: {
30114
+ last_modified: string;
30115
+ mount_relative_path: string;
30116
+ sandbox_mount_prefix: string;
30117
+ size: number;
30118
+ }[];
30119
+ next_cursor?: string | undefined;
30120
+ }, {
30121
+ items: {
30122
+ last_modified: string;
30123
+ mount_relative_path: string;
30124
+ sandbox_mount_prefix: string;
30125
+ size: number;
30126
+ }[];
30127
+ next_cursor?: string | undefined;
30128
+ }>, {
30129
+ items: {
30130
+ lastModified: string;
30131
+ mountRelativePath: string;
30132
+ sandboxMountPrefix: string;
30133
+ size: number;
30134
+ }[];
30135
+ nextCursor: string | undefined;
30136
+ }, {
30137
+ items: {
30138
+ last_modified: string;
30139
+ mount_relative_path: string;
30140
+ sandbox_mount_prefix: string;
30141
+ size: number;
30142
+ }[];
30143
+ next_cursor?: string | undefined;
30144
+ }>;
30145
+ type FileListResponse = z.infer<typeof FileListResponseSchema>;
30146
+ declare const ToolRouterSessionFilesMountUploadOptionsSchema: z.ZodObject<{
30147
+ /** Remote path/filename on the mount. When passing a buffer, either mimetype or remotePath is required. */
30148
+ remotePath: z.ZodOptional<z.ZodString>;
30149
+ mountId: z.ZodDefault<z.ZodString>;
30150
+ /** MIME type. When passing a buffer, either mimetype or remotePath is required. Ignored when passing File (uses file.type). */
30151
+ mimetype: z.ZodOptional<z.ZodString>;
30152
+ }, "strip", z.ZodTypeAny, {
30153
+ mountId: string;
30154
+ remotePath?: string | undefined;
30155
+ mimetype?: string | undefined;
30156
+ }, {
30157
+ mountId?: string | undefined;
30158
+ remotePath?: string | undefined;
30159
+ mimetype?: string | undefined;
30160
+ }>;
30161
+ type ToolRouterSessionFilesMountUploadOptions = z.input<typeof ToolRouterSessionFilesMountUploadOptionsSchema>;
30162
+ declare const ToolRouterSessionFilesMountDownloadOptionsSchema: z.ZodObject<{
30163
+ mountId: z.ZodDefault<z.ZodString>;
30164
+ }, "strip", z.ZodTypeAny, {
30165
+ mountId: string;
30166
+ }, {
30167
+ mountId?: string | undefined;
30168
+ }>;
30169
+ type ToolRouterSessionFilesMountDownloadOptions = z.input<typeof ToolRouterSessionFilesMountDownloadOptionsSchema>;
30170
+ declare const ToolRouterSessionFilesMountDeleteOptionsSchema: z.ZodObject<{
30171
+ mountId: z.ZodDefault<z.ZodString>;
30172
+ }, "strip", z.ZodTypeAny, {
30173
+ mountId: string;
30174
+ }, {
30175
+ mountId?: string | undefined;
30176
+ }>;
30177
+ type ToolRouterSessionFilesMountDeleteOptions = z.input<typeof ToolRouterSessionFilesMountDeleteOptionsSchema>;
30178
+ declare const RemoteFileDataSchema: z.ZodEffects<z.ZodObject<{
30179
+ expires_at: z.ZodString;
30180
+ mount_relative_path: z.ZodString;
30181
+ sandbox_mount_prefix: z.ZodString;
30182
+ download_url: z.ZodString;
30183
+ }, "strip", z.ZodTypeAny, {
30184
+ mount_relative_path: string;
30185
+ sandbox_mount_prefix: string;
30186
+ expires_at: string;
30187
+ download_url: string;
30188
+ }, {
30189
+ mount_relative_path: string;
30190
+ sandbox_mount_prefix: string;
30191
+ expires_at: string;
30192
+ download_url: string;
30193
+ }>, {
30194
+ expiresAt: string;
30195
+ mountRelativePath: string;
30196
+ sandboxMountPrefix: string;
30197
+ downloadUrl: string;
30198
+ }, {
30199
+ mount_relative_path: string;
30200
+ sandbox_mount_prefix: string;
30201
+ expires_at: string;
30202
+ download_url: string;
30203
+ }>;
30204
+ /** Parsed shape from API response. Use with `new RemoteFile(data)`. */
30205
+ type RemoteFileData = z.infer<typeof RemoteFileDataSchema>;
30206
+ declare const FileDeleteResponseSchema: z.ZodEffects<z.ZodObject<{
30207
+ mount_relative_path: z.ZodString;
30208
+ sandbox_mount_prefix: z.ZodString;
30209
+ }, "strip", z.ZodTypeAny, {
30210
+ mount_relative_path: string;
30211
+ sandbox_mount_prefix: string;
30212
+ }, {
30213
+ mount_relative_path: string;
30214
+ sandbox_mount_prefix: string;
30215
+ }>, {
30216
+ mountRelativePath: string;
30217
+ sandboxMountPrefix: string;
30218
+ }, {
30219
+ mount_relative_path: string;
30220
+ sandbox_mount_prefix: string;
30221
+ }>;
30222
+ type FileDeleteResponse = z.infer<typeof FileDeleteResponseSchema>;
30223
+ //#endregion
30224
+ //#region src/models/RemoteFile.d.ts
30225
+ /**
30226
+ * Represents a file stored in a tool router session's file mount.
30227
+ * Provides methods to fetch, save, and work with the file content.
30228
+ *
30229
+ * @example
30230
+ * ```typescript
30231
+ * const remoteFile = await session.experimental.files.download('/output/report.pdf');
30232
+ * const buffer = await remoteFile.buffer();
30233
+ * await remoteFile.save('/tmp/report.pdf');
30234
+ * const text = await remoteFile.text();
30235
+ * ```
30236
+ *
30237
+ * @example
30238
+ * ```typescript
30239
+ * // Create from API response (snake_case)
30240
+ * const remoteFile = RemoteFile.parse(apiResponse);
30241
+ *
30242
+ * // Or create from parsed data (camelCase)
30243
+ * const remoteFile = new RemoteFile({
30244
+ * expiresAt: '...',
30245
+ * mountRelativePath: 'report.pdf',
30246
+ * sandboxMountPrefix: '/mnt/files',
30247
+ * downloadUrl: 'https://...',
30248
+ * });
30249
+ * ```
30250
+ */
30251
+ declare class RemoteFile {
30252
+ /** ISO 8601 timestamp when the download URL expires */
30253
+ readonly expiresAt: string;
30254
+ /** Relative path within the mount (e.g. "report.pdf") */
30255
+ readonly mountRelativePath: string;
30256
+ /** Absolute mount path inside the sandbox (e.g. /mnt/files) */
30257
+ readonly sandboxMountPrefix: string;
30258
+ /** Presigned URL for downloading the file */
30259
+ readonly downloadUrl: string;
30260
+ constructor(data: RemoteFileData);
30261
+ /**
30262
+ * Parses an API response (snake_case) and returns a RemoteFile instance.
30263
+ * @param data - Raw API response with snake_case keys
30264
+ * @returns A RemoteFile instance
30265
+ * @throws ValidationError if the response shape is invalid
30266
+ */
30267
+ static parse(data: unknown): RemoteFile;
30268
+ /** Filename extracted from the mount path (e.g. "report.pdf" from "output/report.pdf") */
30269
+ get filename(): string;
30270
+ /**
30271
+ * Fetches the file content as a buffer.
30272
+ * @returns The file content as a Uint8Array
30273
+ * @throws RemoteFileDownloadError if the fetch fails
30274
+ */
30275
+ buffer(): Promise<Uint8Array>;
30276
+ /**
30277
+ * Fetches the file content as UTF-8 text.
30278
+ * @returns The file content as a string
30279
+ * @throws Error if the fetch fails
30280
+ */
30281
+ text(): Promise<string>;
30282
+ /**
30283
+ * Fetches the file content as a Blob.
30284
+ * @returns The file content as a Blob
30285
+ * @throws RemoteFileDownloadError if the fetch fails
30286
+ */
30287
+ blob(): Promise<Blob>;
30288
+ /**
30289
+ * Downloads and saves the file to the local filesystem.
30290
+ * Requires a Node.js runtime with file system support (not available in Cloudflare Workers/Edge).
30291
+ *
30292
+ * @param path - Local path to save the file. If omitted, saves to the Composio temp directory using the filename from the mount path.
30293
+ * @returns The absolute path where the file was saved
30294
+ * @throws Error if file system is not supported or the save fails
30295
+ */
30296
+ save(path?: string): Promise<string>;
30297
+ }
30298
+ //#endregion
30299
+ //#region src/models/ToolRouterSessionFileMount.d.ts
30300
+ /**
30301
+ * File mount for a Composio session, reached via `session.experimental.files`
30302
+ * on a session created with `composio.sessions.create(...)`. Upload, list,
30303
+ * download, and delete files scoped to a single session.
30304
+ */
30305
+ declare class ToolRouterSessionFilesMount {
30306
+ private readonly sessionId;
30307
+ private readonly client;
30308
+ constructor(client: Composio, sessionId: string);
30309
+ /**
30310
+ * Lists files and directories at the specified path on the session's file mount.
30311
+ *
30312
+ * Use this to browse the virtual filesystem attached to the tool router session.
30313
+ * The path is relative to the mount root (e.g., `"/"` for root, `"/documents"` for a subdirectory).
30314
+ * Supports cursor-based pagination via `cursor` and `limit` options.
30315
+ *
30316
+ * @param options - Optional configuration for the list operation.
30317
+ * @param options.path - The directory path to list. Use `"/"` for the mount root.
30318
+ * @param options.mountId - The ID of the file mount to operate on. Defaults to `"files"` when omitted.
30319
+ * @param options.cursor - Pagination cursor from the previous response's nextCursor field.
30320
+ * @param options.limit - Maximum number of files to return per page (1-500).
30321
+ * @returns List of files with nextCursor for pagination.
30322
+ *
30323
+ * @example
30324
+ * ```typescript
30325
+ * const session = await composio.toolRouter.use('session_123');
30326
+ * const { items, nextCursor } = await session.experimental.files.list({ path: '/' });
30327
+ * ```
30328
+ *
30329
+ * @example
30330
+ * ```typescript
30331
+ * // Paginated listing
30332
+ * let result = await session.experimental.files.list({ path: '/', limit: 10 });
30333
+ * while (result.nextCursor) {
30334
+ * result = await session.experimental.files.list({ path: '/', cursor: result.nextCursor, limit: 10 });
30335
+ * }
30336
+ * ```
30337
+ */
30338
+ list(options?: ToolRouterSessionFilesMountListOptions): Promise<FileListResponse>;
30339
+ private normalizeUploadInput;
30340
+ /**
30341
+ * Uploads a file to the session's file mount.
30342
+ *
30343
+ * Accepts a file path (local or URL), a native File object, or a raw buffer.
30344
+ * The file is stored in the virtual filesystem associated with the tool router session.
30345
+ * URL inputs require a Node.js or Bun runtime so the destination can be DNS-validated;
30346
+ * edge runtimes must fetch the file themselves and pass a File or ArrayBuffer.
30347
+ *
30348
+ * @param input - File path (string), native File, or raw buffer (ArrayBuffer | Uint8Array).
30349
+ * @param options - Optional configuration. When passing a buffer, remotePath is required.
30350
+ * @returns Metadata about the uploaded file.
30351
+ *
30352
+ * @example
30353
+ * ```typescript
30354
+ * // From file path (local or URL)
30355
+ * await session.experimental.files.upload('/path/to/report.pdf');
30356
+ * await session.experimental.files.upload('https://example.com/file.pdf');
30357
+ * ```
30358
+ *
30359
+ * @example
30360
+ * ```typescript
30361
+ * // From native File (e.g. from input[type=file])
30362
+ * await session.experimental.files.upload(fileInput.files[0]);
30363
+ * ```
30364
+ *
30365
+ * @example
30366
+ * ```typescript
30367
+ * // From raw buffer
30368
+ * await session.experimental.files.upload(buffer, { remotePath: 'data.json', mimetype: 'application/json' });
30369
+ * ```
30370
+ */
30371
+ upload(input: string | File | ArrayBuffer | Uint8Array, options?: ToolRouterSessionFilesMountUploadOptions): Promise<RemoteFile>;
30372
+ /**
30373
+ * Downloads a file from the session's file mount to the local filesystem.
30374
+ *
30375
+ * Retrieves a file stored in the session's virtual filesystem (e.g., one produced
30376
+ * by a tool or previously uploaded) and saves it to the specified local path.
30377
+ *
30378
+ * @param filePath - The path of the file on the mount to download, or the local path where the file should be saved (implementation-specific).
30379
+ * @param options - Optional configuration for the download.
30380
+ * @param options.mountId - The ID of the file mount to download from. Defaults to `"files"` when omitted.
30381
+ * @returns The downloaded file data or path (implementation-specific).
30382
+ *
30383
+ * @example
30384
+ * ```typescript
30385
+ * const session = await composio.toolRouter.use('session_123');
30386
+ * const result = await session.experimental.files.download('/output/report.pdf');
30387
+ * ```
30388
+ *
30389
+ * @example
30390
+ * ```typescript
30391
+ * // Download from a custom mount
30392
+ * await session.experimental.files.download('/exports/data.json', {
30393
+ * mountId: 'custom-mount',
30394
+ * });
30395
+ * ```
30396
+ */
30397
+ download(filePath: string, options?: ToolRouterSessionFilesMountDownloadOptions): Promise<RemoteFile>;
30398
+ /**
30399
+ * Deletes a file or directory at the specified path on the session's file mount.
30400
+ *
30401
+ * Removes the file or directory from the virtual filesystem. Use with caution:
30402
+ * deletion is typically irreversible. Ensure the path exists and is intended for removal.
30403
+ *
30404
+ * @param remotePath - The path of the file or directory to delete on the mount.
30405
+ * @param options - Optional configuration for the delete operation.
30406
+ * @param options.mountId - The ID of the file mount to operate on. Defaults to `"files"` when omitted.
30407
+ * @returns Confirmation of deletion (implementation-specific).
30408
+ *
30409
+ * @example
30410
+ * ```typescript
30411
+ * const session = await composio.toolRouter.use('session_123');
30412
+ * await session.experimental.files.delete('/temp/cache.json');
30413
+ * ```
30414
+ *
30415
+ * @example
30416
+ * ```typescript
30417
+ * // Delete from a custom mount
30418
+ * await session.experimental.files.delete('/old-backup', {
30419
+ * mountId: 'custom-mount',
30420
+ * });
30421
+ * ```
30422
+ *
30423
+ * @warning This operation is destructive. Deleted files cannot be recovered.
30424
+ */
30425
+ delete(remotePath: string, options?: ToolRouterSessionFilesMountDeleteOptions): Promise<FileDeleteResponse>;
30426
+ }
30427
+ //#endregion
30428
+ //#region src/types/toolRouter.types.d.ts
30429
+ declare const SessionPreset: {
30430
+ readonly DIRECT_TOOLS: "direct_tools";
30431
+ };
30432
+ type SessionPreset = (typeof SessionPreset)[keyof typeof SessionPreset];
30433
+ declare const MCPServerTypeSchema: z.ZodEnum<["http", "sse"]>;
30434
+ type MCPServerType = z.infer<typeof MCPServerTypeSchema>;
30435
+ /**
30436
+ * Sandbox compute tier for the session sandbox.
30437
+ *
30438
+ * | Tier | vCPU | RAM |
30439
+ * | -------- | ---- | ----- |
30440
+ * | standard | 1 | 1 GB |
30441
+ * | medium | 2 | 2 GB |
30442
+ * | large | 4 | 4 GB |
30443
+ * | xlarge | 8 | 8 GB |
30444
+ *
30445
+ * Defaults to `standard` server-side when omitted.
30446
+ */
30447
+ declare const SandboxSizeSchema: z.ZodEnum<["standard", "medium", "large", "xlarge"]>;
30448
+ type SandboxSize = z.infer<typeof SandboxSizeSchema>;
30449
+ declare const ToolRouterSandboxConfigSchema: z.ZodObject<{
30450
+ enable: z.ZodDefault<z.ZodBoolean>;
30451
+ enableProxyExecution: z.ZodOptional<z.ZodBoolean>;
30452
+ autoOffloadThreshold: z.ZodOptional<z.ZodNumber>;
30453
+ sandboxSize: z.ZodOptional<z.ZodEnum<["standard", "medium", "large", "xlarge"]>>;
30454
+ }, "strip", z.ZodTypeAny, {
30455
+ enable: boolean;
30456
+ enableProxyExecution?: boolean | undefined;
30457
+ autoOffloadThreshold?: number | undefined;
30458
+ sandboxSize?: "standard" | "medium" | "large" | "xlarge" | undefined;
30459
+ }, {
30460
+ enable?: boolean | undefined;
30461
+ enableProxyExecution?: boolean | undefined;
30462
+ autoOffloadThreshold?: number | undefined;
30463
+ sandboxSize?: "standard" | "medium" | "large" | "xlarge" | undefined;
30464
+ }>;
30465
+ type ToolRouterSandboxConfig = z.infer<typeof ToolRouterSandboxConfigSchema>;
30466
+ declare const ToolRouterConfigManageConnectionsSchema: z.ZodObject<{
30467
+ enable: z.ZodOptional<z.ZodDefault<z.ZodBoolean>>;
30468
+ callbackUrl: z.ZodOptional<z.ZodString>;
30469
+ waitForConnections: z.ZodOptional<z.ZodBoolean>;
30470
+ }, "strict", z.ZodTypeAny, {
30471
+ enable?: boolean | undefined;
30472
+ callbackUrl?: string | undefined;
30473
+ waitForConnections?: boolean | undefined;
30474
+ }, {
30475
+ enable?: boolean | undefined;
30476
+ callbackUrl?: string | undefined;
30477
+ waitForConnections?: boolean | undefined;
30478
+ }>;
30479
+ declare const ToolRouterToolkitsParamSchema: z.ZodArray<z.ZodString, "many">;
30480
+ declare const ToolRouterToolkitsDisabledConfigSchema: z.ZodObject<{
30481
+ disable: z.ZodArray<z.ZodString, "many">;
30482
+ }, "strict", z.ZodTypeAny, {
30483
+ disable: string[];
30484
+ }, {
30485
+ disable: string[];
30486
+ }>;
30487
+ declare const ToolRouterToolkitsEnabledConfigSchema: z.ZodObject<{
30488
+ enable: z.ZodArray<z.ZodString, "many">;
30489
+ }, "strict", z.ZodTypeAny, {
30490
+ enable: string[];
30491
+ }, {
30492
+ enable: string[];
30493
+ }>;
30494
+ declare const ToolRouterManageConnectionsConfigSchema: z.ZodObject<{
30495
+ enable: z.ZodDefault<z.ZodOptional<z.ZodBoolean>>;
30496
+ callbackUrl: z.ZodOptional<z.ZodString>;
30497
+ }, "strip", z.ZodTypeAny, {
30498
+ enable: boolean;
30499
+ callbackUrl?: string | undefined;
30500
+ }, {
30501
+ enable?: boolean | undefined;
30502
+ callbackUrl?: string | undefined;
30503
+ }>;
30504
+ declare const ToolRouterTagsParamSchema: z.ZodArray<z.ZodEnum<["readOnlyHint", "destructiveHint", "idempotentHint", "openWorldHint"]>, "many">;
30505
+ declare const ToolRouterTagsEnableDisableSchema: z.ZodObject<{
30506
+ enable: z.ZodOptional<z.ZodArray<z.ZodEnum<["readOnlyHint", "destructiveHint", "idempotentHint", "openWorldHint"]>, "many">>;
30507
+ disable: z.ZodOptional<z.ZodArray<z.ZodEnum<["readOnlyHint", "destructiveHint", "idempotentHint", "openWorldHint"]>, "many">>;
30508
+ }, "strict", z.ZodTypeAny, {
30509
+ disable?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | undefined;
30510
+ enable?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | undefined;
30511
+ }, {
30512
+ disable?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | undefined;
30513
+ enable?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | undefined;
30514
+ }>;
30515
+ declare const ToolRouterConfigTagsSchema: z.ZodUnion<[z.ZodArray<z.ZodEnum<["readOnlyHint", "destructiveHint", "idempotentHint", "openWorldHint"]>, "many">, z.ZodObject<{
30516
+ enable: z.ZodOptional<z.ZodArray<z.ZodEnum<["readOnlyHint", "destructiveHint", "idempotentHint", "openWorldHint"]>, "many">>;
30517
+ disable: z.ZodOptional<z.ZodArray<z.ZodEnum<["readOnlyHint", "destructiveHint", "idempotentHint", "openWorldHint"]>, "many">>;
30518
+ }, "strict", z.ZodTypeAny, {
30519
+ disable?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | undefined;
30520
+ enable?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | undefined;
30521
+ }, {
30522
+ disable?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | undefined;
30523
+ enable?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | undefined;
30524
+ }>]>;
30525
+ type ToolRouterConfigTags = z.infer<typeof ToolRouterConfigTagsSchema>;
30526
+ /**
30527
+ * Tools config - Configure tools per toolkit using toolkit slug as key
30528
+ * @example
30529
+ * ```typescript
30530
+ * {
30531
+ * gmail: {
30532
+ * enable: ['gmail_search', 'gmail_send']
30533
+ * },
30534
+ * slack: {
30535
+ * disable: ['slack_delete_message']
30536
+ * }
30537
+ * }
30538
+ * ```
30539
+ *
30540
+ * @example
30541
+ * ```typescript
30542
+ * {
30543
+ * gmail: ['gmail_search', 'gmail_send'],
30544
+ * slack: { tags: ['readOnlyHint'] }
30545
+ * }
30546
+ * ```
30547
+ */
30548
+ declare const ToolRouterToolsParamSchema: z.ZodArray<z.ZodString, "many">;
30549
+ type ToolRouterToolsParam = z.infer<typeof ToolRouterToolsParamSchema>;
30550
+ declare const ToolRouterConfigToolsSchema: z.ZodEffects<z.ZodUnion<[z.ZodArray<z.ZodString, "many">, z.ZodObject<{
30551
+ enable: z.ZodArray<z.ZodString, "many">;
30552
+ }, "strict", z.ZodTypeAny, {
30553
+ enable: string[];
30554
+ }, {
30555
+ enable: string[];
30556
+ }>, z.ZodObject<{
30557
+ disable: z.ZodArray<z.ZodString, "many">;
30558
+ }, "strict", z.ZodTypeAny, {
30559
+ disable: string[];
30560
+ }, {
30561
+ disable: string[];
30562
+ }>, z.ZodObject<{
30563
+ tags: z.ZodUnion<[z.ZodArray<z.ZodEnum<["readOnlyHint", "destructiveHint", "idempotentHint", "openWorldHint"]>, "many">, z.ZodObject<{
30564
+ enable: z.ZodOptional<z.ZodArray<z.ZodEnum<["readOnlyHint", "destructiveHint", "idempotentHint", "openWorldHint"]>, "many">>;
30565
+ disable: z.ZodOptional<z.ZodArray<z.ZodEnum<["readOnlyHint", "destructiveHint", "idempotentHint", "openWorldHint"]>, "many">>;
30566
+ }, "strict", z.ZodTypeAny, {
30567
+ disable?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | undefined;
30568
+ enable?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | undefined;
30569
+ }, {
30570
+ disable?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | undefined;
30571
+ enable?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | undefined;
30572
+ }>]>;
30573
+ }, "strict", z.ZodTypeAny, {
30574
+ tags: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | {
30575
+ disable?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | undefined;
30576
+ enable?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | undefined;
30577
+ };
30578
+ }, {
30579
+ tags: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | {
30580
+ disable?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | undefined;
30581
+ enable?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | undefined;
30582
+ };
30583
+ }>]>, string[] | {
30584
+ enable: string[];
30585
+ } | {
30586
+ disable: string[];
30587
+ } | {
30588
+ tags: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | {
30589
+ disable?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | undefined;
30590
+ enable?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | undefined;
30591
+ };
30592
+ }, string[] | {
30593
+ enable: string[];
30594
+ } | {
30595
+ disable: string[];
30596
+ } | {
30597
+ tags: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | {
30598
+ disable?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | undefined;
30599
+ enable?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | undefined;
30600
+ };
30601
+ }>;
30602
+ type ToolRouterConfigTools = z.infer<typeof ToolRouterConfigToolsSchema>;
30603
+ declare const ToolRouterCreateSessionConfigSchema: z.ZodEffects<z.ZodEffects<z.ZodObject<{
30604
+ sessionPreset: z.ZodOptional<z.ZodOptional<z.ZodLiteral<"direct_tools">>>;
30605
+ mcp: z.ZodOptional<z.ZodOptional<z.ZodBoolean>>;
30606
+ tools: z.ZodOptional<z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnion<[z.ZodArray<z.ZodString, "many">, z.ZodEffects<z.ZodUnion<[z.ZodArray<z.ZodString, "many">, z.ZodObject<{
30607
+ enable: z.ZodArray<z.ZodString, "many">;
30608
+ }, "strict", z.ZodTypeAny, {
30609
+ enable: string[];
30610
+ }, {
30611
+ enable: string[];
30612
+ }>, z.ZodObject<{
30613
+ disable: z.ZodArray<z.ZodString, "many">;
30614
+ }, "strict", z.ZodTypeAny, {
30615
+ disable: string[];
30616
+ }, {
30617
+ disable: string[];
30618
+ }>, z.ZodObject<{
30619
+ tags: z.ZodUnion<[z.ZodArray<z.ZodEnum<["readOnlyHint", "destructiveHint", "idempotentHint", "openWorldHint"]>, "many">, z.ZodObject<{
30620
+ enable: z.ZodOptional<z.ZodArray<z.ZodEnum<["readOnlyHint", "destructiveHint", "idempotentHint", "openWorldHint"]>, "many">>;
30621
+ disable: z.ZodOptional<z.ZodArray<z.ZodEnum<["readOnlyHint", "destructiveHint", "idempotentHint", "openWorldHint"]>, "many">>;
30622
+ }, "strict", z.ZodTypeAny, {
30623
+ disable?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | undefined;
30624
+ enable?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | undefined;
30625
+ }, {
30626
+ disable?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | undefined;
30627
+ enable?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | undefined;
30628
+ }>]>;
30629
+ }, "strict", z.ZodTypeAny, {
30630
+ tags: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | {
30631
+ disable?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | undefined;
30632
+ enable?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | undefined;
30633
+ };
30634
+ }, {
30635
+ tags: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | {
30636
+ disable?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | undefined;
30637
+ enable?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | undefined;
30638
+ };
30639
+ }>]>, string[] | {
30640
+ enable: string[];
30641
+ } | {
30642
+ disable: string[];
30643
+ } | {
30644
+ tags: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | {
30645
+ disable?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | undefined;
30646
+ enable?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | undefined;
30647
+ };
30648
+ }, string[] | {
30649
+ enable: string[];
30650
+ } | {
30651
+ disable: string[];
30652
+ } | {
30653
+ tags: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | {
30654
+ disable?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | undefined;
30655
+ enable?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | undefined;
30656
+ };
30657
+ }>]>>>>;
30658
+ tags: z.ZodOptional<z.ZodOptional<z.ZodUnion<[z.ZodArray<z.ZodEnum<["readOnlyHint", "destructiveHint", "idempotentHint", "openWorldHint"]>, "many">, z.ZodObject<{
30659
+ enable: z.ZodOptional<z.ZodArray<z.ZodEnum<["readOnlyHint", "destructiveHint", "idempotentHint", "openWorldHint"]>, "many">>;
30660
+ disable: z.ZodOptional<z.ZodArray<z.ZodEnum<["readOnlyHint", "destructiveHint", "idempotentHint", "openWorldHint"]>, "many">>;
30661
+ }, "strict", z.ZodTypeAny, {
30662
+ disable?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | undefined;
30663
+ enable?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | undefined;
30664
+ }, {
30665
+ disable?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | undefined;
30666
+ enable?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | undefined;
30667
+ }>]>>>;
30668
+ toolkits: z.ZodOptional<z.ZodOptional<z.ZodUnion<[z.ZodArray<z.ZodString, "many">, z.ZodObject<{
30669
+ disable: z.ZodArray<z.ZodString, "many">;
30670
+ }, "strict", z.ZodTypeAny, {
30671
+ disable: string[];
30672
+ }, {
30673
+ disable: string[];
30674
+ }>, z.ZodObject<{
30675
+ enable: z.ZodArray<z.ZodString, "many">;
30676
+ }, "strict", z.ZodTypeAny, {
30677
+ enable: string[];
30678
+ }, {
30679
+ enable: string[];
30680
+ }>]>>>;
30681
+ authConfigs: z.ZodOptional<z.ZodDefault<z.ZodRecord<z.ZodString, z.ZodString>>>;
30682
+ connectedAccounts: z.ZodOptional<z.ZodDefault<z.ZodRecord<z.ZodString, z.ZodUnion<[z.ZodString, z.ZodArray<z.ZodString, "many">]>>>>;
30683
+ manageConnections: z.ZodOptional<z.ZodDefault<z.ZodOptional<z.ZodUnion<[z.ZodBoolean, z.ZodObject<{
30684
+ enable: z.ZodOptional<z.ZodDefault<z.ZodBoolean>>;
30685
+ callbackUrl: z.ZodOptional<z.ZodString>;
30686
+ waitForConnections: z.ZodOptional<z.ZodBoolean>;
30687
+ }, "strict", z.ZodTypeAny, {
30688
+ enable?: boolean | undefined;
30689
+ callbackUrl?: string | undefined;
30690
+ waitForConnections?: boolean | undefined;
30691
+ }, {
30692
+ enable?: boolean | undefined;
30693
+ callbackUrl?: string | undefined;
30694
+ waitForConnections?: boolean | undefined;
30695
+ }>]>>>>;
30696
+ sandbox: z.ZodOptional<z.ZodOptional<z.ZodObject<{
30697
+ enable: z.ZodDefault<z.ZodBoolean>;
30698
+ enableProxyExecution: z.ZodOptional<z.ZodBoolean>;
30699
+ autoOffloadThreshold: z.ZodOptional<z.ZodNumber>;
30700
+ sandboxSize: z.ZodOptional<z.ZodEnum<["standard", "medium", "large", "xlarge"]>>;
30701
+ }, "strip", z.ZodTypeAny, {
30702
+ enable: boolean;
30703
+ enableProxyExecution?: boolean | undefined;
30704
+ autoOffloadThreshold?: number | undefined;
30705
+ sandboxSize?: "standard" | "medium" | "large" | "xlarge" | undefined;
30706
+ }, {
30707
+ enable?: boolean | undefined;
30708
+ enableProxyExecution?: boolean | undefined;
30709
+ autoOffloadThreshold?: number | undefined;
30710
+ sandboxSize?: "standard" | "medium" | "large" | "xlarge" | undefined;
30711
+ }>>>;
30712
+ workbench: z.ZodOptional<z.ZodOptional<z.ZodObject<{
30713
+ enable: z.ZodDefault<z.ZodBoolean>;
30714
+ enableProxyExecution: z.ZodOptional<z.ZodBoolean>;
30715
+ autoOffloadThreshold: z.ZodOptional<z.ZodNumber>;
30716
+ sandboxSize: z.ZodOptional<z.ZodEnum<["standard", "medium", "large", "xlarge"]>>;
30717
+ }, "strip", z.ZodTypeAny, {
30718
+ enable: boolean;
30719
+ enableProxyExecution?: boolean | undefined;
30720
+ autoOffloadThreshold?: number | undefined;
30721
+ sandboxSize?: "standard" | "medium" | "large" | "xlarge" | undefined;
30722
+ }, {
30723
+ enable?: boolean | undefined;
30724
+ enableProxyExecution?: boolean | undefined;
30725
+ autoOffloadThreshold?: number | undefined;
30726
+ sandboxSize?: "standard" | "medium" | "large" | "xlarge" | undefined;
30727
+ }>>>;
30728
+ multiAccount: z.ZodOptional<z.ZodOptional<z.ZodObject<{
30729
+ enable: z.ZodDefault<z.ZodBoolean>;
30730
+ maxAccountsPerToolkit: z.ZodOptional<z.ZodNumber>;
30731
+ requireExplicitSelection: z.ZodOptional<z.ZodBoolean>;
30732
+ }, "strip", z.ZodTypeAny, {
30733
+ enable: boolean;
30734
+ maxAccountsPerToolkit?: number | undefined;
30735
+ requireExplicitSelection?: boolean | undefined;
30736
+ }, {
30737
+ enable?: boolean | undefined;
30738
+ maxAccountsPerToolkit?: number | undefined;
30739
+ requireExplicitSelection?: boolean | undefined;
30740
+ }>>>;
30741
+ preload: z.ZodOptional<z.ZodOptional<z.ZodObject<{
30742
+ tools: z.ZodOptional<z.ZodUnion<[z.ZodArray<z.ZodString, "many">, z.ZodLiteral<"all">]>>;
30743
+ }, "strict", z.ZodTypeAny, {
30744
+ tools?: string[] | "all" | undefined;
30745
+ }, {
30746
+ tools?: string[] | "all" | undefined;
30747
+ }>>>;
30748
+ experimental: z.ZodOptional<z.ZodOptional<z.ZodObject<{
30749
+ assistivePrompt: z.ZodOptional<z.ZodObject<{
30750
+ userTimezone: z.ZodOptional<z.ZodString>;
30751
+ }, "strip", z.ZodTypeAny, {
30752
+ userTimezone?: string | undefined;
30753
+ }, {
30754
+ userTimezone?: string | undefined;
30755
+ }>>;
30756
+ customTools: z.ZodOptional<z.ZodArray<z.ZodType<CustomTool, z.ZodTypeDef, CustomTool>, "many">>;
30757
+ customToolkits: z.ZodOptional<z.ZodArray<z.ZodType<CustomToolkit, z.ZodTypeDef, CustomToolkit>, "many">>;
30758
+ }, "strip", z.ZodTypeAny, {
30759
+ assistivePrompt?: {
30760
+ userTimezone?: string | undefined;
30761
+ } | undefined;
30762
+ customTools?: CustomTool[] | undefined;
30763
+ customToolkits?: CustomToolkit[] | undefined;
30764
+ }, {
30765
+ assistivePrompt?: {
30766
+ userTimezone?: string | undefined;
30767
+ } | undefined;
30768
+ customTools?: CustomTool[] | undefined;
30769
+ customToolkits?: CustomToolkit[] | undefined;
30770
+ }>>>;
30771
+ }, "strip", z.ZodTypeAny, {
30772
+ tags?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | {
30773
+ disable?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | undefined;
30774
+ enable?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | undefined;
30775
+ } | undefined;
30776
+ tools?: Record<string, string[] | {
30777
+ enable: string[];
30778
+ } | {
30779
+ disable: string[];
30780
+ } | {
30781
+ tags: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | {
30782
+ disable?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | undefined;
30783
+ enable?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | undefined;
30784
+ };
30785
+ }> | undefined;
30786
+ toolkits?: string[] | {
30787
+ disable: string[];
30788
+ } | {
30789
+ enable: string[];
30790
+ } | undefined;
30791
+ authConfigs?: Record<string, string> | undefined;
30792
+ sessionPreset?: "direct_tools" | undefined;
30793
+ mcp?: boolean | undefined;
30794
+ connectedAccounts?: Record<string, string | string[]> | undefined;
30795
+ manageConnections?: boolean | {
30796
+ enable?: boolean | undefined;
30797
+ callbackUrl?: string | undefined;
30798
+ waitForConnections?: boolean | undefined;
30799
+ } | undefined;
30800
+ sandbox?: {
30801
+ enable: boolean;
30802
+ enableProxyExecution?: boolean | undefined;
30803
+ autoOffloadThreshold?: number | undefined;
30804
+ sandboxSize?: "standard" | "medium" | "large" | "xlarge" | undefined;
30805
+ } | undefined;
30806
+ workbench?: {
30807
+ enable: boolean;
30808
+ enableProxyExecution?: boolean | undefined;
30809
+ autoOffloadThreshold?: number | undefined;
30810
+ sandboxSize?: "standard" | "medium" | "large" | "xlarge" | undefined;
30811
+ } | undefined;
30812
+ multiAccount?: {
30813
+ enable: boolean;
30814
+ maxAccountsPerToolkit?: number | undefined;
30815
+ requireExplicitSelection?: boolean | undefined;
30816
+ } | undefined;
30817
+ preload?: {
30818
+ tools?: string[] | "all" | undefined;
30819
+ } | undefined;
30820
+ experimental?: {
30821
+ assistivePrompt?: {
30822
+ userTimezone?: string | undefined;
30823
+ } | undefined;
30824
+ customTools?: CustomTool[] | undefined;
30825
+ customToolkits?: CustomToolkit[] | undefined;
30826
+ } | undefined;
30827
+ }, {
30828
+ tags?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | {
30829
+ disable?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | undefined;
30830
+ enable?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | undefined;
30831
+ } | undefined;
30832
+ tools?: Record<string, string[] | {
30833
+ enable: string[];
30834
+ } | {
30835
+ disable: string[];
30836
+ } | {
30837
+ tags: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | {
30838
+ disable?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | undefined;
30839
+ enable?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | undefined;
30840
+ };
30841
+ }> | undefined;
30842
+ toolkits?: string[] | {
30843
+ disable: string[];
30844
+ } | {
30845
+ enable: string[];
30846
+ } | undefined;
30847
+ authConfigs?: Record<string, string> | undefined;
30848
+ sessionPreset?: "direct_tools" | undefined;
30849
+ mcp?: boolean | undefined;
30850
+ connectedAccounts?: Record<string, string | string[]> | undefined;
30851
+ manageConnections?: boolean | {
30852
+ enable?: boolean | undefined;
30853
+ callbackUrl?: string | undefined;
30854
+ waitForConnections?: boolean | undefined;
30855
+ } | undefined;
30856
+ sandbox?: {
30857
+ enable?: boolean | undefined;
30858
+ enableProxyExecution?: boolean | undefined;
30859
+ autoOffloadThreshold?: number | undefined;
30860
+ sandboxSize?: "standard" | "medium" | "large" | "xlarge" | undefined;
30861
+ } | undefined;
30862
+ workbench?: {
30863
+ enable?: boolean | undefined;
30864
+ enableProxyExecution?: boolean | undefined;
30865
+ autoOffloadThreshold?: number | undefined;
30866
+ sandboxSize?: "standard" | "medium" | "large" | "xlarge" | undefined;
30867
+ } | undefined;
30868
+ multiAccount?: {
30869
+ enable?: boolean | undefined;
30870
+ maxAccountsPerToolkit?: number | undefined;
30871
+ requireExplicitSelection?: boolean | undefined;
30872
+ } | undefined;
30873
+ preload?: {
30874
+ tools?: string[] | "all" | undefined;
30875
+ } | undefined;
30876
+ experimental?: {
30877
+ assistivePrompt?: {
30878
+ userTimezone?: string | undefined;
30879
+ } | undefined;
30880
+ customTools?: CustomTool[] | undefined;
30881
+ customToolkits?: CustomToolkit[] | undefined;
30882
+ } | undefined;
30883
+ }>, {
30884
+ tags?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | {
30885
+ disable?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | undefined;
30886
+ enable?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | undefined;
30887
+ } | undefined;
30888
+ tools?: Record<string, string[] | {
30889
+ enable: string[];
30890
+ } | {
30891
+ disable: string[];
30892
+ } | {
30893
+ tags: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | {
30894
+ disable?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | undefined;
30895
+ enable?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | undefined;
30896
+ };
30897
+ }> | undefined;
30898
+ toolkits?: string[] | {
30899
+ disable: string[];
30900
+ } | {
30901
+ enable: string[];
30902
+ } | undefined;
30903
+ authConfigs?: Record<string, string> | undefined;
30904
+ sessionPreset?: "direct_tools" | undefined;
30905
+ mcp?: boolean | undefined;
30906
+ connectedAccounts?: Record<string, string | string[]> | undefined;
30907
+ manageConnections?: boolean | {
30908
+ enable?: boolean | undefined;
30909
+ callbackUrl?: string | undefined;
30910
+ waitForConnections?: boolean | undefined;
30911
+ } | undefined;
30912
+ sandbox?: {
30913
+ enable: boolean;
30914
+ enableProxyExecution?: boolean | undefined;
30915
+ autoOffloadThreshold?: number | undefined;
30916
+ sandboxSize?: "standard" | "medium" | "large" | "xlarge" | undefined;
30917
+ } | undefined;
30918
+ workbench?: {
30919
+ enable: boolean;
30920
+ enableProxyExecution?: boolean | undefined;
30921
+ autoOffloadThreshold?: number | undefined;
30922
+ sandboxSize?: "standard" | "medium" | "large" | "xlarge" | undefined;
30923
+ } | undefined;
30924
+ multiAccount?: {
30925
+ enable: boolean;
30926
+ maxAccountsPerToolkit?: number | undefined;
30927
+ requireExplicitSelection?: boolean | undefined;
30928
+ } | undefined;
30929
+ preload?: {
30930
+ tools?: string[] | "all" | undefined;
30931
+ } | undefined;
30932
+ experimental?: {
30933
+ assistivePrompt?: {
30934
+ userTimezone?: string | undefined;
30935
+ } | undefined;
30936
+ customTools?: CustomTool[] | undefined;
30937
+ customToolkits?: CustomToolkit[] | undefined;
30938
+ } | undefined;
30939
+ }, {
30940
+ tags?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | {
30941
+ disable?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | undefined;
30942
+ enable?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | undefined;
30943
+ } | undefined;
30944
+ tools?: Record<string, string[] | {
30945
+ enable: string[];
30946
+ } | {
30947
+ disable: string[];
30948
+ } | {
30949
+ tags: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | {
30950
+ disable?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | undefined;
30951
+ enable?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | undefined;
30952
+ };
30953
+ }> | undefined;
30954
+ toolkits?: string[] | {
30955
+ disable: string[];
30956
+ } | {
30957
+ enable: string[];
30958
+ } | undefined;
30959
+ authConfigs?: Record<string, string> | undefined;
30960
+ sessionPreset?: "direct_tools" | undefined;
30961
+ mcp?: boolean | undefined;
30962
+ connectedAccounts?: Record<string, string | string[]> | undefined;
30963
+ manageConnections?: boolean | {
30964
+ enable?: boolean | undefined;
30965
+ callbackUrl?: string | undefined;
30966
+ waitForConnections?: boolean | undefined;
30967
+ } | undefined;
30968
+ sandbox?: {
30969
+ enable?: boolean | undefined;
30970
+ enableProxyExecution?: boolean | undefined;
30971
+ autoOffloadThreshold?: number | undefined;
30972
+ sandboxSize?: "standard" | "medium" | "large" | "xlarge" | undefined;
30973
+ } | undefined;
30974
+ workbench?: {
30975
+ enable?: boolean | undefined;
30976
+ enableProxyExecution?: boolean | undefined;
30977
+ autoOffloadThreshold?: number | undefined;
30978
+ sandboxSize?: "standard" | "medium" | "large" | "xlarge" | undefined;
30979
+ } | undefined;
30980
+ multiAccount?: {
30981
+ enable?: boolean | undefined;
30982
+ maxAccountsPerToolkit?: number | undefined;
30983
+ requireExplicitSelection?: boolean | undefined;
30984
+ } | undefined;
30985
+ preload?: {
30986
+ tools?: string[] | "all" | undefined;
30987
+ } | undefined;
30988
+ experimental?: {
30989
+ assistivePrompt?: {
30990
+ userTimezone?: string | undefined;
30991
+ } | undefined;
30992
+ customTools?: CustomTool[] | undefined;
30993
+ customToolkits?: CustomToolkit[] | undefined;
30994
+ } | undefined;
30995
+ }>, {
30996
+ tags?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | {
30997
+ disable?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | undefined;
30998
+ enable?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | undefined;
30999
+ } | undefined;
31000
+ tools?: Record<string, string[] | {
31001
+ enable: string[];
31002
+ } | {
31003
+ disable: string[];
31004
+ } | {
31005
+ tags: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | {
31006
+ disable?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | undefined;
31007
+ enable?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | undefined;
31008
+ };
31009
+ }> | undefined;
31010
+ toolkits?: string[] | {
31011
+ disable: string[];
31012
+ } | {
31013
+ enable: string[];
31014
+ } | undefined;
31015
+ authConfigs?: Record<string, string> | undefined;
31016
+ sessionPreset?: "direct_tools" | undefined;
31017
+ mcp?: boolean | undefined;
31018
+ connectedAccounts?: Record<string, string | string[]> | undefined;
31019
+ manageConnections?: boolean | {
31020
+ enable?: boolean | undefined;
31021
+ callbackUrl?: string | undefined;
31022
+ waitForConnections?: boolean | undefined;
31023
+ } | undefined;
31024
+ sandbox?: {
31025
+ enable: boolean;
31026
+ enableProxyExecution?: boolean | undefined;
31027
+ autoOffloadThreshold?: number | undefined;
31028
+ sandboxSize?: "standard" | "medium" | "large" | "xlarge" | undefined;
31029
+ } | undefined;
31030
+ workbench?: {
31031
+ enable: boolean;
31032
+ enableProxyExecution?: boolean | undefined;
31033
+ autoOffloadThreshold?: number | undefined;
31034
+ sandboxSize?: "standard" | "medium" | "large" | "xlarge" | undefined;
31035
+ } | undefined;
31036
+ multiAccount?: {
31037
+ enable: boolean;
31038
+ maxAccountsPerToolkit?: number | undefined;
31039
+ requireExplicitSelection?: boolean | undefined;
31040
+ } | undefined;
31041
+ preload?: {
31042
+ tools?: string[] | "all" | undefined;
31043
+ } | undefined;
31044
+ experimental?: {
31045
+ assistivePrompt?: {
31046
+ userTimezone?: string | undefined;
31047
+ } | undefined;
31048
+ customTools?: CustomTool[] | undefined;
31049
+ customToolkits?: CustomToolkit[] | undefined;
31050
+ } | undefined;
31051
+ }, unknown>;
31052
+ /**
31053
+ * The config for the tool router session.
31054
+ *
31055
+ * @param {SessionPreset} [sessionPreset] - Shortcut that exposes every tool allowed by the session filters directly in session.tools() and the MCP tool list. Disables search, multi-execute, manage-connections, and sandbox by default; explicit overrides for supported fields still win. Without this preset, ToolRouter uses the default configuration with meta tools enabled.
31056
+ * @param {ToolRouterToolkitsParamSchema | ToolRouterToolkitsDisabledConfigSchema | ToolRouterToolkitsEnabledConfigSchema} toolkits - The toolkits to use in the tool router session
31057
+ * @param {Record<string, ToolRouterToolsParam | ToolRouterConfigTools>} tools - The tools to configure per toolkit (key is toolkit slug)
31058
+ * @param {Array<'readOnlyHint' | 'destructiveHint' | 'idempotentHint' | 'openWorldHint'>} tags - Global tags to filter tools by behavior
31059
+ * @param {Record<string, string>} authConfigs - The auth configs to use in the tool router session
31060
+ * @param {Record<string, string | string[]>} connectedAccounts - The connected accounts to use in the tool router session. A single string is coerced to a single-element array before being sent to the backend.
31061
+ * @param {ToolRouterConfigManageConnectionsSchema | boolean} manageConnections - The config for the manage connections in the tool router session. Defaults to true, if set to false, you need to manage connections manually. If set to an object, you can configure the manage connections settings.
31062
+ * @param {boolean} [manageConnections.enable] - Whether to use tools to manage connections in the tool router session @default true
31063
+ * @param {string} [manageConnections.callbackUrl] - The callback url to use in the tool router session
31064
+ * @param {object} sandbox - Sandbox configuration for code execution. Preferred over workbench.
31065
+ * @param {boolean} [sandbox.enable] - Whether to enable the sandbox entirely. Defaults to true. When false, no code execution tools are available.
31066
+ * @param {boolean} [sandbox.enableProxyExecution] - Whether to enable proxy execution
31067
+ * @param {number} [sandbox.autoOffloadThreshold] - Auto offload threshold in characters for moving execution to the sandbox
31068
+ * @param {SandboxSize} [sandbox.sandboxSize] - Sandbox compute tier: 'standard' (1 vCPU/1 GB, default), 'medium' (2 vCPU/2 GB), 'large' (4 vCPU/4 GB), or 'xlarge' (8 vCPU/8 GB)
31069
+ * @param {object} workbench - Deprecated alias for sandbox. Accepted for backwards compatibility.
31070
+ * @param {object} [multiAccount] - Multi-account configuration for this session
31071
+ * @param {boolean} [multiAccount.enable] - When true, enables multi-account mode. Falls back to org/project-level config when not set.
31072
+ * @param {number} [multiAccount.maxAccountsPerToolkit] - Max connected accounts per toolkit (2-10, default 5)
31073
+ * @param {boolean} [multiAccount.requireExplicitSelection] - When true, require explicit account selection when multiple accounts are connected
31074
+ * @param {object} [preload] - Tools to preload into session.tools() and the MCP tool list
31075
+ * @param {string[] | 'all'} [preload.tools] - Tool slugs to preload, or "all" to preload every app tool allowed by the session filters. "all" requires a positive filter such as toolkits, tools, or tags; the backend validates and caps the final tool set.
31076
+ */
31077
+ type ToolRouterCreateSessionConfig = z.infer<typeof ToolRouterCreateSessionConfigSchema>;
31078
+ declare const ToolkitConnectionStateSchema: z.ZodObject<{
31079
+ slug: z.ZodString;
31080
+ name: z.ZodString;
31081
+ logo: z.ZodOptional<z.ZodString>;
31082
+ isNoAuth: z.ZodDefault<z.ZodBoolean>;
31083
+ connection: z.ZodOptional<z.ZodObject<{
31084
+ isActive: z.ZodBoolean;
31085
+ authConfig: z.ZodOptional<z.ZodNullable<z.ZodObject<{
31086
+ id: z.ZodString;
31087
+ mode: z.ZodString;
31088
+ isComposioManaged: z.ZodBoolean;
31089
+ }, "strip", z.ZodTypeAny, {
31090
+ id: string;
31091
+ mode: string;
31092
+ isComposioManaged: boolean;
31093
+ }, {
31094
+ id: string;
31095
+ mode: string;
31096
+ isComposioManaged: boolean;
31097
+ }>>>;
31098
+ connectedAccount: z.ZodOptional<z.ZodObject<{
31099
+ id: z.ZodString;
31100
+ status: z.ZodString;
31101
+ }, "strip", z.ZodTypeAny, {
31102
+ status: string;
31103
+ id: string;
31104
+ }, {
31105
+ status: string;
31106
+ id: string;
31107
+ }>>;
31108
+ }, "strip", z.ZodTypeAny, {
31109
+ isActive: boolean;
31110
+ authConfig?: {
31111
+ id: string;
31112
+ mode: string;
31113
+ isComposioManaged: boolean;
31114
+ } | null | undefined;
31115
+ connectedAccount?: {
31116
+ status: string;
31117
+ id: string;
31118
+ } | undefined;
31119
+ }, {
31120
+ isActive: boolean;
31121
+ authConfig?: {
31122
+ id: string;
31123
+ mode: string;
31124
+ isComposioManaged: boolean;
31125
+ } | null | undefined;
31126
+ connectedAccount?: {
31127
+ status: string;
31128
+ id: string;
31129
+ } | undefined;
31130
+ }>>;
31131
+ }, "strip", z.ZodTypeAny, {
31132
+ slug: string;
31133
+ name: string;
31134
+ isNoAuth: boolean;
31135
+ logo?: string | undefined;
31136
+ connection?: {
31137
+ isActive: boolean;
31138
+ authConfig?: {
31139
+ id: string;
31140
+ mode: string;
31141
+ isComposioManaged: boolean;
31142
+ } | null | undefined;
31143
+ connectedAccount?: {
31144
+ status: string;
31145
+ id: string;
31146
+ } | undefined;
31147
+ } | undefined;
31148
+ }, {
31149
+ slug: string;
31150
+ name: string;
31151
+ logo?: string | undefined;
31152
+ isNoAuth?: boolean | undefined;
31153
+ connection?: {
31154
+ isActive: boolean;
31155
+ authConfig?: {
31156
+ id: string;
31157
+ mode: string;
31158
+ isComposioManaged: boolean;
31159
+ } | null | undefined;
31160
+ connectedAccount?: {
31161
+ status: string;
31162
+ id: string;
31163
+ } | undefined;
31164
+ } | undefined;
31165
+ }>;
31166
+ declare const ToolkitConnectionsDetailsSchema: z.ZodObject<{
31167
+ items: z.ZodArray<z.ZodObject<{
31168
+ slug: z.ZodString;
31169
+ name: z.ZodString;
31170
+ logo: z.ZodOptional<z.ZodString>;
31171
+ isNoAuth: z.ZodDefault<z.ZodBoolean>;
31172
+ connection: z.ZodOptional<z.ZodObject<{
31173
+ isActive: z.ZodBoolean;
31174
+ authConfig: z.ZodOptional<z.ZodNullable<z.ZodObject<{
31175
+ id: z.ZodString;
31176
+ mode: z.ZodString;
31177
+ isComposioManaged: z.ZodBoolean;
31178
+ }, "strip", z.ZodTypeAny, {
31179
+ id: string;
31180
+ mode: string;
31181
+ isComposioManaged: boolean;
31182
+ }, {
31183
+ id: string;
31184
+ mode: string;
31185
+ isComposioManaged: boolean;
31186
+ }>>>;
31187
+ connectedAccount: z.ZodOptional<z.ZodObject<{
31188
+ id: z.ZodString;
31189
+ status: z.ZodString;
31190
+ }, "strip", z.ZodTypeAny, {
31191
+ status: string;
31192
+ id: string;
31193
+ }, {
31194
+ status: string;
31195
+ id: string;
31196
+ }>>;
31197
+ }, "strip", z.ZodTypeAny, {
31198
+ isActive: boolean;
31199
+ authConfig?: {
31200
+ id: string;
31201
+ mode: string;
31202
+ isComposioManaged: boolean;
31203
+ } | null | undefined;
31204
+ connectedAccount?: {
31205
+ status: string;
31206
+ id: string;
31207
+ } | undefined;
31208
+ }, {
31209
+ isActive: boolean;
31210
+ authConfig?: {
31211
+ id: string;
31212
+ mode: string;
31213
+ isComposioManaged: boolean;
31214
+ } | null | undefined;
31215
+ connectedAccount?: {
31216
+ status: string;
31217
+ id: string;
31218
+ } | undefined;
31219
+ }>>;
31220
+ }, "strip", z.ZodTypeAny, {
31221
+ slug: string;
31222
+ name: string;
31223
+ isNoAuth: boolean;
31224
+ logo?: string | undefined;
31225
+ connection?: {
31226
+ isActive: boolean;
31227
+ authConfig?: {
31228
+ id: string;
31229
+ mode: string;
31230
+ isComposioManaged: boolean;
31231
+ } | null | undefined;
31232
+ connectedAccount?: {
31233
+ status: string;
31234
+ id: string;
31235
+ } | undefined;
31236
+ } | undefined;
31237
+ }, {
31238
+ slug: string;
31239
+ name: string;
31240
+ logo?: string | undefined;
31241
+ isNoAuth?: boolean | undefined;
31242
+ connection?: {
31243
+ isActive: boolean;
31244
+ authConfig?: {
31245
+ id: string;
31246
+ mode: string;
31247
+ isComposioManaged: boolean;
31248
+ } | null | undefined;
31249
+ connectedAccount?: {
31250
+ status: string;
31251
+ id: string;
31252
+ } | undefined;
31253
+ } | undefined;
31254
+ }>, "many">;
31255
+ cursor: z.ZodOptional<z.ZodString>;
31256
+ totalPages: z.ZodNumber;
31257
+ }, "strip", z.ZodTypeAny, {
31258
+ items: {
31259
+ slug: string;
31260
+ name: string;
31261
+ isNoAuth: boolean;
31262
+ logo?: string | undefined;
31263
+ connection?: {
31264
+ isActive: boolean;
31265
+ authConfig?: {
31266
+ id: string;
31267
+ mode: string;
31268
+ isComposioManaged: boolean;
31269
+ } | null | undefined;
31270
+ connectedAccount?: {
31271
+ status: string;
31272
+ id: string;
31273
+ } | undefined;
31274
+ } | undefined;
31275
+ }[];
31276
+ totalPages: number;
31277
+ cursor?: string | undefined;
31278
+ }, {
31279
+ items: {
31280
+ slug: string;
31281
+ name: string;
31282
+ logo?: string | undefined;
31283
+ isNoAuth?: boolean | undefined;
31284
+ connection?: {
31285
+ isActive: boolean;
31286
+ authConfig?: {
31287
+ id: string;
31288
+ mode: string;
31289
+ isComposioManaged: boolean;
31290
+ } | null | undefined;
31291
+ connectedAccount?: {
31292
+ status: string;
31293
+ id: string;
31294
+ } | undefined;
31295
+ } | undefined;
31296
+ }[];
31297
+ totalPages: number;
31298
+ cursor?: string | undefined;
31299
+ }>;
31300
+ type ToolkitConnectionsDetails = z.infer<typeof ToolkitConnectionsDetailsSchema>;
31301
+ type ToolkitConnectionState = z.infer<typeof ToolkitConnectionStateSchema>;
31302
+ declare const ToolRouterMCPServerConfigSchema: z.ZodObject<{
31303
+ type: z.ZodEnum<["http", "sse"]>;
31304
+ url: z.ZodString;
31305
+ headers: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
31306
+ }, "strip", z.ZodTypeAny, {
31307
+ type: "http" | "sse";
31308
+ url: string;
31309
+ headers?: Record<string, string> | undefined;
31310
+ }, {
31311
+ type: "http" | "sse";
31312
+ url: string;
31313
+ headers?: Record<string, string> | undefined;
31314
+ }>;
31315
+ type ToolRouterMCPServerConfig = z.infer<typeof ToolRouterMCPServerConfigSchema>;
31316
+ type ToolRouterToolsFn<TToolCollection, TTool, TProvider extends BaseComposioProvider<TToolCollection, TTool, unknown>> = (modifiers?: SessionMetaToolOptions) => Promise<ReturnType<TProvider['wrapTools']>>;
31317
+ type ToolRouterAuthorizeFn = (toolkit: string, options?: {
31318
+ callbackUrl?: string;
31319
+ alias?: string;
31320
+ }) => Promise<ConnectionRequest>;
31321
+ declare const ToolRouterToolkitsOptionsSchema: z.ZodObject<{
31322
+ toolkits: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
31323
+ cursor: z.ZodOptional<z.ZodString>;
31324
+ limit: z.ZodOptional<z.ZodNumber>;
31325
+ isConnected: z.ZodOptional<z.ZodBoolean>;
31326
+ search: z.ZodOptional<z.ZodString>;
31327
+ }, "strip", z.ZodTypeAny, {
31328
+ toolkits?: string[] | undefined;
31329
+ limit?: number | undefined;
31330
+ search?: string | undefined;
31331
+ cursor?: string | undefined;
31332
+ isConnected?: boolean | undefined;
31333
+ }, {
31334
+ toolkits?: string[] | undefined;
31335
+ limit?: number | undefined;
31336
+ search?: string | undefined;
31337
+ cursor?: string | undefined;
31338
+ isConnected?: boolean | undefined;
31339
+ }>;
31340
+ type ToolRouterToolkitsOptions = z.infer<typeof ToolRouterToolkitsOptionsSchema>;
31341
+ type ToolRouterToolkitsFn = (options?: ToolRouterToolkitsOptions) => Promise<ToolkitConnectionsDetails>;
31342
+ declare const ToolRouterSessionSearchResponseSchema: z.ZodObject<{
31343
+ success: z.ZodBoolean;
31344
+ error: z.ZodNullable<z.ZodString>;
31345
+ results: z.ZodArray<z.ZodObject<{
31346
+ index: z.ZodNumber;
31347
+ useCase: z.ZodString;
31348
+ primaryToolSlugs: z.ZodArray<z.ZodString, "many">;
31349
+ relatedToolSlugs: z.ZodArray<z.ZodString, "many">;
31350
+ toolkits: z.ZodArray<z.ZodString, "many">;
31351
+ difficulty: z.ZodOptional<z.ZodString>;
31352
+ error: z.ZodOptional<z.ZodNullable<z.ZodString>>;
31353
+ executionGuidance: z.ZodOptional<z.ZodString>;
31354
+ knownPitfalls: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
31355
+ memory: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodArray<z.ZodString, "many">>>;
31356
+ planId: z.ZodOptional<z.ZodString>;
31357
+ recommendedPlanSteps: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
31358
+ referenceWorkbenchSnippets: z.ZodOptional<z.ZodArray<z.ZodObject<{
31359
+ code: z.ZodString;
31360
+ description: z.ZodString;
31361
+ }, "strip", z.ZodTypeAny, {
31362
+ code: string;
31363
+ description: string;
31364
+ }, {
31365
+ code: string;
31366
+ description: string;
31367
+ }>, "many">>;
31368
+ }, "strip", z.ZodTypeAny, {
31369
+ toolkits: string[];
31370
+ index: number;
31371
+ useCase: string;
31372
+ primaryToolSlugs: string[];
31373
+ relatedToolSlugs: string[];
31374
+ error?: string | null | undefined;
31375
+ difficulty?: string | undefined;
31376
+ executionGuidance?: string | undefined;
31377
+ knownPitfalls?: string[] | undefined;
31378
+ memory?: Record<string, string[]> | undefined;
31379
+ planId?: string | undefined;
31380
+ recommendedPlanSteps?: string[] | undefined;
31381
+ referenceWorkbenchSnippets?: {
31382
+ code: string;
31383
+ description: string;
31384
+ }[] | undefined;
31385
+ }, {
31386
+ toolkits: string[];
31387
+ index: number;
31388
+ useCase: string;
31389
+ primaryToolSlugs: string[];
31390
+ relatedToolSlugs: string[];
31391
+ error?: string | null | undefined;
31392
+ difficulty?: string | undefined;
31393
+ executionGuidance?: string | undefined;
31394
+ knownPitfalls?: string[] | undefined;
31395
+ memory?: Record<string, string[]> | undefined;
31396
+ planId?: string | undefined;
31397
+ recommendedPlanSteps?: string[] | undefined;
31398
+ referenceWorkbenchSnippets?: {
31399
+ code: string;
31400
+ description: string;
31401
+ }[] | undefined;
31402
+ }>, "many">;
31403
+ toolSchemas: z.ZodRecord<z.ZodString, z.ZodObject<{
31404
+ toolSlug: z.ZodString;
31405
+ toolkit: z.ZodString;
31406
+ description: z.ZodOptional<z.ZodString>;
31407
+ hasFullSchema: z.ZodOptional<z.ZodBoolean>;
31408
+ inputSchema: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
31409
+ outputSchema: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
31410
+ schemaRef: z.ZodOptional<z.ZodObject<{
31411
+ args: z.ZodObject<{
31412
+ toolSlugs: z.ZodArray<z.ZodString, "many">;
31413
+ }, "strip", z.ZodTypeAny, {
31414
+ toolSlugs: string[];
31415
+ }, {
31416
+ toolSlugs: string[];
31417
+ }>;
31418
+ message: z.ZodOptional<z.ZodString>;
31419
+ tool: z.ZodLiteral<"COMPOSIO_GET_TOOL_SCHEMAS">;
31420
+ }, "strip", z.ZodTypeAny, {
31421
+ args: {
31422
+ toolSlugs: string[];
31423
+ };
31424
+ tool: "COMPOSIO_GET_TOOL_SCHEMAS";
31425
+ message?: string | undefined;
31426
+ }, {
31427
+ args: {
31428
+ toolSlugs: string[];
31429
+ };
31430
+ tool: "COMPOSIO_GET_TOOL_SCHEMAS";
31431
+ message?: string | undefined;
31432
+ }>>;
31433
+ }, "strip", z.ZodTypeAny, {
31434
+ toolkit: string;
31435
+ toolSlug: string;
31436
+ description?: string | undefined;
31437
+ hasFullSchema?: boolean | undefined;
31438
+ inputSchema?: Record<string, unknown> | undefined;
31439
+ outputSchema?: Record<string, unknown> | undefined;
31440
+ schemaRef?: {
31441
+ args: {
31442
+ toolSlugs: string[];
31443
+ };
31444
+ tool: "COMPOSIO_GET_TOOL_SCHEMAS";
31445
+ message?: string | undefined;
31446
+ } | undefined;
31447
+ }, {
31448
+ toolkit: string;
31449
+ toolSlug: string;
31450
+ description?: string | undefined;
31451
+ hasFullSchema?: boolean | undefined;
31452
+ inputSchema?: Record<string, unknown> | undefined;
31453
+ outputSchema?: Record<string, unknown> | undefined;
31454
+ schemaRef?: {
31455
+ args: {
31456
+ toolSlugs: string[];
31457
+ };
31458
+ tool: "COMPOSIO_GET_TOOL_SCHEMAS";
31459
+ message?: string | undefined;
31460
+ } | undefined;
31461
+ }>>;
31462
+ toolkitConnectionStatuses: z.ZodArray<z.ZodObject<{
31463
+ toolkit: z.ZodString;
31464
+ description: z.ZodString;
31465
+ hasActiveConnection: z.ZodBoolean;
31466
+ statusMessage: z.ZodString;
31467
+ connectionDetails: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
31468
+ currentUserInfo: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
31469
+ }, "strip", z.ZodTypeAny, {
31470
+ description: string;
31471
+ toolkit: string;
31472
+ hasActiveConnection: boolean;
31473
+ statusMessage: string;
31474
+ connectionDetails?: Record<string, unknown> | undefined;
31475
+ currentUserInfo?: Record<string, unknown> | undefined;
31476
+ }, {
31477
+ description: string;
31478
+ toolkit: string;
31479
+ hasActiveConnection: boolean;
31480
+ statusMessage: string;
31481
+ connectionDetails?: Record<string, unknown> | undefined;
31482
+ currentUserInfo?: Record<string, unknown> | undefined;
31483
+ }>, "many">;
31484
+ nextStepsGuidance: z.ZodArray<z.ZodString, "many">;
31485
+ session: z.ZodObject<{
31486
+ id: z.ZodString;
31487
+ generateId: z.ZodBoolean;
31488
+ instructions: z.ZodString;
31489
+ }, "strip", z.ZodTypeAny, {
31490
+ id: string;
31491
+ generateId: boolean;
31492
+ instructions: string;
31493
+ }, {
31494
+ id: string;
31495
+ generateId: boolean;
31496
+ instructions: string;
31497
+ }>;
31498
+ timeInfo: z.ZodObject<{
31499
+ currentTimeUtc: z.ZodString;
31500
+ currentTimeUtcEpochSeconds: z.ZodNumber;
31501
+ message: z.ZodString;
31502
+ }, "strip", z.ZodTypeAny, {
31503
+ message: string;
31504
+ currentTimeUtc: string;
31505
+ currentTimeUtcEpochSeconds: number;
31506
+ }, {
31507
+ message: string;
31508
+ currentTimeUtc: string;
31509
+ currentTimeUtcEpochSeconds: number;
31510
+ }>;
31511
+ }, "strip", z.ZodTypeAny, {
31512
+ error: string | null;
31513
+ success: boolean;
31514
+ results: {
31515
+ toolkits: string[];
31516
+ index: number;
31517
+ useCase: string;
31518
+ primaryToolSlugs: string[];
31519
+ relatedToolSlugs: string[];
31520
+ error?: string | null | undefined;
31521
+ difficulty?: string | undefined;
31522
+ executionGuidance?: string | undefined;
31523
+ knownPitfalls?: string[] | undefined;
31524
+ memory?: Record<string, string[]> | undefined;
31525
+ planId?: string | undefined;
31526
+ recommendedPlanSteps?: string[] | undefined;
31527
+ referenceWorkbenchSnippets?: {
31528
+ code: string;
31529
+ description: string;
31530
+ }[] | undefined;
31531
+ }[];
31532
+ toolSchemas: Record<string, {
31533
+ toolkit: string;
31534
+ toolSlug: string;
31535
+ description?: string | undefined;
31536
+ hasFullSchema?: boolean | undefined;
31537
+ inputSchema?: Record<string, unknown> | undefined;
31538
+ outputSchema?: Record<string, unknown> | undefined;
31539
+ schemaRef?: {
31540
+ args: {
31541
+ toolSlugs: string[];
31542
+ };
31543
+ tool: "COMPOSIO_GET_TOOL_SCHEMAS";
31544
+ message?: string | undefined;
31545
+ } | undefined;
31546
+ }>;
31547
+ toolkitConnectionStatuses: {
31548
+ description: string;
31549
+ toolkit: string;
31550
+ hasActiveConnection: boolean;
31551
+ statusMessage: string;
31552
+ connectionDetails?: Record<string, unknown> | undefined;
31553
+ currentUserInfo?: Record<string, unknown> | undefined;
31554
+ }[];
31555
+ nextStepsGuidance: string[];
31556
+ session: {
31557
+ id: string;
31558
+ generateId: boolean;
31559
+ instructions: string;
31560
+ };
31561
+ timeInfo: {
31562
+ message: string;
31563
+ currentTimeUtc: string;
31564
+ currentTimeUtcEpochSeconds: number;
31565
+ };
31566
+ }, {
31567
+ error: string | null;
31568
+ success: boolean;
31569
+ results: {
31570
+ toolkits: string[];
31571
+ index: number;
31572
+ useCase: string;
31573
+ primaryToolSlugs: string[];
31574
+ relatedToolSlugs: string[];
31575
+ error?: string | null | undefined;
31576
+ difficulty?: string | undefined;
31577
+ executionGuidance?: string | undefined;
31578
+ knownPitfalls?: string[] | undefined;
31579
+ memory?: Record<string, string[]> | undefined;
31580
+ planId?: string | undefined;
31581
+ recommendedPlanSteps?: string[] | undefined;
31582
+ referenceWorkbenchSnippets?: {
31583
+ code: string;
31584
+ description: string;
31585
+ }[] | undefined;
31586
+ }[];
31587
+ toolSchemas: Record<string, {
31588
+ toolkit: string;
31589
+ toolSlug: string;
31590
+ description?: string | undefined;
31591
+ hasFullSchema?: boolean | undefined;
31592
+ inputSchema?: Record<string, unknown> | undefined;
31593
+ outputSchema?: Record<string, unknown> | undefined;
31594
+ schemaRef?: {
31595
+ args: {
31596
+ toolSlugs: string[];
31597
+ };
31598
+ tool: "COMPOSIO_GET_TOOL_SCHEMAS";
31599
+ message?: string | undefined;
31600
+ } | undefined;
31601
+ }>;
31602
+ toolkitConnectionStatuses: {
31603
+ description: string;
31604
+ toolkit: string;
31605
+ hasActiveConnection: boolean;
31606
+ statusMessage: string;
31607
+ connectionDetails?: Record<string, unknown> | undefined;
31608
+ currentUserInfo?: Record<string, unknown> | undefined;
31609
+ }[];
31610
+ nextStepsGuidance: string[];
31611
+ session: {
31612
+ id: string;
31613
+ generateId: boolean;
31614
+ instructions: string;
31615
+ };
31616
+ timeInfo: {
31617
+ message: string;
31618
+ currentTimeUtc: string;
31619
+ currentTimeUtcEpochSeconds: number;
31620
+ };
31621
+ }>;
31622
+ type ToolRouterSessionSearchResponse = z.infer<typeof ToolRouterSessionSearchResponseSchema>;
31623
+ declare const ToolRouterSessionExecuteResponseSchema: z.ZodObject<{
31624
+ data: z.ZodRecord<z.ZodString, z.ZodUnknown>;
31625
+ error: z.ZodNullable<z.ZodString>;
31626
+ logId: z.ZodString;
31627
+ }, "strip", z.ZodTypeAny, {
31628
+ data: Record<string, unknown>;
31629
+ error: string | null;
31630
+ logId: string;
31631
+ }, {
31632
+ data: Record<string, unknown>;
31633
+ error: string | null;
31634
+ logId: string;
31635
+ }>;
31636
+ type ToolRouterSessionExecuteResponse = z.infer<typeof ToolRouterSessionExecuteResponseSchema>;
31637
+ interface ToolRouterSessionProxyExecuteResponse {
31638
+ /** The HTTP status code returned from the proxied API */
31639
+ status: number;
31640
+ /** The response data from the proxied API */
31641
+ data?: unknown;
31642
+ /** HTTP headers from the proxied API */
31643
+ headers?: Record<string, string>;
31644
+ /** Binary response data (present when response is a file) */
31645
+ binaryData?: {
31646
+ contentType: string;
31647
+ size: number;
31648
+ url: string;
31649
+ expiresAt?: string;
31650
+ };
31651
+ }
31652
+ /**
31653
+ * Experimental features on a tool router session.
31654
+ * Contains features that may be modified or removed in future versions.
31655
+ */
31656
+ interface SessionExperimental {
31657
+ /**
31658
+ * The assistive system prompt to inject into your agent for optimal tool router usage.
31659
+ * Only returned on session creation, not on GET.
31660
+ */
31661
+ assistivePrompt?: string;
31662
+ /**
31663
+ * File mount operations (list, upload, download, delete) for the session's virtual filesystem.
31664
+ */
31665
+ files: ToolRouterSessionFilesMount;
31666
+ }
31667
+ type ToolRouterSessionSearchFn = (params: {
31668
+ query: string;
31669
+ toolkits?: string[];
31670
+ }) => Promise<ToolRouterSessionSearchResponse>;
31671
+ type ToolRouterSessionExecuteFn = (toolSlug: string, arguments_?: Record<string, unknown>, options?: ToolRouterSessionExecuteOptions) => Promise<ToolRouterSessionExecuteResponse>;
31672
+ interface ToolRouterSessionExecuteOptions {
31673
+ /**
31674
+ * Account identifier for direct app tool execution in multi-account sessions.
31675
+ * Meta/helper tools either ignore this top-level field or define
31676
+ * their own account-selection fields, for example
31677
+ * COMPOSIO_MULTI_EXECUTE_TOOL.tools[].account.
31678
+ */
31679
+ account?: string;
31680
+ }
31681
+ type ToolRouterSessionPreloadConfig = SessionCreateResponse.Config.Preload;
31682
+ type ToolRouterSessionWorkbenchConfig = SessionCreateResponse.Config.Workbench;
31683
+ type ToolRouterSessionWarning = SessionCreateResponse.Warning;
31684
+ interface ToolRouterSessionMetadata {
31685
+ preload?: ToolRouterSessionPreloadConfig;
31686
+ workbench?: ToolRouterSessionWorkbenchConfig;
31687
+ configVersion?: number;
31688
+ warnings?: ToolRouterSessionWarning[];
31689
+ preloadedCustomToolSlugs?: string[];
31690
+ inlineCustomToolsPayload?: InlineCustomToolsWirePayload;
31691
+ }
31692
+ declare const SessionProxyExecuteParamsSchema: z.ZodObject<{
31693
+ /** The toolkit whose connected account to use for auth (e.g. 'gmail', 'github') */
31694
+ toolkit: z.ZodString;
31695
+ /** The API endpoint URL to call */
31696
+ endpoint: z.ZodString;
31697
+ /** HTTP method */
31698
+ method: z.ZodEnum<["GET", "POST", "PUT", "DELETE", "PATCH"]>;
31699
+ /** Request body (for POST/PUT/PATCH) */
31700
+ body: z.ZodOptional<z.ZodUnknown>;
31701
+ /** Query params or headers to include */
31702
+ parameters: z.ZodOptional<z.ZodArray<z.ZodObject<{
31703
+ in: z.ZodEnum<["query", "header"]>;
31704
+ name: z.ZodString;
31705
+ value: z.ZodUnion<[z.ZodString, z.ZodNumber]>;
31706
+ }, "strip", z.ZodTypeAny, {
31707
+ name: string;
31708
+ value: string | number;
31709
+ in: "query" | "header";
31710
+ }, {
31711
+ name: string;
31712
+ value: string | number;
31713
+ in: "query" | "header";
31714
+ }>, "many">>;
31715
+ }, "strip", z.ZodTypeAny, {
31716
+ toolkit: string;
31717
+ endpoint: string;
31718
+ method: "GET" | "POST" | "PUT" | "DELETE" | "PATCH";
31719
+ body?: unknown;
31720
+ parameters?: {
31721
+ name: string;
31722
+ value: string | number;
31723
+ in: "query" | "header";
31724
+ }[] | undefined;
31725
+ }, {
31726
+ toolkit: string;
31727
+ endpoint: string;
31728
+ method: "GET" | "POST" | "PUT" | "DELETE" | "PATCH";
31729
+ body?: unknown;
31730
+ parameters?: {
31731
+ name: string;
31732
+ value: string | number;
31733
+ in: "query" | "header";
31734
+ }[] | undefined;
31735
+ }>;
31736
+ type SessionProxyExecuteParams = z.infer<typeof SessionProxyExecuteParamsSchema>;
31737
+ type ToolRouterSessionProxyExecuteFn = (params: SessionProxyExecuteParams) => Promise<ToolRouterSessionProxyExecuteResponse>;
31738
+ declare const ToolRouterUpdateSessionConfigSchema: z.ZodEffects<z.ZodObject<{
31739
+ toolkits: z.ZodOptional<z.ZodOptional<z.ZodUnion<[z.ZodArray<z.ZodString, "many">, z.ZodObject<{
31740
+ disable: z.ZodArray<z.ZodString, "many">;
31741
+ }, "strict", z.ZodTypeAny, {
31742
+ disable: string[];
31743
+ }, {
31744
+ disable: string[];
31745
+ }>, z.ZodObject<{
31746
+ enable: z.ZodArray<z.ZodString, "many">;
31747
+ }, "strict", z.ZodTypeAny, {
31748
+ enable: string[];
31749
+ }, {
31750
+ enable: string[];
31751
+ }>]>>>;
31752
+ tools: z.ZodOptional<z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnion<[z.ZodArray<z.ZodString, "many">, z.ZodEffects<z.ZodUnion<[z.ZodArray<z.ZodString, "many">, z.ZodObject<{
31753
+ enable: z.ZodArray<z.ZodString, "many">;
31754
+ }, "strict", z.ZodTypeAny, {
31755
+ enable: string[];
31756
+ }, {
31757
+ enable: string[];
31758
+ }>, z.ZodObject<{
31759
+ disable: z.ZodArray<z.ZodString, "many">;
31760
+ }, "strict", z.ZodTypeAny, {
31761
+ disable: string[];
31762
+ }, {
31763
+ disable: string[];
31764
+ }>, z.ZodObject<{
31765
+ tags: z.ZodUnion<[z.ZodArray<z.ZodEnum<["readOnlyHint", "destructiveHint", "idempotentHint", "openWorldHint"]>, "many">, z.ZodObject<{
31766
+ enable: z.ZodOptional<z.ZodArray<z.ZodEnum<["readOnlyHint", "destructiveHint", "idempotentHint", "openWorldHint"]>, "many">>;
31767
+ disable: z.ZodOptional<z.ZodArray<z.ZodEnum<["readOnlyHint", "destructiveHint", "idempotentHint", "openWorldHint"]>, "many">>;
31768
+ }, "strict", z.ZodTypeAny, {
31769
+ disable?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | undefined;
31770
+ enable?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | undefined;
31771
+ }, {
31772
+ disable?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | undefined;
31773
+ enable?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | undefined;
31774
+ }>]>;
31775
+ }, "strict", z.ZodTypeAny, {
31776
+ tags: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | {
31777
+ disable?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | undefined;
31778
+ enable?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | undefined;
31779
+ };
31780
+ }, {
31781
+ tags: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | {
31782
+ disable?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | undefined;
31783
+ enable?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | undefined;
31784
+ };
31785
+ }>]>, string[] | {
31786
+ enable: string[];
31787
+ } | {
31788
+ disable: string[];
31789
+ } | {
31790
+ tags: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | {
31791
+ disable?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | undefined;
31792
+ enable?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | undefined;
31793
+ };
31794
+ }, string[] | {
31795
+ enable: string[];
31796
+ } | {
31797
+ disable: string[];
31798
+ } | {
31799
+ tags: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | {
31800
+ disable?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | undefined;
31801
+ enable?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | undefined;
31802
+ };
31803
+ }>]>>>>;
31804
+ tags: z.ZodOptional<z.ZodOptional<z.ZodUnion<[z.ZodArray<z.ZodEnum<["readOnlyHint", "destructiveHint", "idempotentHint", "openWorldHint"]>, "many">, z.ZodObject<{
31805
+ enable: z.ZodOptional<z.ZodArray<z.ZodEnum<["readOnlyHint", "destructiveHint", "idempotentHint", "openWorldHint"]>, "many">>;
31806
+ disable: z.ZodOptional<z.ZodArray<z.ZodEnum<["readOnlyHint", "destructiveHint", "idempotentHint", "openWorldHint"]>, "many">>;
31807
+ }, "strict", z.ZodTypeAny, {
31808
+ disable?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | undefined;
31809
+ enable?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | undefined;
31810
+ }, {
31811
+ disable?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | undefined;
31812
+ enable?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | undefined;
31813
+ }>]>>>;
31814
+ authConfigs: z.ZodOptional<z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>>;
31815
+ connectedAccounts: z.ZodOptional<z.ZodOptional<z.ZodEffects<z.ZodRecord<z.ZodString, z.ZodUnion<[z.ZodString, z.ZodArray<z.ZodString, "many">]>>, Record<string, string[]>, Record<string, string | string[]>>>>;
31816
+ manageConnections: z.ZodOptional<z.ZodOptional<z.ZodNullable<z.ZodUnion<[z.ZodBoolean, z.ZodObject<{
31817
+ enable: z.ZodOptional<z.ZodDefault<z.ZodBoolean>>;
31818
+ callbackUrl: z.ZodOptional<z.ZodString>;
31819
+ waitForConnections: z.ZodOptional<z.ZodBoolean>;
31820
+ }, "strict", z.ZodTypeAny, {
31821
+ enable?: boolean | undefined;
31822
+ callbackUrl?: string | undefined;
31823
+ waitForConnections?: boolean | undefined;
31824
+ }, {
31825
+ enable?: boolean | undefined;
31826
+ callbackUrl?: string | undefined;
31827
+ waitForConnections?: boolean | undefined;
31828
+ }>]>>>>;
31829
+ sandbox: z.ZodOptional<z.ZodOptional<z.ZodNullable<z.ZodObject<{
31830
+ enable: z.ZodOptional<z.ZodDefault<z.ZodBoolean>>;
31831
+ enableProxyExecution: z.ZodOptional<z.ZodOptional<z.ZodBoolean>>;
31832
+ autoOffloadThreshold: z.ZodOptional<z.ZodOptional<z.ZodNumber>>;
31833
+ sandboxSize: z.ZodOptional<z.ZodOptional<z.ZodEnum<["standard", "medium", "large", "xlarge"]>>>;
31834
+ }, "strip", z.ZodTypeAny, {
31835
+ enable?: boolean | undefined;
31836
+ enableProxyExecution?: boolean | undefined;
31837
+ autoOffloadThreshold?: number | undefined;
31838
+ sandboxSize?: "standard" | "medium" | "large" | "xlarge" | undefined;
31839
+ }, {
31840
+ enable?: boolean | undefined;
31841
+ enableProxyExecution?: boolean | undefined;
31842
+ autoOffloadThreshold?: number | undefined;
31843
+ sandboxSize?: "standard" | "medium" | "large" | "xlarge" | undefined;
31844
+ }>>>>;
31845
+ workbench: z.ZodOptional<z.ZodOptional<z.ZodNullable<z.ZodObject<{
31846
+ enable: z.ZodOptional<z.ZodDefault<z.ZodBoolean>>;
31847
+ enableProxyExecution: z.ZodOptional<z.ZodOptional<z.ZodBoolean>>;
31848
+ autoOffloadThreshold: z.ZodOptional<z.ZodOptional<z.ZodNumber>>;
31849
+ sandboxSize: z.ZodOptional<z.ZodOptional<z.ZodEnum<["standard", "medium", "large", "xlarge"]>>>;
31850
+ }, "strip", z.ZodTypeAny, {
31851
+ enable?: boolean | undefined;
31852
+ enableProxyExecution?: boolean | undefined;
31853
+ autoOffloadThreshold?: number | undefined;
31854
+ sandboxSize?: "standard" | "medium" | "large" | "xlarge" | undefined;
31855
+ }, {
31856
+ enable?: boolean | undefined;
31857
+ enableProxyExecution?: boolean | undefined;
31858
+ autoOffloadThreshold?: number | undefined;
31859
+ sandboxSize?: "standard" | "medium" | "large" | "xlarge" | undefined;
31860
+ }>>>>;
31861
+ multiAccount: z.ZodOptional<z.ZodOptional<z.ZodNullable<z.ZodObject<{
31862
+ enable: z.ZodOptional<z.ZodBoolean>;
31863
+ maxAccountsPerToolkit: z.ZodOptional<z.ZodNumber>;
31864
+ requireExplicitSelection: z.ZodOptional<z.ZodBoolean>;
31865
+ }, "strip", z.ZodTypeAny, {
31866
+ enable?: boolean | undefined;
31867
+ maxAccountsPerToolkit?: number | undefined;
31868
+ requireExplicitSelection?: boolean | undefined;
31869
+ }, {
31870
+ enable?: boolean | undefined;
31871
+ maxAccountsPerToolkit?: number | undefined;
31872
+ requireExplicitSelection?: boolean | undefined;
31873
+ }>>>>;
31874
+ preload: z.ZodOptional<z.ZodOptional<z.ZodObject<{
31875
+ tools: z.ZodOptional<z.ZodUnion<[z.ZodArray<z.ZodString, "many">, z.ZodLiteral<"all">]>>;
31876
+ }, "strict", z.ZodTypeAny, {
31877
+ tools?: string[] | "all" | undefined;
31878
+ }, {
31879
+ tools?: string[] | "all" | undefined;
31880
+ }>>>;
31881
+ }, "strip", z.ZodTypeAny, {
31882
+ tags?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | {
31883
+ disable?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | undefined;
31884
+ enable?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | undefined;
31885
+ } | undefined;
31886
+ tools?: Record<string, string[] | {
31887
+ enable: string[];
31888
+ } | {
31889
+ disable: string[];
31890
+ } | {
31891
+ tags: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | {
31892
+ disable?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | undefined;
31893
+ enable?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | undefined;
31894
+ };
31895
+ }> | undefined;
31896
+ toolkits?: string[] | {
31897
+ disable: string[];
31898
+ } | {
31899
+ enable: string[];
31900
+ } | undefined;
31901
+ authConfigs?: Record<string, string> | undefined;
31902
+ connectedAccounts?: Record<string, string[]> | undefined;
31903
+ manageConnections?: boolean | {
31904
+ enable?: boolean | undefined;
31905
+ callbackUrl?: string | undefined;
31906
+ waitForConnections?: boolean | undefined;
31907
+ } | null | undefined;
31908
+ sandbox?: {
31909
+ enable?: boolean | undefined;
31910
+ enableProxyExecution?: boolean | undefined;
31911
+ autoOffloadThreshold?: number | undefined;
31912
+ sandboxSize?: "standard" | "medium" | "large" | "xlarge" | undefined;
31913
+ } | null | undefined;
31914
+ workbench?: {
31915
+ enable?: boolean | undefined;
31916
+ enableProxyExecution?: boolean | undefined;
31917
+ autoOffloadThreshold?: number | undefined;
31918
+ sandboxSize?: "standard" | "medium" | "large" | "xlarge" | undefined;
31919
+ } | null | undefined;
31920
+ multiAccount?: {
31921
+ enable?: boolean | undefined;
31922
+ maxAccountsPerToolkit?: number | undefined;
31923
+ requireExplicitSelection?: boolean | undefined;
31924
+ } | null | undefined;
31925
+ preload?: {
31926
+ tools?: string[] | "all" | undefined;
31927
+ } | undefined;
31928
+ }, {
31929
+ tags?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | {
31930
+ disable?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | undefined;
31931
+ enable?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | undefined;
31932
+ } | undefined;
31933
+ tools?: Record<string, string[] | {
31934
+ enable: string[];
31935
+ } | {
31936
+ disable: string[];
31937
+ } | {
31938
+ tags: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | {
31939
+ disable?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | undefined;
31940
+ enable?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | undefined;
31941
+ };
31942
+ }> | undefined;
31943
+ toolkits?: string[] | {
31944
+ disable: string[];
31945
+ } | {
31946
+ enable: string[];
31947
+ } | undefined;
31948
+ authConfigs?: Record<string, string> | undefined;
31949
+ connectedAccounts?: Record<string, string | string[]> | undefined;
31950
+ manageConnections?: boolean | {
31951
+ enable?: boolean | undefined;
31952
+ callbackUrl?: string | undefined;
31953
+ waitForConnections?: boolean | undefined;
31954
+ } | null | undefined;
31955
+ sandbox?: {
31956
+ enable?: boolean | undefined;
31957
+ enableProxyExecution?: boolean | undefined;
31958
+ autoOffloadThreshold?: number | undefined;
31959
+ sandboxSize?: "standard" | "medium" | "large" | "xlarge" | undefined;
31960
+ } | null | undefined;
31961
+ workbench?: {
31962
+ enable?: boolean | undefined;
31963
+ enableProxyExecution?: boolean | undefined;
31964
+ autoOffloadThreshold?: number | undefined;
31965
+ sandboxSize?: "standard" | "medium" | "large" | "xlarge" | undefined;
31966
+ } | null | undefined;
31967
+ multiAccount?: {
31968
+ enable?: boolean | undefined;
31969
+ maxAccountsPerToolkit?: number | undefined;
31970
+ requireExplicitSelection?: boolean | undefined;
31971
+ } | null | undefined;
31972
+ preload?: {
31973
+ tools?: string[] | "all" | undefined;
31974
+ } | undefined;
31975
+ }>, {
31976
+ tags?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | {
31977
+ disable?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | undefined;
31978
+ enable?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | undefined;
31979
+ } | undefined;
31980
+ tools?: Record<string, string[] | {
31981
+ enable: string[];
31982
+ } | {
31983
+ disable: string[];
31984
+ } | {
31985
+ tags: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | {
31986
+ disable?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | undefined;
31987
+ enable?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | undefined;
31988
+ };
31989
+ }> | undefined;
31990
+ toolkits?: string[] | {
31991
+ disable: string[];
31992
+ } | {
31993
+ enable: string[];
31994
+ } | undefined;
31995
+ authConfigs?: Record<string, string> | undefined;
31996
+ connectedAccounts?: Record<string, string[]> | undefined;
31997
+ manageConnections?: boolean | {
31998
+ enable?: boolean | undefined;
31999
+ callbackUrl?: string | undefined;
32000
+ waitForConnections?: boolean | undefined;
32001
+ } | null | undefined;
32002
+ sandbox?: {
32003
+ enable?: boolean | undefined;
32004
+ enableProxyExecution?: boolean | undefined;
32005
+ autoOffloadThreshold?: number | undefined;
32006
+ sandboxSize?: "standard" | "medium" | "large" | "xlarge" | undefined;
32007
+ } | null | undefined;
32008
+ workbench?: {
32009
+ enable?: boolean | undefined;
32010
+ enableProxyExecution?: boolean | undefined;
32011
+ autoOffloadThreshold?: number | undefined;
32012
+ sandboxSize?: "standard" | "medium" | "large" | "xlarge" | undefined;
32013
+ } | null | undefined;
32014
+ multiAccount?: {
32015
+ enable?: boolean | undefined;
32016
+ maxAccountsPerToolkit?: number | undefined;
32017
+ requireExplicitSelection?: boolean | undefined;
32018
+ } | null | undefined;
32019
+ preload?: {
32020
+ tools?: string[] | "all" | undefined;
32021
+ } | undefined;
32022
+ }, {
32023
+ tags?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | {
32024
+ disable?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | undefined;
32025
+ enable?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | undefined;
32026
+ } | undefined;
32027
+ tools?: Record<string, string[] | {
32028
+ enable: string[];
32029
+ } | {
32030
+ disable: string[];
32031
+ } | {
32032
+ tags: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | {
32033
+ disable?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | undefined;
32034
+ enable?: ("readOnlyHint" | "destructiveHint" | "idempotentHint" | "openWorldHint")[] | undefined;
32035
+ };
32036
+ }> | undefined;
32037
+ toolkits?: string[] | {
32038
+ disable: string[];
32039
+ } | {
32040
+ enable: string[];
32041
+ } | undefined;
32042
+ authConfigs?: Record<string, string> | undefined;
32043
+ connectedAccounts?: Record<string, string | string[]> | undefined;
32044
+ manageConnections?: boolean | {
32045
+ enable?: boolean | undefined;
32046
+ callbackUrl?: string | undefined;
32047
+ waitForConnections?: boolean | undefined;
32048
+ } | null | undefined;
32049
+ sandbox?: {
32050
+ enable?: boolean | undefined;
32051
+ enableProxyExecution?: boolean | undefined;
32052
+ autoOffloadThreshold?: number | undefined;
32053
+ sandboxSize?: "standard" | "medium" | "large" | "xlarge" | undefined;
32054
+ } | null | undefined;
32055
+ workbench?: {
32056
+ enable?: boolean | undefined;
32057
+ enableProxyExecution?: boolean | undefined;
32058
+ autoOffloadThreshold?: number | undefined;
32059
+ sandboxSize?: "standard" | "medium" | "large" | "xlarge" | undefined;
32060
+ } | null | undefined;
32061
+ multiAccount?: {
32062
+ enable?: boolean | undefined;
32063
+ maxAccountsPerToolkit?: number | undefined;
32064
+ requireExplicitSelection?: boolean | undefined;
32065
+ } | null | undefined;
32066
+ preload?: {
32067
+ tools?: string[] | "all" | undefined;
32068
+ } | undefined;
32069
+ }>;
32070
+ type ToolRouterUpdateSessionConfig = z.infer<typeof ToolRouterUpdateSessionConfigSchema>;
32071
+ type ToolRouterSessionUpdateFn = (config: ToolRouterUpdateSessionConfig) => Promise<void>;
32072
+ declare const ToolRouterSessionDeleteResponseSchema: z.ZodObject<{
32073
+ sessionId: z.ZodString;
32074
+ deleted: z.ZodLiteral<true>;
32075
+ }, "strip", z.ZodTypeAny, {
32076
+ sessionId: string;
32077
+ deleted: true;
32078
+ }, {
32079
+ sessionId: string;
32080
+ deleted: true;
32081
+ }>;
32082
+ type ToolRouterSessionDeleteResponse = z.infer<typeof ToolRouterSessionDeleteResponseSchema>;
32083
+ type ToolRouterSessionDeleteFn = (requestOptions?: ComposioRequestOptions) => Promise<ToolRouterSessionDeleteResponse>;
32084
+ /** Session type returned by ToolRouter.create() and ToolRouter.use() */
32085
+ interface Session<TToolCollection, TTool, TProvider extends BaseComposioProvider<TToolCollection, TTool, unknown>> {
32086
+ sessionId: string;
32087
+ mcp: ToolRouterMCPServerConfig;
32088
+ /** Stored preload configuration for this session. */
32089
+ preload: ToolRouterSessionPreloadConfig;
32090
+ /**
32091
+ * Resolved sandbox (code-execution) config returned by the API. `enable` defaults to `true` server-side.
32092
+ *
32093
+ * This is the read-side counterpart to the `sandbox` key you pass into `create()`.
32094
+ */
32095
+ sandbox?: ToolRouterSessionWorkbenchConfig;
32096
+ /**
32097
+ * Resolved sandbox config for the session.
32098
+ *
32099
+ * @deprecated Use `sandbox` instead. `workbench` is a backwards-compatible alias and will be removed in a future release.
32100
+ */
32101
+ workbench?: ToolRouterSessionWorkbenchConfig;
32102
+ /** Server-side config version when returned by the API. */
32103
+ configVersion?: number;
32104
+ /** Non-blocking session creation warnings returned by the API. */
32105
+ warnings: ToolRouterSessionWarning[];
32106
+ tools: ToolRouterToolsFn<TToolCollection, TTool, TProvider>;
32107
+ authorize: ToolRouterAuthorizeFn;
32108
+ toolkits: ToolRouterToolkitsFn;
32109
+ /** Search for tools by semantic use case */
32110
+ search: ToolRouterSessionSearchFn;
32111
+ /** Execute a tool within the session */
32112
+ execute: ToolRouterSessionExecuteFn;
32113
+ /** Update the session configuration. Mutates this session in-place. */
32114
+ update: ToolRouterSessionUpdateFn;
32115
+ /** Delete the session. Deleted sessions are no longer retrievable or executable. */
32116
+ delete: ToolRouterSessionDeleteFn;
32117
+ /** Proxy an API call through Composio's auth layer using the session's connected account */
32118
+ proxyExecute: ToolRouterSessionProxyExecuteFn;
32119
+ /** List custom tools registered in this session, with their final slugs and schemas */
32120
+ customTools: (options?: {
32121
+ toolkit?: string;
32122
+ }) => RegisteredCustomTool[];
32123
+ /** List custom toolkits registered in this session, with final slugs on nested tools */
32124
+ customToolkits: () => RegisteredCustomToolkit[];
32125
+ /** Experimental features (files, assistive prompt, etc.) */
32126
+ experimental: SessionExperimental;
32127
+ }
32128
+ /**
32129
+ * Session type without the typed `mcp` endpoint.
32130
+ *
32131
+ * Returned by `create()` / `use()` when `{ mcp: true }` is not passed. The
32132
+ * hosted MCP endpoint still exists on the underlying session at runtime — this
32133
+ * only hides it from the type so MCP is an explicit opt-in. Pass `{ mcp: true }`
32134
+ * to get a `Session` with `session.mcp` surfaced. See
32135
+ * https://docs.composio.dev/docs/sessions-via-mcp
32136
+ */
32137
+ type SessionWithoutMcp<TToolCollection, TTool, TProvider extends BaseComposioProvider<TToolCollection, TTool, unknown>> = Omit<Session<TToolCollection, TTool, TProvider>, 'mcp'>;
32138
+ //#endregion
32139
+ //#region src/types/customTool.types.d.ts
32140
+ type AnyZodSchema = z$1.ZodType | z$2.ZodType;
32141
+ type InferZodSchema<T extends AnyZodSchema> = T extends z$1.ZodType ? z$1.infer<T> : T extends z$2.ZodType ? z$2.infer<T> : never;
32142
+ /**
32143
+ * Session context injected into custom tool execute functions at runtime.
32144
+ * Provides identity context and methods to call other tools or proxy API requests.
32145
+ */
32146
+ interface SessionContext {
32147
+ /** The user ID for this session */
32148
+ readonly userId: string;
32149
+ /** Execute any Composio native tool from within a custom tool. Returns the same shape as session.execute(). */
32150
+ execute(toolSlug: string, arguments_: Record<string, unknown>): Promise<ToolRouterSessionExecuteResponse>;
32151
+ /** Proxy API calls through Composio's auth layer (resolved from session toolkit). */
32152
+ proxyExecute(params: SessionProxyExecuteParams): Promise<ToolRouterSessionProxyExecuteResponse>;
32153
+ /**
32154
+ * Caller-supplied AbortSignal forwarded from `session.execute(..., { signal })`.
32155
+ * Custom-tool execution is cooperative: long-running user code that respects
32156
+ * this signal (e.g. by passing it into `fetch`) can abort mid-execution and
32157
+ * surface as `ComposioRequestCancelledError`. Undefined when the caller did
32158
+ * not pass `requestOptions`.
32159
+ */
32160
+ readonly signal?: AbortSignal;
32161
+ }
32162
+ /**
32163
+ * Execute function for custom tools.
32164
+ * Just return the result data, or throw an error. The SDK wraps it internally.
32165
+ *
32166
+ * Supports two call patterns:
32167
+ * - `(input) => data` — for tools that don't need session context
32168
+ * - `(input, ctx) => data` — for tools that need to call other tools or proxy APIs
32169
+ */
32170
+ type CustomToolExecuteFn<T extends AnyZodSchema> = (input: InferZodSchema<T>, ctx: SessionContext) => Promise<Record<string, unknown>>;
32171
+ /**
32172
+ * Zod schema for validating a custom tool slug.
32173
+ * Alphanumeric, underscores, and hyphens only. No `LOCAL_` or `COMPOSIO_` prefix.
32174
+ * Length is validated contextually (standalone vs extension vs toolkit) at creation time.
32175
+ */
32176
+ declare const CustomToolSlugSchema: z$1.ZodEffects<z$1.ZodEffects<z$1.ZodString, string, string>, string, string>;
32177
+ /**
32178
+ * Zod schema for validating the string/scalar fields of createCustomTool() options.
32179
+ * Slug is validated separately as the first argument.
32180
+ * Used internally for validation — inputParams, outputParams, and execute are checked manually.
32181
+ */
32182
+ declare const CreateCustomToolBaseSchema: z$1.ZodObject<{
32183
+ name: z$1.ZodString;
32184
+ description: z$1.ZodString;
32185
+ /**
32186
+ * Composio toolkit slug that this tool extends (inherits auth from).
32187
+ * Must be a valid Composio toolkit slug (e.g. `'gmail'`, `'github'`, `'meta_ads'`).
32188
+ * The backend validates this against the toolkit catalog.
32189
+ * Leave empty for tools that don't need any Composio-managed authentication.
32190
+ */
32191
+ extendsToolkit: z$1.ZodOptional<z$1.ZodString>;
32192
+ preload: z$1.ZodOptional<z$1.ZodBoolean>;
32193
+ }, "strip", z$1.ZodTypeAny, {
32194
+ name: string;
32195
+ description: string;
32196
+ preload?: boolean | undefined;
32197
+ extendsToolkit?: string | undefined;
32198
+ }, {
32199
+ name: string;
32200
+ description: string;
32201
+ preload?: boolean | undefined;
32202
+ extendsToolkit?: string | undefined;
32203
+ }>;
32204
+ /** Options for creating a custom tool via `createCustomTool()`. */
32205
+ type CreateCustomToolParams<T extends AnyZodSchema> = z$1.infer<typeof CreateCustomToolBaseSchema> & {
32206
+ /** Zod schema for input parameters */
32207
+ inputParams: T;
32208
+ /** Optional Zod schema for output parameters (sent to backend for documentation) */
32209
+ outputParams?: AnyZodSchema;
32210
+ /** The function that executes the tool */
32211
+ execute: CustomToolExecuteFn<T>;
32212
+ };
32213
+ /**
32214
+ * Custom tool definition returned from `createCustomTool()`.
32215
+ * Pass to `composio.create(userId, { experimental: { customTools: [...] } })` to bind to a session.
32216
+ */
32217
+ interface CustomTool {
32218
+ readonly slug: string;
32219
+ readonly name: string;
32220
+ readonly description: string;
32221
+ /**
32222
+ * Composio toolkit slug that this tool extends (inherits auth from).
32223
+ * Must be a valid Composio toolkit slug. Validated by the backend.
32224
+ * Undefined means the tool doesn't need any Composio-managed authentication.
32225
+ */
32226
+ readonly extendsToolkit?: string;
32227
+ /**
32228
+ * Include this custom tool in session.tools() so it can be called without
32229
+ * searching first.
32230
+ */
32231
+ readonly preload?: boolean;
32232
+ readonly inputSchema: Record<string, unknown>;
32233
+ /** JSON Schema representation of the output (for backend documentation) */
32234
+ readonly outputSchema?: Record<string, unknown>;
32235
+ /** @internal Original Zod schema — used for runtime input validation (defaults, coercions, transforms) */
32236
+ readonly inputParams: AnyZodSchema;
32237
+ /** Direct reference to the execute function — useful for testing */
32238
+ readonly execute: CustomToolExecuteFn<AnyZodSchema>;
32239
+ }
32240
+ /** Serialized tool definition sent to backend for search indexing. Uses official client type. */
32241
+ type CustomToolDefinition = SessionCreateParams.Experimental.CustomTool;
32242
+ type CustomToolWireDefinition = CustomToolDefinition;
32243
+ /**
32244
+ * Zod schema for validating the string/scalar fields of createCustomToolkit() options.
32245
+ * Slug is validated separately as the first argument.
32246
+ */
32247
+ declare const CreateCustomToolkitBaseSchema: z$1.ZodObject<{
32248
+ name: z$1.ZodString;
32249
+ description: z$1.ZodString;
32250
+ preload: z$1.ZodOptional<z$1.ZodBoolean>;
32251
+ }, "strip", z$1.ZodTypeAny, {
32252
+ name: string;
32253
+ description: string;
32254
+ preload?: boolean | undefined;
32255
+ }, {
32256
+ name: string;
32257
+ description: string;
32258
+ preload?: boolean | undefined;
32259
+ }>;
32260
+ /** Options for creating a custom toolkit via `createCustomToolkit()`. */
32261
+ type CreateCustomToolkitParams = z$1.infer<typeof CreateCustomToolkitBaseSchema> & {
32262
+ /** Tools to include in this toolkit. Must not have `extendsToolkit` set. */
32263
+ tools: CustomTool[];
32264
+ };
32265
+ /**
32266
+ * Custom toolkit definition returned from `createCustomToolkit()`.
32267
+ * Pass to `composio.create(userId, { experimental: { customToolkits: [...] } })`.
32268
+ */
32269
+ interface CustomToolkit {
32270
+ readonly slug: string;
32271
+ readonly name: string;
32272
+ readonly description: string;
32273
+ /**
32274
+ * Default session.tools() exposure for tools in this custom toolkit.
32275
+ * Tool-level preload values override this default.
32276
+ */
32277
+ readonly preload?: boolean;
32278
+ readonly tools: readonly CustomTool[];
32279
+ }
32280
+ /** Serialized toolkit definition sent to backend. Uses official client type. */
32281
+ type CustomToolkitDefinition = SessionCreateParams.Experimental.CustomToolkit;
32282
+ type CustomToolkitWireDefinition = CustomToolkitDefinition;
32283
+ interface InlineCustomToolsWirePayload {
32284
+ custom_tools?: CustomToolWireDefinition[];
32285
+ custom_toolkits?: CustomToolkitWireDefinition[];
32286
+ }
32287
+ /** @internal Entry in the per-session custom tools routing map. */
32288
+ type CustomToolsMapEntry = {
32289
+ handle: CustomTool;
32290
+ /** @internal The final slug assigned by the prefixing rules (e.g. LOCAL_GREP, LOCAL_GMAIL_GET_EMAILS) */
32291
+ finalSlug: string;
32292
+ /** Resolved toolkit — from extendsToolkit, parent custom toolkit, or undefined for standalone */
32293
+ toolkit?: string;
32294
+ };
32295
+ /** @internal Lookup maps used by ToolRouterSession for routing custom tools. */
32296
+ type CustomToolsMap = {
32297
+ /** Lookup by final slug (e.g. LOCAL_GET_USER_CONTEXT) — used for agent execution path */
32298
+ byFinalSlug: Map<string, CustomToolsMapEntry>;
32299
+ /** Lookup by unique original slug (e.g. GET_USER_CONTEXT) — used for programmatic session.execute() */
32300
+ byOriginalSlug: Map<string, CustomToolsMapEntry>;
32301
+ /** Lookup by resolved toolkit + original slug — used when multiple custom toolkits reuse tool names */
32302
+ byToolkitAndOriginalSlug?: Map<string, CustomToolsMapEntry>;
32303
+ /** Original slugs that appear in multiple toolkits and cannot be resolved safely without the final slug */
32304
+ ambiguousOriginalSlugs?: Set<string>;
32305
+ /** The original custom toolkits passed at session creation — used for session.customToolkits() */
32306
+ toolkits?: CustomToolkit[];
32307
+ /** The original standalone custom tools passed at session creation — kept for inline re-injection on later requests. */
32308
+ tools?: CustomTool[];
32309
+ };
32310
+ /** A custom tool as registered in a session, with its final resolved slug. */
32311
+ interface RegisteredCustomTool {
32312
+ /** The final slug as registered with the backend (e.g. LOCAL_GREP, LOCAL_GMAIL_GET_EMAILS) */
32313
+ slug: string;
32314
+ name: string;
32315
+ description: string;
32316
+ /** Resolved toolkit — extendsToolkit value, custom toolkit slug, or undefined for standalone */
32317
+ toolkit?: string;
32318
+ inputSchema: Record<string, unknown>;
32319
+ outputSchema?: Record<string, unknown>;
32320
+ }
32321
+ /** A custom toolkit as registered in a session, with final slugs on nested tools. */
32322
+ interface RegisteredCustomToolkit {
32323
+ slug: string;
32324
+ name: string;
32325
+ description: string;
32326
+ tools: RegisteredCustomTool[];
32327
+ }
32328
+ /** Custom tool as returned in the session create response (has prefixed slug + original_slug). */
32329
+ type CustomToolResponse = SessionCreateResponse.Experimental.CustomTool;
32330
+ /** Custom toolkit as returned in the session create response (has prefixed slugs + original_slugs). */
32331
+ type CustomToolkitResponse = SessionCreateResponse.Experimental.CustomToolkit;
32332
+ //#endregion
32333
+ export { ToolRouterSessionMetadata as $, ToolExecuteResponse as $i, MCPGenerateURLParams as $n, Oauth1ActiveConnectionDataSchema as $r, ConnectedAccountExperimentalSchema as $t, SessionProxyExecuteParams as A, BeforeFileUploadSource as Ai, UpdateConnectedAccountParamsSchema as An, McpUpdateResponseSchema as Ar, FileListResponseSchema as At, ToolRouterCreateSessionConfigSchema as B, beforeExecuteMetaModifier as Bi, ComposioMcpUpdateResponseSchema as Bn, BaseConnectionFields as Br, ToolRouterSessionFilesMountUploadOptionsSchema as Bt, MCPServerType as C, Oauth2InitiatedConnectionDataSchema as Ci, CreateConnectedAccountParamsSchema as Cn, McpRetrieveResponse as Cr, ToolkitConnectionStateSchema as Ct, Session as D, Oauth2RevokedConnectionDataSchema as Di, UpdateConnectedAccountAclParams as Dn, McpServerUrlInfo as Dr, FileDeleteResponse as Dt, SandboxSizeSchema as E, Oauth2RevokedConnectionData as Ei, DefaultCreateConnectedAccountParamsSchema as En, McpServerGetResponse as Er, RemoteFile as Et, ToolRouterConfigTags as F, SessionMetaToolOptions as Fi, ComposioGenerateURLParamsSchema as Fn, ExecuteToolFnOptions as Fr, ToolRouterSessionFilesMountDownloadOptions as Ft, ToolRouterSandboxConfigSchema as G, JSONSchemaProperty as Gi, GenerateURLParams as Gn, ConnectionStatuses as Gr, ConnectedAccountAclConfigResponse as Gt, ToolRouterMCPServerConfigSchema as H, beforeFileUploadModifier as Hi, CustomCreateResponse$1 as Hn, ConnectionData as Hr, ConnectionRequest as Ht, ToolRouterConfigTagsSchema as I, ToolOptions as Ii, ComposioGenerateURLResponseSchema as In, GlobalExecuteToolFn as Ir, ToolRouterSessionFilesMountDownloadOptionsSchema as It, ToolRouterSessionDeleteResponseSchema as J, Tool as Ji, GenerateURLResponseSchema as Jn, CustomOauth1ConnectionData as Jr, ConnectedAccountAuthConfig as Jt, ToolRouterSessionDeleteFn as K, JSONSchemaPropertySchema as Ki, GenerateURLParamsSchema as Kn, CustomConnectionData as Kr, ConnectedAccountAclConfigResponseSchema as Kt, ToolRouterConfigTools as L, TransformToolSchemaModifier as Li, ComposioMcpDeleteResponseSchema as Ln, Provider as Lr, ToolRouterSessionFilesMountListOptions as Lt, SessionWithoutMcp as M, MetaToolArguments as Mi, BaseComposioProvider as Mn, McpUrlResponseCamelCase as Mr, RemoteFileDataSchema as Mt, ToolRouterAuthorizeFn as N, ProviderOptions as Ni, BaseNonAgenticProvider as Nn, McpUserConnectionStatus as Nr, ToolRouterSessionFilesMountDeleteOptions as Nt, SessionExperimental as O, RedirectableAuthSchemeSchema as Oi, UpdateConnectedAccountAclParamsSchema as On, McpToolkitConnectionStatus as Or, FileDeleteResponseSchema as Ot, ToolRouterConfigManageConnectionsSchema as P, SessionExecuteMetaModifiers as Pi, ComposioCustomCreateResponseSchema as Pn, ExecuteToolFn as Pr, ToolRouterSessionFilesMountDeleteOptionsSchema as Pt, ToolRouterSessionExecuteResponseSchema as Q, ToolExecuteParamsSchema as Qi, MCPCreateMethodResponse as Qn, Oauth1ActiveConnectionData as Qr, ConnectedAccountExperimentalResponseSchema as Qt, ToolRouterConfigToolsSchema as R, afterExecuteMetaModifier as Ri, ComposioMcpListResponseSchema as Rn, ToolCallExecutionTarget as Rr, ToolRouterSessionFilesMountListOptionsSchema as Rt, SessionContext as S, Oauth2InitiatedConnectionData as Si, CreateConnectedAccountParams as Sn, McpListResponseSchema as Sr, ToolkitConnectionState as St, SandboxSize as T, Oauth2InitiatingConnectionDataSchema as Ti, CreateConnectedAccountResponseSchema as Tn, McpServerCreateResponse as Tr, ToolkitConnectionsDetailsSchema as Tt, ToolRouterManageConnectionsConfigSchema as U, CustomAuthParams as Ui, CustomCreateResponseSchema as Un, ConnectionDataSchema as Ur, ConnectionRequestState as Ut, ToolRouterMCPServerConfig as V, beforeExecuteModifier as Vi, ConnectionStatus as Vn, BillcomAuthConnectionDataSchema as Vr, ComposioRequestOptions as Vt, ToolRouterSandboxConfig as W, CustomAuthParamsSchema as Wi, CustomCreateResponseValidated as Wn, ConnectionStatusEnum as Wr, ConnectedAccountAclConfig as Wt, ToolRouterSessionExecuteOptions as X, ToolExecuteMetaParamsSchema as Xi, MCPAuthOptions as Xn, CustomOauth2ConnectionData as Xr, ConnectedAccountExperimental as Xt, ToolRouterSessionExecuteFn as Y, ToolExecuteMetaParams as Yi, GenerateURLResponseValidated as Yn, CustomOauth1ConnectionDataSchema as Yr, ConnectedAccountAuthConfigSchema as Yt, ToolRouterSessionExecuteResponse as Z, ToolExecuteParams as Zi, MCPAuthOptionsSchema as Zn, CustomOauth2ConnectionDataSchema as Zr, ConnectedAccountExperimentalResponse as Zt, CustomToolsMapEntry as _, ToolkitVersionSchema as _a, Oauth2ExpiredConnectionDataSchema as _i, CreateConnectedAccountLinkOptionsSchema as _n, MCPToolkitConfigSchema as _r, ToolRouterToolsFn as _t, CreateCustomToolkitParams as a, ToolListResponseSchema as aa, Oauth1FailedConnectionDataSchema as ai, ConnectedAccountRefreshOptions as an, MCPMultiAppServerSchema as ar, ToolRouterSessionSearchResponseSchema as at, RegisteredCustomTool as b, Oauth2InactiveConnectionData as bi, CreateConnectedAccountOptions as bn, McpDeleteResponseSchema as br, ToolRouterUpdateSessionConfig as bt, CustomToolExecuteFn as c, ToolRetrievalOptions as ca, Oauth1InitiatedConnectionData as ci, ConnectedAccountRetrieveResponseSchema as cn, MCPServerCreateResponseSchema as cr, ToolRouterSessionWorkbenchConfig as ct, CustomToolWireDefinition as d, ToolkitLatestVersion as da, Oauth1InitiatingConnectionDataSchema as di, ConnectedAccountStatusSchema as dn, MCPServerSchema as dr, ToolRouterToolkitsDisabledConfigSchema as dt, ToolExecuteResponseSchema as ea, Oauth1ConnectionData as ei, ConnectedAccountListParams as en, MCPGenerateURLParamsSchema as er, ToolRouterSessionPreloadConfig as et, CustomToolkit as f, ToolkitLatestVersionSchema as fa, Oauth2ActiveConnectionData as fi, ConnectedAccountStatuses as fn, MCPServerUpdateParams as fr, ToolRouterToolkitsEnabledConfigSchema as ft, CustomToolsMap as g, ToolkitVersionParamSchema as ga, Oauth2ExpiredConnectionData as gi, CreateConnectedAccountLinkOptions as gn, MCPToolkitConfig as gr, ToolRouterToolkitsParamSchema as gt, CustomToolkitWireDefinition as h, ToolkitVersionParam as ha, Oauth2ConnectionDataSchema as hi, ConnectedAccountTypes as hn, MCPSingleAppServerSchema as hr, ToolRouterToolkitsOptionsSchema as ht, CreateCustomToolkitBaseSchema as i, ToolListResponse as ia, Oauth1FailedConnectionData as ii, ConnectedAccountListResponseSchema as in, MCPMultiAppServer as ir, ToolRouterSessionSearchResponse as it, SessionProxyExecuteParamsSchema as j, ExecuteToolModifiers as ji, BaseAgenticProvider as jn, McpUrlResponse as jr, RemoteFileData as jt, SessionPreset as k, AgenticToolOptions as ki, UpdateConnectedAccountParams as kn, McpUpdateResponse as kr, FileListResponse as kt, CustomToolResponse as l, ToolSchema as la, Oauth1InitiatedConnectionDataSchema as li, ConnectedAccountStatus as ln, MCPServerListResponse as lr, ToolRouterTagsEnableDisableSchema as lt, CustomToolkitResponse as m, ToolkitVersion as ma, Oauth2ConnectionData as mi, ConnectedAccountTypeSchema as mn, MCPSingleAppServer as mr, ToolRouterToolkitsOptions as mt, CreateCustomToolBaseSchema as n, ToolListParams as na, Oauth1ExpiredConnectionData as ni, ConnectedAccountListResponse as nn, MCPGetServerParamsSchema as nr, ToolRouterSessionProxyExecuteResponse as nt, CustomTool as o, ToolProxyParams as oa, Oauth1InactiveConnectionData as oi, ConnectedAccountRefreshOptionsSchema as on, MCPServer as or, ToolRouterSessionUpdateFn as ot, CustomToolkitDefinition as p, ToolkitSchema as pa, Oauth2ActiveConnectionDataSchema as pi, ConnectedAccountType as pn, MCPServerUpdateParamsSchema as pr, ToolRouterToolkitsFn as pt, ToolRouterSessionDeleteResponse as q, SchemaModifierOptions as qi, GenerateURLResponse$1 as qn, CustomConnectionDataSchema as qr, ConnectedAccountAclConfigSchema as qt, CreateCustomToolParams as r, ToolListParamsSchema as ra, Oauth1ExpiredConnectionDataSchema as ri, ConnectedAccountListResponseItem as rn, MCPInstanceParams as rr, ToolRouterSessionSearchFn as rt, CustomToolDefinition as s, ToolProxyParamsSchema as sa, Oauth1InactiveConnectionDataSchema as si, ConnectedAccountRetrieveResponse as sn, MCPServerCreateResponse as sr, ToolRouterSessionWarning as st, AnyZodSchema as t, ToolList as ta, Oauth1ConnectionDataSchema as ti, ConnectedAccountListParamsSchema as tn, MCPGetServerParams as tr, ToolRouterSessionProxyExecuteFn as tt, CustomToolSlugSchema as u, Toolkit as ua, Oauth1InitiatingConnectionData as ui, ConnectedAccountStatusEnum as un, MCPServerListResponseSchema as ur, ToolRouterTagsParamSchema as ut, InferZodSchema as v, ToolkitVersions as va, Oauth2FailedConnectionData as vi, CreateConnectedAccountLinkResponse as vn, MCPToolkitConfigsArraySchema as vr, ToolRouterToolsParam as vt, MCPServerTypeSchema as w, Oauth2InitiatingConnectionData as wi, CreateConnectedAccountResponse as wn, McpRetrieveResponseSchema as wr, ToolkitConnectionsDetails as wt, RegisteredCustomToolkit as x, Oauth2InactiveConnectionDataSchema as xi, CreateConnectedAccountOptionsSchema as xn, McpListResponse as xr, ToolRouterUpdateSessionConfigSchema as xt, InlineCustomToolsWirePayload as y, ToolkitVersionsSchema as ya, Oauth2FailedConnectionDataSchema as yi, CreateConnectedAccountLinkResponseSchema as yn, McpDeleteResponse as yr, ToolRouterToolsParamSchema as yt, ToolRouterCreateSessionConfig as z, afterExecuteModifier as zi, ComposioMcpRetrieveResponseSchema as zn, ToolCallSession as zr, ToolRouterSessionFilesMountUploadOptions as zt };