@composio/core 0.1.8-alpha.0 → 0.1.10-alpha.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.d.cts CHANGED
@@ -71,26 +71,26 @@ type ToolList = Array<Tool>;
71
71
  * ToolListParams is the parameters for the list of tools.
72
72
  */
73
73
  declare const ToolListParamsSchema: z.ZodObject<{
74
+ tools: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
74
75
  cursor: z.ZodOptional<z.ZodString>;
75
76
  important: z.ZodOptional<z.ZodString>;
76
77
  limit: z.ZodOptional<z.ZodString>;
77
78
  search: z.ZodOptional<z.ZodString>;
78
79
  toolkits: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
79
- tools: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
80
80
  }, "strip", z.ZodTypeAny, {
81
+ tools?: string[] | undefined;
81
82
  cursor?: string | undefined;
82
83
  important?: string | undefined;
83
84
  limit?: string | undefined;
84
85
  search?: string | undefined;
85
86
  toolkits?: string[] | undefined;
86
- tools?: string[] | undefined;
87
87
  }, {
88
+ tools?: string[] | undefined;
88
89
  cursor?: string | undefined;
89
90
  important?: string | undefined;
90
91
  limit?: string | undefined;
91
92
  search?: string | undefined;
92
93
  toolkits?: string[] | undefined;
93
- tools?: string[] | undefined;
94
94
  }>;
95
95
  type ToolListParams = z.infer<typeof ToolListParamsSchema>;
96
96
  /**
@@ -250,56 +250,6 @@ interface ExecuteMetadata {
250
250
  connectedAccountId?: string;
251
251
  }
252
252
 
253
- /**
254
- * @fileoverview Custom tools class for Composio SDK, used to manage custom tools created by users.
255
- *
256
- * @author Musthaq Ahamad <musthaq@composio.dev>
257
- * @date 2025-05-05
258
- * @module CustomTools
259
- */
260
-
261
- declare class CustomTools {
262
- private client;
263
- private customToolsRegistry;
264
- constructor(client: ComposioClient);
265
- /**
266
- * Create a custom tool and registers it in the registry.
267
- * This is just an in memory registry and is not persisted.
268
- * @param {CustomToolOptions} toolOptions CustomToolOptions
269
- * @returns {Tool} The tool created
270
- */
271
- createTool(toolOptions: CustomToolOptions): Promise<Tool>;
272
- /**
273
- * Get all the custom tools from the registry.
274
- * @param {string[]} param0.toolSlugs The slugs of the tools to get
275
- * @returns {ToolList} The list of tools
276
- */
277
- getCustomTools({ toolSlugs }: {
278
- toolSlugs?: string[];
279
- }): Promise<ToolList>;
280
- /**
281
- * Get a custom tool by slug from the registry.
282
- * @param {string} slug The slug of the tool to get
283
- * @returns {Tool} The tool
284
- */
285
- getCustomToolBySlug(slug: string): Promise<Tool | null>;
286
- /**
287
- * Get the connected account for the user and toolkit.
288
- * @param {string} toolkitSlug The slug of the toolkit
289
- * @param {ExecuteMetadata} metadata The metadata of the execution
290
- * @returns {ConnectedAccount} The connected account
291
- */
292
- private getConnectedAccount;
293
- /**
294
- * Execute a custom tool
295
- * @param {slug} slug The slug of the tool to execute
296
- * @param {Record<string, unknown>} inputParams The input parameters for the tool
297
- * @param {ExecuteMetadata} metadata The metadata of the execution
298
- * @returns {Promise<ToolExecuteResponse>} The response from the tool
299
- */
300
- executeCustomTool(slug: string, inputParams: Record<string, unknown>, metadata: ExecuteMetadata): Promise<ToolExecuteResponse>;
301
- }
302
-
303
253
  /**
304
254
  * Base toolset implementation, which needs to be implemented by the extended class.
305
255
  * This class is used to create a base toolset by implementing this class.
@@ -347,7 +297,7 @@ declare abstract class BaseToolset {
347
297
  /**
348
298
  * @internal
349
299
  * Set the function to execute a tool.
350
- * This is set automatically injected by the core SDK.
300
+ * This is set automatically and injected by the core SDK.
351
301
  */
352
302
  _setExecuteToolFn(executeToolFn: GlobalExecuteToolFn): void;
353
303
  /**
@@ -412,17 +362,17 @@ type BaseComposioToolset<TToolCollection, TTool> = BaseNonAgenticToolset<TToolCo
412
362
  * Modifier for altering the tool execute params
413
363
  * Called before the tool execute call
414
364
  */
415
- type BeforeToolExecuteModifier = (toolSlug: string, toolExecuteParams: ToolExecuteParams) => ToolExecuteParams;
365
+ type BeforeToolExecuteModifier = (toolSlug: string, toolkitSlug: string, toolExecuteParams: ToolExecuteParams) => ToolExecuteParams;
416
366
  /**
417
367
  * Modifier for altering the tool execute response
418
368
  * Called after the tool execute call
419
369
  */
420
- type AfterToolExecuteModifier = (toolSlug: string, toolExecuteResponse: ToolExecuteResponse) => ToolExecuteResponse;
370
+ type AfterToolExecuteModifier = (toolSlug: string, toolkitSlug: string, toolExecuteResponse: ToolExecuteResponse) => ToolExecuteResponse;
421
371
  /**
422
372
  * Modifier for altering the tool schema
423
373
  * Called after the tool schema is retrieved
424
374
  */
425
- type TransformToolSchemaModifier = (toolSlug: string, toolSchema: Tool) => Tool;
375
+ type TransformToolSchemaModifier = (toolSlug: string, toolkitSlug: string, toolSchema: Tool) => Tool;
426
376
  /**
427
377
  * Non Agentic tool options. These are used by Non-Agentic toolsets
428
378
  */
@@ -458,7 +408,7 @@ type ToolsetOptions<T extends BaseComposioToolset<unknown, unknown>> = T extends
458
408
  */
