@composio/client 0.1.0-alpha.25 → 0.1.0-alpha.27
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/CHANGELOG.md +36 -0
- package/client.d.mts +7 -5
- package/client.d.mts.map +1 -1
- package/client.d.ts +7 -5
- package/client.d.ts.map +1 -1
- package/client.js +4 -10
- package/client.js.map +1 -1
- package/client.mjs +4 -10
- package/client.mjs.map +1 -1
- package/internal/request-options.d.mts +42 -0
- package/internal/request-options.d.mts.map +1 -1
- package/internal/request-options.d.ts +42 -0
- package/internal/request-options.d.ts.map +1 -1
- package/internal/request-options.js.map +1 -1
- package/internal/request-options.mjs.map +1 -1
- package/internal/types.d.mts +8 -6
- package/internal/types.d.mts.map +1 -1
- package/internal/types.d.ts +8 -6
- package/internal/types.d.ts.map +1 -1
- package/internal/uploads.js +1 -1
- package/internal/uploads.js.map +1 -1
- package/internal/uploads.mjs +1 -1
- package/internal/uploads.mjs.map +1 -1
- package/internal/utils/log.js +1 -1
- package/internal/utils/log.js.map +1 -1
- package/internal/utils/log.mjs +1 -1
- package/internal/utils/log.mjs.map +1 -1
- package/internal/utils/path.d.mts.map +1 -1
- package/internal/utils/path.d.ts.map +1 -1
- package/internal/utils/path.js +26 -5
- package/internal/utils/path.js.map +1 -1
- package/internal/utils/path.mjs +26 -5
- package/internal/utils/path.mjs.map +1 -1
- package/package.json +1 -1
- package/resources/auth-configs.d.mts +22 -4
- package/resources/auth-configs.d.mts.map +1 -1
- package/resources/auth-configs.d.ts +22 -4
- package/resources/auth-configs.d.ts.map +1 -1
- package/resources/{v3/cli.d.mts → cli.d.mts} +36 -36
- package/resources/cli.d.mts.map +1 -0
- package/resources/{v3/cli.d.ts → cli.d.ts} +36 -36
- package/resources/cli.d.ts.map +1 -0
- package/resources/{v3/cli.js → cli.js} +16 -16
- package/resources/cli.js.map +1 -0
- package/resources/{v3/cli.mjs → cli.mjs} +16 -16
- package/resources/cli.mjs.map +1 -0
- package/resources/connected-accounts.d.mts +2153 -633
- package/resources/connected-accounts.d.mts.map +1 -1
- package/resources/connected-accounts.d.ts +2153 -633
- package/resources/connected-accounts.d.ts.map +1 -1
- package/resources/connected-accounts.js +7 -2
- package/resources/connected-accounts.js.map +1 -1
- package/resources/connected-accounts.mjs +7 -2
- package/resources/connected-accounts.mjs.map +1 -1
- package/resources/files.d.mts +14 -1
- package/resources/files.d.mts.map +1 -1
- package/resources/files.d.ts +14 -1
- package/resources/files.d.ts.map +1 -1
- package/resources/index.d.mts +2 -2
- package/resources/index.d.mts.map +1 -1
- package/resources/index.d.ts +2 -2
- package/resources/index.d.ts.map +1 -1
- package/resources/index.js +3 -3
- package/resources/index.js.map +1 -1
- package/resources/index.mjs +1 -1
- package/resources/index.mjs.map +1 -1
- package/resources/mcp/mcp.d.mts +5 -9
- package/resources/mcp/mcp.d.mts.map +1 -1
- package/resources/mcp/mcp.d.ts +5 -9
- package/resources/mcp/mcp.d.ts.map +1 -1
- package/resources/mcp/mcp.js +1 -1
- package/resources/mcp/mcp.js.map +1 -1
- package/resources/mcp/mcp.mjs +1 -1
- package/resources/mcp/mcp.mjs.map +1 -1
- package/resources/toolkits.d.mts +17 -2
- package/resources/toolkits.d.mts.map +1 -1
- package/resources/toolkits.d.ts +17 -2
- package/resources/toolkits.d.ts.map +1 -1
- package/resources/tools.d.mts +9 -4
- package/resources/tools.d.mts.map +1 -1
- package/resources/tools.d.ts +9 -4
- package/resources/tools.d.ts.map +1 -1
- package/resources/trigger-instances/trigger-instances.d.mts +12 -3
- package/resources/trigger-instances/trigger-instances.d.mts.map +1 -1
- package/resources/trigger-instances/trigger-instances.d.ts +12 -3
- package/resources/trigger-instances/trigger-instances.d.ts.map +1 -1
- package/resources/trigger-instances/trigger-instances.js.map +1 -1
- package/resources/trigger-instances/trigger-instances.mjs.map +1 -1
- package/resources/triggers-types.d.mts +8 -3
- package/resources/triggers-types.d.mts.map +1 -1
- package/resources/triggers-types.d.ts +8 -3
- package/resources/triggers-types.d.ts.map +1 -1
- package/src/client.ts +23 -14
- package/src/internal/request-options.ts +53 -0
- package/src/internal/types.ts +9 -6
- package/src/internal/uploads.ts +1 -1
- package/src/internal/utils/log.ts +1 -1
- package/src/internal/utils/path.ts +32 -7
- package/src/resources/auth-configs.ts +27 -4
- package/src/resources/{v3/cli.ts → cli.ts} +39 -42
- package/src/resources/connected-accounts.ts +4045 -1211
- package/src/resources/files.ts +18 -1
- package/src/resources/index.ts +9 -1
- package/src/resources/mcp/mcp.ts +6 -11
- package/src/resources/toolkits.ts +23 -2
- package/src/resources/tools.ts +11 -4
- package/src/resources/trigger-instances/trigger-instances.ts +15 -3
- package/src/resources/triggers-types.ts +10 -3
- package/src/version.ts +1 -1
- package/version.d.mts +1 -1
- package/version.d.ts +1 -1
- package/version.js +1 -1
- package/version.mjs +1 -1
- package/resources/v3/auth/auth.d.mts +0 -10
- package/resources/v3/auth/auth.d.mts.map +0 -1
- package/resources/v3/auth/auth.d.ts +0 -10
- package/resources/v3/auth/auth.d.ts.map +0 -1
- package/resources/v3/auth/auth.js +0 -17
- package/resources/v3/auth/auth.js.map +0 -1
- package/resources/v3/auth/auth.mjs +0 -12
- package/resources/v3/auth/auth.mjs.map +0 -1
- package/resources/v3/auth/index.d.mts +0 -3
- package/resources/v3/auth/index.d.mts.map +0 -1
- package/resources/v3/auth/index.d.ts +0 -3
- package/resources/v3/auth/index.d.ts.map +0 -1
- package/resources/v3/auth/index.js +0 -9
- package/resources/v3/auth/index.js.map +0 -1
- package/resources/v3/auth/index.mjs +0 -4
- package/resources/v3/auth/index.mjs.map +0 -1
- package/resources/v3/auth/session.d.mts +0 -246
- package/resources/v3/auth/session.d.mts.map +0 -1
- package/resources/v3/auth/session.d.ts +0 -246
- package/resources/v3/auth/session.d.ts.map +0 -1
- package/resources/v3/auth/session.js +0 -25
- package/resources/v3/auth/session.js.map +0 -1
- package/resources/v3/auth/session.mjs +0 -21
- package/resources/v3/auth/session.mjs.map +0 -1
- package/resources/v3/auth.d.mts +0 -2
- package/resources/v3/auth.d.mts.map +0 -1
- package/resources/v3/auth.d.ts +0 -2
- package/resources/v3/auth.d.ts.map +0 -1
- package/resources/v3/auth.js +0 -6
- package/resources/v3/auth.js.map +0 -1
- package/resources/v3/auth.mjs +0 -3
- package/resources/v3/auth.mjs.map +0 -1
- package/resources/v3/cli.d.mts.map +0 -1
- package/resources/v3/cli.d.ts.map +0 -1
- package/resources/v3/cli.js.map +0 -1
- package/resources/v3/cli.mjs.map +0 -1
- package/resources/v3/index.d.mts +0 -5
- package/resources/v3/index.d.mts.map +0 -1
- package/resources/v3/index.d.ts +0 -5
- package/resources/v3/index.d.ts.map +0 -1
- package/resources/v3/index.js +0 -13
- package/resources/v3/index.js.map +0 -1
- package/resources/v3/index.mjs +0 -6
- package/resources/v3/index.mjs.map +0 -1
- package/resources/v3/internal/action-execution.d.mts +0 -169
- package/resources/v3/internal/action-execution.d.mts.map +0 -1
- package/resources/v3/internal/action-execution.d.ts +0 -169
- package/resources/v3/internal/action-execution.d.ts.map +0 -1
- package/resources/v3/internal/action-execution.js +0 -38
- package/resources/v3/internal/action-execution.js.map +0 -1
- package/resources/v3/internal/action-execution.mjs +0 -34
- package/resources/v3/internal/action-execution.mjs.map +0 -1
- package/resources/v3/internal/index.d.mts +0 -4
- package/resources/v3/internal/index.d.mts.map +0 -1
- package/resources/v3/internal/index.d.ts +0 -4
- package/resources/v3/internal/index.d.ts.map +0 -1
- package/resources/v3/internal/index.js +0 -11
- package/resources/v3/internal/index.js.map +0 -1
- package/resources/v3/internal/index.mjs +0 -5
- package/resources/v3/internal/index.mjs.map +0 -1
- package/resources/v3/internal/internal.d.mts +0 -14
- package/resources/v3/internal/internal.d.mts.map +0 -1
- package/resources/v3/internal/internal.d.ts +0 -14
- package/resources/v3/internal/internal.d.ts.map +0 -1
- package/resources/v3/internal/internal.js +0 -21
- package/resources/v3/internal/internal.js.map +0 -1
- package/resources/v3/internal/internal.mjs +0 -16
- package/resources/v3/internal/internal.mjs.map +0 -1
- package/resources/v3/internal/trigger.d.mts +0 -84
- package/resources/v3/internal/trigger.d.mts.map +0 -1
- package/resources/v3/internal/trigger.d.ts +0 -84
- package/resources/v3/internal/trigger.d.ts.map +0 -1
- package/resources/v3/internal/trigger.js +0 -23
- package/resources/v3/internal/trigger.js.map +0 -1
- package/resources/v3/internal/trigger.mjs +0 -19
- package/resources/v3/internal/trigger.mjs.map +0 -1
- package/resources/v3/internal.d.mts +0 -2
- package/resources/v3/internal.d.mts.map +0 -1
- package/resources/v3/internal.d.ts +0 -2
- package/resources/v3/internal.d.ts.map +0 -1
- package/resources/v3/internal.js +0 -6
- package/resources/v3/internal.js.map +0 -1
- package/resources/v3/internal.mjs +0 -3
- package/resources/v3/internal.mjs.map +0 -1
- package/resources/v3/v3.d.mts +0 -18
- package/resources/v3/v3.d.mts.map +0 -1
- package/resources/v3/v3.d.ts +0 -18
- package/resources/v3/v3.d.ts.map +0 -1
- package/resources/v3/v3.js +0 -25
- package/resources/v3/v3.js.map +0 -1
- package/resources/v3/v3.mjs +0 -20
- package/resources/v3/v3.mjs.map +0 -1
- package/resources/v3.d.mts +0 -2
- package/resources/v3.d.mts.map +0 -1
- package/resources/v3.d.ts +0 -2
- package/resources/v3.d.ts.map +0 -1
- package/resources/v3.js +0 -6
- package/resources/v3.js.map +0 -1
- package/resources/v3.mjs +0 -3
- package/resources/v3.mjs.map +0 -1
- package/src/resources/v3/auth/auth.ts +0 -15
- package/src/resources/v3/auth/index.ts +0 -4
- package/src/resources/v3/auth/session.ts +0 -298
- package/src/resources/v3/auth.ts +0 -3
- package/src/resources/v3/index.ts +0 -13
- package/src/resources/v3/internal/action-execution.ts +0 -236
- package/src/resources/v3/internal/index.ts +0 -10
- package/src/resources/v3/internal/internal.ts +0 -35
- package/src/resources/v3/internal/trigger.ts +0 -122
- package/src/resources/v3/internal.ts +0 -3
- package/src/resources/v3/v3.ts +0 -41
- package/src/resources/v3.ts +0 -3
|
@@ -12,25 +12,43 @@ export function encodeURIPath(str: string) {
|
|
|
12
12
|
return str.replace(/[^A-Za-z0-9\-._~!$&'()*+,;=:@]+/g, encodeURIComponent);
|
|
13
13
|
}
|
|
14
14
|
|
|
15
|
+
const EMPTY = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.create(null));
|
|
16
|
+
|
|
15
17
|
export const createPathTagFunction = (pathEncoder = encodeURIPath) =>
|
|
16
18
|
function path(statics: readonly string[], ...params: readonly unknown[]): string {
|
|
17
19
|
// If there are no params, no processing is needed.
|
|
18
20
|
if (statics.length === 1) return statics[0]!;
|
|
19
21
|
|
|
20
22
|
let postPath = false;
|
|
23
|
+
const invalidSegments = [];
|
|
21
24
|
const path = statics.reduce((previousValue, currentValue, index) => {
|
|
22
25
|
if (/[?#]/.test(currentValue)) {
|
|
23
26
|
postPath = true;
|
|
24
27
|
}
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
28
|
+
const value = params[index];
|
|
29
|
+
let encoded = (postPath ? encodeURIComponent : pathEncoder)('' + value);
|
|
30
|
+
if (
|
|
31
|
+
index !== params.length &&
|
|
32
|
+
(value == null ||
|
|
33
|
+
(typeof value === 'object' &&
|
|
34
|
+
// handle values from other realms
|
|
35
|
+
value.toString ===
|
|
36
|
+
Object.getPrototypeOf(Object.getPrototypeOf((value as any).hasOwnProperty ?? EMPTY) ?? EMPTY)
|
|
37
|
+
?.toString))
|
|
38
|
+
) {
|
|
39
|
+
encoded = value + '';
|
|
40
|
+
invalidSegments.push({
|
|
41
|
+
start: previousValue.length + currentValue.length,
|
|
42
|
+
length: encoded.length,
|
|
43
|
+
error: `Value of type ${Object.prototype.toString
|
|
44
|
+
.call(value)
|
|
45
|
+
.slice(8, -1)} is not a valid path parameter`,
|
|
46
|
+
});
|
|
47
|
+
}
|
|
48
|
+
return previousValue + currentValue + (index === params.length ? '' : encoded);
|
|
30
49
|
}, '');
|
|
31
50
|
|
|
32
51
|
const pathOnly = path.split(/[?#]/, 1)[0]!;
|
|
33
|
-
const invalidSegments = [];
|
|
34
52
|
const invalidSegmentPattern = /(?<=^|\/)(?:\.|%2e){1,2}(?=\/|$)/gi;
|
|
35
53
|
let match;
|
|
36
54
|
|
|
@@ -39,9 +57,12 @@ export const createPathTagFunction = (pathEncoder = encodeURIPath) =>
|
|
|
39
57
|
invalidSegments.push({
|
|
40
58
|
start: match.index,
|
|
41
59
|
length: match[0].length,
|
|
60
|
+
error: `Value "${match[0]}" can\'t be safely passed as a path parameter`,
|
|
42
61
|
});
|
|
43
62
|
}
|
|
44
63
|
|
|
64
|
+
invalidSegments.sort((a, b) => a.start - b.start);
|
|
65
|
+
|
|
45
66
|
if (invalidSegments.length > 0) {
|
|
46
67
|
let lastEnd = 0;
|
|
47
68
|
const underline = invalidSegments.reduce((acc, segment) => {
|
|
@@ -51,7 +72,11 @@ export const createPathTagFunction = (pathEncoder = encodeURIPath) =>
|
|
|
51
72
|
return acc + spaces + arrows;
|
|
52
73
|
}, '');
|
|
53
74
|
|
|
54
|
-
throw new ComposioError(
|
|
75
|
+
throw new ComposioError(
|
|
76
|
+
`Path parameters result in path with invalid segments:\n${invalidSegments
|
|
77
|
+
.map((e) => e.error)
|
|
78
|
+
.join('\n')}\n${path}\n${underline}`,
|
|
79
|
+
);
|
|
55
80
|
}
|
|
56
81
|
|
|
57
82
|
return path;
|
|
@@ -279,11 +279,15 @@ export namespace AuthConfigRetrieveResponse {
|
|
|
279
279
|
export type AuthConfigUpdateResponse = unknown;
|
|
280
280
|
|
|
281
281
|
export interface AuthConfigListResponse {
|
|
282
|
+
current_page: number;
|
|
283
|
+
|
|
282
284
|
items: Array<AuthConfigListResponse.Item>;
|
|
283
285
|
|
|
284
|
-
|
|
286
|
+
total_items: number;
|
|
285
287
|
|
|
286
288
|
total_pages: number;
|
|
289
|
+
|
|
290
|
+
next_cursor?: string | null;
|
|
287
291
|
}
|
|
288
292
|
|
|
289
293
|
export namespace AuthConfigListResponse {
|
|
@@ -437,7 +441,7 @@ export interface AuthConfigCreateParams {
|
|
|
437
441
|
export namespace AuthConfigCreateParams {
|
|
438
442
|
export interface Toolkit {
|
|
439
443
|
/**
|
|
440
|
-
*
|
|
444
|
+
* Toolkit slug to create auth config for
|
|
441
445
|
*/
|
|
442
446
|
slug: string;
|
|
443
447
|
}
|
|
@@ -481,11 +485,27 @@ export namespace AuthConfigCreateParams {
|
|
|
481
485
|
*/
|
|
482
486
|
name?: string;
|
|
483
487
|
|
|
488
|
+
proxy_config?: UnionMember1.ProxyConfig;
|
|
489
|
+
|
|
484
490
|
/**
|
|
485
491
|
* The actions that the user can perform on the auth config
|
|
486
492
|
*/
|
|
487
493
|
restrict_to_following_tools?: Array<string>;
|
|
488
494
|
}
|
|
495
|
+
|
|
496
|
+
export namespace UnionMember1 {
|
|
497
|
+
export interface ProxyConfig {
|
|
498
|
+
/**
|
|
499
|
+
* The url of the auth proxy
|
|
500
|
+
*/
|
|
501
|
+
proxy_url: string;
|
|
502
|
+
|
|
503
|
+
/**
|
|
504
|
+
* The auth key for the auth proxy
|
|
505
|
+
*/
|
|
506
|
+
proxy_auth_key?: string;
|
|
507
|
+
}
|
|
508
|
+
}
|
|
489
509
|
}
|
|
490
510
|
|
|
491
511
|
export type AuthConfigUpdateParams = AuthConfigUpdateParams.Variant0 | AuthConfigUpdateParams.Variant1;
|
|
@@ -510,7 +530,10 @@ export declare namespace AuthConfigUpdateParams {
|
|
|
510
530
|
|
|
511
531
|
export interface AuthConfigListParams {
|
|
512
532
|
/**
|
|
513
|
-
* The cursor
|
|
533
|
+
* Cursor for pagination. The cursor is a base64 encoded string of the page and
|
|
534
|
+
* limit. The page is the page number and the limit is the number of items per
|
|
535
|
+
* page. The cursor is used to paginate through the items. The cursor is not
|
|
536
|
+
* required for the first page.
|
|
514
537
|
*/
|
|
515
538
|
cursor?: string;
|
|
516
539
|
|
|
@@ -527,7 +550,7 @@ export interface AuthConfigListParams {
|
|
|
527
550
|
is_composio_managed?: string | boolean;
|
|
528
551
|
|
|
529
552
|
/**
|
|
530
|
-
*
|
|
553
|
+
* Number of items per page
|
|
531
554
|
*/
|
|
532
555
|
limit?: number | null;
|
|
533
556
|
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
2
|
|
|
3
|
-
import { APIResource } from '
|
|
4
|
-
import { APIPromise } from '
|
|
5
|
-
import { RequestOptions } from '
|
|
3
|
+
import { APIResource } from '../core/resource';
|
|
4
|
+
import { APIPromise } from '../core/api-promise';
|
|
5
|
+
import { RequestOptions } from '../internal/request-options';
|
|
6
6
|
|
|
7
7
|
export class Cli extends APIResource {
|
|
8
8
|
/**
|
|
@@ -13,7 +13,7 @@ export class Cli extends APIResource {
|
|
|
13
13
|
*
|
|
14
14
|
* @example
|
|
15
15
|
* ```ts
|
|
16
|
-
* const response = await client.
|
|
16
|
+
* const response = await client.cli.createSession();
|
|
17
17
|
* ```
|
|
18
18
|
*/
|
|
19
19
|
createSession(options?: RequestOptions): APIPromise<CliCreateSessionResponse> {
|
|
@@ -21,40 +21,37 @@ export class Cli extends APIResource {
|
|
|
21
21
|
}
|
|
22
22
|
|
|
23
23
|
/**
|
|
24
|
-
*
|
|
25
|
-
*
|
|
26
|
-
*
|
|
27
|
-
*
|
|
24
|
+
* Retrieves the current state of a CLI session using either the session ID (UUID)
|
|
25
|
+
* or the 6-character code. This endpoint is used by both the CLI client to check
|
|
26
|
+
* if the session has been linked, and by the web interface to display session
|
|
27
|
+
* details before linking.
|
|
28
28
|
*
|
|
29
29
|
* @example
|
|
30
30
|
* ```ts
|
|
31
|
-
* const response = await client.
|
|
31
|
+
* const response = await client.cli.getSession({
|
|
32
32
|
* id: 'ABC123',
|
|
33
33
|
* });
|
|
34
34
|
* ```
|
|
35
35
|
*/
|
|
36
|
-
|
|
37
|
-
return this._client.
|
|
36
|
+
getSession(query: CliGetSessionParams, options?: RequestOptions): APIPromise<CliGetSessionResponse> {
|
|
37
|
+
return this._client.get('/api/v3/cli/get-session', { query, ...options });
|
|
38
38
|
}
|
|
39
39
|
|
|
40
40
|
/**
|
|
41
|
-
*
|
|
42
|
-
*
|
|
43
|
-
*
|
|
44
|
-
*
|
|
41
|
+
* Links a pending CLI session to the currently authenticated user. This is the
|
|
42
|
+
* final step in the CLI authentication flow, where the user enters the code in the
|
|
43
|
+
* web interface and their account is associated with the CLI session, allowing the
|
|
44
|
+
* CLI to act on their behalf.
|
|
45
45
|
*
|
|
46
46
|
* @example
|
|
47
47
|
* ```ts
|
|
48
|
-
* const response = await client.
|
|
48
|
+
* const response = await client.cli.linkSession({
|
|
49
49
|
* id: 'ABC123',
|
|
50
50
|
* });
|
|
51
51
|
* ```
|
|
52
52
|
*/
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
options?: RequestOptions,
|
|
56
|
-
): APIPromise<CliRetrieveSessionResponse> {
|
|
57
|
-
return this._client.get('/api/v3/cli/get-session', { query, ...options });
|
|
53
|
+
linkSession(body: CliLinkSessionParams, options?: RequestOptions): APIPromise<CliLinkSessionResponse> {
|
|
54
|
+
return this._client.put('/api/v3/cli/link-session', { body, ...options });
|
|
58
55
|
}
|
|
59
56
|
}
|
|
60
57
|
|
|
@@ -81,17 +78,17 @@ export interface CliCreateSessionResponse {
|
|
|
81
78
|
status: 'pending' | 'linked';
|
|
82
79
|
}
|
|
83
80
|
|
|
84
|
-
export interface
|
|
81
|
+
export interface CliGetSessionResponse {
|
|
85
82
|
/**
|
|
86
83
|
* The unique identifier for the CLI session
|
|
87
84
|
*/
|
|
88
85
|
id: string;
|
|
89
86
|
|
|
90
87
|
/**
|
|
91
|
-
* Information about the linked account.
|
|
92
|
-
*
|
|
88
|
+
* Information about the linked account, if any. Null if the session status is
|
|
89
|
+
* "pending".
|
|
93
90
|
*/
|
|
94
|
-
account:
|
|
91
|
+
account: CliGetSessionResponse.Account | null;
|
|
95
92
|
|
|
96
93
|
/**
|
|
97
94
|
* The 6-character hexadecimal code used for CLI login
|
|
@@ -109,10 +106,10 @@ export interface CliLinkSessionResponse {
|
|
|
109
106
|
status: 'pending' | 'linked';
|
|
110
107
|
}
|
|
111
108
|
|
|
112
|
-
export namespace
|
|
109
|
+
export namespace CliGetSessionResponse {
|
|
113
110
|
/**
|
|
114
|
-
* Information about the linked account.
|
|
115
|
-
*
|
|
111
|
+
* Information about the linked account, if any. Null if the session status is
|
|
112
|
+
* "pending".
|
|
116
113
|
*/
|
|
117
114
|
export interface Account {
|
|
118
115
|
/**
|
|
@@ -132,17 +129,17 @@ export namespace CliLinkSessionResponse {
|
|
|
132
129
|
}
|
|
133
130
|
}
|
|
134
131
|
|
|
135
|
-
export interface
|
|
132
|
+
export interface CliLinkSessionResponse {
|
|
136
133
|
/**
|
|
137
134
|
* The unique identifier for the CLI session
|
|
138
135
|
*/
|
|
139
136
|
id: string;
|
|
140
137
|
|
|
141
138
|
/**
|
|
142
|
-
* Information about the linked account
|
|
143
|
-
*
|
|
139
|
+
* Information about the linked account. Always present for successful responses
|
|
140
|
+
* from this endpoint.
|
|
144
141
|
*/
|
|
145
|
-
account:
|
|
142
|
+
account: CliLinkSessionResponse.Account;
|
|
146
143
|
|
|
147
144
|
/**
|
|
148
145
|
* The 6-character hexadecimal code used for CLI login
|
|
@@ -160,10 +157,10 @@ export interface CliRetrieveSessionResponse {
|
|
|
160
157
|
status: 'pending' | 'linked';
|
|
161
158
|
}
|
|
162
159
|
|
|
163
|
-
export namespace
|
|
160
|
+
export namespace CliLinkSessionResponse {
|
|
164
161
|
/**
|
|
165
|
-
* Information about the linked account
|
|
166
|
-
*
|
|
162
|
+
* Information about the linked account. Always present for successful responses
|
|
163
|
+
* from this endpoint.
|
|
167
164
|
*/
|
|
168
165
|
export interface Account {
|
|
169
166
|
/**
|
|
@@ -183,17 +180,17 @@ export namespace CliRetrieveSessionResponse {
|
|
|
183
180
|
}
|
|
184
181
|
}
|
|
185
182
|
|
|
186
|
-
export interface
|
|
183
|
+
export interface CliGetSessionParams {
|
|
187
184
|
/**
|
|
188
|
-
*
|
|
185
|
+
* CLI session ID (UUID format) or 6-character code to check. Both formats are
|
|
186
|
+
* supported for flexibility in client implementations.
|
|
189
187
|
*/
|
|
190
188
|
id: string;
|
|
191
189
|
}
|
|
192
190
|
|
|
193
|
-
export interface
|
|
191
|
+
export interface CliLinkSessionParams {
|
|
194
192
|
/**
|
|
195
|
-
* CLI session ID
|
|
196
|
-
* supported for flexibility in client implementations.
|
|
193
|
+
* The CLI session ID or code to link to the current user
|
|
197
194
|
*/
|
|
198
195
|
id: string;
|
|
199
196
|
}
|
|
@@ -201,9 +198,9 @@ export interface CliRetrieveSessionParams {
|
|
|
201
198
|
export declare namespace Cli {
|
|
202
199
|
export {
|
|
203
200
|
type CliCreateSessionResponse as CliCreateSessionResponse,
|
|
201
|
+
type CliGetSessionResponse as CliGetSessionResponse,
|
|
204
202
|
type CliLinkSessionResponse as CliLinkSessionResponse,
|
|
205
|
-
type
|
|
203
|
+
type CliGetSessionParams as CliGetSessionParams,
|
|
206
204
|
type CliLinkSessionParams as CliLinkSessionParams,
|
|
207
|
-
type CliRetrieveSessionParams as CliRetrieveSessionParams,
|
|
208
205
|
};
|
|
209
206
|
}
|