@composio/client 0.1.0-alpha.75 → 0.1.0-alpha.76

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 (44) hide show
  1. package/CHANGELOG.md +10 -0
  2. package/package.json +1 -1
  3. package/resources/auth-configs.d.mts +0 -54
  4. package/resources/auth-configs.d.mts.map +1 -1
  5. package/resources/auth-configs.d.ts +0 -54
  6. package/resources/auth-configs.d.ts.map +1 -1
  7. package/resources/connected-accounts.d.mts +4 -89
  8. package/resources/connected-accounts.d.mts.map +1 -1
  9. package/resources/connected-accounts.d.ts +4 -89
  10. package/resources/connected-accounts.d.ts.map +1 -1
  11. package/resources/connected-accounts.js +4 -6
  12. package/resources/connected-accounts.js.map +1 -1
  13. package/resources/connected-accounts.mjs +4 -6
  14. package/resources/connected-accounts.mjs.map +1 -1
  15. package/resources/logs/triggers.d.mts +3 -5
  16. package/resources/logs/triggers.d.mts.map +1 -1
  17. package/resources/logs/triggers.d.ts +3 -5
  18. package/resources/logs/triggers.d.ts.map +1 -1
  19. package/resources/logs/triggers.js +3 -5
  20. package/resources/logs/triggers.js.map +1 -1
  21. package/resources/logs/triggers.mjs +3 -5
  22. package/resources/logs/triggers.mjs.map +1 -1
  23. package/resources/toolkits.d.mts +14 -0
  24. package/resources/toolkits.d.mts.map +1 -1
  25. package/resources/toolkits.d.ts +14 -0
  26. package/resources/toolkits.d.ts.map +1 -1
  27. package/resources/trigger-instances/trigger-instances.d.mts +10 -14
  28. package/resources/trigger-instances/trigger-instances.d.mts.map +1 -1
  29. package/resources/trigger-instances/trigger-instances.d.ts +10 -14
  30. package/resources/trigger-instances/trigger-instances.d.ts.map +1 -1
  31. package/resources/trigger-instances/trigger-instances.js +3 -2
  32. package/resources/trigger-instances/trigger-instances.js.map +1 -1
  33. package/resources/trigger-instances/trigger-instances.mjs +3 -2
  34. package/resources/trigger-instances/trigger-instances.mjs.map +1 -1
  35. package/src/resources/auth-configs.ts +0 -60
  36. package/src/resources/connected-accounts.ts +4 -102
  37. package/src/resources/logs/triggers.ts +3 -5
  38. package/src/resources/toolkits.ts +17 -0
  39. package/src/resources/trigger-instances/trigger-instances.ts +10 -16
  40. package/src/version.ts +1 -1
  41. package/version.d.mts +1 -1
  42. package/version.d.ts +1 -1
  43. package/version.js +1 -1
  44. package/version.mjs +1 -1
@@ -129,16 +129,14 @@ export class ConnectedAccounts extends APIResource {
129
129
  }
130
130
 
131
131
  /**
132
+ * DEPRECATED: Manual refresh of a connected account is deprecated. Composio
133
+ * automatically refreshes credentials in the background as they approach expiry,
134
+ * so this endpoint is no longer required and may be removed in a future release.
132
135
  * Initiates a new authentication flow for a connected account when credentials
133
136
  * have expired or become invalid. This may generate a new authentication URL for
134
137
  * OAuth flows or refresh tokens for other auth schemes.
135
138
  *
136
- * @example
137
- * ```ts
138
- * const response = await client.connectedAccounts.refresh(
139
- * 'ca_1a2b3c4d5e6f',
140
- * );
141
- * ```
139
+ * @deprecated
142
140
  */