459
409
  declare class Tools<TToolCollection, TTool, TToolset extends BaseComposioToolset<TToolCollection, TTool>> {
460
410
  private client;
461
- customTools: CustomTools;
411
+ private readonly customTools;
462
412
  private toolset;
463
413
  constructor(client: ComposioClient, toolset: TToolset);
464
414
  /**
@@ -497,11 +447,43 @@ declare class Tools<TToolCollection, TTool, TToolset extends BaseComposioToolset
497
447
  * Retrieves a tool by its Slug.
498
448
  * @param slug The ID of the tool to be retrieved
499
449
  * @returns {Promise<Tool>} The tool
450
+ *
451
+ * @example
452
+ * ```ts
453
+ * const tool = await composio.tools.getComposioToolBySlug('default', 'github');
454
+ * ```
500
455
  */
501
456
  getComposioToolBySlug(userId: string, slug: string, modifier?: TransformToolSchemaModifier): Promise<Tool>;
502
- get(userId: string, slug: string, options?: ToolsetOptions<TToolset>): Promise<TTool>;
503
- get(userId: string, filters: ToolListParams, options?: ToolsetOptions<TToolset>): Promise<TToolCollection>;
504
457
  /**
458
+ * Get a tool by its slug
459
+ * @param userId - The user id
460
+ * @param slug - The slug of the tool
461
+ * @param options - The options for the tool
462
+ * @returns The tool
463
+ *
464
+ * @example
465
+ * ```ts
466
+ * const tool = await composio.tools.get('default', 'github');
467
+ * ```
468
+ */
469
+ get<T extends TToolset>(userId: string, slug: string, options?: ToolsetOptions<TToolset>): Promise<ReturnType<T['wrapTool']>>;
470
+ /**
471
+ * Get a list of tools by their slugs
472
+ * @param userId - The user id
473
+ * @param filters - The filters for the tools
474
+ * @param options - The options for the tools
475
+ * @returns The tools
476
+ *
477
+ * @example
478
+ * ```ts
479
+ * const tools = await composio.tools.get('default', {
480
+ * tools: ['github'],
481
+ * });
482
+ * ```
483
+ */
484
+ get<T extends TToolset>(userId: string, filters: ToolListParams, options?: ToolsetOptions<TToolset>): Promise<ReturnType<T['wrapTools']>>;
485
+ /**
486
+ * @internal
505
487
  * Creates a function that executes a tool.
506
488
  * This function is used by agentic the toolsets to execute the tool
507
489
  * @param {string} userId - The user id
@@ -509,6 +491,24 @@ declare class Tools<TToolCollection, TTool, TToolset extends BaseComposioToolset
509
491
  * @returns {ExecuteToolFn} The execute tool function
510
492
  */
511
493
  private createExecuteToolFn;
494
+ /**
495
+ * @internal
496
+ * Handles the execution of a custom tool
497
+ * @param tool - The tool to execute
498
+ * @param body - The body of the tool execution
499
+ * @param modifiers - The modifiers to be applied to the tool execution
500
+ * @returns The response from the tool execution
501
+ */
502
+ private handleCustomToolExecution;
503
+ /**
504
+ * @internal
505
+ * Handles the execution of a composio tool
506
+ * @param tool - The tool to execute
507
+ * @param body - The body of the tool execution
508
+ * @param modifiers - The modifiers to be applied to the tool execution
509
+ * @returns The response from the tool execution
510
+ */
511
+ private handleComposioToolExecution;
512
512
  /**
513
513
  * Exectes a given tool with the provided parameters.
514
514
  *
@@ -554,17 +554,17 @@ declare class Tools<TToolCollection, TTool, TToolset extends BaseComposioToolset
554
554
  declare const ToolkitsListParamsSchema: z.ZodObject<{
555
555
  category: z.ZodOptional<z.ZodString>;
556
556
  isLocal: z.ZodOptional<z.ZodBoolean>;
557
- managedBy: z.ZodOptional<z.ZodEnum<["all", "composio_managed", "project_managed"]>>;
557
+ managedBy: z.ZodOptional<z.ZodEnum<["all", "composio", "project"]>>;
558
558
  sortBy: z.ZodOptional<z.ZodEnum<["usage", "alphabetically"]>>;
559
559
  }, "strip", z.ZodTypeAny, {
560
560
  category?: string | undefined;
561
561
  isLocal?: boolean | undefined;
562
- managedBy?: "all" | "composio_managed" | "project_managed" | undefined;
562
+ managedBy?: "all" | "composio" | "project" | undefined;
563
563
  sortBy?: "usage" | "alphabetically" | undefined;
564
564
  }, {
565
565
  category?: string | undefined;
566
566
  isLocal?: boolean | undefined;
567
- managedBy?: "all" | "composio_managed" | "project_managed" | undefined;
567
+ managedBy?: "all" | "composio" | "project" | undefined;
568
568
  sortBy?: "usage" | "alphabetically" | undefined;
569
569
  }>;
570
570
  type ToolkitListParams = z.infer<typeof ToolkitsListParamsSchema>;
@@ -573,44 +573,47 @@ declare const ToolKitListResponseSchema: z.ZodObject<{
573
573
  name: z.ZodString;
574
574
  slug: z.ZodString;
575
575
  meta: z.ZodObject<{
576
- categories: z.ZodArray<z.ZodObject<{
577
- id: z.ZodString;
576
+ categories: z.ZodOptional<z.ZodArray<z.ZodObject<{
577
+ slug: z.ZodString;
578
578
  name: z.ZodString;
579
579
  }, "strip", z.ZodTypeAny, {
580
+ slug: string;
580
581
  name: string;
581
- id: string;
582
582
  }, {
583
+ slug: string;
583
584
  name: string;
584
- id: string;
585
- }>, "many">;
586
- createdAt: z.ZodString;
587
- description: z.ZodString;
588
- logo: z.ZodString;
589
- toolsCount: z.ZodNumber;
590
- triggersCount: z.ZodNumber;
591
- updatedAt: z.ZodString;
585
+ }>, "many">>;
586
+ appUrl: z.ZodOptional<z.ZodString>;
587
+ createdAt: z.ZodOptional<z.ZodString>;
588
+ description: z.ZodOptional<z.ZodString>;
589
+ logo: z.ZodOptional<z.ZodString>;
590
+ toolsCount: z.ZodOptional<z.ZodNumber>;
591
+ triggersCount: z.ZodOptional<z.ZodNumber>;
592
+ updatedAt: z.ZodOptional<z.ZodString>;
592
593
  }, "strip", z.ZodTypeAny, {
593
- logo: string;
594
- description: string;
595
- categories: {
594
+ logo?: string | undefined;
595
+ description?: string | undefined;
596
+ categories?: {
597
+ slug: string;
596
598
  name: string;
597
- id: string;
598
- }[];
599
- createdAt: string;
600
- toolsCount: number;
601
- triggersCount: number;
602
- updatedAt: string;
599
+ }[] | undefined;
600
+ appUrl?: string | undefined;
601
+ createdAt?: string | undefined;
602
+ toolsCount?: number | undefined;
603
+ triggersCount?: number | undefined;
604
+ updatedAt?: string | undefined;
603
605
  }, {
604
- logo: string;
605
- description: string;
606
- categories: {
606
+ logo?: string | undefined;
607
+ description?: string | undefined;
608
+ categories?: {
609
+ slug: string;
607
610
  name: string;
608
- id: string;
609
- }[];
610
- createdAt: string;
611
- toolsCount: number;
612
- triggersCount: number;
613
- updatedAt: string;
611
+ }[] | undefined;
612
+ appUrl?: string | undefined;
613
+ createdAt?: string | undefined;
614
+ toolsCount?: number | undefined;
615
+ triggersCount?: number | undefined;
616
+ updatedAt?: string | undefined;
614
617
  }>;
615
618
  isLocalToolkit: z.ZodBoolean;
616
619
  authSchemes: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
@@ -620,16 +623,17 @@ declare const ToolKitListResponseSchema: z.ZodObject<{
620
623
  slug: string;
621
624
  name: string;
622
625
  meta: {
623
- logo: string;
624
- description: string;
625
- categories: {
626
+ logo?: string | undefined;
627
+ description?: string | undefined;
628
+ categories?: {
629
+ slug: string;
626
630
  name: string;
627
- id: string;
628
- }[];
629
- createdAt: string;
630
- toolsCount: number;
631
- triggersCount: number;
632
- updatedAt: string;
631
+ }[] | undefined;
632
+ appUrl?: string | undefined;
633
+ createdAt?: string | undefined;
634
+ toolsCount?: number | undefined;
635
+ triggersCount?: number | undefined;
636
+ updatedAt?: string | undefined;
633
637
  };
634
638
  isLocalToolkit: boolean;
635
639
  authSchemes?: string[] | undefined;
@@ -639,16 +643,17 @@ declare const ToolKitListResponseSchema: z.ZodObject<{
639
643
  slug: string;
640
644
  name: string;
641
645
  meta: {
642
- logo: string;
643
- description: string;
644
- categories: {
646
+ logo?: string | undefined;
647
+ description?: string | undefined;
648
+ categories?: {
649
+ slug: string;
645
650
  name: string;
646
- id: string;
647
- }[];
648
- createdAt: string;
649
- toolsCount: number;
650
- triggersCount: number;
651
- updatedAt: string;
651
+ }[] | undefined;
652
+ appUrl?: string | undefined;
653
+ createdAt?: string | undefined;
654
+ toolsCount?: number | undefined;
655
+ triggersCount?: number | undefined;
656
+ updatedAt?: string | undefined;
652
657
  };
653
658
  isLocalToolkit: boolean;
654
659
  authSchemes?: string[] | undefined;
@@ -662,16 +667,17 @@ declare const ToolKitListResponseSchema: z.ZodObject<{
662
667
  slug: string;
663
668
  name: string;
664
669
  meta: {
665
- logo: string;
666
- description: string;
667
- categories: {
670
+ logo?: string | undefined;
671
+ description?: string | undefined;
672
+ categories?: {
673
+ slug: string;
668
674
  name: string;
669
- id: string;
670
- }[];
671
- createdAt: string;
672
- toolsCount: number;
673
- triggersCount: number;
674
- updatedAt: string;
675
+ }[] | undefined;
676
+ appUrl?: string | undefined;
677
+ createdAt?: string | undefined;
678
+ toolsCount?: number | undefined;
679
+ triggersCount?: number | undefined;
680
+ updatedAt?: string | undefined;
675
681
  };
676
682
  isLocalToolkit: boolean;
677
683
  authSchemes?: string[] | undefined;
@@ -685,16 +691,17 @@ declare const ToolKitListResponseSchema: z.ZodObject<{
685
691
  slug: string;
686
692
  name: string;
687
693
  meta: {
688
- logo: string;
689
- description: string;
690
- categories: {
694
+ logo?: string | undefined;
695
+ description?: string | undefined;
696
+ categories?: {
697
+ slug: string;
691
698
  name: string;
692
- id: string;
693
- }[];
694
- createdAt: string;
695
- toolsCount: number;
696
- triggersCount: number;
697
- updatedAt: string;
699
+ }[] | undefined;
700
+ appUrl?: string | undefined;
701
+ createdAt?: string | undefined;
702
+ toolsCount?: number | undefined;
703
+ triggersCount?: number | undefined;
704
+ updatedAt?: string | undefined;
698
705
  };
699
706
  isLocalToolkit: boolean;
700
707
  authSchemes?: string[] | undefined;
@@ -709,51 +716,54 @@ declare const ToolkitRetrieveResponseSchema: z.ZodObject<{
709
716
  name: z.ZodString;
710
717
  slug: z.ZodString;
711
718
  meta: z.ZodObject<{
712
- categories: z.ZodArray<z.ZodObject<{
713
- id: z.ZodString;
719
+ categories: z.ZodOptional<z.ZodArray<z.ZodObject<{
720
+ slug: z.ZodString;
714
721
  name: z.ZodString;
715
722
  }, "strip", z.ZodTypeAny, {
723
+ slug: string;
716
724
  name: string;
717
- id: string;
718
725
  }, {
726
+ slug: string;
719
727
  name: string;
720
- id: string;
721
- }>, "many">;
722
- createdAt: z.ZodString;
723
- description: z.ZodString;
724
- logo: z.ZodString;
725
- toolsCount: z.ZodNumber;
726
- triggersCount: z.ZodNumber;
727
- updatedAt: z.ZodString;
728
+ }>, "many">>;
729
+ appUrl: z.ZodOptional<z.ZodString>;
730
+ createdAt: z.ZodOptional<z.ZodString>;
731
+ description: z.ZodOptional<z.ZodString>;
732
+ logo: z.ZodOptional<z.ZodString>;
733
+ toolsCount: z.ZodOptional<z.ZodNumber>;
734
+ triggersCount: z.ZodOptional<z.ZodNumber>;
735
+ updatedAt: z.ZodOptional<z.ZodString>;
728
736
  }, "strip", z.ZodTypeAny, {
729
- logo: string;
730
- description: string;
731
- categories: {
737
+ logo?: string | undefined;
738
+ description?: string | undefined;
739
+ categories?: {
740
+ slug: string;
732
741
  name: string;
733
- id: string;
734
- }[];
735
- createdAt: string;
736
- toolsCount: number;
737
- triggersCount: number;
738
- updatedAt: string;
742
+ }[] | undefined;
743
+ appUrl?: string | undefined;
744
+ createdAt?: string | undefined;
745
+ toolsCount?: number | undefined;
746
+ triggersCount?: number | undefined;
747
+ updatedAt?: string | undefined;
739
748
  }, {
740
- logo: string;
741
- description: string;
742
- categories: {
749
+ logo?: string | undefined;
750
+ description?: string | undefined;
751
+ categories?: {
752
+ slug: string;
743
753
  name: string;
744
- id: string;
745
- }[];
746
- createdAt: string;
747
- toolsCount: number;
748
- triggersCount: number;
749
- updatedAt: string;
754
+ }[] | undefined;
755
+ appUrl?: string | undefined;
756
+ createdAt?: string | undefined;
757
+ toolsCount?: number | undefined;
758
+ triggersCount?: number | undefined;
759
+ updatedAt?: string | undefined;
750
760
  }>;
751
761
  isLocalToolkit: z.ZodBoolean;
752
762
  composioManagedAuthSchemes: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
753
763
  authConfigDetails: z.ZodOptional<z.ZodArray<z.ZodObject<{
754
764
  name: z.ZodString;
755
765
  mode: z.ZodString;
756
- fields: z.ZodArray<z.ZodObject<{
766
+ fields: z.ZodObject<{
757
767
  authConfigCreation: z.ZodObject<{
758
768
  optional: z.ZodArray<z.ZodObject<{
759
769
  name: z.ZodString;
@@ -932,14 +942,14 @@ declare const ToolkitRetrieveResponseSchema: z.ZodObject<{
932
942
  default?: string | null | undefined;
933
943
  }[];
934
944
  };
935
- }>, "many">;
936
- proxy: z.ZodObject<{
937
- baseUrul: z.ZodString;
945
+ }>;
946
+ proxy: z.ZodOptional<z.ZodObject<{
947
+ baseUrl: z.ZodOptional<z.ZodString>;
938
948
  }, "strip", z.ZodTypeAny, {
939
- baseUrul: string;
949
+ baseUrl?: string | undefined;
940
950
  }, {
941
- baseUrul: string;
942
- }>;
951
+ baseUrl?: string | undefined;
952
+ }>>;
943
953
  }, "strip", z.ZodTypeAny, {
944
954
  name: string;
945
955
  mode: string;
@@ -972,10 +982,10 @@ declare const ToolkitRetrieveResponseSchema: z.ZodObject<{
972
982
  default?: string | null | undefined;
973
983
  }[];
974
984
  };
975
- }[];
976
- proxy: {
977
- baseUrul: string;
978
985
  };
986
+ proxy?: {
987
+ baseUrl?: string | undefined;
988
+ } | undefined;
979
989
  }, {
980
990
  name: string;
981
991
  mode: string;
@@ -1008,25 +1018,26 @@ declare const ToolkitRetrieveResponseSchema: z.ZodObject<{
1008
1018
  default?: string | null | undefined;
1009
1019
  }[];
1010
1020
  };
1011
- }[];
1012
- proxy: {
1013
- baseUrul: string;
1014
1021
  };
1022
+ proxy?: {
1023
+ baseUrl?: string | undefined;
1024
+ } | undefined;
1015
1025
  }>, "many">>;
1016
1026
  }, "strip", z.ZodTypeAny, {
1017
1027
  slug: string;
1018
1028
  name: string;
1019
1029
  meta: {
1020
- logo: string;
1021
- description: string;
1022
- categories: {
1030
+ logo?: string | undefined;
1031
+ description?: string | undefined;
1032
+ categories?: {
1033
+ slug: string;
1023
1034
  name: string;
1024
- id: string;
1025
- }[];
1026
- createdAt: string;
1027
- toolsCount: number;
1028
- triggersCount: number;
1029
- updatedAt: string;
1035
+ }[] | undefined;
1036
+ appUrl?: string | undefined;
1037
+ createdAt?: string | undefined;
1038
+ toolsCount?: number | undefined;
1039
+ triggersCount?: number | undefined;
1040
+ updatedAt?: string | undefined;
1030
1041
  };
1031
1042
  isLocalToolkit: boolean;
1032
1043
  composioManagedAuthSchemes?: string[] | undefined;
@@ -1062,25 +1073,26 @@ declare const ToolkitRetrieveResponseSchema: z.ZodObject<{
1062
1073
  default?: string | null | undefined;
1063
1074
  }[];
1064
1075
  };
1065
- }[];
1066
- proxy: {
1067
- baseUrul: string;
1068
1076
  };
1077
+ proxy?: {
1078
+ baseUrl?: string | undefined;
1079
+ } | undefined;
1069
1080
  }[] | undefined;
1070
1081
  }, {
1071
1082
  slug: string;
1072
1083
  name: string;
1073
1084
  meta: {
1074
- logo: string;
1075
- description: string;
1076
- categories: {
1085
+ logo?: string | undefined;
1086
+ description?: string | undefined;
1087
+ categories?: {
1088
+ slug: string;
1077
1089
  name: string;
1078
- id: string;
1079
- }[];
1080
- createdAt: string;
1081
- toolsCount: number;
1082
- triggersCount: number;
1083
- updatedAt: string;
1090
+ }[] | undefined;
1091
+ appUrl?: string | undefined;
1092
+ createdAt?: string | undefined;
1093
+ toolsCount?: number | undefined;
1094
+ triggersCount?: number | undefined;
1095
+ updatedAt?: string | undefined;
1084
1096
  };
1085
1097
  isLocalToolkit: boolean;
1086
1098
  composioManagedAuthSchemes?: string[] | undefined;
@@ -1116,10 +1128,10 @@ declare const ToolkitRetrieveResponseSchema: z.ZodObject<{
1116
1128
  default?: string | null | undefined;
1117
1129
  }[];
1118
1130
  };
1119
- }[];
1120
- proxy: {
1121
- baseUrul: string;
1122
1131
  };
1132
+ proxy?: {
1133
+ baseUrl?: string | undefined;
1134
+ } | undefined;
1123
1135
  }[] | undefined;
1124
1136
  }>;
1125
1137
  type ToolkitRetrieveResponse = z.infer<typeof ToolkitRetrieveResponseSchema>;
@@ -1153,6 +1165,136 @@ declare const ToolkitRetrieveCategoriesResponseSchema: z.ZodObject<{
1153
1165
  }>;
1154
1166
  type ToolkitRetrieveCategoriesResponse = z.infer<typeof ToolkitRetrieveCategoriesResponseSchema>;
1155
1167
 
1168
+ /**
1169
+ * Connected Account create parameters
1170
+ */
1171
+ declare const ConnectedAccountStatuses: {
1172
+ readonly ACTIVE: "ACTIVE";
1173
+ readonly INACTIVE: "INACTIVE";
1174
+ readonly DELETED: "DELETED";
1175
+ readonly INITIATED: "INITIATED";
1176
+ readonly EXPIRED: "EXPIRED";
1177
+ readonly FAILED: "FAILED";
1178
+ };
1179
+ type ConnectedAccountStatus = (typeof ConnectedAccountStatuses)[keyof typeof ConnectedAccountStatuses];
1180
+ type CreateConnectedAccountOptions = z.infer<typeof CreateConnectedAccountOptionsSchema>;
1181
+ declare const CreateConnectedAccountOptionsSchema: z.ZodObject<{
1182
+ redirectUrl: z.ZodOptional<z.ZodString>;
1183
+ data: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
1184
+ }, "strip", z.ZodTypeAny, {
1185
+ data?: Record<string, unknown> | undefined;
1186
+ redirectUrl?: string | undefined;
1187
+ }, {
1188
+ data?: Record<string, unknown> | undefined;
1189
+ redirectUrl?: string | undefined;
1190
+ }>;
1191
+ type CreateConnectedAccountOptionsSchema = z.infer<typeof CreateConnectedAccountOptionsSchema>;
1192
+ declare const ConnectedAccountRetrieveResponseSchema: z.ZodObject<{
1193
+ id: z.ZodString;
1194
+ authConfig: z.ZodObject<{
1195
+ id: z.ZodString;
1196
+ authScheme: z.ZodEnum<["OAUTH2", "OAUTH1", "OAUTH1A", "API_KEY", "BASIC", "BILLCOM_AUTH", "BEARER_TOKEN", "GOOGLE_SERVICE_ACCOUNT", "NO_AUTH", "BASIC_WITH_JWT", "COMPOSIO_LINK", "CALCOM_AUTH", "SNOWFLAKE"]>;
1197
+ isComposioManaged: z.ZodBoolean;
1198
+ isDisabled: z.ZodBoolean;
1199
+ }, "strip", z.ZodTypeAny, {
1200
+ id: string;
1201
+ authScheme: "NO_AUTH" | "OAUTH2" | "OAUTH1" | "OAUTH1A" | "API_KEY" | "BASIC" | "BILLCOM_AUTH" | "BEARER_TOKEN" | "GOOGLE_SERVICE_ACCOUNT" | "BASIC_WITH_JWT" | "COMPOSIO_LINK" | "CALCOM_AUTH" | "SNOWFLAKE";
1202
+ isComposioManaged: boolean;
1203
+ isDisabled: boolean;
1204
+ }, {
1205
+ id: string;
1206
+ authScheme: "NO_AUTH" | "OAUTH2" | "OAUTH1" | "OAUTH1A" | "API_KEY" | "BASIC" | "BILLCOM_AUTH" | "BEARER_TOKEN" | "GOOGLE_SERVICE_ACCOUNT" | "BASIC_WITH_JWT" | "COMPOSIO_LINK" | "CALCOM_AUTH" | "SNOWFLAKE";
1207
+ isComposioManaged: boolean;
1208
+ isDisabled: boolean;
1209
+ }>;
1210
+ userId: z.ZodString;
1211
+ data: z.ZodRecord<z.ZodString, z.ZodUnknown>;
1212
+ params: z.ZodRecord<z.ZodString, z.ZodUnknown>;
1213
+ status: z.ZodEnum<["ACTIVE", "INACTIVE", "DELETED", "INITIATED", "EXPIRED", "FAILED"]>;
1214
+ statusReason: z.ZodNullable<z.ZodString>;
1215
+ toolkit: z.ZodObject<{
1216
+ slug: z.ZodString;
1217
+ }, "strip", z.ZodTypeAny, {
1218
+ slug: string;
1219
+ }, {
1220
+ slug: string;
1221
+ }>;
1222
+ testRequestEndpoint: z.ZodOptional<z.ZodString>;
1223
+ isDisabled: z.ZodBoolean;
1224
+ createdAt: z.ZodString;
1225
+ updatedAt: z.ZodString;
1226
+ }, "strip", z.ZodTypeAny, {
1227
+ params: Record<string, unknown>;
1228
+ status: "ACTIVE" | "INACTIVE" | "DELETED" | "INITIATED" | "EXPIRED" | "FAILED";
1229
+ toolkit: {
1230
+ slug: string;
1231
+ };
1232
+ userId: string;
1233
+ data: Record<string, unknown>;
1234
+ createdAt: string;
1235
+ updatedAt: string;
1236
+ id: string;
1237
+ authConfig: {
1238
+ id: string;
1239
+ authScheme: "NO_AUTH" | "OAUTH2" | "OAUTH1" | "OAUTH1A" | "API_KEY" | "BASIC" | "BILLCOM_AUTH" | "BEARER_TOKEN" | "GOOGLE_SERVICE_ACCOUNT" | "BASIC_WITH_JWT" | "COMPOSIO_LINK" | "CALCOM_AUTH" | "SNOWFLAKE";
1240
+ isComposioManaged: boolean;
1241
+ isDisabled: boolean;
1242
+ };
1243
+ isDisabled: boolean;
1244
+ statusReason: string | null;
1245
+ testRequestEndpoint?: string | undefined;
1246
+ }, {
1247
+ params: Record<string, unknown>;
1248
+ status: "ACTIVE" | "INACTIVE" | "DELETED" | "INITIATED" | "EXPIRED" | "FAILED";
1249
+ toolkit: {
1250
+ slug: string;
1251
+ };
1252
+ userId: string;
1253
+ data: Record<string, unknown>;
1254
+ createdAt: string;
1255
+ updatedAt: string;
1256
+ id: string;
1257
+ authConfig: {
1258
+ id: string;
1259
+ authScheme: "NO_AUTH" | "OAUTH2" | "OAUTH1" | "OAUTH1A" | "API_KEY" | "BASIC" | "BILLCOM_AUTH" | "BEARER_TOKEN" | "GOOGLE_SERVICE_ACCOUNT" | "BASIC_WITH_JWT" | "COMPOSIO_LINK" | "CALCOM_AUTH" | "SNOWFLAKE";
1260
+ isComposioManaged: boolean;
1261
+ isDisabled: boolean;
1262
+ };
1263
+ isDisabled: boolean;
1264
+ statusReason: string | null;
1265
+ testRequestEndpoint?: string | undefined;
1266
+ }>;
1267
+ type ConnectedAccountRetrieveResponse = z.infer<typeof ConnectedAccountRetrieveResponseSchema>;
1268
+
1269
+ /**
1270
+ * @fileoverview Connection request class for Composio SDK, used to manage an initiated connection request.
1271
+ *
1272
+ * @author Musthaq Ahamad <musthaq@composio.dev>
1273
+ * @date 2025-05-05
1274
+ * @module ConnectionRequest
1275
+ */
1276
+
1277
+ declare class ConnectionRequest {
1278
+ private client;
1279
+ private connectedAccountId;
1280
+ private connectedAccountStatus;
1281
+ redirectUrl?: string | null;
1282
+ constructor(client: ComposioClient, connectedAccountId: string, connectedAccountStatus: ConnectedAccountStatus, redirectUrl?: string | null);
1283
+ /**
1284
+ * Transform the response from the Composio API to the SDK format
1285
+ * @param response
1286
+ * @returns
1287
+ */
1288
+ private transformResponse;
1289
+ /**
1290
+ * Wait for the connection to be established.
1291
+ * The function will poll the Composio API every second until the connection is established or the timeout is reached.
1292
+ * @param {number} timeout - The time in milliseconds to wait for the connection to be established. Default is 30 seconds.
1293
+ * @returns
1294
+ */
1295
+ waitForConnection(timeout?: number): Promise<ConnectedAccountRetrieveResponse>;
1296
+ }
1297
+
1156
1298
  /**
1157
1299
  * Toolkits class
1158
1300
  *
@@ -1196,6 +1338,15 @@ declare class Toolkits {
1196
1338
  * @returns {Promise<ToolkitRetrieveCategoriesResponse>} List of categories
1197
1339
  */
1198
1340
  listCategories(): Promise<ToolkitRetrieveCategoriesResponse>;
1341
+ /**
1342
+ * Authorizes a user to use a toolkit.
1343
+ * This method will create an auth config if one doesn't exist and initiate a connection request.
1344
+ * @param {string} userId - The user id of the user to authorize
1345
+ * @param {string} toolkitSlug - The slug of the toolkit to authorize
1346
+ * @param {string} authConfigId - The id of the auth config to use
1347
+ * @returns {Promise<ConnectionRequest>} The connection request object
1348
+ */
1349
+ authorize(userId: string, toolkitSlug: string): Promise<ConnectionRequest>;
1199
1350
  }
