@squidcloud/local-backend 1.0.75 → 1.0.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 (193) hide show
  1. package/dist/common/src/ai-assistant.context.d.ts +13 -13
  2. package/dist/common/src/ai-assistant.context.js +19 -19
  3. package/dist/common/src/ai-assistant.schemas.d.ts +243 -243
  4. package/dist/common/src/ai-assistant.schemas.js +210 -210
  5. package/dist/common/src/ai-assistant.types.d.ts +85 -85
  6. package/dist/common/src/ai-assistant.types.js +11 -11
  7. package/dist/common/src/api-call.context.d.ts +13 -13
  8. package/dist/common/src/api-call.context.js +16 -16
  9. package/dist/common/src/api.types.d.ts +23 -23
  10. package/dist/common/src/api.types.js +2 -2
  11. package/dist/common/src/application.schemas.d.ts +1332 -1312
  12. package/dist/common/src/application.schemas.js +880 -860
  13. package/dist/common/src/application.schemas.js.map +1 -1
  14. package/dist/common/src/application.types.d.ts +189 -186
  15. package/dist/common/src/application.types.js +89 -89
  16. package/dist/common/src/application.types.js.map +1 -1
  17. package/dist/common/src/backend-function.schemas.d.ts +3 -3
  18. package/dist/common/src/backend-function.schemas.js +12 -12
  19. package/dist/common/src/backend-function.types.d.ts +6 -6
  20. package/dist/common/src/backend-function.types.js +2 -2
  21. package/dist/common/src/backend-run.types.d.ts +54 -54
  22. package/dist/common/src/backend-run.types.js +91 -91
  23. package/dist/common/src/bundle-api.types.d.ts +65 -65
  24. package/dist/common/src/bundle-api.types.js +2 -2
  25. package/dist/common/src/bundle-data.types.d.ts +60 -60
  26. package/dist/common/src/bundle-data.types.js +2 -2
  27. package/dist/common/src/communication.types.d.ts +18 -18
  28. package/dist/common/src/communication.types.js +40 -40
  29. package/dist/common/src/context.types.d.ts +24 -24
  30. package/dist/common/src/context.types.js +2 -2
  31. package/dist/common/src/distributed-lock.context.d.ts +5 -5
  32. package/dist/common/src/distributed-lock.context.js +10 -10
  33. package/dist/common/src/document.types.d.ts +32 -32
  34. package/dist/common/src/document.types.js +50 -50
  35. package/dist/common/src/graphql.context.d.ts +14 -14
  36. package/dist/common/src/graphql.context.js +12 -12
  37. package/dist/common/src/graphql.types.d.ts +11 -11
  38. package/dist/common/src/graphql.types.js +34 -34
  39. package/dist/common/src/heartbeat.types.d.ts +4 -4
  40. package/dist/common/src/heartbeat.types.js +16 -16
  41. package/dist/common/src/http-status.enum.d.ts +50 -50
  42. package/dist/common/src/http-status.enum.js +54 -54
  43. package/dist/common/src/http-status.enum.js.map +1 -1
  44. package/dist/common/src/index.d.ts +55 -55
  45. package/dist/common/src/index.js +71 -71
  46. package/dist/common/src/integrations/ai_assistant.types.d.ts +30 -26
  47. package/dist/common/src/integrations/ai_assistant.types.js +2 -2
  48. package/dist/common/src/integrations/api.types.d.ts +80 -80
  49. package/dist/common/src/integrations/api.types.js +2 -2
  50. package/dist/common/src/integrations/auth.types.d.ts +39 -39
  51. package/dist/common/src/integrations/auth.types.js +2 -2
  52. package/dist/common/src/integrations/database.types.d.ts +231 -231
  53. package/dist/common/src/integrations/database.types.js +2 -2
  54. package/dist/common/src/integrations/index.d.ts +126 -126
  55. package/dist/common/src/integrations/index.js +113 -113
  56. package/dist/common/src/integrations/index.js.map +1 -1
  57. package/dist/common/src/integrations/observability.types.d.ts +23 -23
  58. package/dist/common/src/integrations/observability.types.js +23 -23
  59. package/dist/common/src/logger.types.d.ts +21 -21
  60. package/dist/common/src/logger.types.js +11 -11
  61. package/dist/common/src/logger.types.js.map +1 -1
  62. package/dist/common/src/metrics.types.d.ts +73 -73
  63. package/dist/common/src/metrics.types.js +11 -11
  64. package/dist/common/src/mutation.context.d.ts +13 -13
  65. package/dist/common/src/mutation.context.js +26 -26
  66. package/dist/common/src/mutation.schemas.d.ts +5 -5
  67. package/dist/common/src/mutation.schemas.js +114 -114
  68. package/dist/common/src/mutation.types.d.ts +63 -63
  69. package/dist/common/src/mutation.types.js +142 -142
  70. package/dist/common/src/named-query.context.d.ts +4 -4
  71. package/dist/common/src/named-query.context.js +9 -9
  72. package/dist/common/src/named-query.schemas.d.ts +3 -3
  73. package/dist/common/src/named-query.schemas.js +13 -13
  74. package/dist/common/src/named-query.types.d.ts +8 -8
  75. package/dist/common/src/named-query.types.js +2 -2
  76. package/dist/common/src/query/base-query-builder.d.ts +37 -37
  77. package/dist/common/src/query/base-query-builder.js +36 -36
  78. package/dist/common/src/query/index.d.ts +4 -4
  79. package/dist/common/src/query/index.js +20 -20
  80. package/dist/common/src/query/pagination.d.ts +42 -42
  81. package/dist/common/src/query/pagination.js +164 -164
  82. package/dist/common/src/query/query-context.d.ts +47 -47
  83. package/dist/common/src/query/query-context.js +159 -159
  84. package/dist/common/src/query/serialized-query.types.d.ts +24 -24
  85. package/dist/common/src/query/serialized-query.types.js +2 -2
  86. package/dist/common/src/query.types.d.ts +86 -86
  87. package/dist/common/src/query.types.js +153 -153
  88. package/dist/common/src/regions.d.ts +21 -21
  89. package/dist/common/src/regions.js +46 -46
  90. package/dist/common/src/schema/schema.types.d.ts +30 -30
  91. package/dist/common/src/schema/schema.types.js +172 -172
  92. package/dist/common/src/secret.schemas.d.ts +4 -4
  93. package/dist/common/src/secret.schemas.js +17 -17
  94. package/dist/common/src/secret.types.d.ts +65 -65
  95. package/dist/common/src/secret.types.js +5 -5
  96. package/dist/common/src/security.types.d.ts +3 -3
  97. package/dist/common/src/security.types.js +2 -2
  98. package/dist/common/src/socket.schemas.d.ts +3 -3
  99. package/dist/common/src/socket.schemas.js +58 -58
  100. package/dist/common/src/socket.types.d.ts +125 -125
  101. package/dist/common/src/socket.types.js +9 -9
  102. package/dist/common/src/socket.types.js.map +1 -1
  103. package/dist/common/src/time-units.d.ts +5 -5
  104. package/dist/common/src/time-units.js +8 -8
  105. package/dist/common/src/trigger.types.d.ts +15 -15
  106. package/dist/common/src/trigger.types.js +2 -2
  107. package/dist/common/src/types.d.ts +21 -21
  108. package/dist/common/src/types.js +2 -2
  109. package/dist/common/src/utils/array.d.ts +8 -8
  110. package/dist/common/src/utils/array.js +54 -54
  111. package/dist/common/src/utils/assert.d.ts +8 -8
  112. package/dist/common/src/utils/assert.js +49 -49
  113. package/dist/common/src/utils/error.d.ts +4 -4
  114. package/dist/common/src/utils/error.js +10 -10
  115. package/dist/common/src/utils/global.utils.d.ts +11 -11
  116. package/dist/common/src/utils/global.utils.js +50 -50
  117. package/dist/common/src/utils/http.d.ts +2 -2
  118. package/dist/common/src/utils/http.js +41 -41
  119. package/dist/common/src/utils/id.d.ts +2 -2
  120. package/dist/common/src/utils/id.js +21 -21
  121. package/dist/common/src/utils/lock.manager.d.ts +9 -9
  122. package/dist/common/src/utils/lock.manager.js +39 -39
  123. package/dist/common/src/utils/nullish.d.ts +2 -2
  124. package/dist/common/src/utils/nullish.js +11 -11
  125. package/dist/common/src/utils/object.d.ts +5 -5
  126. package/dist/common/src/utils/object.js +75 -75
  127. package/dist/common/src/utils/serialization.d.ts +6 -6
  128. package/dist/common/src/utils/serialization.js +77 -77
  129. package/dist/common/src/utils/transforms.d.ts +18 -18
  130. package/dist/common/src/utils/transforms.js +92 -92
  131. package/dist/common/src/utils/url.d.ts +1 -1
  132. package/dist/common/src/utils/url.js +15 -15
  133. package/dist/common/src/utils/validation.d.ts +17 -17
  134. package/dist/common/src/utils/validation.js +209 -209
  135. package/dist/common/src/webhook-response.d.ts +6 -6
  136. package/dist/common/src/webhook-response.js +2 -2
  137. package/dist/common/src/websocket.impl.d.ts +21 -21
  138. package/dist/common/src/websocket.impl.js +76 -76
  139. package/dist/internal-common/src/async-queue.d.ts +4 -4
  140. package/dist/internal-common/src/async-queue.js +17 -17
  141. package/dist/internal-common/src/code-executor.types.d.ts +13 -13
  142. package/dist/internal-common/src/code-executor.types.js +2 -2
  143. package/dist/internal-common/src/dao.types.d.ts +49 -49
  144. package/dist/internal-common/src/dao.types.js +2 -2
  145. package/dist/internal-common/src/environment/environment.types.d.ts +74 -74
  146. package/dist/internal-common/src/environment/environment.types.js +2 -2
  147. package/dist/internal-common/src/environment/index.d.ts +6 -6
  148. package/dist/internal-common/src/environment/index.js +27 -27
  149. package/dist/internal-common/src/environment/local.environment.d.ts +2 -2
  150. package/dist/internal-common/src/environment/local.environment.js +62 -62
  151. package/dist/internal-common/src/filters/custom-exception.filter.d.ts +6 -6
  152. package/dist/internal-common/src/filters/custom-exception.filter.js +44 -44
  153. package/dist/internal-common/src/filters/custom-exception.filter.js.map +1 -1
  154. package/dist/internal-common/src/index.d.ts +14 -14
  155. package/dist/internal-common/src/index.js +32 -32
  156. package/dist/internal-common/src/interceptors/body.interceptor.d.ts +5 -5
  157. package/dist/internal-common/src/interceptors/body.interceptor.js +24 -24
  158. package/dist/internal-common/src/interceptors/body.interceptor.js.map +1 -1
  159. package/dist/internal-common/src/kafka/kafka.manager.d.ts +22 -22
  160. package/dist/internal-common/src/kafka/kafka.manager.js +116 -116
  161. package/dist/internal-common/src/kafka/kafka.types.d.ts +17 -17
  162. package/dist/internal-common/src/kafka/kafka.types.js +2 -2
  163. package/dist/internal-common/src/kafka-observability-publisher.d.ts +11 -11
  164. package/dist/internal-common/src/kafka-observability-publisher.js +20 -20
  165. package/dist/internal-common/src/local-dev.types.d.ts +35 -35
  166. package/dist/internal-common/src/local-dev.types.js +2 -2
  167. package/dist/internal-common/src/observability-publisher.d.ts +9 -9
  168. package/dist/internal-common/src/observability-publisher.js +58 -58
  169. package/dist/internal-common/src/observability.types.d.ts +17 -17
  170. package/dist/internal-common/src/observability.types.js +2 -2
  171. package/dist/internal-common/src/shutdown.manager.d.ts +20 -20
  172. package/dist/internal-common/src/shutdown.manager.js +75 -75
  173. package/dist/internal-common/src/shutdown.manager.js.map +1 -1
  174. package/dist/internal-common/src/utils.d.ts +5 -5
  175. package/dist/internal-common/src/utils.js +29 -29
  176. package/dist/local-backend/src/index.d.ts +4 -4
  177. package/dist/local-backend/src/index.js +20 -20
  178. package/dist/local-backend/src/local-backend-socket.service.d.ts +19 -19
  179. package/dist/local-backend/src/local-backend-socket.service.js +110 -110
  180. package/dist/local-backend/src/local-backend-socket.service.js.map +1 -1
  181. package/dist/local-backend/src/local-backend.app.d.ts +2 -2
  182. package/dist/local-backend/src/local-backend.app.js +19 -19
  183. package/dist/local-backend/src/local-backend.controller.d.ts +8 -8
  184. package/dist/local-backend/src/local-backend.controller.js +49 -49
  185. package/dist/local-backend/src/local-backend.controller.js.map +1 -1
  186. package/dist/local-backend/src/local-backend.module.d.ts +8 -8
  187. package/dist/local-backend/src/local-backend.module.js +53 -53
  188. package/dist/local-backend/src/local-backend.module.js.map +1 -1
  189. package/dist/local-backend/src/local-backend.service.d.ts +15 -15
  190. package/dist/local-backend/src/local-backend.service.js +170 -170
  191. package/dist/local-backend/src/local-backend.service.js.map +1 -1
  192. package/dist/tsconfig.build.tsbuildinfo +1 -1
  193. package/package.json +8 -33
