@dazl/api-client 1.0.9 → 1.0.11
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/db/generated-types.d.ts +5 -4
- package/dist/db/generated-types.d.ts.map +1 -1
- package/dist/db/jsonb.types.d.ts +6 -0
- package/dist/db/jsonb.types.d.ts.map +1 -1
- package/dist/internal/index.d.ts +2 -2
- package/dist/internal/index.d.ts.map +1 -1
- package/dist/internal/index.js +1 -1
- package/dist/internal/index.js.map +1 -1
- package/dist/internal/sdk.gen.d.ts +7 -1
- package/dist/internal/sdk.gen.d.ts.map +1 -1
- package/dist/internal/sdk.gen.js +35 -0
- package/dist/internal/sdk.gen.js.map +1 -1
- package/dist/internal/types.gen.d.ts +236 -1
- package/dist/internal/types.gen.d.ts.map +1 -1
- package/dist/public/index.d.ts +2 -2
- package/dist/public/index.d.ts.map +1 -1
- package/dist/public/index.js +1 -1
- package/dist/public/index.js.map +1 -1
- package/dist/public/sdk.gen.d.ts +7 -1
- package/dist/public/sdk.gen.d.ts.map +1 -1
- package/dist/public/sdk.gen.js +35 -0
- package/dist/public/sdk.gen.js.map +1 -1
- package/dist/public/types.gen.d.ts +234 -1
- package/dist/public/types.gen.d.ts.map +1 -1
- package/package.json +1 -1
- package/src/db/generated-types.ts +5 -4
- package/src/db/jsonb.types.ts +7 -0
- package/src/internal/index.ts +2 -2
- package/src/internal/sdk.gen.ts +40 -1
- package/src/internal/types.gen.ts +260 -1
- package/src/public/index.ts +2 -2
- package/src/public/sdk.gen.ts +40 -1
- package/src/public/types.gen.ts +258 -1
|
@@ -162,6 +162,7 @@ export type ProjectRaw = {
|
|
|
162
162
|
*/
|
|
163
163
|
updatedAt?: number;
|
|
164
164
|
}>;
|
|
165
|
+
workspaceId: string | null;
|
|
165
166
|
};
|
|
166
167
|
|
|
167
168
|
export type OwnerDazlId = {
|
|
@@ -511,8 +512,31 @@ export type FeatureToggle = {
|
|
|
511
512
|
export type Workspace = {
|
|
512
513
|
id: string;
|
|
513
514
|
name: string;
|
|
514
|
-
|
|
515
|
+
/**
|
|
516
|
+
* The user which created the workspace. Null if the user was deleted.
|
|
517
|
+
*/
|
|
518
|
+
dazlUserId: string | null;
|
|
515
519
|
createdAt: string;
|
|
520
|
+
isDefault: boolean;
|
|
521
|
+
};
|
|
522
|
+
|
|
523
|
+
export type CreateSessionAuthorized = {
|
|
524
|
+
status: 'authorized';
|
|
525
|
+
url: string;
|
|
526
|
+
headers?: {
|
|
527
|
+
[key: string]: string;
|
|
528
|
+
};
|
|
529
|
+
};
|
|
530
|
+
|
|
531
|
+
export type CreateSessionUnauthorized = {
|
|
532
|
+
status: 'unauthorized';
|
|
533
|
+
};
|
|
534
|
+
|
|
535
|
+
export type IntegrationName = 'confluence' | 'figma' | 'google-docs' | 'google-sheets' | 'google-slides' | 'jira' | 'linear' | 'miro' | 'notion';
|
|
536
|
+
|
|
537
|
+
export type ConnectionStatus = {
|
|
538
|
+
integrationName: IntegrationName;
|
|
539
|
+
isConnected: boolean;
|
|
516
540
|
};
|
|
517
541
|
|
|
518
542
|
export type EnsureMyUserData = {
|
|
@@ -2631,6 +2655,7 @@ export type CreateProjectData = {
|
|
|
2631
2655
|
latestScreenshot?: string | null;
|
|
2632
2656
|
originTemplateId?: string | null;
|
|
2633
2657
|
createdAt?: string;
|
|
2658
|
+
workspaceId?: string;
|
|
2634
2659
|
projectInitData?: {
|
|
2635
2660
|
gitRepoURL: string;
|
|
2636
2661
|
gitBranchToClone?: string | null;
|
|
@@ -7461,3 +7486,237 @@ export type OverrideAllResponses = {
|
|
|
7461
7486
|
};
|
|
7462
7487
|
|
|
7463
7488
|
export type OverrideAllResponse = OverrideAllResponses[keyof OverrideAllResponses];
|
|
7489
|
+
|
|
7490
|
+
export type CreateSessionData = {
|
|
7491
|
+
body: {
|
|
7492
|
+
integrationName: IntegrationName;
|
|
7493
|
+
};
|
|
7494
|
+
path?: never;
|
|
7495
|
+
query?: never;
|
|
7496
|
+
url: '/mcp/create-session';
|
|
7497
|
+
};
|
|
7498
|
+
|
|
7499
|
+
export type CreateSessionErrors = {
|
|
7500
|
+
/**
|
|
7501
|
+
* Bad request - Invalid parameters or malformed JSON
|
|
7502
|
+
*/
|
|
7503
|
+
400: {
|
|
7504
|
+
message: string;
|
|
7505
|
+
issues?: string;
|
|
7506
|
+
};
|
|
7507
|
+
/**
|
|
7508
|
+
* Unauthorized
|
|
7509
|
+
*/
|
|
7510
|
+
401: ErrorResponse;
|
|
7511
|
+
/**
|
|
7512
|
+
* Forbidden
|
|
7513
|
+
*/
|
|
7514
|
+
403: ErrorResponse;
|
|
7515
|
+
/**
|
|
7516
|
+
* Not Found
|
|
7517
|
+
*/
|
|
7518
|
+
404: ErrorResponse;
|
|
7519
|
+
/**
|
|
7520
|
+
* Conflict
|
|
7521
|
+
*/
|
|
7522
|
+
409: ErrorResponse;
|
|
7523
|
+
/**
|
|
7524
|
+
* Internal server error
|
|
7525
|
+
*/
|
|
7526
|
+
500: ErrorResponse;
|
|
7527
|
+
/**
|
|
7528
|
+
* Service Unavailable
|
|
7529
|
+
*/
|
|
7530
|
+
503: ErrorResponse;
|
|
7531
|
+
};
|
|
7532
|
+
|
|
7533
|
+
export type CreateSessionError = CreateSessionErrors[keyof CreateSessionErrors];
|
|
7534
|
+
|
|
7535
|
+
export type CreateSessionResponses = {
|
|
7536
|
+
/**
|
|
7537
|
+
* An authorized MCP session (real url + headers) or an unauthorized marker
|
|
7538
|
+
*/
|
|
7539
|
+
200: ({
|
|
7540
|
+
status: 'authorized';
|
|
7541
|
+
} & CreateSessionAuthorized) | ({
|
|
7542
|
+
status: 'unauthorized';
|
|
7543
|
+
} & CreateSessionUnauthorized);
|
|
7544
|
+
};
|
|
7545
|
+
|
|
7546
|
+
export type CreateSessionResponse = CreateSessionResponses[keyof CreateSessionResponses];
|
|
7547
|
+
|
|
7548
|
+
export type InitiateConnectionData = {
|
|
7549
|
+
body: {
|
|
7550
|
+
integrationName: IntegrationName;
|
|
7551
|
+
/**
|
|
7552
|
+
* Where the browser lands after OAuth; built by the caller
|
|
7553
|
+
*/
|
|
7554
|
+
callbackUrl: string;
|
|
7555
|
+
};
|
|
7556
|
+
path?: never;
|
|
7557
|
+
query?: never;
|
|
7558
|
+
url: '/mcp/connections';
|
|
7559
|
+
};
|
|
7560
|
+
|
|
7561
|
+
export type InitiateConnectionErrors = {
|
|
7562
|
+
/**
|
|
7563
|
+
* Bad request - Invalid parameters or malformed JSON
|
|
7564
|
+
*/
|
|
7565
|
+
400: {
|
|
7566
|
+
message: string;
|
|
7567
|
+
issues?: string;
|
|
7568
|
+
};
|
|
7569
|
+
/**
|
|
7570
|
+
* Unauthorized
|
|
7571
|
+
*/
|
|
7572
|
+
401: ErrorResponse;
|
|
7573
|
+
/**
|
|
7574
|
+
* Forbidden
|
|
7575
|
+
*/
|
|
7576
|
+
403: ErrorResponse;
|
|
7577
|
+
/**
|
|
7578
|
+
* Not Found
|
|
7579
|
+
*/
|
|
7580
|
+
404: ErrorResponse;
|
|
7581
|
+
/**
|
|
7582
|
+
* Conflict
|
|
7583
|
+
*/
|
|
7584
|
+
409: ErrorResponse;
|
|
7585
|
+
/**
|
|
7586
|
+
* Internal server error
|
|
7587
|
+
*/
|
|
7588
|
+
500: ErrorResponse;
|
|
7589
|
+
/**
|
|
7590
|
+
* Service Unavailable
|
|
7591
|
+
*/
|
|
7592
|
+
503: ErrorResponse;
|
|
7593
|
+
};
|
|
7594
|
+
|
|
7595
|
+
export type InitiateConnectionError = InitiateConnectionErrors[keyof InitiateConnectionErrors];
|
|
7596
|
+
|
|
7597
|
+
export type InitiateConnectionResponses = {
|
|
7598
|
+
/**
|
|
7599
|
+
* The OAuth connection request id and the redirect URL to send the user to
|
|
7600
|
+
*/
|
|
7601
|
+
200: {
|
|
7602
|
+
connectionRequestId: string;
|
|
7603
|
+
redirectUrl: string;
|
|
7604
|
+
};
|
|
7605
|
+
};
|
|
7606
|
+
|
|
7607
|
+
export type InitiateConnectionResponse = InitiateConnectionResponses[keyof InitiateConnectionResponses];
|
|
7608
|
+
|
|
7609
|
+
export type FinalizeConnectionData = {
|
|
7610
|
+
body: {
|
|
7611
|
+
integrationName: IntegrationName;
|
|
7612
|
+
};
|
|
7613
|
+
path: {
|
|
7614
|
+
connectionRequestId: string;
|
|
7615
|
+
};
|
|
7616
|
+
query?: never;
|
|
7617
|
+
url: '/mcp/connections/{connectionRequestId}/finalize';
|
|
7618
|
+
};
|
|
7619
|
+
|
|
7620
|
+
export type FinalizeConnectionErrors = {
|
|
7621
|
+
/**
|
|
7622
|
+
* Bad request - Invalid parameters or malformed JSON
|
|
7623
|
+
*/
|
|
7624
|
+
400: {
|
|
7625
|
+
message: string;
|
|
7626
|
+
issues?: string;
|
|
7627
|
+
};
|
|
7628
|
+
/**
|
|
7629
|
+
* Unauthorized
|
|
7630
|
+
*/
|
|
7631
|
+
401: ErrorResponse;
|
|
7632
|
+
/**
|
|
7633
|
+
* Forbidden
|
|
7634
|
+
*/
|
|
7635
|
+
403: ErrorResponse;
|
|
7636
|
+
/**
|
|
7637
|
+
* Not Found
|
|
7638
|
+
*/
|
|
7639
|
+
404: ErrorResponse;
|
|
7640
|
+
/**
|
|
7641
|
+
* Conflict
|
|
7642
|
+
*/
|
|
7643
|
+
409: ErrorResponse;
|
|
7644
|
+
/**
|
|
7645
|
+
* Internal server error
|
|
7646
|
+
*/
|
|
7647
|
+
500: ErrorResponse;
|
|
7648
|
+
/**
|
|
7649
|
+
* Service Unavailable
|
|
7650
|
+
*/
|
|
7651
|
+
503: ErrorResponse;
|
|
7652
|
+
};
|
|
7653
|
+
|
|
7654
|
+
export type FinalizeConnectionError = FinalizeConnectionErrors[keyof FinalizeConnectionErrors];
|
|
7655
|
+
|
|
7656
|
+
export type FinalizeConnectionResponses = {
|
|
7657
|
+
/**
|
|
7658
|
+
* The persisted connected-account id (ca_...)
|
|
7659
|
+
*/
|
|
7660
|
+
200: {
|
|
7661
|
+
connectionId: string;
|
|
7662
|
+
};
|
|
7663
|
+
};
|
|
7664
|
+
|
|
7665
|
+
export type FinalizeConnectionResponse = FinalizeConnectionResponses[keyof FinalizeConnectionResponses];
|
|
7666
|
+
|
|
7667
|
+
export type GetConnectionStatusData = {
|
|
7668
|
+
body?: never;
|
|
7669
|
+
path?: never;
|
|
7670
|
+
query?: {
|
|
7671
|
+
/**
|
|
7672
|
+
* If omitted, returns status for all integrations
|
|
7673
|
+
*/
|
|
7674
|
+
integrationName?: 'confluence' | 'figma' | 'google-docs' | 'google-sheets' | 'google-slides' | 'jira' | 'linear' | 'miro' | 'notion';
|
|
7675
|
+
};
|
|
7676
|
+
url: '/mcp/connections/status';
|
|
7677
|
+
};
|
|
7678
|
+
|
|
7679
|
+
export type GetConnectionStatusErrors = {
|
|
7680
|
+
/**
|
|
7681
|
+
* Bad request - Invalid parameters or malformed JSON
|
|
7682
|
+
*/
|
|
7683
|
+
400: {
|
|
7684
|
+
message: string;
|
|
7685
|
+
issues?: string;
|
|
7686
|
+
};
|
|
7687
|
+
/**
|
|
7688
|
+
* Unauthorized
|
|
7689
|
+
*/
|
|
7690
|
+
401: ErrorResponse;
|
|
7691
|
+
/**
|
|
7692
|
+
* Forbidden
|
|
7693
|
+
*/
|
|
7694
|
+
403: ErrorResponse;
|
|
7695
|
+
/**
|
|
7696
|
+
* Not Found
|
|
7697
|
+
*/
|
|
7698
|
+
404: ErrorResponse;
|
|
7699
|
+
/**
|
|
7700
|
+
* Conflict
|
|
7701
|
+
*/
|
|
7702
|
+
409: ErrorResponse;
|
|
7703
|
+
/**
|
|
7704
|
+
* Internal server error
|
|
7705
|
+
*/
|
|
7706
|
+
500: ErrorResponse;
|
|
7707
|
+
/**
|
|
7708
|
+
* Service Unavailable
|
|
7709
|
+
*/
|
|
7710
|
+
503: ErrorResponse;
|
|
7711
|
+
};
|
|
7712
|
+
|
|
7713
|
+
export type GetConnectionStatusError = GetConnectionStatusErrors[keyof GetConnectionStatusErrors];
|
|
7714
|
+
|
|
7715
|
+
export type GetConnectionStatusResponses = {
|
|
7716
|
+
/**
|
|
7717
|
+
* Active-connection status for the requested integration(s)
|
|
7718
|
+
*/
|
|
7719
|
+
200: Array<ConnectionStatus>;
|
|
7720
|
+
};
|
|
7721
|
+
|
|
7722
|
+
export type GetConnectionStatusResponse = GetConnectionStatusResponses[keyof GetConnectionStatusResponses];
|
package/src/public/index.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
// This file is auto-generated by @hey-api/openapi-ts
|
|
2
2
|
|
|
3
|
-
export { EnvConfig, type Options, Ping, User, UserSettings, Workspace as Workspace2 } from './sdk.gen.ts';
|
|
4
|
-
export type { ClientOptions, CreateWorkspaceData, CreateWorkspaceError, CreateWorkspaceErrors, CreateWorkspaceResponse, CreateWorkspaceResponses, EnsureMyUserData, EnsureMyUserError, EnsureMyUserErrors, EnsureMyUserResponse, EnsureMyUserResponses, ErrorResponse, FeatureToggle, GetAllData, GetAllError, GetAllErrors, GetAllResponse, GetAllResponses, GetAllWorkspacesData, GetAllWorkspacesError, GetAllWorkspacesErrors, GetAllWorkspacesResponse, GetAllWorkspacesResponses, GetFeatureTogglesData, GetFeatureTogglesError, GetFeatureTogglesErrors, GetFeatureTogglesResponse, GetFeatureTogglesResponses, GetMyUserData, GetMyUserError, GetMyUserErrors, GetMyUserResponse, GetMyUserResponses, GetPingData, GetPingError, GetPingErrors, GetPingResponse, GetPingResponses, OverrideAllData, OverrideAllError, OverrideAllErrors, OverrideAllResponse, OverrideAllResponses, UpdateMyUserData, UpdateMyUserError, UpdateMyUserErrors, UpdateMyUserResponse, UpdateMyUserResponses, UserRaw, Workspace } from './types.gen.ts';
|
|
3
|
+
export { EnvConfig, Mcp, type Options, Ping, User, UserSettings, Workspace as Workspace2 } from './sdk.gen.ts';
|
|
4
|
+
export type { ClientOptions, ConnectionStatus, CreateSessionAuthorized, CreateSessionData, CreateSessionError, CreateSessionErrors, CreateSessionResponse, CreateSessionResponses, CreateSessionUnauthorized, CreateWorkspaceData, CreateWorkspaceError, CreateWorkspaceErrors, CreateWorkspaceResponse, CreateWorkspaceResponses, EnsureMyUserData, EnsureMyUserError, EnsureMyUserErrors, EnsureMyUserResponse, EnsureMyUserResponses, ErrorResponse, FeatureToggle, FinalizeConnectionData, FinalizeConnectionError, FinalizeConnectionErrors, FinalizeConnectionResponse, FinalizeConnectionResponses, GetAllData, GetAllError, GetAllErrors, GetAllResponse, GetAllResponses, GetAllWorkspacesData, GetAllWorkspacesError, GetAllWorkspacesErrors, GetAllWorkspacesResponse, GetAllWorkspacesResponses, GetConnectionStatusData, GetConnectionStatusError, GetConnectionStatusErrors, GetConnectionStatusResponse, GetConnectionStatusResponses, GetFeatureTogglesData, GetFeatureTogglesError, GetFeatureTogglesErrors, GetFeatureTogglesResponse, GetFeatureTogglesResponses, GetMyUserData, GetMyUserError, GetMyUserErrors, GetMyUserResponse, GetMyUserResponses, GetPingData, GetPingError, GetPingErrors, GetPingResponse, GetPingResponses, InitiateConnectionData, InitiateConnectionError, InitiateConnectionErrors, InitiateConnectionResponse, InitiateConnectionResponses, IntegrationName, OverrideAllData, OverrideAllError, OverrideAllErrors, OverrideAllResponse, OverrideAllResponses, UpdateMyUserData, UpdateMyUserError, UpdateMyUserErrors, UpdateMyUserResponse, UpdateMyUserResponses, UserRaw, Workspace } from './types.gen.ts';
|
package/src/public/sdk.gen.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
// This file is auto-generated by @hey-api/openapi-ts
|
|
2
2
|
|
|
3
3
|
import type { Client, ClientMeta, Options as Options2, RequestResult, TDataShape } from './client/index.ts';
|
|
4
|
-
import type { CreateWorkspaceData, CreateWorkspaceErrors, CreateWorkspaceResponses, EnsureMyUserData, EnsureMyUserErrors, EnsureMyUserResponses, GetAllData, GetAllErrors, GetAllResponses, GetAllWorkspacesData, GetAllWorkspacesErrors, GetAllWorkspacesResponses, GetFeatureTogglesData, GetFeatureTogglesErrors, GetFeatureTogglesResponses, GetMyUserData, GetMyUserErrors, GetMyUserResponses, GetPingData, GetPingErrors, GetPingResponses, OverrideAllData, OverrideAllErrors, OverrideAllResponses, UpdateMyUserData, UpdateMyUserErrors, UpdateMyUserResponses } from './types.gen.ts';
|
|
4
|
+
import type { CreateSessionData, CreateSessionErrors, CreateSessionResponses, CreateWorkspaceData, CreateWorkspaceErrors, CreateWorkspaceResponses, EnsureMyUserData, EnsureMyUserErrors, EnsureMyUserResponses, FinalizeConnectionData, FinalizeConnectionErrors, FinalizeConnectionResponses, GetAllData, GetAllErrors, GetAllResponses, GetAllWorkspacesData, GetAllWorkspacesErrors, GetAllWorkspacesResponses, GetConnectionStatusData, GetConnectionStatusErrors, GetConnectionStatusResponses, GetFeatureTogglesData, GetFeatureTogglesErrors, GetFeatureTogglesResponses, GetMyUserData, GetMyUserErrors, GetMyUserResponses, GetPingData, GetPingErrors, GetPingResponses, InitiateConnectionData, InitiateConnectionErrors, InitiateConnectionResponses, OverrideAllData, OverrideAllErrors, OverrideAllResponses, UpdateMyUserData, UpdateMyUserErrors, UpdateMyUserResponses } from './types.gen.ts';
|
|
5
5
|
|
|
6
6
|
export type Options<TData extends TDataShape = TDataShape, ThrowOnError extends boolean = boolean, TResponse = unknown> = Options2<TData, ThrowOnError, TResponse> & {
|
|
7
7
|
/**
|
|
@@ -86,6 +86,45 @@ export class UserSettings {
|
|
|
86
86
|
}
|
|
87
87
|
}
|
|
88
88
|
|
|
89
|
+
export class Mcp {
|
|
90
|
+
public static createSession<ThrowOnError extends boolean = false>(options: Options<CreateSessionData, ThrowOnError>): RequestResult<CreateSessionResponses, CreateSessionErrors, ThrowOnError> {
|
|
91
|
+
return options.client.post<CreateSessionResponses, CreateSessionErrors, ThrowOnError>({
|
|
92
|
+
url: '/mcp/create-session',
|
|
93
|
+
...options,
|
|
94
|
+
headers: {
|
|
95
|
+
'Content-Type': 'application/json',
|
|
96
|
+
...options.headers
|
|
97
|
+
}
|
|
98
|
+
});
|
|
99
|
+
}
|
|
100
|
+
|
|
101
|
+
public static initiateConnection<ThrowOnError extends boolean = false>(options: Options<InitiateConnectionData, ThrowOnError>): RequestResult<InitiateConnectionResponses, InitiateConnectionErrors, ThrowOnError> {
|
|
102
|
+
return options.client.post<InitiateConnectionResponses, InitiateConnectionErrors, ThrowOnError>({
|
|
103
|
+
url: '/mcp/connections',
|
|
104
|
+
...options,
|
|
105
|
+
headers: {
|
|
106
|
+
'Content-Type': 'application/json',
|
|
107
|
+
...options.headers
|
|
108
|
+
}
|
|
109
|
+
});
|
|
110
|
+
}
|
|
111
|
+
|
|
112
|
+
public static finalizeConnection<ThrowOnError extends boolean = false>(options: Options<FinalizeConnectionData, ThrowOnError>): RequestResult<FinalizeConnectionResponses, FinalizeConnectionErrors, ThrowOnError> {
|
|
113
|
+
return options.client.post<FinalizeConnectionResponses, FinalizeConnectionErrors, ThrowOnError>({
|
|
114
|
+
url: '/mcp/connections/{connectionRequestId}/finalize',
|
|
115
|
+
...options,
|
|
116
|
+
headers: {
|
|
117
|
+
'Content-Type': 'application/json',
|
|
118
|
+
...options.headers
|
|
119
|
+
}
|
|
120
|
+
});
|
|
121
|
+
}
|
|
122
|
+
|
|
123
|
+
public static getConnectionStatus<ThrowOnError extends boolean = false>(options: Options<GetConnectionStatusData, ThrowOnError>): RequestResult<GetConnectionStatusResponses, GetConnectionStatusErrors, ThrowOnError> {
|
|
124
|
+
return options.client.get<GetConnectionStatusResponses, GetConnectionStatusErrors, ThrowOnError>({ url: '/mcp/connections/status', ...options });
|
|
125
|
+
}
|
|
126
|
+
}
|
|
127
|
+
|
|
89
128
|
export class Ping {
|
|
90
129
|
/**
|
|
91
130
|
* Ping endpoint for test
|
package/src/public/types.gen.ts
CHANGED
|
@@ -33,8 +33,31 @@ export type FeatureToggle = {
|
|
|
33
33
|
export type Workspace = {
|
|
34
34
|
id: string;
|
|
35
35
|
name: string;
|
|
36
|
-
|
|
36
|
+
/**
|
|
37
|
+
* The user which created the workspace. Null if the user was deleted.
|
|
38
|
+
*/
|
|
39
|
+
dazlUserId: string | null;
|
|
37
40
|
createdAt: string;
|
|
41
|
+
isDefault: boolean;
|
|
42
|
+
};
|
|
43
|
+
|
|
44
|
+
export type CreateSessionAuthorized = {
|
|
45
|
+
status: 'authorized';
|
|
46
|
+
url: string;
|
|
47
|
+
headers?: {
|
|
48
|
+
[key: string]: string;
|
|
49
|
+
};
|
|
50
|
+
};
|
|
51
|
+
|
|
52
|
+
export type CreateSessionUnauthorized = {
|
|
53
|
+
status: 'unauthorized';
|
|
54
|
+
};
|
|
55
|
+
|
|
56
|
+
export type IntegrationName = 'confluence' | 'figma' | 'google-docs' | 'google-sheets' | 'google-slides' | 'jira' | 'linear' | 'miro' | 'notion';
|
|
57
|
+
|
|
58
|
+
export type ConnectionStatus = {
|
|
59
|
+
integrationName: IntegrationName;
|
|
60
|
+
isConnected: boolean;
|
|
38
61
|
};
|
|
39
62
|
|
|
40
63
|
export type EnsureMyUserData = {
|
|
@@ -488,6 +511,240 @@ export type OverrideAllResponses = {
|
|
|
488
511
|
|
|
489
512
|
export type OverrideAllResponse = OverrideAllResponses[keyof OverrideAllResponses];
|
|
490
513
|
|
|
514
|
+
export type CreateSessionData = {
|
|
515
|
+
body: {
|
|
516
|
+
integrationName: IntegrationName;
|
|
517
|
+
};
|
|
518
|
+
path?: never;
|
|
519
|
+
query?: never;
|
|
520
|
+
url: '/mcp/create-session';
|
|
521
|
+
};
|
|
522
|
+
|
|
523
|
+
export type CreateSessionErrors = {
|
|
524
|
+
/**
|
|
525
|
+
* Bad request - Invalid parameters or malformed JSON
|
|
526
|
+
*/
|
|
527
|
+
400: {
|
|
528
|
+
message: string;
|
|
529
|
+
issues?: string;
|
|
530
|
+
};
|
|
531
|
+
/**
|
|
532
|
+
* Unauthorized
|
|
533
|
+
*/
|
|
534
|
+
401: ErrorResponse;
|
|
535
|
+
/**
|
|
536
|
+
* Forbidden
|
|
537
|
+
*/
|
|
538
|
+
403: ErrorResponse;
|
|
539
|
+
/**
|
|
540
|
+
* Not Found
|
|
541
|
+
*/
|
|
542
|
+
404: ErrorResponse;
|
|
543
|
+
/**
|
|
544
|
+
* Conflict
|
|
545
|
+
*/
|
|
546
|
+
409: ErrorResponse;
|
|
547
|
+
/**
|
|
548
|
+
* Internal server error
|
|
549
|
+
*/
|
|
550
|
+
500: ErrorResponse;
|
|
551
|
+
/**
|
|
552
|
+
* Service Unavailable
|
|
553
|
+
*/
|
|
554
|
+
503: ErrorResponse;
|
|
555
|
+
};
|
|
556
|
+
|
|
557
|
+
export type CreateSessionError = CreateSessionErrors[keyof CreateSessionErrors];
|
|
558
|
+
|
|
559
|
+
export type CreateSessionResponses = {
|
|
560
|
+
/**
|
|
561
|
+
* An authorized MCP session (real url + headers) or an unauthorized marker
|
|
562
|
+
*/
|
|
563
|
+
200: ({
|
|
564
|
+
status: 'authorized';
|
|
565
|
+
} & CreateSessionAuthorized) | ({
|
|
566
|
+
status: 'unauthorized';
|
|
567
|
+
} & CreateSessionUnauthorized);
|
|
568
|
+
};
|
|
569
|
+
|
|
570
|
+
export type CreateSessionResponse = CreateSessionResponses[keyof CreateSessionResponses];
|
|
571
|
+
|
|
572
|
+
export type InitiateConnectionData = {
|
|
573
|
+
body: {
|
|
574
|
+
integrationName: IntegrationName;
|
|
575
|
+
/**
|
|
576
|
+
* Where the browser lands after OAuth; built by the caller
|
|
577
|
+
*/
|
|
578
|
+
callbackUrl: string;
|
|
579
|
+
};
|
|
580
|
+
path?: never;
|
|
581
|
+
query?: never;
|
|
582
|
+
url: '/mcp/connections';
|
|
583
|
+
};
|
|
584
|
+
|
|
585
|
+
export type InitiateConnectionErrors = {
|
|
586
|
+
/**
|
|
587
|
+
* Bad request - Invalid parameters or malformed JSON
|
|
588
|
+
*/
|
|
589
|
+
400: {
|
|
590
|
+
message: string;
|
|
591
|
+
issues?: string;
|
|
592
|
+
};
|
|
593
|
+
/**
|
|
594
|
+
* Unauthorized
|
|
595
|
+
*/
|
|
596
|
+
401: ErrorResponse;
|
|
597
|
+
/**
|
|
598
|
+
* Forbidden
|
|
599
|
+
*/
|
|
600
|
+
403: ErrorResponse;
|
|
601
|
+
/**
|
|
602
|
+
* Not Found
|
|
603
|
+
*/
|
|
604
|
+
404: ErrorResponse;
|
|
605
|
+
/**
|
|
606
|
+
* Conflict
|
|
607
|
+
*/
|
|
608
|
+
409: ErrorResponse;
|
|
609
|
+
/**
|
|
610
|
+
* Internal server error
|
|
611
|
+
*/
|
|
612
|
+
500: ErrorResponse;
|
|
613
|
+
/**
|
|
614
|
+
* Service Unavailable
|
|
615
|
+
*/
|
|
616
|
+
503: ErrorResponse;
|
|
617
|
+
};
|
|
618
|
+
|
|
619
|
+
export type InitiateConnectionError = InitiateConnectionErrors[keyof InitiateConnectionErrors];
|
|
620
|
+
|
|
621
|
+
export type InitiateConnectionResponses = {
|
|
622
|
+
/**
|
|
623
|
+
* The OAuth connection request id and the redirect URL to send the user to
|
|
624
|
+
*/
|
|
625
|
+
200: {
|
|
626
|
+
connectionRequestId: string;
|
|
627
|
+
redirectUrl: string;
|
|
628
|
+
};
|
|
629
|
+
};
|
|
630
|
+
|
|
631
|
+
export type InitiateConnectionResponse = InitiateConnectionResponses[keyof InitiateConnectionResponses];
|
|
632
|
+
|
|
633
|
+
export type FinalizeConnectionData = {
|
|
634
|
+
body: {
|
|
635
|
+
integrationName: IntegrationName;
|
|
636
|
+
};
|
|
637
|
+
path: {
|
|
638
|
+
connectionRequestId: string;
|
|
639
|
+
};
|
|
640
|
+
query?: never;
|
|
641
|
+
url: '/mcp/connections/{connectionRequestId}/finalize';
|
|
642
|
+
};
|
|
643
|
+
|
|
644
|
+
export type FinalizeConnectionErrors = {
|
|
645
|
+
/**
|
|
646
|
+
* Bad request - Invalid parameters or malformed JSON
|
|
647
|
+
*/
|
|
648
|
+
400: {
|
|
649
|
+
message: string;
|
|
650
|
+
issues?: string;
|
|
651
|
+
};
|
|
652
|
+
/**
|
|
653
|
+
* Unauthorized
|
|
654
|
+
*/
|
|
655
|
+
401: ErrorResponse;
|
|
656
|
+
/**
|
|
657
|
+
* Forbidden
|
|
658
|
+
*/
|
|
659
|
+
403: ErrorResponse;
|
|
660
|
+
/**
|
|
661
|
+
* Not Found
|
|
662
|
+
*/
|
|
663
|
+
404: ErrorResponse;
|
|
664
|
+
/**
|
|
665
|
+
* Conflict
|
|
666
|
+
*/
|
|
667
|
+
409: ErrorResponse;
|
|
668
|
+
/**
|
|
669
|
+
* Internal server error
|
|
670
|
+
*/
|
|
671
|
+
500: ErrorResponse;
|
|
672
|
+
/**
|
|
673
|
+
* Service Unavailable
|
|
674
|
+
*/
|
|
675
|
+
503: ErrorResponse;
|
|
676
|
+
};
|
|
677
|
+
|
|
678
|
+
export type FinalizeConnectionError = FinalizeConnectionErrors[keyof FinalizeConnectionErrors];
|
|
679
|
+
|
|
680
|
+
export type FinalizeConnectionResponses = {
|
|
681
|
+
/**
|
|
682
|
+
* The persisted connected-account id (ca_...)
|
|
683
|
+
*/
|
|
684
|
+
200: {
|
|
685
|
+
connectionId: string;
|
|
686
|
+
};
|
|
687
|
+
};
|
|
688
|
+
|
|
689
|
+
export type FinalizeConnectionResponse = FinalizeConnectionResponses[keyof FinalizeConnectionResponses];
|
|
690
|
+
|
|
691
|
+
export type GetConnectionStatusData = {
|
|
692
|
+
body?: never;
|
|
693
|
+
path?: never;
|
|
694
|
+
query?: {
|
|
695
|
+
/**
|
|
696
|
+
* If omitted, returns status for all integrations
|
|
697
|
+
*/
|
|
698
|
+
integrationName?: 'confluence' | 'figma' | 'google-docs' | 'google-sheets' | 'google-slides' | 'jira' | 'linear' | 'miro' | 'notion';
|
|
699
|
+
};
|
|
700
|
+
url: '/mcp/connections/status';
|
|
701
|
+
};
|
|
702
|
+
|
|
703
|
+
export type GetConnectionStatusErrors = {
|
|
704
|
+
/**
|
|
705
|
+
* Bad request - Invalid parameters or malformed JSON
|
|
706
|
+
*/
|
|
707
|
+
400: {
|
|
708
|
+
message: string;
|
|
709
|
+
issues?: string;
|
|
710
|
+
};
|
|
711
|
+
/**
|
|
712
|
+
* Unauthorized
|
|
713
|
+
*/
|
|
714
|
+
401: ErrorResponse;
|
|
715
|
+
/**
|
|
716
|
+
* Forbidden
|
|
717
|
+
*/
|
|
718
|
+
403: ErrorResponse;
|
|
719
|
+
/**
|
|
720
|
+
* Not Found
|
|
721
|
+
*/
|
|
722
|
+
404: ErrorResponse;
|
|
723
|
+
/**
|
|
724
|
+
* Conflict
|
|
725
|
+
*/
|
|
726
|
+
409: ErrorResponse;
|
|
727
|
+
/**
|
|
728
|
+
* Internal server error
|
|
729
|
+
*/
|
|
730
|
+
500: ErrorResponse;
|
|
731
|
+
/**
|
|
732
|
+
* Service Unavailable
|
|
733
|
+
*/
|
|
734
|
+
503: ErrorResponse;
|
|
735
|
+
};
|
|
736
|
+
|
|
737
|
+
export type GetConnectionStatusError = GetConnectionStatusErrors[keyof GetConnectionStatusErrors];
|
|
738
|
+
|
|
739
|
+
export type GetConnectionStatusResponses = {
|
|
740
|
+
/**
|
|
741
|
+
* Active-connection status for the requested integration(s)
|
|
742
|
+
*/
|
|
743
|
+
200: Array<ConnectionStatus>;
|
|
744
|
+
};
|
|
745
|
+
|
|
746
|
+
export type GetConnectionStatusResponse = GetConnectionStatusResponses[keyof GetConnectionStatusResponses];
|
|
747
|
+
|
|
491
748
|
export type GetPingData = {
|
|
492
749
|
body?: never;
|
|
493
750
|
path?: never;
|