@mcp-s/connectors 0.0.20260928085734
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/README.md +73 -0
- package/dist/index.d.ts +14 -0
- package/dist/index.js +22 -0
- package/dist/public/_headers +3 -0
- package/dist/public/connectors/atlassian-mcp.json +1 -0
- package/dist/public/connectors/datadog-mcp.json +1 -0
- package/dist/public/connectors/github.json +1 -0
- package/dist/public/connectors/gmail.json +1 -0
- package/dist/public/index.json +77 -0
- package/dist/schema/auth.d.ts +406 -0
- package/dist/schema/auth.js +114 -0
- package/dist/schema/catalog.d.ts +1260 -0
- package/dist/schema/catalog.js +182 -0
- package/dist/schema/common.d.ts +31 -0
- package/dist/schema/common.js +23 -0
- package/dist/schema/enums.d.ts +42 -0
- package/dist/schema/enums.js +44 -0
- package/dist/schema/parts.d.ts +123 -0
- package/dist/schema/parts.js +85 -0
- package/dist/schema/tool.d.ts +107 -0
- package/dist/schema/tool.js +60 -0
- package/package.json +39 -0
|
@@ -0,0 +1,77 @@
|
|
|
1
|
+
{
|
|
2
|
+
"schema_version": 1,
|
|
3
|
+
"generated_at": "2026-09-28T08:57:34.740Z",
|
|
4
|
+
"connectors": [
|
|
5
|
+
{
|
|
6
|
+
"id": "github",
|
|
7
|
+
"slug": "github",
|
|
8
|
+
"kind": "api",
|
|
9
|
+
"status": "active",
|
|
10
|
+
"name": "GitHub",
|
|
11
|
+
"description": "GitHub is a web-based Git repository hosting service.",
|
|
12
|
+
"icon": "github.svg",
|
|
13
|
+
"category": "code-version-control",
|
|
14
|
+
"applications": [
|
|
15
|
+
"github"
|
|
16
|
+
],
|
|
17
|
+
"hash": "ed3c35296dfb2843b4465c26b912be69a4255d713644fa143be0b2f4b4c99fa3"
|
|
18
|
+
},
|
|
19
|
+
{
|
|
20
|
+
"id": "gmail",
|
|
21
|
+
"slug": "gmail",
|
|
22
|
+
"kind": "api",
|
|
23
|
+
"status": "active",
|
|
24
|
+
"name": "Gmail",
|
|
25
|
+
"description": "Gmail is a web-based email service developed by Google.",
|
|
26
|
+
"icon": "gmail.svg",
|
|
27
|
+
"category": "communication-messaging",
|
|
28
|
+
"applications": [
|
|
29
|
+
"gmail"
|
|
30
|
+
],
|
|
31
|
+
"hash": "fa7c2c6591719e6fab3ab070a6c17d320d4e8fda780ce993bd9dbb5910eeb73d"
|
|
32
|
+
},
|
|
33
|
+
{
|
|
34
|
+
"id": "datadog-mcp",
|
|
35
|
+
"slug": "datadog-mcp",
|
|
36
|
+
"kind": "mcp",
|
|
37
|
+
"status": "beta",
|
|
38
|
+
"name": "Datadog MCP",
|
|
39
|
+
"description": "Query Datadog logs, metrics, traces, monitors, incidents and dashboards through Datadog's official MCP server.",
|
|
40
|
+
"icon": "datadog",
|
|
41
|
+
"category": "observability-monitoring",
|
|
42
|
+
"applications": [
|
|
43
|
+
"datadog"
|
|
44
|
+
],
|
|
45
|
+
"supersedes": {
|
|
46
|
+
"registry": [
|
|
47
|
+
"datadog"
|
|
48
|
+
]
|
|
49
|
+
},
|
|
50
|
+
"hash": "6d1cfda8a60ab0470752ce04584c02b2514d5b8dcac2d2e17f1074380764b32b"
|
|
51
|
+
},
|
|
52
|
+
{
|
|
53
|
+
"id": "atlassian",
|
|
54
|
+
"slug": "atlassian-mcp",
|
|
55
|
+
"kind": "mcp",
|
|
56
|
+
"status": "draft",
|
|
57
|
+
"name": "Atlassian MCP",
|
|
58
|
+
"description": "Read and write Jira issues and Confluence pages through Atlassian's own MCP server.",
|
|
59
|
+
"icon": "atlassian",
|
|
60
|
+
"category": "project-management-issue-tracking",
|
|
61
|
+
"applications": [
|
|
62
|
+
"jira",
|
|
63
|
+
"confluence"
|
|
64
|
+
],
|
|
65
|
+
"supersedes": {
|
|
66
|
+
"connectors": [
|
|
67
|
+
"jira",
|
|
68
|
+
"confluence"
|
|
69
|
+
],
|
|
70
|
+
"registry": [
|
|
71
|
+
"atlassian"
|
|
72
|
+
]
|
|
73
|
+
},
|
|
74
|
+
"hash": "bd840afb09f27f26335f79d4fd9bd93ff33980cff1595499cfe372a85291cbdd"
|
|
75
|
+
}
|
|
76
|
+
]
|
|
77
|
+
}
|
|
@@ -0,0 +1,406 @@
|
|
|
1
|
+
import { z } from "zod";
|
|
2
|
+
export declare const wizardStep: z.ZodObject<{
|
|
3
|
+
markdown: z.ZodString;
|
|
4
|
+
component: z.ZodOptional<z.ZodEnum<{
|
|
5
|
+
redirectUrl: "redirectUrl";
|
|
6
|
+
credentials: "credentials";
|
|
7
|
+
generalSettings: "generalSettings";
|
|
8
|
+
requestHeader: "requestHeader";
|
|
9
|
+
}>>;
|
|
10
|
+
componentProps: z.ZodOptional<z.ZodObject<{
|
|
11
|
+
headerKey: z.ZodString;
|
|
12
|
+
}, z.core.$loose>>;
|
|
13
|
+
}, z.core.$loose>;
|
|
14
|
+
export type WizardStep = z.infer<typeof wizardStep>;
|
|
15
|
+
export declare const authDocs: z.ZodObject<{
|
|
16
|
+
description: z.ZodOptional<z.ZodString>;
|
|
17
|
+
link: z.ZodOptional<z.ZodString>;
|
|
18
|
+
steps: z.ZodArray<z.ZodObject<{
|
|
19
|
+
markdown: z.ZodString;
|
|
20
|
+
component: z.ZodOptional<z.ZodEnum<{
|
|
21
|
+
redirectUrl: "redirectUrl";
|
|
22
|
+
credentials: "credentials";
|
|
23
|
+
generalSettings: "generalSettings";
|
|
24
|
+
requestHeader: "requestHeader";
|
|
25
|
+
}>>;
|
|
26
|
+
componentProps: z.ZodOptional<z.ZodObject<{
|
|
27
|
+
headerKey: z.ZodString;
|
|
28
|
+
}, z.core.$loose>>;
|
|
29
|
+
}, z.core.$loose>>;
|
|
30
|
+
}, z.core.$loose>;
|
|
31
|
+
declare const oauth: z.ZodObject<{
|
|
32
|
+
authUrl: z.ZodOptional<z.ZodString>;
|
|
33
|
+
authUrlMapping: z.ZodOptional<z.ZodString>;
|
|
34
|
+
tokenUrl: z.ZodOptional<z.ZodString>;
|
|
35
|
+
tokenUrlMapping: z.ZodOptional<z.ZodString>;
|
|
36
|
+
refreshTokenUrl: z.ZodOptional<z.ZodString>;
|
|
37
|
+
scopes: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
38
|
+
defaultScopes: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
39
|
+
pkce: z.ZodOptional<z.ZodBoolean>;
|
|
40
|
+
codeExchangeConfig: z.ZodOptional<z.ZodObject<{
|
|
41
|
+
modelCredentialsMapping: z.ZodOptional<z.ZodString>;
|
|
42
|
+
externalIdMapping: z.ZodOptional<z.ZodString>;
|
|
43
|
+
isForm: z.ZodOptional<z.ZodBoolean>;
|
|
44
|
+
authorizationMapping: z.ZodOptional<z.ZodString>;
|
|
45
|
+
clientSecretBasic: z.ZodOptional<z.ZodBoolean>;
|
|
46
|
+
}, z.core.$loose>>;
|
|
47
|
+
authInitUrlParams: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
|
|
48
|
+
docs: z.ZodOptional<z.ZodObject<{
|
|
49
|
+
description: z.ZodOptional<z.ZodString>;
|
|
50
|
+
link: z.ZodOptional<z.ZodString>;
|
|
51
|
+
steps: z.ZodArray<z.ZodObject<{
|
|
52
|
+
markdown: z.ZodString;
|
|
53
|
+
component: z.ZodOptional<z.ZodEnum<{
|
|
54
|
+
redirectUrl: "redirectUrl";
|
|
55
|
+
credentials: "credentials";
|
|
56
|
+
generalSettings: "generalSettings";
|
|
57
|
+
requestHeader: "requestHeader";
|
|
58
|
+
}>>;
|
|
59
|
+
componentProps: z.ZodOptional<z.ZodObject<{
|
|
60
|
+
headerKey: z.ZodString;
|
|
61
|
+
}, z.core.$loose>>;
|
|
62
|
+
}, z.core.$loose>>;
|
|
63
|
+
}, z.core.$loose>>;
|
|
64
|
+
dynamicConfiguration: z.ZodOptional<z.ZodArray<z.ZodEnum<{
|
|
65
|
+
pkce: "pkce";
|
|
66
|
+
modelCredentialsMapping: "modelCredentialsMapping";
|
|
67
|
+
isForm: "isForm";
|
|
68
|
+
}>>>;
|
|
69
|
+
allowMultipleAccounts: z.ZodOptional<z.ZodBoolean>;
|
|
70
|
+
}, z.core.$loose>;
|
|
71
|
+
/**
|
|
72
|
+
* One Willow-managed OAuth app. The client id and secret are deliberately
|
|
73
|
+
* optional: the catalog never carries them. Each deployment supplies its own
|
|
74
|
+
* from the `instant_connectors` table, and a deployment with no row does not
|
|
75
|
+
* offer Instant OAuth at all.
|
|
76
|
+
*/
|
|
77
|
+
declare const willowOAuthApp: z.ZodObject<{
|
|
78
|
+
clientId: z.ZodOptional<z.ZodString>;
|
|
79
|
+
clientSecretEncrypted: z.ZodOptional<z.ZodObject<{
|
|
80
|
+
encryptedData: z.ZodString;
|
|
81
|
+
encryptedDek: z.ZodString;
|
|
82
|
+
iv: z.ZodString;
|
|
83
|
+
tag: z.ZodString;
|
|
84
|
+
gateway_id: z.ZodOptional<z.ZodString>;
|
|
85
|
+
kid: z.ZodOptional<z.ZodString>;
|
|
86
|
+
}, z.core.$loose>>;
|
|
87
|
+
scopes: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
88
|
+
callbackUrl: z.ZodOptional<z.ZodString>;
|
|
89
|
+
label: z.ZodOptional<z.ZodString>;
|
|
90
|
+
}, z.core.$loose>;
|
|
91
|
+
declare const willowOAuth: z.ZodObject<{
|
|
92
|
+
clientId: z.ZodOptional<z.ZodString>;
|
|
93
|
+
clientSecretEncrypted: z.ZodOptional<z.ZodObject<{
|
|
94
|
+
encryptedData: z.ZodString;
|
|
95
|
+
encryptedDek: z.ZodString;
|
|
96
|
+
iv: z.ZodString;
|
|
97
|
+
tag: z.ZodString;
|
|
98
|
+
gateway_id: z.ZodOptional<z.ZodString>;
|
|
99
|
+
kid: z.ZodOptional<z.ZodString>;
|
|
100
|
+
}, z.core.$loose>>;
|
|
101
|
+
scopes: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
102
|
+
callbackUrl: z.ZodOptional<z.ZodString>;
|
|
103
|
+
label: z.ZodOptional<z.ZodString>;
|
|
104
|
+
hosts: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
105
|
+
clientId: z.ZodOptional<z.ZodString>;
|
|
106
|
+
clientSecretEncrypted: z.ZodOptional<z.ZodObject<{
|
|
107
|
+
encryptedData: z.ZodString;
|
|
108
|
+
encryptedDek: z.ZodString;
|
|
109
|
+
iv: z.ZodString;
|
|
110
|
+
tag: z.ZodString;
|
|
111
|
+
gateway_id: z.ZodOptional<z.ZodString>;
|
|
112
|
+
kid: z.ZodOptional<z.ZodString>;
|
|
113
|
+
}, z.core.$loose>>;
|
|
114
|
+
scopes: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
115
|
+
callbackUrl: z.ZodOptional<z.ZodString>;
|
|
116
|
+
label: z.ZodOptional<z.ZodString>;
|
|
117
|
+
}, z.core.$loose>>>;
|
|
118
|
+
defaultScopes: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
119
|
+
multiHostCallback: z.ZodOptional<z.ZodBoolean>;
|
|
120
|
+
docs: z.ZodOptional<z.ZodObject<{
|
|
121
|
+
description: z.ZodOptional<z.ZodString>;
|
|
122
|
+
link: z.ZodOptional<z.ZodString>;
|
|
123
|
+
steps: z.ZodArray<z.ZodObject<{
|
|
124
|
+
markdown: z.ZodString;
|
|
125
|
+
component: z.ZodOptional<z.ZodEnum<{
|
|
126
|
+
redirectUrl: "redirectUrl";
|
|
127
|
+
credentials: "credentials";
|
|
128
|
+
generalSettings: "generalSettings";
|
|
129
|
+
requestHeader: "requestHeader";
|
|
130
|
+
}>>;
|
|
131
|
+
componentProps: z.ZodOptional<z.ZodObject<{
|
|
132
|
+
headerKey: z.ZodString;
|
|
133
|
+
}, z.core.$loose>>;
|
|
134
|
+
}, z.core.$loose>>;
|
|
135
|
+
}, z.core.$loose>>;
|
|
136
|
+
}, z.core.$loose>;
|
|
137
|
+
export declare const authSettings: z.ZodObject<{
|
|
138
|
+
apiKey: z.ZodOptional<z.ZodObject<{
|
|
139
|
+
headerName: z.ZodOptional<z.ZodString>;
|
|
140
|
+
authorizationMapping: z.ZodOptional<z.ZodString>;
|
|
141
|
+
caMapping: z.ZodOptional<z.ZodString>;
|
|
142
|
+
queryParamName: z.ZodOptional<z.ZodString>;
|
|
143
|
+
docs: z.ZodOptional<z.ZodObject<{
|
|
144
|
+
description: z.ZodOptional<z.ZodString>;
|
|
145
|
+
link: z.ZodOptional<z.ZodString>;
|
|
146
|
+
steps: z.ZodArray<z.ZodObject<{
|
|
147
|
+
markdown: z.ZodString;
|
|
148
|
+
component: z.ZodOptional<z.ZodEnum<{
|
|
149
|
+
redirectUrl: "redirectUrl";
|
|
150
|
+
credentials: "credentials";
|
|
151
|
+
generalSettings: "generalSettings";
|
|
152
|
+
requestHeader: "requestHeader";
|
|
153
|
+
}>>;
|
|
154
|
+
componentProps: z.ZodOptional<z.ZodObject<{
|
|
155
|
+
headerKey: z.ZodString;
|
|
156
|
+
}, z.core.$loose>>;
|
|
157
|
+
}, z.core.$loose>>;
|
|
158
|
+
}, z.core.$loose>>;
|
|
159
|
+
}, z.core.$loose>>;
|
|
160
|
+
oauth: z.ZodOptional<z.ZodObject<{
|
|
161
|
+
authUrl: z.ZodOptional<z.ZodString>;
|
|
162
|
+
authUrlMapping: z.ZodOptional<z.ZodString>;
|
|
163
|
+
tokenUrl: z.ZodOptional<z.ZodString>;
|
|
164
|
+
tokenUrlMapping: z.ZodOptional<z.ZodString>;
|
|
165
|
+
refreshTokenUrl: z.ZodOptional<z.ZodString>;
|
|
166
|
+
scopes: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
167
|
+
defaultScopes: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
168
|
+
pkce: z.ZodOptional<z.ZodBoolean>;
|
|
169
|
+
codeExchangeConfig: z.ZodOptional<z.ZodObject<{
|
|
170
|
+
modelCredentialsMapping: z.ZodOptional<z.ZodString>;
|
|
171
|
+
externalIdMapping: z.ZodOptional<z.ZodString>;
|
|
172
|
+
isForm: z.ZodOptional<z.ZodBoolean>;
|
|
173
|
+
authorizationMapping: z.ZodOptional<z.ZodString>;
|
|
174
|
+
clientSecretBasic: z.ZodOptional<z.ZodBoolean>;
|
|
175
|
+
}, z.core.$loose>>;
|
|
176
|
+
authInitUrlParams: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
|
|
177
|
+
docs: z.ZodOptional<z.ZodObject<{
|
|
178
|
+
description: z.ZodOptional<z.ZodString>;
|
|
179
|
+
link: z.ZodOptional<z.ZodString>;
|
|
180
|
+
steps: z.ZodArray<z.ZodObject<{
|
|
181
|
+
markdown: z.ZodString;
|
|
182
|
+
component: z.ZodOptional<z.ZodEnum<{
|
|
183
|
+
redirectUrl: "redirectUrl";
|
|
184
|
+
credentials: "credentials";
|
|
185
|
+
generalSettings: "generalSettings";
|
|
186
|
+
requestHeader: "requestHeader";
|
|
187
|
+
}>>;
|
|
188
|
+
componentProps: z.ZodOptional<z.ZodObject<{
|
|
189
|
+
headerKey: z.ZodString;
|
|
190
|
+
}, z.core.$loose>>;
|
|
191
|
+
}, z.core.$loose>>;
|
|
192
|
+
}, z.core.$loose>>;
|
|
193
|
+
dynamicConfiguration: z.ZodOptional<z.ZodArray<z.ZodEnum<{
|
|
194
|
+
pkce: "pkce";
|
|
195
|
+
modelCredentialsMapping: "modelCredentialsMapping";
|
|
196
|
+
isForm: "isForm";
|
|
197
|
+
}>>>;
|
|
198
|
+
allowMultipleAccounts: z.ZodOptional<z.ZodBoolean>;
|
|
199
|
+
}, z.core.$loose>>;
|
|
200
|
+
"webrix-oauth": z.ZodOptional<z.ZodObject<{
|
|
201
|
+
clientId: z.ZodOptional<z.ZodString>;
|
|
202
|
+
clientSecretEncrypted: z.ZodOptional<z.ZodObject<{
|
|
203
|
+
encryptedData: z.ZodString;
|
|
204
|
+
encryptedDek: z.ZodString;
|
|
205
|
+
iv: z.ZodString;
|
|
206
|
+
tag: z.ZodString;
|
|
207
|
+
gateway_id: z.ZodOptional<z.ZodString>;
|
|
208
|
+
kid: z.ZodOptional<z.ZodString>;
|
|
209
|
+
}, z.core.$loose>>;
|
|
210
|
+
scopes: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
211
|
+
callbackUrl: z.ZodOptional<z.ZodString>;
|
|
212
|
+
label: z.ZodOptional<z.ZodString>;
|
|
213
|
+
hosts: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
214
|
+
clientId: z.ZodOptional<z.ZodString>;
|
|
215
|
+
clientSecretEncrypted: z.ZodOptional<z.ZodObject<{
|
|
216
|
+
encryptedData: z.ZodString;
|
|
217
|
+
encryptedDek: z.ZodString;
|
|
218
|
+
iv: z.ZodString;
|
|
219
|
+
tag: z.ZodString;
|
|
220
|
+
gateway_id: z.ZodOptional<z.ZodString>;
|
|
221
|
+
kid: z.ZodOptional<z.ZodString>;
|
|
222
|
+
}, z.core.$loose>>;
|
|
223
|
+
scopes: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
224
|
+
callbackUrl: z.ZodOptional<z.ZodString>;
|
|
225
|
+
label: z.ZodOptional<z.ZodString>;
|
|
226
|
+
}, z.core.$loose>>>;
|
|
227
|
+
defaultScopes: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
228
|
+
multiHostCallback: z.ZodOptional<z.ZodBoolean>;
|
|
229
|
+
docs: z.ZodOptional<z.ZodObject<{
|
|
230
|
+
description: z.ZodOptional<z.ZodString>;
|
|
231
|
+
link: z.ZodOptional<z.ZodString>;
|
|
232
|
+
steps: z.ZodArray<z.ZodObject<{
|
|
233
|
+
markdown: z.ZodString;
|
|
234
|
+
component: z.ZodOptional<z.ZodEnum<{
|
|
235
|
+
redirectUrl: "redirectUrl";
|
|
236
|
+
credentials: "credentials";
|
|
237
|
+
generalSettings: "generalSettings";
|
|
238
|
+
requestHeader: "requestHeader";
|
|
239
|
+
}>>;
|
|
240
|
+
componentProps: z.ZodOptional<z.ZodObject<{
|
|
241
|
+
headerKey: z.ZodString;
|
|
242
|
+
}, z.core.$loose>>;
|
|
243
|
+
}, z.core.$loose>>;
|
|
244
|
+
}, z.core.$loose>>;
|
|
245
|
+
}, z.core.$loose>>;
|
|
246
|
+
"server-app": z.ZodOptional<z.ZodObject<{
|
|
247
|
+
platformSecretEncrypted: z.ZodOptional<z.ZodObject<{
|
|
248
|
+
encryptedData: z.ZodString;
|
|
249
|
+
encryptedDek: z.ZodString;
|
|
250
|
+
iv: z.ZodString;
|
|
251
|
+
tag: z.ZodString;
|
|
252
|
+
gateway_id: z.ZodOptional<z.ZodString>;
|
|
253
|
+
kid: z.ZodOptional<z.ZodString>;
|
|
254
|
+
}, z.core.$loose>>;
|
|
255
|
+
algorithm: z.ZodOptional<z.ZodEnum<{
|
|
256
|
+
RS256: "RS256";
|
|
257
|
+
HS256: "HS256";
|
|
258
|
+
ES256: "ES256";
|
|
259
|
+
}>>;
|
|
260
|
+
mode: z.ZodOptional<z.ZodEnum<{
|
|
261
|
+
exchange: "exchange";
|
|
262
|
+
direct: "direct";
|
|
263
|
+
}>>;
|
|
264
|
+
claimsMapping: z.ZodOptional<z.ZodString>;
|
|
265
|
+
ttlSeconds: z.ZodOptional<z.ZodNumber>;
|
|
266
|
+
keyMaterial: z.ZodOptional<z.ZodEnum<{
|
|
267
|
+
privateKey: "privateKey";
|
|
268
|
+
secret: "secret";
|
|
269
|
+
}>>;
|
|
270
|
+
tokenUrlPath: z.ZodOptional<z.ZodString>;
|
|
271
|
+
supportScopes: z.ZodOptional<z.ZodBoolean>;
|
|
272
|
+
supportInstallationId: z.ZodOptional<z.ZodBoolean>;
|
|
273
|
+
supportSubject: z.ZodOptional<z.ZodBoolean>;
|
|
274
|
+
tokenBodyMapping: z.ZodOptional<z.ZodString>;
|
|
275
|
+
tokenHeadersMapping: z.ZodOptional<z.ZodString>;
|
|
276
|
+
docs: z.ZodOptional<z.ZodObject<{
|
|
277
|
+
description: z.ZodOptional<z.ZodString>;
|
|
278
|
+
link: z.ZodOptional<z.ZodString>;
|
|
279
|
+
steps: z.ZodArray<z.ZodObject<{
|
|
280
|
+
markdown: z.ZodString;
|
|
281
|
+
component: z.ZodOptional<z.ZodEnum<{
|
|
282
|
+
redirectUrl: "redirectUrl";
|
|
283
|
+
credentials: "credentials";
|
|
284
|
+
generalSettings: "generalSettings";
|
|
285
|
+
requestHeader: "requestHeader";
|
|
286
|
+
}>>;
|
|
287
|
+
componentProps: z.ZodOptional<z.ZodObject<{
|
|
288
|
+
headerKey: z.ZodString;
|
|
289
|
+
}, z.core.$loose>>;
|
|
290
|
+
}, z.core.$loose>>;
|
|
291
|
+
}, z.core.$loose>>;
|
|
292
|
+
}, z.core.$loose>>;
|
|
293
|
+
"server-app-per-user": z.ZodOptional<z.ZodObject<{
|
|
294
|
+
howtoMarkdown: z.ZodOptional<z.ZodString>;
|
|
295
|
+
algorithm: z.ZodOptional<z.ZodEnum<{
|
|
296
|
+
RS256: "RS256";
|
|
297
|
+
HS256: "HS256";
|
|
298
|
+
ES256: "ES256";
|
|
299
|
+
}>>;
|
|
300
|
+
mode: z.ZodOptional<z.ZodEnum<{
|
|
301
|
+
exchange: "exchange";
|
|
302
|
+
direct: "direct";
|
|
303
|
+
}>>;
|
|
304
|
+
claimsMapping: z.ZodOptional<z.ZodString>;
|
|
305
|
+
ttlSeconds: z.ZodOptional<z.ZodNumber>;
|
|
306
|
+
keyMaterial: z.ZodOptional<z.ZodEnum<{
|
|
307
|
+
privateKey: "privateKey";
|
|
308
|
+
secret: "secret";
|
|
309
|
+
}>>;
|
|
310
|
+
tokenUrlPath: z.ZodOptional<z.ZodString>;
|
|
311
|
+
supportScopes: z.ZodOptional<z.ZodBoolean>;
|
|
312
|
+
supportInstallationId: z.ZodOptional<z.ZodBoolean>;
|
|
313
|
+
supportSubject: z.ZodOptional<z.ZodBoolean>;
|
|
314
|
+
tokenBodyMapping: z.ZodOptional<z.ZodString>;
|
|
315
|
+
tokenHeadersMapping: z.ZodOptional<z.ZodString>;
|
|
316
|
+
docs: z.ZodOptional<z.ZodObject<{
|
|
317
|
+
description: z.ZodOptional<z.ZodString>;
|
|
318
|
+
link: z.ZodOptional<z.ZodString>;
|
|
319
|
+
steps: z.ZodArray<z.ZodObject<{
|
|
320
|
+
markdown: z.ZodString;
|
|
321
|
+
component: z.ZodOptional<z.ZodEnum<{
|
|
322
|
+
redirectUrl: "redirectUrl";
|
|
323
|
+
credentials: "credentials";
|
|
324
|
+
generalSettings: "generalSettings";
|
|
325
|
+
requestHeader: "requestHeader";
|
|
326
|
+
}>>;
|
|
327
|
+
componentProps: z.ZodOptional<z.ZodObject<{
|
|
328
|
+
headerKey: z.ZodString;
|
|
329
|
+
}, z.core.$loose>>;
|
|
330
|
+
}, z.core.$loose>>;
|
|
331
|
+
}, z.core.$loose>>;
|
|
332
|
+
}, z.core.$loose>>;
|
|
333
|
+
"proxy-oauth": z.ZodOptional<z.ZodObject<{}, z.core.$loose>>;
|
|
334
|
+
"proxy-connector-oauth": z.ZodOptional<z.ZodObject<{}, z.core.$loose>>;
|
|
335
|
+
"proxy-api-key": z.ZodOptional<z.ZodObject<{}, z.core.$loose>>;
|
|
336
|
+
"proxy-client-credentials": z.ZodOptional<z.ZodObject<{}, z.core.$loose>>;
|
|
337
|
+
"proxy-passthrough": z.ZodOptional<z.ZodObject<{}, z.core.$loose>>;
|
|
338
|
+
"api-key-per-user": z.ZodOptional<z.ZodObject<{
|
|
339
|
+
headerName: z.ZodOptional<z.ZodString>;
|
|
340
|
+
authorizationMapping: z.ZodOptional<z.ZodString>;
|
|
341
|
+
howtoMarkdown: z.ZodOptional<z.ZodString>;
|
|
342
|
+
docs: z.ZodOptional<z.ZodObject<{
|
|
343
|
+
description: z.ZodOptional<z.ZodString>;
|
|
344
|
+
link: z.ZodOptional<z.ZodString>;
|
|
345
|
+
steps: z.ZodArray<z.ZodObject<{
|
|
346
|
+
markdown: z.ZodString;
|
|
347
|
+
component: z.ZodOptional<z.ZodEnum<{
|
|
348
|
+
redirectUrl: "redirectUrl";
|
|
349
|
+
credentials: "credentials";
|
|
350
|
+
generalSettings: "generalSettings";
|
|
351
|
+
requestHeader: "requestHeader";
|
|
352
|
+
}>>;
|
|
353
|
+
componentProps: z.ZodOptional<z.ZodObject<{
|
|
354
|
+
headerKey: z.ZodString;
|
|
355
|
+
}, z.core.$loose>>;
|
|
356
|
+
}, z.core.$loose>>;
|
|
357
|
+
}, z.core.$loose>>;
|
|
358
|
+
}, z.core.$loose>>;
|
|
359
|
+
"client-credentials": z.ZodOptional<z.ZodObject<{
|
|
360
|
+
tokenUrl: z.ZodOptional<z.ZodString>;
|
|
361
|
+
authorizationMapping: z.ZodOptional<z.ZodString>;
|
|
362
|
+
tokenBodyMapping: z.ZodOptional<z.ZodString>;
|
|
363
|
+
docs: z.ZodOptional<z.ZodObject<{
|
|
364
|
+
description: z.ZodOptional<z.ZodString>;
|
|
365
|
+
link: z.ZodOptional<z.ZodString>;
|
|
366
|
+
steps: z.ZodArray<z.ZodObject<{
|
|
367
|
+
markdown: z.ZodString;
|
|
368
|
+
component: z.ZodOptional<z.ZodEnum<{
|
|
369
|
+
redirectUrl: "redirectUrl";
|
|
370
|
+
credentials: "credentials";
|
|
371
|
+
generalSettings: "generalSettings";
|
|
372
|
+
requestHeader: "requestHeader";
|
|
373
|
+
}>>;
|
|
374
|
+
componentProps: z.ZodOptional<z.ZodObject<{
|
|
375
|
+
headerKey: z.ZodString;
|
|
376
|
+
}, z.core.$loose>>;
|
|
377
|
+
}, z.core.$loose>>;
|
|
378
|
+
}, z.core.$loose>>;
|
|
379
|
+
}, z.core.$loose>>;
|
|
380
|
+
"client-credentials-per-user": z.ZodOptional<z.ZodObject<{
|
|
381
|
+
tokenUrl: z.ZodOptional<z.ZodString>;
|
|
382
|
+
authorizationMapping: z.ZodOptional<z.ZodString>;
|
|
383
|
+
tokenBodyMapping: z.ZodOptional<z.ZodString>;
|
|
384
|
+
docs: z.ZodOptional<z.ZodObject<{
|
|
385
|
+
description: z.ZodOptional<z.ZodString>;
|
|
386
|
+
link: z.ZodOptional<z.ZodString>;
|
|
387
|
+
steps: z.ZodArray<z.ZodObject<{
|
|
388
|
+
markdown: z.ZodString;
|
|
389
|
+
component: z.ZodOptional<z.ZodEnum<{
|
|
390
|
+
redirectUrl: "redirectUrl";
|
|
391
|
+
credentials: "credentials";
|
|
392
|
+
generalSettings: "generalSettings";
|
|
393
|
+
requestHeader: "requestHeader";
|
|
394
|
+
}>>;
|
|
395
|
+
componentProps: z.ZodOptional<z.ZodObject<{
|
|
396
|
+
headerKey: z.ZodString;
|
|
397
|
+
}, z.core.$loose>>;
|
|
398
|
+
}, z.core.$loose>>;
|
|
399
|
+
}, z.core.$loose>>;
|
|
400
|
+
}, z.core.$loose>>;
|
|
401
|
+
}, z.core.$loose>;
|
|
402
|
+
export type ConnectorAuthSettings = z.infer<typeof authSettings>;
|
|
403
|
+
export type ConnectorAuthOAuth = z.infer<typeof oauth>;
|
|
404
|
+
export type ConnectorAuthWillowOAuth = z.infer<typeof willowOAuth>;
|
|
405
|
+
export type ConnectorAuthWillowOAuthApp = z.infer<typeof willowOAuthApp>;
|
|
406
|
+
export {};
|
|
@@ -0,0 +1,114 @@
|
|
|
1
|
+
import { z } from "zod";
|
|
2
|
+
import { encryptedPayload, jsonata, obj } from "./common.js";
|
|
3
|
+
import { ConnectorAuthType } from "./enums.js";
|
|
4
|
+
export const wizardStep = obj({
|
|
5
|
+
markdown: z.string(),
|
|
6
|
+
component: z
|
|
7
|
+
.enum(["redirectUrl", "credentials", "generalSettings", "requestHeader"])
|
|
8
|
+
.optional(),
|
|
9
|
+
componentProps: obj({ headerKey: z.string() }).optional(),
|
|
10
|
+
});
|
|
11
|
+
export const authDocs = obj({
|
|
12
|
+
description: z.string().optional(),
|
|
13
|
+
link: z.string().optional(),
|
|
14
|
+
steps: z.array(wizardStep),
|
|
15
|
+
});
|
|
16
|
+
const apiKey = obj({
|
|
17
|
+
headerName: z.string().optional(),
|
|
18
|
+
authorizationMapping: jsonata.optional(),
|
|
19
|
+
caMapping: jsonata.optional(),
|
|
20
|
+
queryParamName: z.string().optional(),
|
|
21
|
+
docs: authDocs.optional(),
|
|
22
|
+
});
|
|
23
|
+
const oauth = obj({
|
|
24
|
+
authUrl: z.string().optional(),
|
|
25
|
+
authUrlMapping: jsonata.optional(),
|
|
26
|
+
tokenUrl: z.string().optional(),
|
|
27
|
+
tokenUrlMapping: jsonata.optional(),
|
|
28
|
+
refreshTokenUrl: z.string().optional(),
|
|
29
|
+
scopes: z.array(z.string()).optional(),
|
|
30
|
+
defaultScopes: z.array(z.string()).optional(),
|
|
31
|
+
pkce: z.boolean().optional(),
|
|
32
|
+
codeExchangeConfig: obj({
|
|
33
|
+
modelCredentialsMapping: jsonata.optional(),
|
|
34
|
+
externalIdMapping: jsonata.optional(),
|
|
35
|
+
isForm: z.boolean().optional(),
|
|
36
|
+
authorizationMapping: jsonata.optional(),
|
|
37
|
+
clientSecretBasic: z.boolean().optional(),
|
|
38
|
+
}).optional(),
|
|
39
|
+
authInitUrlParams: z.record(z.string(), z.string()).optional(),
|
|
40
|
+
docs: authDocs.optional(),
|
|
41
|
+
dynamicConfiguration: z
|
|
42
|
+
.array(z.enum(["pkce", "isForm", "modelCredentialsMapping"]))
|
|
43
|
+
.optional(),
|
|
44
|
+
allowMultipleAccounts: z.boolean().optional(),
|
|
45
|
+
});
|
|
46
|
+
/**
|
|
47
|
+
* One Willow-managed OAuth app. The client id and secret are deliberately
|
|
48
|
+
* optional: the catalog never carries them. Each deployment supplies its own
|
|
49
|
+
* from the `instant_connectors` table, and a deployment with no row does not
|
|
50
|
+
* offer Instant OAuth at all.
|
|
51
|
+
*/
|
|
52
|
+
const willowOAuthApp = obj({
|
|
53
|
+
clientId: z.string().optional(),
|
|
54
|
+
clientSecretEncrypted: encryptedPayload.optional(),
|
|
55
|
+
scopes: z.array(z.string()).optional(),
|
|
56
|
+
callbackUrl: z.string().optional(),
|
|
57
|
+
label: z.string().optional(),
|
|
58
|
+
});
|
|
59
|
+
const willowOAuth = willowOAuthApp.extend({
|
|
60
|
+
hosts: z.record(z.string(), willowOAuthApp).optional(),
|
|
61
|
+
defaultScopes: z.array(z.string()).optional(),
|
|
62
|
+
multiHostCallback: z.boolean().optional(),
|
|
63
|
+
docs: authDocs.optional(),
|
|
64
|
+
});
|
|
65
|
+
const clientCredentials = obj({
|
|
66
|
+
tokenUrl: z.string().optional(),
|
|
67
|
+
authorizationMapping: jsonata.optional(),
|
|
68
|
+
tokenBodyMapping: jsonata.optional(),
|
|
69
|
+
docs: authDocs.optional(),
|
|
70
|
+
});
|
|
71
|
+
const serverAppBase = {
|
|
72
|
+
algorithm: z.enum(["RS256", "HS256", "ES256"]).optional(),
|
|
73
|
+
mode: z.enum(["exchange", "direct"]).optional(),
|
|
74
|
+
claimsMapping: jsonata.optional(),
|
|
75
|
+
ttlSeconds: z.number().optional(),
|
|
76
|
+
keyMaterial: z.enum(["privateKey", "secret"]).optional(),
|
|
77
|
+
tokenUrlPath: z.string().optional(),
|
|
78
|
+
supportScopes: z.boolean().optional(),
|
|
79
|
+
supportInstallationId: z.boolean().optional(),
|
|
80
|
+
supportSubject: z.boolean().optional(),
|
|
81
|
+
tokenBodyMapping: jsonata.optional(),
|
|
82
|
+
tokenHeadersMapping: jsonata.optional(),
|
|
83
|
+
docs: authDocs.optional(),
|
|
84
|
+
};
|
|
85
|
+
const serverApp = obj({
|
|
86
|
+
...serverAppBase,
|
|
87
|
+
platformSecretEncrypted: encryptedPayload.optional(),
|
|
88
|
+
});
|
|
89
|
+
const serverAppPerUser = obj({
|
|
90
|
+
...serverAppBase,
|
|
91
|
+
howtoMarkdown: z.string().optional(),
|
|
92
|
+
});
|
|
93
|
+
const apiKeyPerUser = obj({
|
|
94
|
+
headerName: z.string().optional(),
|
|
95
|
+
authorizationMapping: jsonata.optional(),
|
|
96
|
+
howtoMarkdown: z.string().optional(),
|
|
97
|
+
docs: authDocs.optional(),
|
|
98
|
+
});
|
|
99
|
+
const empty = obj({});
|
|
100
|
+
export const authSettings = obj({
|
|
101
|
+
[ConnectorAuthType.API_KEY]: apiKey.optional(),
|
|
102
|
+
[ConnectorAuthType.OAUTH]: oauth.optional(),
|
|
103
|
+
[ConnectorAuthType.WILLOW_OAUTH]: willowOAuth.optional(),
|
|
104
|
+
[ConnectorAuthType.SERVER_APP]: serverApp.optional(),
|
|
105
|
+
[ConnectorAuthType.SERVER_APP_PER_USER]: serverAppPerUser.optional(),
|
|
106
|
+
[ConnectorAuthType.PROXY_OAUTH]: empty.optional(),
|
|
107
|
+
[ConnectorAuthType.PROXY_CONNECTOR_OAUTH]: empty.optional(),
|
|
108
|
+
[ConnectorAuthType.PROXY_API_KEY]: empty.optional(),
|
|
109
|
+
[ConnectorAuthType.PROXY_CLIENT_CREDENTIALS]: empty.optional(),
|
|
110
|
+
[ConnectorAuthType.PROXY_PASSTHROUGH]: empty.optional(),
|
|
111
|
+
[ConnectorAuthType.API_KEY_PER_USER]: apiKeyPerUser.optional(),
|
|
112
|
+
[ConnectorAuthType.CLIENT_CREDENTIALS]: clientCredentials.optional(),
|
|
113
|
+
[ConnectorAuthType.CLIENT_CREDENTIALS_PER_USER]: clientCredentials.optional(),
|
|
114
|
+
});
|