1200
1351
 
1201
1352
  type TriggerStatusEnum = "enable" | "disable";
@@ -1589,13 +1740,31 @@ declare const AuthConfigListResponseSchema: z.ZodObject<{
1589
1740
  nextCursor?: string | undefined;
1590
1741
  }>;
1591
1742
  type AuthConfigListResponse = z.infer<typeof AuthConfigListResponseSchema>;
1592
- declare const AuthConfigUpdateParamsSchema: z.ZodObject<{
1593
- credentials: z.ZodRecord<z.ZodString, z.ZodUnion<[z.ZodString, z.ZodNumber, z.ZodBoolean]>>;
1743
+ declare const AuthConfigUpdateParamsSchema: z.ZodDiscriminatedUnion<"type", [z.ZodObject<{
1744
+ credentials: z.ZodRecord<z.ZodString, z.ZodUnion<[z.ZodString, z.ZodUnknown]>>;
1745
+ type: z.ZodLiteral<"custom">;
1746
+ restrictToFollowingTools: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
1594
1747
  }, "strip", z.ZodTypeAny, {
1595
- credentials: Record<string, string | number | boolean>;
1748
+ type: "custom";
1749
+ credentials: Record<string, unknown>;
1750
+ restrictToFollowingTools?: string[] | undefined;
1596
1751
  }, {
1597
- credentials: Record<string, string | number | boolean>;
1598
- }>;
1752
+ type: "custom";
1753
+ credentials: Record<string, unknown>;
1754
+ restrictToFollowingTools?: string[] | undefined;
1755
+ }>, z.ZodObject<{
1756
+ scopes: z.ZodString;
1757
+ type: z.ZodLiteral<"default">;
1758
+ restrictToFollowingTools: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
1759
+ }, "strip", z.ZodTypeAny, {
1760
+ type: "default";
1761
+ scopes: string;
1762
+ restrictToFollowingTools?: string[] | undefined;
1763
+ }, {
1764
+ type: "default";
1765
+ scopes: string;
1766
+ restrictToFollowingTools?: string[] | undefined;
1767
+ }>]>;
1599
1768
  type AuthConfigUpdateParams = z.infer<typeof AuthConfigUpdateParamsSchema>;