143
141
  refresh(
144
142
  nanoid: string,
@@ -216,12 +214,6 @@ export interface ConnectedAccountCreateResponse {
216
214
  */
217
215
  status: 'INITIALIZING' | 'INITIATED' | 'ACTIVE' | 'FAILED' | 'EXPIRED' | 'INACTIVE' | 'REVOKED';
218
216
 
219
- /**
220
- * @deprecated DEPRECATED: This field will be removed in a future version. Please
221
- * use id and auth_config.id instead.
222
- */
223
- deprecated?: ConnectedAccountCreateResponse.Deprecated;
224
-
225
217
  /**
226
218
  * Experimental features - not stable, may be modified or removed in future
227
219
  * versions.
@@ -4637,22 +4629,6 @@ export namespace ConnectedAccountCreateResponse {
4637
4629
  }
4638
4630
  }
4639
4631
 
4640
- /**
4641
- * @deprecated DEPRECATED: This field will be removed in a future version. Please
4642
- * use id and auth_config.id instead.
4643
- */
4644
- export interface Deprecated {
4645
- /**
4646
- * The uuid of the auth config
4647
- */
4648
- authConfigUuid: string;
4649
-
4650
- /**
4651
- * The uuid of the connected account
4652
- */
4653
- uuid: string;
4654
- }
4655
-
4656
4632
  /**
4657
4633
  * Experimental features - not stable, may be modified or removed in future
4658
4634
  * versions.
@@ -4776,11 +4752,6 @@ export interface ConnectedAccountRetrieveResponse {
4776
4752
  */
4777
4753
  word_id: string | null;
4778
4754
 
4779
- /**
4780
- * @deprecated
4781
- */
4782
- deprecated?: ConnectedAccountRetrieveResponse.Deprecated;
4783
-
4784
4755
  /**
4785
4756
  * Experimental features - not stable, may be modified or removed in future
4786
4757
  * versions.
@@ -4841,23 +4812,6 @@ export namespace ConnectedAccountRetrieveResponse {
4841
4812
  * Whether the auth config is disabled
4842
4813
  */
4843
4814
  is_disabled: boolean;
4844
-
4845
- /**
4846
- * @deprecated
4847
- */
4848
- deprecated?: AuthConfig.Deprecated;
4849
- }
4850
-
4851
- export namespace AuthConfig {
4852
- /**
4853
- * @deprecated
4854
- */
4855
- export interface Deprecated {
4856
- /**
4857
- * The uuid of the auth config
4858
- */
4859
- uuid: string;
4860
- }
4861
4815
  }
4862
4816
 
4863
4817
  export interface UnionMember0 {
@@ -9274,21 +9228,6 @@ export namespace ConnectedAccountRetrieveResponse {
9274
9228
  slug: string;
9275
9229
  }
9276
9230
 
9277
- /**
9278
- * @deprecated
9279
- */
9280
- export interface Deprecated {
9281
- /**
9282
- * The labels of the connection
9283
- */
9284
- labels: Array<string>;
9285
-
9286
- /**
9287
- * The uuid of the connection
9288
- */
9289
- uuid: string;
9290
- }
9291
-
9292
9231
  /**
9293
9232
  * Experimental features - not stable, may be modified or removed in future
9294
9233
  * versions.
@@ -9419,11 +9358,6 @@ export namespace ConnectedAccountListResponse {
9419
9358
  */
9420
9359
  word_id: string | null;
9421
9360
 
9422
- /**
9423
- * @deprecated
9424
- */
9425
- deprecated?: Item.Deprecated;
9426
-
9427
9361
  /**
9428
9362
  * Experimental features - not stable, may be modified or removed in future
9429
9363
  * versions.
@@ -9471,23 +9405,6 @@ export namespace ConnectedAccountListResponse {
9471
9405
  * Whether the auth config is disabled
9472
9406
  */
9473
9407
  is_disabled: boolean;
9474
-
9475
- /**
9476
- * @deprecated
9477
- */
9478
- deprecated?: AuthConfig.Deprecated;
9479
- }
9480
-
9481
- export namespace AuthConfig {
9482
- /**
9483
- * @deprecated
9484
- */
9485
- export interface Deprecated {
9486
- /**
9487
- * The uuid of the auth config
9488
- */
9489
- uuid: string;
9490
- }
9491
9408
  }
9492
9409
 
9493
9410
  export interface UnionMember0 {
@@ -13904,21 +13821,6 @@ export namespace ConnectedAccountListResponse {
13904
13821
  slug: string;
13905
13822
  }
13906
13823
 
13907
- /**
13908
- * @deprecated
13909
- */
13910
- export interface Deprecated {
13911
- /**
13912
- * The labels of the connection
13913
- */
13914
- labels: Array<string>;
13915
-
13916
- /**
13917
- * The uuid of the connection
13918
- */
13919
- uuid: string;
13920
- }
13921
-
13922
13824
  /**
13923
13825
  * Experimental features - not stable, may be modified or removed in future
13924
13826
  * versions.
@@ -10,12 +10,10 @@ import { path } from '../../internal/utils/path';
10
10
  */
11
11
  export class Triggers extends APIResource {
12
12
  /**
13
- * Get detailed trigger log by ID
13
+ * DEPRECATED: This endpoint has declining traffic and will be removed in a future
14
+ * version.
14
15
  *
15
- * @example
16
- * ```ts
17
- * const trigger = await client.logs.triggers.retrieve('id');
18
- * ```
16
+ * @deprecated
19
17
  */
20
18
  retrieve(id: string, options?: RequestOptions): APIPromise<TriggerRetrieveResponse> {
21
19
  return this._client.get(path`/api/v3.1/internal/trigger/log/${id}`, options);
@@ -86,6 +86,12 @@ export interface ToolkitRetrieveResponse {
86
86
  */
87
87
  slug: string;
88
88
 
89
+ /**
90
+ * Toolkit provenance: "native" for Composio-managed toolkits, "custom" for a
91
+ * project-registered custom (MCP) toolkit
92
+ */
93
+ type: 'native' | 'custom';
94
+
89
95
  /**
90
96
  * Complete authentication configuration details for each supported auth method
91
97
  */
@@ -455,6 +461,12 @@ export namespace ToolkitListResponse {
455
461
  */
456
462
  slug: string;
457
463
 
464
+ /**
465
+ * Toolkit provenance: "native" for Composio-managed toolkits, "custom" for a
466
+ * project-registered custom (MCP) toolkit
467
+ */
468
+ type: 'native' | 'custom';
469
+
458
470
  /**
459
471
  * URL to a guide page with authentication setup instructions for this toolkit
460
472
  */
@@ -624,6 +636,11 @@ export interface ToolkitListParams {
624
636
  * Sort order for returned toolkits
625
637
  */
626
638
  sort_by?: 'usage' | 'alphabetically';
639
+
640
+ /**
641
+ * Filter toolkits by provenance (alias over managed_by)
642
+ */
643
+ type?: 'native' | 'custom' | 'all';
627
644
  }
628
645
 
629
646
  export declare namespace Toolkits {
@@ -35,8 +35,9 @@ export class TriggerInstances extends APIResource {
35
35
  * Creates a new trigger instance or updates an existing one with the same
36
36
  * configuration. Triggers listen for events from external services (webhooks or
37
37
  * polling) and can invoke your workflows. If a matching trigger already exists and
38
- * is disabled, it will be re-enabled. Requires a connected account ID to associate
39
- * the trigger with a specific user connection.
38
+ * is disabled, it will be re-enabled. Provide either a connected_account_id to pin
39
+ * a specific user connection, or a user_id to auto-resolve the first active
40
+ * connection for that user and the trigger's toolkit.
40
41
  *
41
42
  * @example
42
43
  * ```ts
@@ -183,17 +184,6 @@ export interface TriggerInstanceUpsertResponse {
183
184
  * ID of the updated trigger
184
185
  */
185
186
  trigger_id: string;
186
-
187
- deprecated?: TriggerInstanceUpsertResponse.Deprecated;
188
- }
189
-
190
- export namespace TriggerInstanceUpsertResponse {
191
- export interface Deprecated {
192
- /**
193
- * ID of the updated trigger
194
- */
195
- uuid: string;
196
- }
197
187
  }
198
188
 
199
189
  export interface TriggerInstanceListActiveParams {
@@ -286,7 +276,8 @@ export interface TriggerInstanceListActiveParams {
286
276
 
287
277
  export interface TriggerInstanceUpsertParams {
288
278
  /**
289
- * Connected account nanoid
279
+ * Connected account nanoid. Optional when user_id is provided — the first active
280
+ * connection for that user and the trigger's toolkit is auto-resolved.
290
281
  */
291
282
  connected_account_id?: string;
292
283
 
@@ -314,8 +305,11 @@ export interface TriggerInstanceUpsertParams {
314
305
  triggerConfig?: { [key: string]: unknown };
315
306
 
316
307
  /**
317
- * The user id (entity id) that owns the connected account. When the project has
318
- * 2FA enabled, this is validated against the owner of connected_account_id.
308
+ * The user id (entity id) that owns the connection. When connected_account_id is
309
+ * omitted, the first active connection for this user and the trigger's toolkit is
310
+ * auto-resolved (same as tool execution). When connected_account_id is also
311
+ * provided and the project has 2FA enabled, user_id is validated against the owner
312
+ * of that connection.
319
313
  */
320
314
  user_id?: string;
321
315
 
package/src/version.ts CHANGED
@@ -1 +1 @@
1
- export const VERSION = '0.1.0-alpha.75'; // x-release-please-version
1
+ export const VERSION = '0.1.0-alpha.76'; // x-release-please-version
package/version.d.mts CHANGED
@@ -1,2 +1,2 @@
1
- export declare const VERSION = "0.1.0-alpha.75";
1
+ export declare const VERSION = "0.1.0-alpha.76";
2
2
  //# sourceMappingURL=version.d.mts.map
package/version.d.ts CHANGED
@@ -1,2 +1,2 @@
1
- export declare const VERSION = "0.1.0-alpha.75";
1
+ export declare const VERSION = "0.1.0-alpha.76";
2
2
  //# sourceMappingURL=version.d.ts.map
package/version.js CHANGED
@@ -1,5 +1,5 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.VERSION = void 0;
4
- exports.VERSION = '0.1.0-alpha.75'; // x-release-please-version
4
+ exports.VERSION = '0.1.0-alpha.76'; // x-release-please-version
5
5
  //# sourceMappingURL=version.js.map
package/version.mjs CHANGED
@@ -1,2 +1,2 @@
1
- export const VERSION = '0.1.0-alpha.75'; // x-release-please-version
1
+ export const VERSION = '0.1.0-alpha.76'; // x-release-please-version
2
2
  //# sourceMappingURL=version.mjs.map