@bitblit/ratchet-epsilon-common 4.0.89-alpha → 4.0.94-alpha

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.
@@ -5,12 +5,12 @@ class RatchetEpsilonCommonInfo {
5
5
  constructor() { }
6
6
  static buildInformation() {
7
7
  const val = {
8
- version: '89',
9
- hash: '1458f175b084b58fabefc52f2a8203c4ed38161d',
10
- branch: 'alpha-2023-03-19-2',
11
- tag: 'alpha-2023-03-19-2',
12
- timeBuiltISO: '2023-03-20T00:02:38-0700',
13
- notes: '',
8
+ version: 'LOCAL-SNAPSHOT',
9
+ hash: 'LOCAL-HASH',
10
+ branch: 'LOCAL-BRANCH',
11
+ tag: 'LOCAL-TAG',
12
+ timeBuiltISO: 'LOCAL-TIME-ISO',
13
+ notes: 'LOCAL-NOTES',
14
14
  };
15
15
  return val;
16
16
  }
package/dist/cjs/index.js CHANGED
@@ -130,6 +130,7 @@ tslib_1.__exportStar(require("./open-api-util/yaml-combiner"), exports);
130
130
  tslib_1.__exportStar(require("./sample/sample-batch-only-local-server"), exports);
131
131
  tslib_1.__exportStar(require("./sample/sample-local-server"), exports);
132
132
  tslib_1.__exportStar(require("./sample/sample-server-components"), exports);
133
+ tslib_1.__exportStar(require("./sample/sample-server-static-files"), exports);
133
134
  tslib_1.__exportStar(require("./util/aws-util"), exports);
134
135
  tslib_1.__exportStar(require("./util/context-util"), exports);
135
136
  tslib_1.__exportStar(require("./util/cron-util"), exports);
@@ -1,14 +1,11 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.SampleServerComponents = void 0;
4
- const tslib_1 = require("tslib");
5
4
  const ratchet_common_1 = require("@bitblit/ratchet-common");
6
5
  const apollo_server_lambda_1 = require("apollo-server-lambda");
7
6
  const apollo_server_core_1 = require("apollo-server-core");
8
7
  const ratchet_common_2 = require("@bitblit/ratchet-common");
9
8
  const ratchet_common_3 = require("@bitblit/ratchet-common");
10
- const fs_1 = tslib_1.__importDefault(require("fs"));
11
- const path_1 = tslib_1.__importDefault(require("path"));
12
9
  const ratchet_common_4 = require("@bitblit/ratchet-common");
13
10
  const epsilon_global_handler_1 = require("../epsilon-global-handler");
14
11
  const built_in_handlers_1 = require("../built-in/http/built-in-handlers");
@@ -28,10 +25,11 @@ const built_in_filters_1 = require("../built-in/http/built-in-filters");
28
25
  const event_util_1 = require("../http/event-util");
29
26
  const log_message_background_error_processor_1 = require("../built-in/background/log-message-background-error-processor");
30
27
  const single_thread_local_background_manager_1 = require("../background/manager/single-thread-local-background-manager");
28
+ const sample_server_static_files_1 = require("./sample-server-static-files");
31
29
  class SampleServerComponents {
32
30
  constructor() { }
33
31
  static async createSampleApollo() {
34
- const gqlString = SampleServerComponents.loadSampleServerGQL();
32
+ const gqlString = sample_server_static_files_1.SampleServerStaticFiles.SAMPLE_SERVER_GRAPHQL;
35
33
  ratchet_common_1.Logger.silly('Creating apollo from : %s', gqlString);
36
34
  const typeDefs = (0, apollo_server_lambda_1.gql)(gqlString);
37
35
  const resolvers = {
@@ -70,7 +68,7 @@ class SampleServerComponents {
70
68
  return server;
71
69
  }
72
70
  static async createSampleEpsilonConfig() {
73
- const yamlString = SampleServerComponents.loadSampleOpenApiYaml();
71
+ const yamlString = sample_server_static_files_1.SampleServerStaticFiles.SAMPLE_OPEN_API_DOC;
74
72
  const authorizers = new Map();
75
73
  authorizers.set('SampleAuthorizer', (token, evt) => built_in_authorizers_1.BuiltInAuthorizers.simpleLoggedInAuth(token, evt));
76
74
  authorizers.set('LogAuthorizer', (token, evt) => built_in_authorizers_1.BuiltInAuthorizers.simpleNoAuthenticationLogAccess(token, evt));
@@ -185,13 +183,5 @@ class SampleServerComponents {
185
183
  const rval = new epsilon_global_handler_1.EpsilonGlobalHandler(epsilonInstance);
186
184
  return rval;
187
185
  }
188
- static loadSampleOpenApiYaml() {
189
- const yamlString = fs_1.default.readFileSync(path_1.default.join(__dirname, '..', 'static', 'sample-open-api-doc.yaml')).toString();
190
- return yamlString;
191
- }
192
- static loadSampleServerGQL() {
193
- const yamlString = fs_1.default.readFileSync(path_1.default.join(__dirname, '..', 'static', 'sample-server.gql')).toString();
194
- return yamlString;
195
- }
196
186
  }
197
187
  exports.SampleServerComponents = SampleServerComponents;
@@ -0,0 +1,597 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.SampleServerStaticFiles = void 0;
4
+ class SampleServerStaticFiles {
5
+ constructor() { }
6
+ }
7
+ exports.SampleServerStaticFiles = SampleServerStaticFiles;
8
+ SampleServerStaticFiles.SAMPLE_OPEN_API_DOC = 'openapi: 3.0.0\n' +
9
+ 'info:\n' +
10
+ ' version: v0\n' +
11
+ ' title: SampleAPI\n' +
12
+ 'tags:\n' +
13
+ ' - name: CORS\n' +
14
+ ' description: These endpoints are here to support CORS\n' +
15
+ ' - name: Public\n' +
16
+ ' description: These endpoints can be called without setting the authorization header\n' +
17
+ ' - name: Secure\n' +
18
+ ' description: Authentication and authorization of the API\n' +
19
+ 'paths:\n' +
20
+ ' /:\n' +
21
+ ' get:\n' +
22
+ ' description: Redirects to the /meta/server endpoint\n' +
23
+ ' tags:\n' +
24
+ ' - Meta\n' +
25
+ ' - Public\n' +
26
+ ' responses:\n' +
27
+ " '301':\n" +
28
+ ' description: Redirects to the /meta/server endpoint\n' +
29
+ ' options:\n' +
30
+ ' tags:\n' +
31
+ ' - CORS\n' +
32
+ ' responses:\n' +
33
+ " '200':\n" +
34
+ ' description: Standard CORS header response\n' +
35
+ ' /meta/server:\n' +
36
+ ' get:\n' +
37
+ ' description: >\n' +
38
+ ' Returns information about the current build and time. Can be used to\n' +
39
+ ' test error-handling code by passing a specific http error code in the\n' +
40
+ ' error query parameter. Can also be used to process specific named tests\n' +
41
+ ' by passing those names to the test parameter.\n' +
42
+ ' tags:\n' +
43
+ ' - Public\n' +
44
+ ' parameters:\n' +
45
+ ' - name: error\n' +
46
+ ' in: query\n' +
47
+ ' description: >-\n' +
48
+ ' If set, throw a specific error for testing (valid are\n' +
49
+ ' 500,400,403,404)\n' +
50
+ ' required: false\n' +
51
+ ' schema:\n' +
52
+ ' type: number\n' +
53
+ ' - name: test\n' +
54
+ ' in: query\n' +
55
+ ' description: Run a specific named test (currently none are publicly available)\n' +
56
+ ' required: false\n' +
57
+ ' schema:\n' +
58
+ ' type: string\n' +
59
+ ' responses:\n' +
60
+ " '200':\n" +
61
+ ' description: Success\n' +
62
+ " '400':\n" +
63
+ ' description: Simulated bad request\n' +
64
+ ' content:\n' +
65
+ " '*/*':\n" +
66
+ ' schema:\n' +
67
+ " $ref: '#/components/schemas/ApiErrorResponse'\n" +
68
+ " '403':\n" +
69
+ ' description: Simulated unauthorized\n' +
70
+ ' content:\n' +
71
+ " '*/*':\n" +
72
+ ' schema:\n' +
73
+ " $ref: '#/components/schemas/ApiErrorResponse'\n" +
74
+ " '404':\n" +
75
+ ' description: Simulated not found\n' +
76
+ ' content:\n' +
77
+ " '*/*':\n" +
78
+ ' schema:\n' +
79
+ " $ref: '#/components/schemas/ApiErrorResponse'\n" +
80
+ " '500':\n" +
81
+ ' description: Simulated internal server error\n' +
82
+ ' content:\n' +
83
+ " '*/*':\n" +
84
+ ' schema:\n' +
85
+ " $ref: '#/components/schemas/ApiErrorResponse'\n" +
86
+ ' options:\n' +
87
+ ' tags:\n' +
88
+ ' - CORS\n' +
89
+ ' responses:\n' +
90
+ " '200':\n" +
91
+ ' description: Standard CORS header response\n' +
92
+ ' /meta/user:\n' +
93
+ ' get:\n' +
94
+ ' description: >\n' +
95
+ ' When logged in, returns the contents of the JWT token as the server\n' +
96
+ ' parses it. This should match what you get when you process the token\n' +
97
+ ' returned from the "POST /access-token" endpoint through a standard JWT\n' +
98
+ ' token processor.\n' +
99
+ ' tags:\n' +
100
+ ' - Meta\n' +
101
+ ' security:\n' +
102
+ ' - SampleAuthorizer: []\n' +
103
+ ' responses:\n' +
104
+ " '200':\n" +
105
+ ' description: Success\n' +
106
+ ' content:\n' +
107
+ " '*/*':\n" +
108
+ ' schema:\n' +
109
+ " $ref: '#/components/schemas/AccessTokenContents'\n" +
110
+ " '401':\n" +
111
+ ' description: Unauthorized\n' +
112
+ ' content:\n' +
113
+ " '*/*':\n" +
114
+ ' schema:\n' +
115
+ " $ref: '#/components/schemas/ApiErrorResponse'\n" +
116
+ ' options:\n' +
117
+ ' tags:\n' +
118
+ ' - CORS\n' +
119
+ ' responses:\n' +
120
+ " '200':\n" +
121
+ ' description: Success\n' +
122
+ " '401':\n" +
123
+ ' description: Unauthorized\n' +
124
+ ' content:\n' +
125
+ " '*/*':\n" +
126
+ ' schema:\n' +
127
+ " $ref: '#/components/schemas/ApiErrorResponse'\n" +
128
+ ' /meta/item/{itemId}:\n' +
129
+ ' get:\n' +
130
+ ' description: >\n' +
131
+ ' Example of a path param\n' +
132
+ ' parameters:\n' +
133
+ ' - name: itemId\n' +
134
+ ' in: path\n' +
135
+ ' description: A sample item id\n' +
136
+ ' required: true\n' +
137
+ ' schema:\n' +
138
+ ' type: string\n' +
139
+ ' tags:\n' +
140
+ ' - Meta\n' +
141
+ ' responses:\n' +
142
+ " '200':\n" +
143
+ ' description: Success\n' +
144
+ ' content:\n' +
145
+ " '*/*':\n" +
146
+ ' schema:\n' +
147
+ " $ref: '#/components/schemas/Empty'\n" +
148
+ " '401':\n" +
149
+ ' description: Unauthorized\n' +
150
+ ' content:\n' +
151
+ " '*/*':\n" +
152
+ ' schema:\n' +
153
+ " $ref: '#/components/schemas/ApiErrorResponse'\n" +
154
+ ' options:\n' +
155
+ ' tags:\n' +
156
+ ' - CORS\n' +
157
+ ' parameters:\n' +
158
+ ' - name: itemId\n' +
159
+ ' in: path\n' +
160
+ ' description: A sample item id\n' +
161
+ ' required: true\n' +
162
+ ' schema:\n' +
163
+ ' type: string\n' +
164
+ ' responses:\n' +
165
+ " '200':\n" +
166
+ ' description: Success\n' +
167
+ " '401':\n" +
168
+ ' description: Unauthorized\n' +
169
+ ' content:\n' +
170
+ " '*/*':\n" +
171
+ ' schema:\n' +
172
+ " $ref: '#/components/schemas/ApiErrorResponse'\n" +
173
+ '\n' +
174
+ ' /meta/sample-item:\n' +
175
+ ' get:\n' +
176
+ ' description: >\n' +
177
+ ' Example of an object returned\n' +
178
+ ' parameters:\n' +
179
+ ' - name: num\n' +
180
+ ' in: path\n' +
181
+ ' description: Number to return in the number value\n' +
182
+ ' required: false\n' +
183
+ ' schema:\n' +
184
+ ' type: number\n' +
185
+ ' tags:\n' +
186
+ ' - Meta\n' +
187
+ ' responses:\n' +
188
+ " '200':\n" +
189
+ ' description: Success\n' +
190
+ ' content:\n' +
191
+ " 'application/json':\n" +
192
+ ' schema:\n' +
193
+ " $ref: '#/components/schemas/BackgroundSampleInputValidatedProcessorData'\n" +
194
+ ' post:\n' +
195
+ ' description: >\n' +
196
+ ' Example of an object posted\n' +
197
+ ' requestBody:\n' +
198
+ ' content:\n' +
199
+ ' application/json:\n' +
200
+ ' schema:\n' +
201
+ " $ref: '#/components/schemas/BackgroundSampleInputValidatedProcessorData'\n" +
202
+ ' description: Request to refresh the access token or change active user\n' +
203
+ ' required: true\n' +
204
+ ' tags:\n' +
205
+ ' - Meta\n' +
206
+ ' responses:\n' +
207
+ " '200':\n" +
208
+ ' description: Success\n' +
209
+ ' content:\n' +
210
+ " 'application/json':\n" +
211
+ ' schema:\n' +
212
+ " $ref: '#/components/schemas/BackgroundSampleInputValidatedProcessorData'\n" +
213
+ ' options:\n' +
214
+ ' tags:\n' +
215
+ ' - CORS\n' +
216
+ ' responses:\n' +
217
+ " '200':\n" +
218
+ ' description: Success\n' +
219
+ '\n' +
220
+ ' /secure/access-token:\n' +
221
+ ' post:\n' +
222
+ ' tags:\n' +
223
+ ' - Secure\n' +
224
+ ' - Public\n' +
225
+ ' responses:\n' +
226
+ " '200':\n" +
227
+ ' description: Success\n' +
228
+ ' content:\n' +
229
+ ' application/json:\n' +
230
+ ' schema:\n' +
231
+ " $ref: '#/components/schemas/AccessTokenResponse'\n" +
232
+ " '400':\n" +
233
+ ' description: Invalid request\n' +
234
+ ' content:\n' +
235
+ ' application/json:\n' +
236
+ ' schema:\n' +
237
+ " $ref: '#/components/schemas/ApiErrorResponse'\n" +
238
+ " '403':\n" +
239
+ ' description: Invalid credentials\n' +
240
+ ' content:\n' +
241
+ ' application/json:\n' +
242
+ ' schema:\n' +
243
+ " $ref: '#/components/schemas/ApiErrorResponse'\n" +
244
+ ' requestBody:\n' +
245
+ ' content:\n' +
246
+ ' application/json:\n' +
247
+ ' schema:\n' +
248
+ " $ref: '#/components/schemas/AccessTokenRequest'\n" +
249
+ ' description: Request to refresh the access token or change active user\n' +
250
+ ' required: true\n' +
251
+ ' options:\n' +
252
+ ' tags:\n' +
253
+ ' - CORS\n' +
254
+ ' responses:\n' +
255
+ " '200':\n" +
256
+ ' description: Standard CORS header response\n' +
257
+ ' /multi/fixed:\n' +
258
+ ' get:\n' +
259
+ ' description: Tests path matching from most specific to least (this is most)\n' +
260
+ ' tags:\n' +
261
+ ' - Public\n' +
262
+ ' responses:\n' +
263
+ " '200':\n" +
264
+ ' description: Success\n' +
265
+ ' options:\n' +
266
+ ' tags:\n' +
267
+ ' - CORS\n' +
268
+ ' responses:\n' +
269
+ " '200':\n" +
270
+ ' description: Standard CORS header response\n' +
271
+ ' /multi/{v}:\n' +
272
+ ' get:\n' +
273
+ ' description: Tests path matching from most specific to least (this is least)\n' +
274
+ ' tags:\n' +
275
+ ' - Public\n' +
276
+ ' parameters:\n' +
277
+ ' - name: v\n' +
278
+ ' in: path\n' +
279
+ ' description: A variable\n' +
280
+ ' required: true\n' +
281
+ ' schema:\n' +
282
+ ' type: string\n' +
283
+ ' responses:\n' +
284
+ " '200':\n" +
285
+ ' description: Success\n' +
286
+ ' options:\n' +
287
+ ' tags:\n' +
288
+ ' - CORS\n' +
289
+ ' parameters:\n' +
290
+ ' - name: v\n' +
291
+ ' in: path\n' +
292
+ ' description: A variable\n' +
293
+ ' required: true\n' +
294
+ ' schema:\n' +
295
+ ' type: string\n' +
296
+ ' responses:\n' +
297
+ " '200':\n" +
298
+ ' description: Standard CORS header response\n' +
299
+ '\n' +
300
+ ' /err/{code}:\n' +
301
+ ' get:\n' +
302
+ ' description: Tests path matching from most specific to least (this is least)\n' +
303
+ ' tags:\n' +
304
+ ' - Public\n' +
305
+ ' parameters:\n' +
306
+ ' - name: code\n' +
307
+ ' in: path\n' +
308
+ ' description: Error code\n' +
309
+ ' required: true\n' +
310
+ ' schema:\n' +
311
+ ' type: number\n' +
312
+ ' responses:\n' +
313
+ " '200':\n" +
314
+ ' description: Success\n' +
315
+ ' options:\n' +
316
+ ' tags:\n' +
317
+ ' - CORS\n' +
318
+ ' parameters:\n' +
319
+ ' - name: code\n' +
320
+ ' in: path\n' +
321
+ ' description: A variable\n' +
322
+ ' required: true\n' +
323
+ ' schema:\n' +
324
+ ' type: number\n' +
325
+ ' responses:\n' +
326
+ " '200':\n" +
327
+ ' description: Standard CORS header response\n' +
328
+ '\n' +
329
+ ' /background:\n' +
330
+ ' post:\n' +
331
+ ' responses:\n' +
332
+ " '200':\n" +
333
+ ' description: Success\n' +
334
+ ' content:\n' +
335
+ ' application/json:\n' +
336
+ ' schema:\n' +
337
+ " $ref: '#/components/schemas/BackgroundQueueResponse'\n" +
338
+ " '400':\n" +
339
+ ' description: Invalid request\n' +
340
+ ' content:\n' +
341
+ ' application/json:\n' +
342
+ ' schema:\n' +
343
+ " $ref: '#/components/schemas/ApiErrorResponse'\n" +
344
+ " '403':\n" +
345
+ ' description: Invalid credentials\n' +
346
+ ' content:\n' +
347
+ ' application/json:\n' +
348
+ ' schema:\n' +
349
+ " $ref: '#/components/schemas/ApiErrorResponse'\n" +
350
+ ' requestBody:\n' +
351
+ ' content:\n' +
352
+ ' application/json:\n' +
353
+ ' schema:\n' +
354
+ " $ref: '#/components/schemas/Empty'\n" +
355
+ ' description: Content to echo\n' +
356
+ ' required: true\n' +
357
+ ' options:\n' +
358
+ ' tags:\n' +
359
+ ' - CORS\n' +
360
+ ' responses:\n' +
361
+ " '200':\n" +
362
+ ' description: Standard CORS header response\n' +
363
+ '\n' +
364
+ ' /background/meta:\n' +
365
+ ' get:\n' +
366
+ ' responses:\n' +
367
+ " '200':\n" +
368
+ ' description: Success\n' +
369
+ ' content:\n' +
370
+ ' application/json:\n' +
371
+ ' schema:\n' +
372
+ " $ref: '#/components/schemas/BackgroundMetaResponse'\n" +
373
+ " '400':\n" +
374
+ ' description: Invalid request\n' +
375
+ ' content:\n' +
376
+ ' application/json:\n' +
377
+ ' schema:\n' +
378
+ " $ref: '#/components/schemas/ApiErrorResponse'\n" +
379
+ " '403':\n" +
380
+ ' description: Invalid credentials\n' +
381
+ ' content:\n' +
382
+ ' application/json:\n' +
383
+ ' schema:\n' +
384
+ " $ref: '#/components/schemas/ApiErrorResponse'\n" +
385
+ ' options:\n' +
386
+ ' tags:\n' +
387
+ ' - CORS\n' +
388
+ ' responses:\n' +
389
+ " '200':\n" +
390
+ ' description: Standard CORS header response\n' +
391
+ '\n' +
392
+ 'x-amazon-apigateway-binary-media-types:\n' +
393
+ " - '*/*'\n" +
394
+ 'x-amazon-apigateway-gateway-responses:\n' +
395
+ ' UNAUTHORIZED:\n' +
396
+ ' statusCode: 401\n' +
397
+ ' responseParameters:\n' +
398
+ ' gatewayresponse.header.Access-Control-Allow-Origin: "\'*\'"\n' +
399
+ ' responseTemplates:\n' +
400
+ ' application/json: \'{"errors":["Unauthorized"], "httpStatusCode": 401}\'\n' +
401
+ ' MISSING_AUTHENTICATION_TOKEN:\n' +
402
+ ' statusCode: 404\n' +
403
+ ' responseParameters:\n' +
404
+ ' gatewayresponse.header.Access-Control-Allow-Origin: "\'*\'"\n' +
405
+ ' responseTemplates:\n' +
406
+ ' application/json: \'{"errors":["No such endpoint"], "httpStatusCode": 404}\'\n' +
407
+ ' INTEGRATION_TIMEOUT:\n' +
408
+ ' statusCode: 504\n' +
409
+ ' responseParameters:\n' +
410
+ ' gatewayresponse.header.Access-Control-Allow-Origin: "\'*\'"\n' +
411
+ ' responseTemplates:\n' +
412
+ ' application/json: \'{"errors":["Timeout"], "httpStatusCode": 504}\'\n' +
413
+ ' DEFAULT_5XX:\n' +
414
+ ' statusCode: 500\n' +
415
+ ' responseParameters:\n' +
416
+ ' gatewayresponse.header.Access-Control-Allow-Origin: "\'*\'"\n' +
417
+ ' responseTemplates:\n' +
418
+ ' application/json: \'{"errors":["Internal Server Error"], "httpStatusCode": 500}\'\n' +
419
+ '\n' +
420
+ 'servers:\n' +
421
+ " - url: 'https://api.sample.com/dev'\n" +
422
+ 'components:\n' +
423
+ ' securitySchemes:\n' +
424
+ ' SampleAuthorizer:\n' +
425
+ ' type: apiKey\n' +
426
+ ' name: Authorization\n' +
427
+ ' in: header\n' +
428
+ ' schemas:\n' +
429
+ ' Empty:\n' +
430
+ ' type: object\n' +
431
+ ' title: Empty Schema\n' +
432
+ '\n' +
433
+ ' AccessTokenRequest:\n' +
434
+ ' type: object\n' +
435
+ ' title: Access Token Request\n' +
436
+ ' required:\n' +
437
+ ' - email\n' +
438
+ ' - password\n' +
439
+ ' - scope\n' +
440
+ ' properties:\n' +
441
+ ' email:\n' +
442
+ ' type: string\n' +
443
+ ' description: Email address of the account to authenticate\n' +
444
+ ' format: email\n' +
445
+ ' minLength: 7\n' +
446
+ ' password:\n' +
447
+ ' type: string\n' +
448
+ ' description: Password of the account to authenticate\n' +
449
+ ' minLength: 6\n' +
450
+ ' scope:\n' +
451
+ ' type: string\n' +
452
+ ' enum:\n' +
453
+ ' - OWNER\n' +
454
+ ' - ADVERTISER\n' +
455
+ ' - GLOBAL\n' +
456
+ ' - RUN_AS_OWNER\n' +
457
+ ' - RUN_AS_ADVERTISER\n' +
458
+ ' description: |\n' +
459
+ ' What style of account to authenticate:\n' +
460
+ ' * `OWNER` - A device owner account\n' +
461
+ ' * `ADVERTISER` - A advertising account\n' +
462
+ ' * `GLOBAL` - Used by Adomni customer service\n' +
463
+ ' * `RUN_AS_OWNER` - Used by Adomni customer service\n' +
464
+ ' * `RUN_AS_ADVERTISER` - Used by Adomni customer service\n' +
465
+ ' default: OWNER\n' +
466
+ ' runAs:\n' +
467
+ ' type: string\n' +
468
+ ' description: Used by Adomni customer service\n' +
469
+ ' format: email\n' +
470
+ ' expirationSeconds:\n' +
471
+ ' type: number\n' +
472
+ ' minimum: 10\n' +
473
+ ' maximum: 3600\n' +
474
+ ' default: 3600\n' +
475
+ ' AccessTokenResponse:\n' +
476
+ ' type: object\n' +
477
+ ' title: Access Token Response\n' +
478
+ ' required:\n' +
479
+ ' - token\n' +
480
+ ' - expires\n' +
481
+ ' properties:\n' +
482
+ ' token:\n' +
483
+ ' type: string\n' +
484
+ ' description: A JWT access token for the API\n' +
485
+ ' expires:\n' +
486
+ ' type: number\n' +
487
+ ' format: int64\n' +
488
+ " description: 'The time this token will expire, expressed in epoch ms'\n" +
489
+ ' AccessTokenContents:\n' +
490
+ ' type: object\n' +
491
+ ' title: Access Token Contents\n' +
492
+ ' description: The contents of the JWT token\n' +
493
+ ' required:\n' +
494
+ ' - exp\n' +
495
+ ' - iss\n' +
496
+ ' - sub\n' +
497
+ ' - iat\n' +
498
+ ' - user\n' +
499
+ ' properties:\n' +
500
+ ' exp:\n' +
501
+ ' type: number\n' +
502
+ ' description: >-\n' +
503
+ ' Expiration claim - The time this token will expire, expressed in\n' +
504
+ ' epoch ms\n' +
505
+ ' iss:\n' +
506
+ ' type: string\n' +
507
+ ' description: Issuer claim - Who created the token\n' +
508
+ ' sub:\n' +
509
+ ' type: string\n' +
510
+ ' description: Subject claim - The target of the token (typically user email)\n' +
511
+ ' iat:\n' +
512
+ ' type: number\n' +
513
+ ' description: >-\n' +
514
+ ' Issued at claim - The time this token was created, expressed in\n' +
515
+ ' epoch ms\n' +
516
+ ' user:\n' +
517
+ ' type: object\n' +
518
+ ' description: Object describing the user authenticated by this token\n' +
519
+ ' ApiErrorResponse:\n' +
520
+ ' type: object\n' +
521
+ ' title: API Error Response\n' +
522
+ ' required:\n' +
523
+ ' - errors\n' +
524
+ ' - httpStatusCode\n' +
525
+ ' properties:\n' +
526
+ ' errors:\n' +
527
+ ' type: array\n' +
528
+ ' items:\n' +
529
+ ' type: string\n' +
530
+ ' description: List of the errors that occurred\n' +
531
+ ' httpStatusCode:\n' +
532
+ ' type: number\n' +
533
+ ' description: Http status code of this error\n' +
534
+ ' detailCode:\n' +
535
+ ' type: number\n' +
536
+ ' description: Adomni detail status code for this error\n' +
537
+ ' BackgroundQueueResponse:\n' +
538
+ ' type: object\n' +
539
+ ' title: Background Queue Response\n' +
540
+ ' description: When any of the background endpoints are hit, this is what will be returned\n' +
541
+ ' required:\n' +
542
+ ' - resultId\n' +
543
+ ' - success\n' +
544
+ ' properties:\n' +
545
+ ' processHandling:\n' +
546
+ ' type: string\n' +
547
+ " enum: ['Queued', 'Immediate']\n" +
548
+ ' success:\n' +
549
+ ' type: boolean\n' +
550
+ ' resultId:\n' +
551
+ ' type: string\n' +
552
+ ' BackgroundMetaResponse:\n' +
553
+ ' type: object\n' +
554
+ ' title: Background Meta Response\n' +
555
+ ' description: If\n' +
556
+ ' properties:\n' +
557
+ ' validTypes:\n' +
558
+ ' type: array\n' +
559
+ ' items:\n' +
560
+ ' type: string\n' +
561
+ ' currentQueueLength:\n' +
562
+ ' type: number\n' +
563
+ '\n' +
564
+ ' BackgroundSampleInputValidatedProcessorData:\n' +
565
+ ' type: object\n' +
566
+ ' title: BackgroundSampleInputValidatedProcessorData\n' +
567
+ ' description: This is used for testing the background validator\n' +
568
+ ' required:\n' +
569
+ ' - nameParam\n' +
570
+ ' - numberParam\n' +
571
+ ' properties:\n' +
572
+ ' nameParam:\n' +
573
+ ' type: string\n' +
574
+ ' description: A sample name parameter\n' +
575
+ ' minimum: 0\n' +
576
+ ' maximum: 10\n' +
577
+ ' numberParam:\n' +
578
+ ' type: number\n' +
579
+ ' description: A sample number parameter\n';
580
+ SampleServerStaticFiles.SAMPLE_SERVER_GRAPHQL = 'schema {\n' +
581
+ ' query: RootQueryType\n' +
582
+ '}\n' +
583
+ '\n' +
584
+ 'type RootQueryType {\n' +
585
+ ' serverMeta: ServerMeta\n' +
586
+ ' forceTimeout: ForceTimeout\n' +
587
+ '}\n' +
588
+ '\n' +
589
+ 'type ServerMeta {\n' +
590
+ ' version: String\n' +
591
+ ' serverTime: String\n' +
592
+ ' status: String\n' +
593
+ '}\n' +
594
+ '\n' +
595
+ 'type ForceTimeout {\n' +
596
+ ' placeholder: String\n' +
597
+ '}\n';