1600
1769
 
1601
1770
  /**
@@ -1615,6 +1784,12 @@ type AuthConfigUpdateParams = z.infer<typeof AuthConfigUpdateParamsSchema>;
1615
1784
  declare class AuthConfigs {
1616
1785
  private client;
1617
1786
  constructor(client: ComposioClient);
1787
+ /**
1788
+ * Protected getter for the client instance.
1789
+ * This is primarily used for testing purposes.
1790
+ * @protected
1791
+ */
1792
+ protected getClient(): ComposioClient;
1618
1793
  private parseAuthConfigRetrieveResponse;
1619
1794
  /**
1620
1795
  * List all auth configs
@@ -1688,135 +1863,6 @@ declare class AuthConfigs {
1688
1863
  disable(nanoid: string): Promise<AuthConfigUpdateStatusResponse>;
1689
1864
  }
1690
1865
 
1691
- /**
1692
- * Connected Account create parameters
1693
- */
1694
- declare const ConnectedAccountStatuses: {
1695
- readonly ACTIVE: "ACTIVE";
1696
- readonly INACTIVE: "INACTIVE";
1697
- readonly PENDING: "DELETED";
1698
- readonly INITIATED: "INITIATED";
1699
- readonly EXPIRED: "EXPIRED";
1700
- readonly FAILED: "FAILED";
1701
- };
1702
- type ConnectedAccountStatus = (typeof ConnectedAccountStatuses)[keyof typeof ConnectedAccountStatuses];
1703
- type CreateConnectedAccountOptions = z.infer<typeof CreateConnectedAccountOptionsSchema>;
1704
- declare const CreateConnectedAccountOptionsSchema: z.ZodObject<{
1705
- redirectUrl: z.ZodOptional<z.ZodString>;
1706
- data: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
1707
- }, "strip", z.ZodTypeAny, {
1708
- data?: Record<string, unknown> | undefined;
1709
- redirectUrl?: string | undefined;
1710
- }, {
1711
- data?: Record<string, unknown> | undefined;
1712
- redirectUrl?: string | undefined;
1713
- }>;
1714
- type CreateConnectedAccountOptionsSchema = z.infer<typeof CreateConnectedAccountOptionsSchema>;
1715
- declare const ConnectedAccountRetrieveResponseSchema: z.ZodObject<{
1716
- id: z.ZodString;
1717
- authConfig: z.ZodObject<{
1718
- id: z.ZodString;
1719
- authScheme: z.ZodEnum<["OAUTH2", "OAUTH1", "OAUTH1A", "API_KEY", "BASIC", "BILLCOM_AUTH", "BEARER_TOKEN", "GOOGLE_SERVICE_ACCOUNT", "NO_AUTH", "BASIC_WITH_JWT", "COMPOSIO_LINK", "CALCOM_AUTH", "SNOWFLAKE"]>;
1720
- isComposioManaged: z.ZodBoolean;
1721
- isDisabled: z.ZodBoolean;
1722
- }, "strip", z.ZodTypeAny, {
1723
- id: string;
1724
- authScheme: "NO_AUTH" | "OAUTH2" | "OAUTH1" | "OAUTH1A" | "API_KEY" | "BASIC" | "BILLCOM_AUTH" | "BEARER_TOKEN" | "GOOGLE_SERVICE_ACCOUNT" | "BASIC_WITH_JWT" | "COMPOSIO_LINK" | "CALCOM_AUTH" | "SNOWFLAKE";
1725
- isComposioManaged: boolean;
1726
- isDisabled: boolean;
1727
- }, {
1728
- id: string;
1729
- authScheme: "NO_AUTH" | "OAUTH2" | "OAUTH1" | "OAUTH1A" | "API_KEY" | "BASIC" | "BILLCOM_AUTH" | "BEARER_TOKEN" | "GOOGLE_SERVICE_ACCOUNT" | "BASIC_WITH_JWT" | "COMPOSIO_LINK" | "CALCOM_AUTH" | "SNOWFLAKE";
1730
- isComposioManaged: boolean;
1731
- isDisabled: boolean;
1732
- }>;
1733
- userId: z.ZodString;
1734
- data: z.ZodRecord<z.ZodString, z.ZodUnknown>;
1735
- params: z.ZodRecord<z.ZodString, z.ZodUnknown>;
1736
- status: z.ZodEnum<["ACTIVE", "INACTIVE", "DELETED", "INITIATED", "EXPIRED", "FAILED"]>;
1737
- statusReason: z.ZodNullable<z.ZodString>;
1738
- toolkit: z.ZodObject<{
1739
- slug: z.ZodString;
1740
- }, "strip", z.ZodTypeAny, {
1741
- slug: string;
1742
- }, {
1743
- slug: string;
1744
- }>;
1745
- testRequestEndpoint: z.ZodOptional<z.ZodString>;
1746
- isDisabled: z.ZodBoolean;
1747
- createdAt: z.ZodString;
1748
- updatedAt: z.ZodString;
1749
- }, "strip", z.ZodTypeAny, {
1750
- params: Record<string, unknown>;
1751
- status: "ACTIVE" | "INACTIVE" | "DELETED" | "INITIATED" | "EXPIRED" | "FAILED";
1752
- toolkit: {
1753
- slug: string;
1754
- };
1755
- userId: string;
1756
- data: Record<string, unknown>;
1757
- id: string;
1758
- createdAt: string;
1759
- updatedAt: string;
1760
- authConfig: {
1761
- id: string;
1762
- authScheme: "NO_AUTH" | "OAUTH2" | "OAUTH1" | "OAUTH1A" | "API_KEY" | "BASIC" | "BILLCOM_AUTH" | "BEARER_TOKEN" | "GOOGLE_SERVICE_ACCOUNT" | "BASIC_WITH_JWT" | "COMPOSIO_LINK" | "CALCOM_AUTH" | "SNOWFLAKE";
1763
- isComposioManaged: boolean;
1764
- isDisabled: boolean;
1765
- };
1766
- isDisabled: boolean;
1767
- statusReason: string | null;
1768
- testRequestEndpoint?: string | undefined;
1769
- }, {
1770
- params: Record<string, unknown>;
1771
- status: "ACTIVE" | "INACTIVE" | "DELETED" | "INITIATED" | "EXPIRED" | "FAILED";
1772
- toolkit: {
1773
- slug: string;
1774
- };
1775
- userId: string;
1776
- data: Record<string, unknown>;
1777
- id: string;
1778
- createdAt: string;
1779
- updatedAt: string;
1780
- authConfig: {
1781
- id: string;
1782
- authScheme: "NO_AUTH" | "OAUTH2" | "OAUTH1" | "OAUTH1A" | "API_KEY" | "BASIC" | "BILLCOM_AUTH" | "BEARER_TOKEN" | "GOOGLE_SERVICE_ACCOUNT" | "BASIC_WITH_JWT" | "COMPOSIO_LINK" | "CALCOM_AUTH" | "SNOWFLAKE";
1783
- isComposioManaged: boolean;
1784
- isDisabled: boolean;
1785
- };
1786
- isDisabled: boolean;
1787
- statusReason: string | null;
1788
- testRequestEndpoint?: string | undefined;
1789
- }>;
1790
- type ConnectedAccountRetrieveResponse = z.infer<typeof ConnectedAccountRetrieveResponseSchema>;
1791
-
1792
- /**
1793
- * @fileoverview Connection request class for Composio SDK, used to manage an initiated connection request.
1794
- *
1795
- * @author Musthaq Ahamad <musthaq@composio.dev>
1796
- * @date 2025-05-05
1797
- * @module ConnectionRequest
1798
- */
1799
-
1800
- declare class ConnectionRequest {
1801
- private client;
1802
- private connectedAccountId;
1803
- private connectedAccountStatus;
1804
- constructor(client: ComposioClient, connectedAccountId: string, connectedAccountStatus: ConnectedAccountStatus);
1805
- /**
1806
- * Transform the response from the Composio API to the SDK format
1807
- * @param response
1808
- * @returns
1809
- */
1810
- private transformResponse;
1811
- /**
1812
- * Wait for the connection to be established.
1813
- * The function will poll the Composio API every second until the connection is established or the timeout is reached.
1814
- * @param {number} timeout - The time in milliseconds to wait for the connection to be established. Default is 30 seconds.
1815
- * @returns
1816
- */
1817
- waitForConnection(timeout?: number): Promise<ConnectedAccountRetrieveResponse>;
1818
- }
1819
-
1820
1866
  /**
1821
1867
  * @fileoverview Connected accounts class for Composio SDK, used to manage connected accounts of a user.
1822
1868
  *
@@ -1859,7 +1905,7 @@ declare class ConnectedAccounts {
1859
1905
  *
1860
1906
  * @link https://docs.composio.dev/reference/connected-accounts/create-connected-account
1861
1907
  */