@@ -1,861 +1,881 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.DiscoverOpenApiSchemaRequestSchema = exports.UpdateAllowedHostsRequestSchema = exports.DiscoverGraphQLConnectionSchemaRequestSchema = exports.DiscoverDataConnectionSchemaRequestSchema = exports.TestDataConnectionRequestSchema = exports.DeleteIntegrationRequestSchema = exports.UpsertIntegrationSchemaRequestSchema = exports.UpsertIntegrationRequestSchema = exports.UpdateOpenIdProviderRequestSchema = void 0;
4
- const integrations_1 = require("./integrations");
5
- exports.UpdateOpenIdProviderRequestSchema = {
6
- type: 'object',
7
- required: ['openIdProvider'],
8
- properties: {
9
- openIdProvider: {
10
- type: 'object',
11
- required: ['providerType', 'clientId', 'domain'],
12
- properties: {
13
- providerType: { type: 'string', const: 'auth0' },
14
- clientId: { type: 'string', nullable: false },
15
- domain: { type: 'string', nullable: false },
16
- },
17
- },
18
- },
19
- };
20
- const MysqlConnectionOptionsSchema = {
21
- type: 'object',
22
- nullable: false,
23
- required: ['secrets', 'host', 'user', 'database'],
24
- properties: {
25
- host: { type: 'string', nullable: false },
26
- user: { type: 'string', nullable: false },
27
- database: { type: 'string', nullable: false },
28
- secrets: {
29
- type: 'object',
30
- required: ['password'],
31
- nullable: false,
32
- properties: {
33
- password: { type: 'string', nullable: false, isSecret: {} },
34
- },
35
- },
36
- connectionLimit: { type: 'number', nullable: false },
37
- },
38
- };
39
- const OracleConnectionOptionsSchema = {
40
- type: 'object',
41
- nullable: false,
42
- required: ['secrets', 'host', 'user', 'database'],
43
- properties: {
44
- host: { type: 'string', nullable: false },
45
- user: { type: 'string', nullable: false },
46
- database: { type: 'string', nullable: false },
47
- secrets: {
48
- type: 'object',
49
- required: ['password'],
50
- nullable: false,
51
- properties: {
52
- password: { type: 'string', nullable: false, isSecret: {} },
53
- },
54
- },
55
- connectionLimit: { type: 'number', nullable: false },
56
- },
57
- };
58
- const MssqlConnectionOptionsSchema = {
59
- type: 'object',
60
- nullable: false,
61
- required: ['secrets', 'host', 'user', 'database'],
62
- properties: {
63
- host: { type: 'string', nullable: false },
64
- user: { type: 'string', nullable: false },
65
- database: { type: 'string', nullable: false },
66
- secrets: {
67
- type: 'object',
68
- required: ['password'],
69
- nullable: false,
70
- properties: {
71
- password: { type: 'string', nullable: false, isSecret: {} },
72
- },
73
- },
74
- connectionLimit: { type: 'number', nullable: false },
75
- sslEnabled: { type: 'boolean', nullable: false },
76
- },
77
- };
78
- const PostgresConnectionOptionsSchema = {
79
- type: 'object',
80
- nullable: false,
81
- required: ['secrets', 'host', 'user', 'database'],
82
- properties: {
83
- host: { type: 'string', nullable: false },
84
- user: { type: 'string', nullable: false },
85
- database: { type: 'string', nullable: false },
86
- schema: { type: 'string', nullable: true },
87
- sslEnabled: { type: 'boolean', nullable: true },
88
- secrets: {
89
- type: 'object',
90
- required: ['password'],
91
- nullable: false,
92
- properties: {
93
- password: { type: 'string', nullable: false, isSecret: {} },
94
- sslCertificate: { type: 'string', nullable: true, isSecret: {} },
95
- },
96
- },
97
- connectionLimit: { type: 'number', nullable: false },
98
- },
99
- };
100
- const MongoConnectionOptionsSchema = {
101
- type: 'object',
102
- nullable: false,
103
- required: ['connectionString'],
104
- properties: {
105
- connectionString: { type: 'string', nullable: false },
106
- user: { type: 'string', nullable: true },
107
- secrets: {
108
- type: 'object',
109
- nullable: false,
110
- properties: {
111
- password: { type: 'string', nullable: false, isSecret: {} },
112
- },
113
- },
114
- maxPoolSize: { type: 'number', nullable: false },
115
- minPoolSize: { type: 'number', nullable: false },
116
- socketTimeoutMS: { type: 'number', nullable: false },
117
- keepAlive: { type: 'boolean', nullable: false },
118
- directConnection: { type: 'boolean', nullable: false },
119
- ssl: {
120
- type: 'object',
121
- nullable: false,
122
- required: ['certificateFile', 'validate'],
123
- properties: {
124
- certificateFile: { type: 'string', nullable: false },
125
- validate: { type: 'boolean', nullable: false },
126
- },
127
- },
128
- },
129
- };
130
- const GraphQLConnectionOptionsSchema = {
131
- type: 'object',
132
- nullable: false,
133
- required: ['baseUrl'],
134
- properties: {
135
- baseUrl: { type: 'string', nullable: false, format: 'uri' },
136
- },
137
- };
138
- const OpenApiDiscoveryOptionsSchema = {
139
- type: 'object',
140
- nullable: false,
141
- required: ['openApiSpecUrl'],
142
- properties: {
143
- openApiSpecUrl: { type: 'string', nullable: false },
144
- },
145
- };
146
- const ApiEndpointsSchema = {
147
- type: 'object',
148
- patternProperties: {
149
- '^\\S+$': {
150
- type: 'object',
151
- required: ['relativePath', 'method'],
152
- properties: {
153
- relativePath: {
154
- type: 'string',
155
- },
156
- method: {
157
- type: 'string',
158
- enum: ['post', 'get', 'delete', 'patch', 'put'],
159
- },
160
- requestSchema: {
161
- type: 'object',
162
- patternProperties: {
163
- '^\\S+$': {
164
- type: 'object',
165
- properties: {
166
- location: {
167
- type: 'string',
168
- enum: ['query', 'body', 'header', 'path'],
169
- },
170
- fieldNameInRequest: {
171
- type: 'string',
172
- },
173
- },
174
- },
175
- },
176
- },
177
- responseSchema: {
178
- type: 'object',
179
- patternProperties: {
180
- '^\\S+$': {
181
- type: 'object',
182
- required: ['location'],
183
- properties: {
184
- location: {
185
- type: 'string',
186
- enum: ['body', 'header'],
187
- },
188
- path: {
189
- type: 'string',
190
- },
191
- },
192
- },
193
- },
194
- },
195
- },
196
- },
197
- },
198
- };
199
- const SnowflakeConnectionOptionsSchema = {
200
- type: 'object',
201
- required: [],
202
- properties: {
203
- account: { type: 'string', nullable: false },
204
- username: { type: 'string', nullable: false },
205
- database: { type: 'string', nullable: false },
206
- schema: { type: 'string', nullable: false },
207
- warehouse: { type: 'string', nullable: false },
208
- role: { type: 'string', nullable: false },
209
- secrets: {
210
- type: 'object',
211
- required: ['password'],
212
- nullable: false,
213
- properties: {
214
- password: { type: 'string', nullable: false, isSecret: {} },
215
- },
216
- },
217
- },
218
- };
219
- const JwtValidationsSchema = {
220
- type: 'object',
221
- nullable: true,
222
- properties: {
223
- iss: { type: 'string', nullable: true },
224
- aud: { type: 'string', nullable: true },
225
- },
226
- };
227
- exports.UpsertIntegrationRequestSchema = {
228
- type: 'object',
229
- required: ['id', 'type', 'config'],
230
- properties: {
231
- id: { type: 'string', nullable: false },
232
- },
233
- oneOf: [
234
- {
235
- type: 'object',
236
- required: [],
237
- properties: {
238
- type: { const: integrations_1.IntegrationType.built_in_db },
239
- },
240
- },
241
- {
242
- type: 'object',
243
- properties: {
244
- type: { const: integrations_1.IntegrationType.mysql },
245
- config: {
246
- type: 'object',
247
- required: ['configuration'],
248
- properties: {
249
- supportsExternalChanges: { type: 'boolean', nullable: true },
250
- configuration: {
251
- type: 'object',
252
- nullable: false,
253
- required: ['connectionOptions'],
254
- properties: {
255
- connectionOptions: MysqlConnectionOptionsSchema,
256
- },
257
- },
258
- },
259
- },
260
- },
261
- },
262
- {
263
- type: 'object',
264
- properties: {
265
- type: { const: integrations_1.IntegrationType.oracledb },
266
- config: {
267
- type: 'object',
268
- required: ['configuration'],
269
- properties: {
270
- supportsExternalChanges: { type: 'boolean', nullable: true },
271
- configuration: {
272
- type: 'object',
273
- nullable: false,
274
- required: ['connectionOptions'],
275
- properties: {
276
- connectionOptions: OracleConnectionOptionsSchema,
277
- },
278
- },
279
- },
280
- },
281
- },
282
- },
283
- {
284
- type: 'object',
285
- properties: {
286
- type: { const: integrations_1.IntegrationType.mssql },
287
- config: {
288
- type: 'object',
289
- required: ['configuration'],
290
- properties: {
291
- supportsExternalChanges: { type: 'boolean', nullable: true },
292
- configuration: {
293
- type: 'object',
294
- nullable: false,
295
- required: ['connectionOptions'],
296
- properties: {
297
- connectionOptions: MssqlConnectionOptionsSchema,
298
- },
299
- },
300
- },
301
- },
302
- },
303
- },
304
- {
305
- type: 'object',
306
- properties: {
307
- type: { const: integrations_1.IntegrationType.postgres },
308
- config: {
309
- type: 'object',
310
- required: ['configuration'],
311
- properties: {
312
- supportsExternalChanges: { type: 'boolean', nullable: true },
313
- configuration: {
314
- type: 'object',
315
- nullable: false,
316
- required: ['connectionOptions'],
317
- properties: {
318
- connectionOptions: PostgresConnectionOptionsSchema,
319
- },
320
- },
321
- },
322
- },
323
- },
324
- },
325
- {
326
- type: 'object',
327
- properties: {
328
- type: { const: integrations_1.IntegrationType.cockroach },
329
- config: {
330
- type: 'object',
331
- required: ['configuration'],
332
- properties: {
333
- configuration: {
334
- type: 'object',
335
- nullable: false,
336
- required: ['connectionOptions'],
337
- properties: {
338
- connectionOptions: PostgresConnectionOptionsSchema,
339
- },
340
- },
341
- },
342
- },
343
- },
344
- },
345
- {
346
- type: 'object',
347
- properties: {
348
- type: { const: integrations_1.IntegrationType.mongo },
349
- config: {
350
- type: 'object',
351
- required: ['configuration'],
352
- properties: {
353
- supportsExternalChanges: { type: 'boolean', nullable: true },
354
- configuration: {
355
- type: 'object',
356
- nullable: false,
357
- required: ['connectionOptions'],
358
- properties: {
359
- connectionOptions: MongoConnectionOptionsSchema,
360
- },
361
- },
362
- },
363
- },
364
- },
365
- },
366
- {
367
- type: 'object',
368
- properties: {
369
- type: { const: integrations_1.IntegrationType.api },
370
- config: {
371
- type: 'object',
372
- properties: {
373
- configuration: {
374
- type: 'object',
375
- nullable: true,
376
- required: ['discoveryOptions'],
377
- properties: {
378
- discoveryOptions: OpenApiDiscoveryOptionsSchema,
379
- },
380
- },
381
- },
382
- },
383
- },
384
- },
385
- {
386
- type: 'object',
387
- properties: {
388
- type: { const: integrations_1.IntegrationType.graphql },
389
- config: {
390
- type: 'object',
391
- required: ['configuration'],
392
- properties: {
393
- configuration: {
394
- type: 'object',
395
- nullable: false,
396
- required: ['connectionOptions'],
397
- properties: {
398
- connectionOptions: GraphQLConnectionOptionsSchema,
399
- },
400
- },
401
- },
402
- },
403
- },
404
- },
405
- {
406
- type: 'object',
407
- properties: {
408
- type: { const: integrations_1.IntegrationType.snowflake },
409
- config: {
410
- type: 'object',
411
- required: ['configuration'],
412
- properties: {
413
- configuration: {
414
- type: 'object',
415
- nullable: false,
416
- required: ['connectionOptions'],
417
- properties: {
418
- connectionOptions: SnowflakeConnectionOptionsSchema,
419
- },
420
- },
421
- },
422
- },
423
- },
424
- },
425
- {
426
- type: 'object',
427
- properties: {
428
- type: { const: integrations_1.IntegrationType.datadog },
429
- config: {
430
- type: 'object',
431
- required: ['configuration'],
432
- properties: {
433
- configuration: {
434
- type: 'object',
435
- nullable: false,
436
- required: ['apiKey', 'appKey', 'datadogRegion'],
437
- properties: {
438
- apiKey: { type: 'string', nullable: false, isSecret: {} },
439
- appKey: { type: 'string', nullable: false, isSecret: {} },
440
- datadogRegion: { type: 'string', nullable: false, enum: Object.keys(integrations_1.datadogRegionMap) },
441
- },
442
- },
443
- },
444
- },
445
- },
446
- },
447
- {
448
- type: 'object',
449
- properties: {
450
- type: { const: integrations_1.IntegrationType.newrelic },
451
- config: {
452
- type: 'object',
453
- required: ['configuration'],
454
- properties: {
455
- configuration: {
456
- type: 'object',
457
- nullable: false,
458
- required: ['apiKey', 'newRelicRegion'],
459
- properties: {
460
- apiKey: { type: 'string', nullable: false, isSecret: {} },
461
- newRelicRegion: { type: 'string', nullable: false, enum: Object.keys(integrations_1.newRelicRegionMap) },
462
- },
463
- },
464
- },
465
- },
466
- },
467
- },
468
- {
469
- type: 'object',
470
- properties: {
471
- type: { const: integrations_1.IntegrationType.auth0 },
472
- config: {
473
- type: 'object',
474
- required: ['configuration'],
475
- properties: {
476
- configuration: {
477
- type: 'object',
478
- nullable: false,
479
- required: ['clientId', 'domain'],
480
- properties: {
481
- clientId: { type: 'string', nullable: false },
482
- domain: { type: 'string', nullable: false },
483
- },
484
- },
485
- },
486
- },
487
- },
488
- },
489
- {
490
- type: 'object',
491
- properties: {
492
- type: { const: integrations_1.IntegrationType.jwt_rsa },
493
- config: {
494
- type: 'object',
495
- required: ['configuration'],
496
- properties: {
497
- configuration: {
498
- type: 'object',
499
- nullable: false,
500
- required: ['jwksUri'],
501
- properties: {
502
- jwksUri: { type: 'string', nullable: false },
503
- validations: JwtValidationsSchema,
504
- },
505
- },
506
- },
507
- },
508
- },
509
- },
510
- {
511
- type: 'object',
512
- properties: {
513
- type: { const: integrations_1.IntegrationType.jwt_hmac },
514
- config: {
515
- type: 'object',
516
- required: ['configuration'],
517
- properties: {
518
- configuration: {
519
- type: 'object',
520
- nullable: false,
521
- required: ['verifyUri'],
522
- properties: {
523
- verifyUri: { type: 'string', nullable: false },
524
- },
525
- },
526
- },
527
- },
528
- },
529
- },
530
- {
531
- type: 'object',
532
- properties: {
533
- type: { const: integrations_1.IntegrationType.ai_assistant },
534
- config: {
535
- type: 'object',
536
- properties: {
537
- configuration: {
538
- type: 'object',
539
- nullable: false,
540
- required: [],
541
- properties: {
542
- apiKey: { type: 'string', nullable: false },
543
- },
544
- },
545
- },
546
- },
547
- },
548
- },
549
- {
550
- type: 'object',
551
- properties: {
552
- type: { const: integrations_1.IntegrationType.cognito },
553
- config: {
554
- type: 'object',
555
- required: ['configuration'],
556
- properties: {
557
- configuration: {
558
- type: 'object',
559
- required: ['region', 'userPoolId', 'appClientId'],
560
- properties: {
561
- region: { type: 'string' },
562
- userPoolId: { type: 'string' },
563
- appClientId: { type: 'string' },
564
- },
565
- },
566
- },
567
- },
568
- },
569
- },
570
- {
571
- type: 'object',
572
- properties: {
573
- type: { const: integrations_1.IntegrationType.okta },
574
- config: {
575
- type: 'object',
576
- required: ['configuration'],
577
- properties: {
578
- configuration: {
579
- type: 'object',
580
- required: ['domain', 'clientId'],
581
- properties: {
582
- domain: { type: 'string' },
583
- clientId: { type: 'string' },
584
- },
585
- },
586
- },
587
- },
588
- },
589
- },
590
- ],
591
- };
592
- exports.UpsertIntegrationSchemaRequestSchema = {
593
- type: 'object',
594
- required: ['id', 'type', 'schema'],
595
- properties: {
596
- id: { type: 'string', nullable: false },
597
- type: { type: 'string', nullable: false },
598
- schema: {
599
- oneOf: [
600
- {
601
- type: 'object',
602
- required: ['type', 'collections'],
603
- properties: {
604
- type: { const: integrations_1.IntegrationSchemaType.data },
605
- collections: { type: 'object', nullable: false },
606
- },
607
- },
608
- {
609
- type: 'object',
610
- required: ['type', 'baseUrl', 'endpoints'],
611
- properties: {
612
- type: { const: integrations_1.IntegrationSchemaType.api },
613
- baseUrl: { type: 'string', nullable: false },
614
- endpoints: { type: 'object', nullable: false },
615
- },
616
- },
617
- {
618
- type: 'object',
619
- required: ['type', 'introspection'],
620
- properties: {
621
- type: { const: integrations_1.IntegrationSchemaType.graphql },
622
- introspection: { type: 'object', nullable: false },
623
- },
624
- },
625
- ],
626
- },
627
- },
628
- };
629
- exports.DeleteIntegrationRequestSchema = {
630
- type: 'object',
631
- required: ['integrationId'],
632
- properties: {
633
- integrationId: { type: 'string', nullable: false },
634
- },
635
- };
636
- exports.TestDataConnectionRequestSchema = {
637
- type: 'object',
638
- required: ['type', 'configuration'],
639
- oneOf: [
640
- {
641
- type: 'object',
642
- required: ['configuration'],
643
- properties: {
644
- type: { const: integrations_1.IntegrationType.mysql },
645
- configuration: {
646
- type: 'object',
647
- required: ['connectionOptions'],
648
- properties: {
649
- connectionOptions: MysqlConnectionOptionsSchema,
650
- },
651
- },
652
- },
653
- },
654
- {
655
- type: 'object',
656
- required: ['configuration'],
657
- properties: {
658
- type: { const: integrations_1.IntegrationType.oracledb },
659
- configuration: {
660
- type: 'object',
661
- required: ['connectionOptions'],
662
- properties: {
663
- connectionOptions: OracleConnectionOptionsSchema,
664
- },
665
- },
666
- },
667
- },
668
- {
669
- type: 'object',
670
- required: ['configuration'],
671
- properties: {
672
- type: { const: integrations_1.IntegrationType.mssql },
673
- configuration: {
674
- type: 'object',
675
- required: ['connectionOptions'],
676
- properties: {
677
- connectionOptions: MssqlConnectionOptionsSchema,
678
- },
679
- },
680
- },
681
- },
682
- {
683
- type: 'object',
684
- required: ['configuration'],
685
- properties: {
686
- type: { const: integrations_1.IntegrationType.postgres },
687
- configuration: {
688
- type: 'object',
689
- required: ['connectionOptions'],
690
- properties: {
691
- connectionOptions: PostgresConnectionOptionsSchema,
692
- },
693
- },
694
- },
695
- },
696
- {
697
- type: 'object',
698
- required: ['configuration'],
699
- properties: {
700
- type: { const: integrations_1.IntegrationType.cockroach },
701
- configuration: {
702
- type: 'object',
703
- required: ['connectionOptions'],
704
- properties: {
705
- connectionOptions: PostgresConnectionOptionsSchema,
706
- },
707
- },
708
- },
709
- },
710
- {
711
- type: 'object',
712
- required: ['configuration'],
713
- properties: {
714
- type: { const: integrations_1.IntegrationType.mongo },
715
- configuration: {
716
- type: 'object',
717
- required: ['connectionOptions'],
718
- properties: {
719
- connectionOptions: MongoConnectionOptionsSchema,
720
- },
721
- },
722
- },
723
- },
724
- {
725
- type: 'object',
726
- required: ['configuration'],
727
- properties: {
728
- type: { const: integrations_1.IntegrationType.snowflake },
729
- configuration: {
730
- type: 'object',
731
- required: ['connectionOptions'],
732
- properties: {
733
- connectionOptions: SnowflakeConnectionOptionsSchema,
734
- },
735
- },
736
- },
737
- },
738
- {
739
- type: 'object',
740
- required: ['configuration'],
741
- properties: {
742
- type: { const: integrations_1.IntegrationType.graphql },
743
- configuration: {
744
- type: 'object',
745
- required: ['connectionOptions'],
746
- properties: {
747
- connectionOptions: GraphQLConnectionOptionsSchema,
748
- },
749
- },
750
- },
751
- },
752
- ],
753
- };
754
- exports.DiscoverDataConnectionSchemaRequestSchema = {
755
- type: 'object',
756
- required: ['integrationType'],
757
- oneOf: [
758
- {
759
- type: 'object',
760
- required: ['connectionOptions'],
761
- properties: {
762
- integrationType: { const: integrations_1.IntegrationType.mysql },
763
- connectionOptions: MysqlConnectionOptionsSchema,
764
- },
765
- },
766
- {
767
- type: 'object',
768
- required: ['connectionOptions'],
769
- properties: {
770
- integrationType: { const: integrations_1.IntegrationType.oracledb },
771
- connectionOptions: OracleConnectionOptionsSchema,
772
- },
773
- },
774
- {
775
- type: 'object',
776
- required: ['connectionOptions'],
777
- properties: {
778
- integrationType: { const: integrations_1.IntegrationType.mssql },
779
- connectionOptions: MssqlConnectionOptionsSchema,
780
- },
781
- },
782
- {
783
- type: 'object',
784
- required: ['connectionOptions'],
785
- properties: {
786
- integrationType: { const: integrations_1.IntegrationType.snowflake },
787
- connectionOptions: SnowflakeConnectionOptionsSchema,
788
- },
789
- },
790
- {
791
- type: 'object',
792
- required: ['connectionOptions'],
793
- properties: {
794
- integrationType: { const: integrations_1.IntegrationType.postgres },
795
- connectionOptions: PostgresConnectionOptionsSchema,
796
- },
797
- },
798
- {
799
- type: 'object',
800
- required: ['connectionOptions'],
801
- properties: {
802
- integrationType: { const: integrations_1.IntegrationType.cockroach },
803
- connectionOptions: PostgresConnectionOptionsSchema,
804
- },
805
- },
806
- {
807
- type: 'object',
808
- required: ['connectionOptions'],
809
- properties: {
810
- integrationType: { const: integrations_1.IntegrationType.mongo },
811
- connectionOptions: MongoConnectionOptionsSchema,
812
- },
813
- },
814
- {
815
- type: 'object',
816
- properties: {
817
- integrationType: { const: integrations_1.IntegrationType.built_in_db },
818
- },
819
- },
820
- ],
821
- };
822
- exports.DiscoverGraphQLConnectionSchemaRequestSchema = {
823
- type: 'object',
824
- required: ['integrationType'],
825
- properties: {
826
- integrationType: { const: integrations_1.IntegrationType.graphql },
827
- connectionOptions: GraphQLConnectionOptionsSchema,
828
- },
829
- };
830
- exports.UpdateAllowedHostsRequestSchema = {
831
- type: 'object',
832
- required: ['allowedHosts'],
833
- properties: {
834
- allowedHosts: {
835
- type: 'array',
836
- nullable: false,
837
- minItems: 1,
838
- items: {
839
- type: 'string',
840
- nullable: false,
841
- },
842
- },
843
- },
844
- };
845
- exports.DiscoverOpenApiSchemaRequestSchema = {
846
- type: 'object',
847
- required: ['discoveryOptions'],
848
- properties: {
849
- discoveryOptions: {
850
- type: 'object',
851
- required: ['openApiSpecUrl'],
852
- properties: {
853
- openApiSpecUrl: {
854
- type: 'string',
855
- format: 'uri',
856
- },
857
- },
858
- },
859
- },
860
- };
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.GetAiAssistantProfilesSchema = exports.GetSchemaSchema = exports.DiscoverOpenApiSchemaRequestSchema = exports.UpdateAllowedHostsRequestSchema = exports.DiscoverGraphQLConnectionSchemaRequestSchema = exports.DiscoverDataConnectionSchemaRequestSchema = exports.TestDataConnectionRequestSchema = exports.DeleteIntegrationRequestSchema = exports.UpsertIntegrationSchemaRequestSchema = exports.UpsertIntegrationRequestSchema = exports.UpdateOpenIdProviderRequestSchema = void 0;
4
+ const integrations_1 = require("./integrations");
5
+ exports.UpdateOpenIdProviderRequestSchema = {
6
+ type: 'object',
7
+ required: ['openIdProvider'],
8
+ properties: {
9
+ openIdProvider: {
10
+ type: 'object',
11
+ required: ['providerType', 'clientId', 'domain'],
12
+ properties: {
13
+ providerType: { type: 'string', const: 'auth0' },
14
+ clientId: { type: 'string', nullable: false },
15
+ domain: { type: 'string', nullable: false },
16
+ },
17
+ },
18
+ },
19
+ };
20
+ const MysqlConnectionOptionsSchema = {
21
+ type: 'object',
22
+ nullable: false,
23
+ required: ['secrets', 'host', 'user', 'database'],
24
+ properties: {
25
+ host: { type: 'string', nullable: false },
26
+ user: { type: 'string', nullable: false },
27
+ database: { type: 'string', nullable: false },
28
+ secrets: {
29
+ type: 'object',
30
+ required: ['password'],
31
+ nullable: false,
32
+ properties: {
33
+ password: { type: 'string', nullable: false, isSecret: {} },
34
+ },
35
+ },
36
+ connectionLimit: { type: 'number', nullable: false },
37
+ },
38
+ };
39
+ const OracleConnectionOptionsSchema = {
40
+ type: 'object',
41
+ nullable: false,
42
+ required: ['secrets', 'host', 'user', 'database'],
43
+ properties: {
44
+ host: { type: 'string', nullable: false },
45
+ user: { type: 'string', nullable: false },
46
+ database: { type: 'string', nullable: false },
47
+ secrets: {
48
+ type: 'object',
49
+ required: ['password'],
50
+ nullable: false,
51
+ properties: {
52
+ password: { type: 'string', nullable: false, isSecret: {} },
53
+ },
54
+ },
55
+ connectionLimit: { type: 'number', nullable: false },
56
+ },
57
+ };
58
+ const MssqlConnectionOptionsSchema = {
59
+ type: 'object',
60
+ nullable: false,
61
+ required: ['secrets', 'host', 'user', 'database'],
62
+ properties: {
63
+ host: { type: 'string', nullable: false },
64
+ user: { type: 'string', nullable: false },
65
+ database: { type: 'string', nullable: false },
66
+ secrets: {
67
+ type: 'object',
68
+ required: ['password'],
69
+ nullable: false,
70
+ properties: {
71
+ password: { type: 'string', nullable: false, isSecret: {} },
72
+ },
73
+ },
74
+ connectionLimit: { type: 'number', nullable: false },
75
+ sslEnabled: { type: 'boolean', nullable: false },
76
+ },
77
+ };
78
+ const PostgresConnectionOptionsSchema = {
79
+ type: 'object',
80
+ nullable: false,
81
+ required: ['secrets', 'host', 'user', 'database'],
82
+ properties: {
83
+ host: { type: 'string', nullable: false },
84
+ user: { type: 'string', nullable: false },
85
+ database: { type: 'string', nullable: false },
86
+ schema: { type: 'string', nullable: true },
87
+ sslEnabled: { type: 'boolean', nullable: true },
88
+ secrets: {
89
+ type: 'object',
90
+ required: ['password'],
91
+ nullable: false,
92
+ properties: {
93
+ password: { type: 'string', nullable: false, isSecret: {} },
94
+ sslCertificate: { type: 'string', nullable: true, isSecret: {} },
95
+ },
96
+ },
97
+ connectionLimit: { type: 'number', nullable: false },
98
+ },
99
+ };
100
+ const MongoConnectionOptionsSchema = {
101
+ type: 'object',
102
+ nullable: false,
103
+ required: ['connectionString'],
104
+ properties: {
105
+ connectionString: { type: 'string', nullable: false },
106
+ user: { type: 'string', nullable: true },
107
+ secrets: {
108
+ type: 'object',
109
+ nullable: false,
110
+ properties: {
111
+ password: { type: 'string', nullable: false, isSecret: {} },
112
+ },
113
+ },
114
+ maxPoolSize: { type: 'number', nullable: false },
115
+ minPoolSize: { type: 'number', nullable: false },
116
+ socketTimeoutMS: { type: 'number', nullable: false },
117
+ keepAlive: { type: 'boolean', nullable: false },
118
+ directConnection: { type: 'boolean', nullable: false },
119
+ ssl: {
120
+ type: 'object',
121
+ nullable: false,
122
+ required: ['certificateFile', 'validate'],
123
+ properties: {
124
+ certificateFile: { type: 'string', nullable: false },
125
+ validate: { type: 'boolean', nullable: false },
126
+ },
127
+ },
128
+ },
129
+ };
130
+ const GraphQLConnectionOptionsSchema = {
131
+ type: 'object',
132
+ nullable: false,
133
+ required: ['baseUrl'],
134
+ properties: {
135
+ baseUrl: { type: 'string', nullable: false, format: 'uri' },
136
+ },
137
+ };
138
+ const OpenApiDiscoveryOptionsSchema = {
139
+ type: 'object',
140
+ nullable: false,
141
+ required: ['openApiSpecUrl'],
142
+ properties: {
143
+ openApiSpecUrl: { type: 'string', nullable: false },
144
+ },
145
+ };
146
+ const ApiEndpointsSchema = {
147
+ type: 'object',
148
+ patternProperties: {
149
+ '^\\S+$': {
150
+ type: 'object',
151
+ required: ['relativePath', 'method'],
152
+ properties: {
153
+ relativePath: {
154
+ type: 'string',
155
+ },
156
+ method: {
157
+ type: 'string',
158
+ enum: ['post', 'get', 'delete', 'patch', 'put'],
159
+ },
160
+ requestSchema: {
161
+ type: 'object',
162
+ patternProperties: {
163
+ '^\\S+$': {
164
+ type: 'object',
165
+ properties: {
166
+ location: {
167
+ type: 'string',
168
+ enum: ['query', 'body', 'header', 'path'],
169
+ },
170
+ fieldNameInRequest: {
171
+ type: 'string',
172
+ },
173
+ },
174
+ },
175
+ },
176
+ },
177
+ responseSchema: {
178
+ type: 'object',
179
+ patternProperties: {
180
+ '^\\S+$': {
181
+ type: 'object',
182
+ required: ['location'],
183
+ properties: {
184
+ location: {
185
+ type: 'string',
186
+ enum: ['body', 'header'],
187
+ },
188
+ path: {
189
+ type: 'string',
190
+ },
191
+ },
192
+ },
193
+ },
194
+ },
195
+ },
196
+ },
197
+ },
198
+ };
199
+ const SnowflakeConnectionOptionsSchema = {
200
+ type: 'object',
201
+ required: [],
202
+ properties: {
203
+ account: { type: 'string', nullable: false },
204
+ username: { type: 'string', nullable: false },
205
+ database: { type: 'string', nullable: false },
206
+ schema: { type: 'string', nullable: false },
207
+ warehouse: { type: 'string', nullable: false },
208
+ role: { type: 'string', nullable: false },
209
+ secrets: {
210
+ type: 'object',
211
+ required: ['password'],
212
+ nullable: false,
213
+ properties: {
214
+ password: { type: 'string', nullable: false, isSecret: {} },
215
+ },
216
+ },
217
+ },
218
+ };
219
+ const JwtValidationsSchema = {
220
+ type: 'object',
221
+ nullable: true,
222
+ properties: {
223
+ iss: { type: 'string', nullable: true },
224
+ aud: { type: 'string', nullable: true },
225
+ },
226
+ };
227
+ exports.UpsertIntegrationRequestSchema = {
228
+ type: 'object',
229
+ required: ['id', 'type', 'config'],
230
+ properties: {
231
+ id: { type: 'string', nullable: false },
232
+ },
233
+ oneOf: [
234
+ {
235
+ type: 'object',
236
+ required: [],
237
+ properties: {
238
+ type: { const: integrations_1.IntegrationType.built_in_db },
239
+ },
240
+ },
241
+ {
242
+ type: 'object',
243
+ properties: {
244
+ type: { const: integrations_1.IntegrationType.mysql },
245
+ config: {
246
+ type: 'object',
247
+ required: ['configuration'],
248
+ properties: {
249
+ supportsExternalChanges: { type: 'boolean', nullable: true },
250
+ configuration: {
251
+ type: 'object',
252
+ nullable: false,
253
+ required: ['connectionOptions'],
254
+ properties: {
255
+ connectionOptions: MysqlConnectionOptionsSchema,
256
+ },
257
+ },
258
+ },
259
+ },
260
+ },
261
+ },
262
+ {
263
+ type: 'object',
264
+ properties: {
265
+ type: { const: integrations_1.IntegrationType.oracledb },
266
+ config: {
267
+ type: 'object',
268
+ required: ['configuration'],
269
+ properties: {
270
+ supportsExternalChanges: { type: 'boolean', nullable: true },
271
+ configuration: {
272
+ type: 'object',
273
+ nullable: false,
274
+ required: ['connectionOptions'],
275
+ properties: {
276
+ connectionOptions: OracleConnectionOptionsSchema,
277
+ },
278
+ },
279
+ },
280
+ },
281
+ },
282
+ },
283
+ {
284
+ type: 'object',
285
+ properties: {
286
+ type: { const: integrations_1.IntegrationType.mssql },
287
+ config: {
288
+ type: 'object',
289
+ required: ['configuration'],
290
+ properties: {
291
+ supportsExternalChanges: { type: 'boolean', nullable: true },
292
+ configuration: {
293
+ type: 'object',
294
+ nullable: false,
295
+ required: ['connectionOptions'],
296
+ properties: {
297
+ connectionOptions: MssqlConnectionOptionsSchema,
298
+ },
299
+ },
300
+ },
301
+ },
302
+ },
303
+ },
304
+ {
305
+ type: 'object',
306
+ properties: {
307
+ type: { const: integrations_1.IntegrationType.postgres },
308
+ config: {
309
+ type: 'object',
310
+ required: ['configuration'],
311
+ properties: {
312
+ supportsExternalChanges: { type: 'boolean', nullable: true },
313
+ configuration: {
314
+ type: 'object',
315
+ nullable: false,
316
+ required: ['connectionOptions'],
317
+ properties: {
318
+ connectionOptions: PostgresConnectionOptionsSchema,
319
+ },
320
+ },
321
+ },
322
+ },
323
+ },
324
+ },
325
+ {
326
+ type: 'object',
327
+ properties: {
328
+ type: { const: integrations_1.IntegrationType.cockroach },
329
+ config: {
330
+ type: 'object',
331
+ required: ['configuration'],
332
+ properties: {
333
+ configuration: {
334
+ type: 'object',
335
+ nullable: false,
336
+ required: ['connectionOptions'],
337
+ properties: {
338
+ connectionOptions: PostgresConnectionOptionsSchema,
339
+ },
340
+ },
341
+ },
342
+ },
343
+ },
344
+ },
345
+ {
346
+ type: 'object',
347
+ properties: {
348
+ type: { const: integrations_1.IntegrationType.mongo },
349
+ config: {
350
+ type: 'object',
351
+ required: ['configuration'],
352
+ properties: {
353
+ supportsExternalChanges: { type: 'boolean', nullable: true },
354
+ configuration: {
355
+ type: 'object',
356
+ nullable: false,
357
+ required: ['connectionOptions'],
358
+ properties: {
359
+ connectionOptions: MongoConnectionOptionsSchema,
360
+ },
361
+ },
362
+ },
363
+ },
364
+ },
365
+ },
366
+ {
367
+ type: 'object',
368
+ properties: {
369
+ type: { const: integrations_1.IntegrationType.api },
370
+ config: {
371
+ type: 'object',
372
+ properties: {
373
+ configuration: {
374
+ type: 'object',
375
+ nullable: true,
376
+ required: ['discoveryOptions'],
377
+ properties: {
378
+ discoveryOptions: OpenApiDiscoveryOptionsSchema,
379
+ },
380
+ },
381
+ },
382
+ },
383
+ },
384
+ },
385
+ {
386
+ type: 'object',
387
+ properties: {
388
+ type: { const: integrations_1.IntegrationType.graphql },
389
+ config: {
390
+ type: 'object',
391
+ required: ['configuration'],
392
+ properties: {
393
+ configuration: {
394
+ type: 'object',
395
+ nullable: false,
396
+ required: ['connectionOptions'],
397
+ properties: {
398
+ connectionOptions: GraphQLConnectionOptionsSchema,
399
+ },
400
+ },
401
+ },
402
+ },
403
+ },
404
+ },
405
+ {
406
+ type: 'object',
407
+ properties: {
408
+ type: { const: integrations_1.IntegrationType.snowflake },
409
+ config: {
410
+ type: 'object',
411
+ required: ['configuration'],
412
+ properties: {
413
+ configuration: {
414
+ type: 'object',
415
+ nullable: false,
416
+ required: ['connectionOptions'],
417
+ properties: {
418
+ connectionOptions: SnowflakeConnectionOptionsSchema,
419
+ },
420
+ },
421
+ },
422
+ },
423
+ },
424
+ },
425
+ {
426
+ type: 'object',
427
+ properties: {
428
+ type: { const: integrations_1.IntegrationType.datadog },
429
+ config: {
430
+ type: 'object',
431
+ required: ['configuration'],
432
+ properties: {
433
+ configuration: {
434
+ type: 'object',
435
+ nullable: false,
436
+ required: ['apiKey', 'appKey', 'datadogRegion'],
437
+ properties: {
438
+ apiKey: { type: 'string', nullable: false, isSecret: {} },
439
+ appKey: { type: 'string', nullable: false, isSecret: {} },
440
+ datadogRegion: { type: 'string', nullable: false, enum: Object.keys(integrations_1.datadogRegionMap) },
441
+ },
442
+ },
443
+ },
444
+ },
445
+ },
446
+ },
447
+ {
448
+ type: 'object',
449
+ properties: {
450
+ type: { const: integrations_1.IntegrationType.newrelic },
451
+ config: {
452
+ type: 'object',
453
+ required: ['configuration'],
454
+ properties: {
455
+ configuration: {
456
+ type: 'object',
457
+ nullable: false,
458
+ required: ['apiKey', 'newRelicRegion'],
459
+ properties: {
460
+ apiKey: { type: 'string', nullable: false, isSecret: {} },
461
+ newRelicRegion: { type: 'string', nullable: false, enum: Object.keys(integrations_1.newRelicRegionMap) },
462
+ },
463
+ },
464
+ },
465
+ },
466
+ },
467
+ },
468
+ {
469
+ type: 'object',
470
+ properties: {
471
+ type: { const: integrations_1.IntegrationType.auth0 },
472
+ config: {
473
+ type: 'object',
474
+ required: ['configuration'],
475
+ properties: {
476
+ configuration: {
477
+ type: 'object',
478
+ nullable: false,
479
+ required: ['clientId', 'domain'],
480
+ properties: {
481
+ clientId: { type: 'string', nullable: false },
482
+ domain: { type: 'string', nullable: false },
483
+ },
484
+ },
485
+ },
486
+ },
487
+ },
488
+ },
489
+ {
490
+ type: 'object',
491
+ properties: {
492
+ type: { const: integrations_1.IntegrationType.jwt_rsa },
493
+ config: {
494
+ type: 'object',
495
+ required: ['configuration'],
496
+ properties: {
497
+ configuration: {
498
+ type: 'object',
499
+ nullable: false,
500
+ required: ['jwksUri'],
501
+ properties: {
502
+ jwksUri: { type: 'string', nullable: false },
503
+ validations: JwtValidationsSchema,
504
+ },
505
+ },
506
+ },
507
+ },
508
+ },
509
+ },
510
+ {
511
+ type: 'object',
512
+ properties: {
513
+ type: { const: integrations_1.IntegrationType.jwt_hmac },
514
+ config: {
515
+ type: 'object',
516
+ required: ['configuration'],
517
+ properties: {
518
+ configuration: {
519
+ type: 'object',
520
+ nullable: false,
521
+ required: ['verifyUri'],
522
+ properties: {
523
+ verifyUri: { type: 'string', nullable: false },
524
+ },
525
+ },
526
+ },
527
+ },
528
+ },
529
+ },
530
+ {
531
+ type: 'object',
532
+ properties: {
533
+ type: { const: integrations_1.IntegrationType.ai_assistant },
534
+ config: {
535
+ type: 'object',
536
+ properties: {
537
+ configuration: {
538
+ type: 'object',
539
+ nullable: false,
540
+ required: [],
541
+ properties: {
542
+ apiKey: { type: 'string', nullable: false },
543
+ },
544
+ },
545
+ },
546
+ },
547
+ },
548
+ },
549
+ {
550
+ type: 'object',
551
+ properties: {
552
+ type: { const: integrations_1.IntegrationType.cognito },
553
+ config: {
554
+ type: 'object',
555
+ required: ['configuration'],
556
+ properties: {
557
+ configuration: {
558
+ type: 'object',
559
+ required: ['region', 'userPoolId', 'appClientId'],
560
+ properties: {
561
+ region: { type: 'string' },
562
+ userPoolId: { type: 'string' },
563
+ appClientId: { type: 'string' },
564
+ },
565
+ },
566
+ },
567
+ },
568
+ },
569
+ },
570
+ {
571
+ type: 'object',
572
+ properties: {
573
+ type: { const: integrations_1.IntegrationType.okta },
574
+ config: {
575
+ type: 'object',
576
+ required: ['configuration'],
577
+ properties: {
578
+ configuration: {
579
+ type: 'object',
580
+ required: ['domain', 'clientId'],
581
+ properties: {
582
+ domain: { type: 'string' },
583
+ clientId: { type: 'string' },
584
+ },
585
+ },
586
+ },
587
+ },
588
+ },
589
+ },
590
+ ],
591
+ };
592
+ exports.UpsertIntegrationSchemaRequestSchema = {
593
+ type: 'object',
594
+ required: ['id', 'type', 'schema'],
595
+ properties: {
596
+ id: { type: 'string', nullable: false },
597
+ type: { type: 'string', nullable: false },
598
+ schema: {
599
+ oneOf: [
600
+ {
601
+ type: 'object',
602
+ required: ['type', 'collections'],
603
+ properties: {
604
+ type: { const: integrations_1.IntegrationSchemaType.data },
605
+ collections: { type: 'object', nullable: false },
606
+ },
607
+ },
608
+ {
609
+ type: 'object',
610
+ required: ['type', 'baseUrl', 'endpoints'],
611
+ properties: {
612
+ type: { const: integrations_1.IntegrationSchemaType.api },
613
+ baseUrl: { type: 'string', nullable: false },
614
+ endpoints: { type: 'object', nullable: false },
615
+ },
616
+ },
617
+ {
618
+ type: 'object',
619
+ required: ['type', 'introspection'],
620
+ properties: {
621
+ type: { const: integrations_1.IntegrationSchemaType.graphql },
622
+ introspection: { type: 'object', nullable: false },
623
+ },
624
+ },
625
+ ],
626
+ },
627
+ },
628
+ };
629
+ exports.DeleteIntegrationRequestSchema = {
630
+ type: 'object',
631
+ required: ['integrationId'],
632
+ properties: {
633
+ integrationId: { type: 'string', nullable: false },
634
+ },
635
+ };
636
+ exports.TestDataConnectionRequestSchema = {
637
+ type: 'object',
638
+ required: ['type', 'configuration'],
639
+ oneOf: [
640
+ {
641
+ type: 'object',
642
+ required: ['configuration'],
643
+ properties: {
644
+ type: { const: integrations_1.IntegrationType.mysql },
645
+ configuration: {
646
+ type: 'object',
647
+ required: ['connectionOptions'],
648
+ properties: {
649
+ connectionOptions: MysqlConnectionOptionsSchema,
650
+ },
651
+ },
652
+ },
653
+ },
654
+ {
655
+ type: 'object',
656
+ required: ['configuration'],
657
+ properties: {
658
+ type: { const: integrations_1.IntegrationType.oracledb },
659
+ configuration: {
660
+ type: 'object',
661
+ required: ['connectionOptions'],
662
+ properties: {
663
+ connectionOptions: OracleConnectionOptionsSchema,
664
+ },
665
+ },
666
+ },
667
+ },
668
+ {
669
+ type: 'object',
670
+ required: ['configuration'],
671
+ properties: {
672
+ type: { const: integrations_1.IntegrationType.mssql },
673
+ configuration: {
674
+ type: 'object',
675
+ required: ['connectionOptions'],
676
+ properties: {
677
+ connectionOptions: MssqlConnectionOptionsSchema,
678
+ },
679
+ },
680
+ },
681
+ },
682
+ {
683
+ type: 'object',
684
+ required: ['configuration'],
685
+ properties: {
686
+ type: { const: integrations_1.IntegrationType.postgres },
687
+ configuration: {
688
+ type: 'object',
689
+ required: ['connectionOptions'],
690
+ properties: {
691
+ connectionOptions: PostgresConnectionOptionsSchema,
692
+ },
693
+ },
694
+ },
695
+ },
696
+ {
697
+ type: 'object',
698
+ required: ['configuration'],
699
+ properties: {
700
+ type: { const: integrations_1.IntegrationType.cockroach },
701
+ configuration: {
702
+ type: 'object',
703
+ required: ['connectionOptions'],
704
+ properties: {
705
+ connectionOptions: PostgresConnectionOptionsSchema,
706
+ },
707
+ },
708
+ },
709
+ },
710
+ {
711
+ type: 'object',
712
+ required: ['configuration'],
713
+ properties: {
714
+ type: { const: integrations_1.IntegrationType.mongo },
715
+ configuration: {
716
+ type: 'object',
717
+ required: ['connectionOptions'],
718
+ properties: {
719
+ connectionOptions: MongoConnectionOptionsSchema,
720
+ },
721
+ },
722
+ },
723
+ },
724
+ {
725
+ type: 'object',
726
+ required: ['configuration'],
727
+ properties: {
728
+ type: { const: integrations_1.IntegrationType.snowflake },
729
+ configuration: {
730
+ type: 'object',
731
+ required: ['connectionOptions'],
732
+ properties: {
733
+ connectionOptions: SnowflakeConnectionOptionsSchema,
734
+ },
735
+ },
736
+ },
737
+ },
738
+ {
739
+ type: 'object',
740
+ required: ['configuration'],
741
+ properties: {
742
+ type: { const: integrations_1.IntegrationType.graphql },
743
+ configuration: {
744
+ type: 'object',
745
+ required: ['connectionOptions'],
746
+ properties: {
747
+ connectionOptions: GraphQLConnectionOptionsSchema,
748
+ },
749
+ },
750
+ },
751
+ },
752
+ ],
753
+ };
754
+ exports.DiscoverDataConnectionSchemaRequestSchema = {
755
+ type: 'object',
756
+ required: ['integrationType'],
757
+ oneOf: [
758
+ {
759
+ type: 'object',
760
+ required: ['connectionOptions'],
761
+ properties: {
762
+ integrationType: { const: integrations_1.IntegrationType.mysql },
763
+ connectionOptions: MysqlConnectionOptionsSchema,
764
+ },
765
+ },
766
+ {
767
+ type: 'object',
768
+ required: ['connectionOptions'],
769
+ properties: {
770
+ integrationType: { const: integrations_1.IntegrationType.oracledb },
771
+ connectionOptions: OracleConnectionOptionsSchema,
772
+ },
773
+ },
774
+ {
775
+ type: 'object',
776
+ required: ['connectionOptions'],
777
+ properties: {
778
+ integrationType: { const: integrations_1.IntegrationType.mssql },
779
+ connectionOptions: MssqlConnectionOptionsSchema,
780
+ },
781
+ },
782
+ {
783
+ type: 'object',
784
+ required: ['connectionOptions'],
785
+ properties: {
786
+ integrationType: { const: integrations_1.IntegrationType.snowflake },
787
+ connectionOptions: SnowflakeConnectionOptionsSchema,
788
+ },
789
+ },
790
+ {
791
+ type: 'object',
792
+ required: ['connectionOptions'],
793
+ properties: {
794
+ integrationType: { const: integrations_1.IntegrationType.postgres },
795
+ connectionOptions: PostgresConnectionOptionsSchema,
796
+ },
797
+ },
798
+ {
799
+ type: 'object',
800
+ required: ['connectionOptions'],
801
+ properties: {
802
+ integrationType: { const: integrations_1.IntegrationType.cockroach },
803
+ connectionOptions: PostgresConnectionOptionsSchema,
804
+ },
805
+ },
806
+ {
807
+ type: 'object',
808
+ required: ['connectionOptions'],
809
+ properties: {
810
+ integrationType: { const: integrations_1.IntegrationType.mongo },
811
+ connectionOptions: MongoConnectionOptionsSchema,
812
+ },
813
+ },
814
+ {
815
+ type: 'object',
816
+ properties: {
817
+ integrationType: { const: integrations_1.IntegrationType.built_in_db },
818
+ },
819
+ },
820
+ ],
821
+ };
822
+ exports.DiscoverGraphQLConnectionSchemaRequestSchema = {
823
+ type: 'object',
824
+ required: ['integrationType'],
825
+ properties: {
826
+ integrationType: { const: integrations_1.IntegrationType.graphql },
827
+ connectionOptions: GraphQLConnectionOptionsSchema,
828
+ },
829
+ };
830
+ exports.UpdateAllowedHostsRequestSchema = {
831
+ type: 'object',
832
+ required: ['allowedHosts'],
833
+ properties: {
834
+ allowedHosts: {
835
+ type: 'array',
836
+ nullable: false,
837
+ minItems: 1,
838
+ items: {
839
+ type: 'string',
840
+ nullable: false,
841
+ },
842
+ },
843
+ },
844
+ };
845
+ exports.DiscoverOpenApiSchemaRequestSchema = {
846
+ type: 'object',
847
+ required: ['discoveryOptions'],
848
+ properties: {
849
+ discoveryOptions: {
850
+ type: 'object',
851
+ required: ['openApiSpecUrl'],
852
+ properties: {
853
+ openApiSpecUrl: {
854
+ type: 'string',
855
+ format: 'uri',
856
+ },
857
+ },
858
+ },
859
+ },
860
+ };
861
+ exports.GetSchemaSchema = {
862
+ type: 'object',
863
+ required: ['integrationId'],
864
+ properties: {
865
+ integrationId: {
866
+ type: 'string',
867
+ nullable: false,
868
+ },
869
+ },
870
+ };
871
+ exports.GetAiAssistantProfilesSchema = {
872
+ type: 'object',
873
+ required: ['integrationId'],
874
+ properties: {
875
+ integrationId: {
876
+ type: 'string',
877
+ nullable: false,
878
+ },
879
+ },
880
+ };
861
881
  //# sourceMappingURL=application.schemas.js.map