1862
- create(userId: string, authConfigId: string, options?: CreateConnectedAccountOptions): Promise<ConnectionRequest>;
1908
+ initiate(userId: string, authConfigId: string, options?: CreateConnectedAccountOptions): Promise<ConnectionRequest>;
1863
1909
  /**
1864
1910
  * Get a connected account by nanoid
1865
1911
  * @param {string} nanoid - Unique identifier of the connected account
@@ -1949,7 +1995,7 @@ declare class OpenAIToolset extends BaseNonAgenticToolset<OpenAiToolCollection,
1949
1995
  * @param {string} userId - The user id.
1950
1996
  * @returns {Promise<string>} The result of the tool call.
1951
1997
  */
1952
- executeToolCall(userId: string, tool: OpenAI.ChatCompletionMessageToolCall, options: ExecuteToolFnOptions, modifiers?: ExecuteToolModifiers): Promise<string>;
1998
+ executeToolCall(userId: string, tool: OpenAI.ChatCompletionMessageToolCall, options?: ExecuteToolFnOptions, modifiers?: ExecuteToolModifiers): Promise<string>;
1953
1999
  /**
1954
2000
  * Handle the tool call from the assistant.
1955
2001
  *
@@ -1957,7 +2003,7 @@ declare class OpenAIToolset extends BaseNonAgenticToolset<OpenAiToolCollection,
1957
2003
  * @param {string} userId - The user id.
1958
2004
  * @returns {Promise<string[]>} The results of the tool call.
1959
2005
  */
1960
- handleToolCall(userId: string, chatCompletion: OpenAI.ChatCompletion, options: ExecuteToolFnOptions, modifiers?: ExecuteToolModifiers): Promise<string[]>;
2006
+ handleToolCall(userId: string, chatCompletion: OpenAI.ChatCompletion, options?: ExecuteToolFnOptions, modifiers?: ExecuteToolModifiers): Promise<string[]>;
1961
2007
  /**
1962
2008
  * Handles all the tool calls from the assistant.
1963
2009
  *
@@ -1965,7 +2011,7 @@ declare class OpenAIToolset extends BaseNonAgenticToolset<OpenAiToolCollection,
1965
2011
  * @param {string} userId - The user id.
1966
2012
  * @returns {Promise<OpenAI.Beta.Threads.Runs.RunSubmitToolOutputsParams.ToolOutput[]>} The tool outputs.
1967
2013
  */
1968
- handleAssistantMessage(userId: string, run: OpenAI.Beta.Threads.Run, options: ExecuteToolFnOptions, modifiers?: ExecuteToolModifiers): Promise<OpenAI.Beta.Threads.Runs.RunSubmitToolOutputsParams.ToolOutput[]>;
2014
+ handleAssistantMessage(userId: string, run: OpenAI.Beta.Threads.Run, options?: ExecuteToolFnOptions, modifiers?: ExecuteToolModifiers): Promise<OpenAI.Beta.Threads.Runs.RunSubmitToolOutputsParams.ToolOutput[]>;
1969
2015
  /**
1970
2016
  * Waits for the assistant stream and handles the tool calls.
1971
2017
  *
@@ -1975,7 +2021,7 @@ declare class OpenAIToolset extends BaseNonAgenticToolset<OpenAiToolCollection,
1975
2021
  * @param {string} userId - The user id.
1976
2022
  * @returns {AsyncGenerator<OpenAI.Beta.Assistants.AssistantStreamEvent, void, unknown>} The run stream.
1977
2023
  */
1978
- waitAndHandleAssistantStreamToolCalls(userId: string, client: OpenAI, runStream: Stream<OpenAI.Beta.Assistants.AssistantStreamEvent>, thread: OpenAI.Beta.Threads.Thread, options: ExecuteToolFnOptions, modifiers?: ExecuteToolModifiers): AsyncGenerator<OpenAI.Beta.Assistants.AssistantStreamEvent, void, unknown>;
2024
+ waitAndHandleAssistantStreamToolCalls(userId: string, client: OpenAI, runStream: Stream<OpenAI.Beta.Assistants.AssistantStreamEvent>, thread: OpenAI.Beta.Threads.Thread, options?: ExecuteToolFnOptions, modifiers?: ExecuteToolModifiers): AsyncGenerator<OpenAI.Beta.Assistants.AssistantStreamEvent, void, unknown>;
1979
2025
  /**
1980
2026
  * Waits for the assistant tool calls and handles them.
1981
2027
  *
@@ -1985,7 +2031,7 @@ declare class OpenAIToolset extends BaseNonAgenticToolset<OpenAiToolCollection,
1985
2031
  * @param {string} userId - The user id.
1986
2032
  * @returns {Promise<OpenAI.Beta.Threads.Run>} The run object.
1987
2033
  */
1988
- waitAndHandleAssistantToolCalls(userId: string, client: OpenAI, run: OpenAI.Beta.Threads.Run, thread: OpenAI.Beta.Threads.Thread, options: ExecuteToolFnOptions, modifiers?: ExecuteToolModifiers): Promise<OpenAI.Beta.Threads.Runs.Run>;
2034
+ waitAndHandleAssistantToolCalls(userId: string, client: OpenAI, run: OpenAI.Beta.Threads.Run, thread: OpenAI.Beta.Threads.Thread, options?: ExecuteToolFnOptions, modifiers?: ExecuteToolModifiers): Promise<OpenAI.Beta.Threads.Runs.Run>;
1989
2035
  }
1990
2036
 
1991
2037
  type ComposioConfig<TToolset extends BaseComposioToolset<unknown, unknown> = OpenAIToolset> = {
@@ -2022,7 +2068,7 @@ declare class Composio<TToolset extends BaseComposioToolset<unknown, unknown> =
2022
2068
  authConfigs: AuthConfigs;
2023
2069
  createAuthConfig: AuthConfigs['create'];
2024
2070
  connectedAccounts: ConnectedAccounts;
2025
- createConnectedAccount: ConnectedAccounts['create'];
2071
+ initiateConnection: ConnectedAccounts['initiate'];
2026
2072
  /**
2027
2073
  * @param {Object} config Configuration for the Composio SDK.
2028
2074
  * @param {string} config.apiKey The API key for the Composio SDK.