@checkdigit/eslint-athena-plugin 1.0.0-PR.2-dcdf

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 (66) hide show
  1. package/LICENSE.txt +21 -0
  2. package/README.md +17 -0
  3. package/SECURITY.md +13 -0
  4. package/dist-mjs/athena/api-locator.mjs +66 -0
  5. package/dist-mjs/athena/api-matcher.mjs +206 -0
  6. package/dist-mjs/athena/athena.mjs +165 -0
  7. package/dist-mjs/athena/column.mjs +1 -0
  8. package/dist-mjs/athena/context.mjs +21 -0
  9. package/dist-mjs/athena/index.mjs +1 -0
  10. package/dist-mjs/athena/service-table.mjs +45 -0
  11. package/dist-mjs/athena/sql-file.mjs +123 -0
  12. package/dist-mjs/athena/types.mjs +1 -0
  13. package/dist-mjs/athena/validate.mjs +619 -0
  14. package/dist-mjs/athena/visitor.mjs +291 -0
  15. package/dist-mjs/get-documentation-url.mjs +9 -0
  16. package/dist-mjs/index.mjs +56 -0
  17. package/dist-mjs/openapi/deref-schema.mjs +20 -0
  18. package/dist-mjs/openapi/generate-schema.mjs +375 -0
  19. package/dist-mjs/openapi/service-schema-generator.mjs +176 -0
  20. package/dist-mjs/peggy/athena-peggy.mjs +20700 -0
  21. package/dist-mjs/service.mjs +9 -0
  22. package/dist-mjs/sql-parser.mjs +28 -0
  23. package/dist-types/athena/api-locator.d.ts +2 -0
  24. package/dist-types/athena/api-matcher.d.ts +14 -0
  25. package/dist-types/athena/athena.d.ts +5 -0
  26. package/dist-types/athena/column.d.ts +1 -0
  27. package/dist-types/athena/context.d.ts +21 -0
  28. package/dist-types/athena/index.d.ts +8 -0
  29. package/dist-types/athena/service-table.d.ts +8 -0
  30. package/dist-types/athena/sql-file.d.ts +5 -0
  31. package/dist-types/athena/types.d.ts +493 -0
  32. package/dist-types/athena/validate.d.ts +14 -0
  33. package/dist-types/athena/visitor.d.ts +75 -0
  34. package/dist-types/get-documentation-url.d.ts +1 -0
  35. package/dist-types/index.d.ts +5 -0
  36. package/dist-types/openapi/deref-schema.d.ts +1 -0
  37. package/dist-types/openapi/generate-schema.d.ts +33 -0
  38. package/dist-types/openapi/service-schema-generator.d.ts +5 -0
  39. package/dist-types/peggy/athena-peggy.d.ts +13 -0
  40. package/dist-types/service.d.ts +2 -0
  41. package/dist-types/sql-parser.d.ts +25 -0
  42. package/package.json +1 -0
  43. package/src/api/v1/swagger.yml +619 -0
  44. package/src/api/v2/swagger.yml +477 -0
  45. package/src/athena/api-locator.ts +78 -0
  46. package/src/athena/api-matcher.ts +323 -0
  47. package/src/athena/athena.ts +224 -0
  48. package/src/athena/column.ts +4 -0
  49. package/src/athena/context.ts +47 -0
  50. package/src/athena/index.ts +13 -0
  51. package/src/athena/service-table.ts +78 -0
  52. package/src/athena/sql-file.ts +161 -0
  53. package/src/athena/types.ts +568 -0
  54. package/src/athena/validate.ts +902 -0
  55. package/src/athena/visitor.ts +406 -0
  56. package/src/get-documentation-url.ts +7 -0
  57. package/src/index.ts +67 -0
  58. package/src/openapi/deref-schema.ts +20 -0
  59. package/src/openapi/generate-schema.ts +553 -0
  60. package/src/openapi/service-schema-generator.ts +241 -0
  61. package/src/peggy/athena-peggy.ts +22149 -0
  62. package/src/peggy/athena.peggy +2971 -0
  63. package/src/service.ts +11 -0
  64. package/src/services/eslintAthenaPlugin/v1/swagger.schema.deref.json +1931 -0
  65. package/src/services/eslintAthenaPlugin/v2/swagger.schema.deref.json +978 -0
  66. package/src/sql-parser.ts +53 -0
@@ -0,0 +1,1931 @@
1
+ {
2
+ "apis": {
3
+ "/eslint-athena-plugin/v1/ping": {
4
+ "get": {
5
+ "request": {
6
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
7
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/api/PingGetRequestContext",
8
+ "type": "object",
9
+ "properties": {
10
+ "headers": {
11
+ "type": "object",
12
+ "additionalProperties": true
13
+ }
14
+ },
15
+ "required": [],
16
+ "additionalProperties": false
17
+ },
18
+ "responses": {
19
+ "200": {
20
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
21
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/api/PingGetResponseOK",
22
+ "type": "object",
23
+ "properties": {
24
+ "headers": {
25
+ "type": "object",
26
+ "additionalProperties": true
27
+ },
28
+ "body": {
29
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
30
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/definitions/Ping",
31
+ "type": "object",
32
+ "additionalProperties": false,
33
+ "required": [
34
+ "serverTime",
35
+ "v1Only"
36
+ ],
37
+ "properties": {
38
+ "serverTime": {
39
+ "type": "string",
40
+ "format": "date-time",
41
+ "description": "Current server time"
42
+ },
43
+ "v1Only": {
44
+ "type": "boolean",
45
+ "description": "Indicates if the server is running in v1-only mode"
46
+ }
47
+ }
48
+ }
49
+ },
50
+ "required": [
51
+ "body"
52
+ ],
53
+ "additionalProperties": false
54
+ },
55
+ "default": {
56
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
57
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/api/PingGetResponseDefault",
58
+ "type": "object",
59
+ "properties": {
60
+ "headers": {
61
+ "type": "object",
62
+ "additionalProperties": true
63
+ },
64
+ "body": {
65
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
66
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/definitions/Error",
67
+ "type": "object",
68
+ "additionalProperties": false,
69
+ "description": "Error message",
70
+ "properties": {
71
+ "message": {
72
+ "type": "string"
73
+ },
74
+ "code": {
75
+ "type": "string"
76
+ }
77
+ }
78
+ }
79
+ },
80
+ "required": [
81
+ "body"
82
+ ],
83
+ "additionalProperties": false
84
+ }
85
+ }
86
+ },
87
+ "head": {
88
+ "request": {
89
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
90
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/api/PingHeadRequestContext",
91
+ "type": "object",
92
+ "properties": {
93
+ "headers": {
94
+ "type": "object",
95
+ "additionalProperties": true
96
+ }
97
+ },
98
+ "required": [],
99
+ "additionalProperties": false
100
+ },
101
+ "responses": {
102
+ "200": {
103
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
104
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/api/PingHeadResponseOK",
105
+ "type": "object",
106
+ "properties": {
107
+ "headers": {
108
+ "type": "object",
109
+ "additionalProperties": true
110
+ }
111
+ },
112
+ "required": [],
113
+ "additionalProperties": false
114
+ },
115
+ "default": {
116
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
117
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/api/PingHeadResponseDefault",
118
+ "type": "object",
119
+ "properties": {
120
+ "headers": {
121
+ "type": "object",
122
+ "additionalProperties": true
123
+ },
124
+ "body": {
125
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
126
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/definitions/Error",
127
+ "type": "object",
128
+ "additionalProperties": false,
129
+ "description": "Error message",
130
+ "properties": {
131
+ "message": {
132
+ "type": "string"
133
+ },
134
+ "code": {
135
+ "type": "string"
136
+ }
137
+ }
138
+ }
139
+ },
140
+ "required": [
141
+ "body"
142
+ ],
143
+ "additionalProperties": false
144
+ }
145
+ }
146
+ }
147
+ },
148
+ "/eslint-athena-plugin/v1/request/:messageId": {
149
+ "put": {
150
+ "request": {
151
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
152
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/api/RequestPutRequestContext",
153
+ "type": "object",
154
+ "properties": {
155
+ "params": {
156
+ "type": "object",
157
+ "additionalProperties": false,
158
+ "properties": {
159
+ "messageId": {
160
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
161
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/definitions/MessageId",
162
+ "description": "Uniquely identifies a message stored in the platform.\n\nA message's request and response are stored and retrieved separately using this identifier.\n",
163
+ "type": "string"
164
+ }
165
+ },
166
+ "required": [
167
+ "messageId"
168
+ ]
169
+ },
170
+ "headers": {
171
+ "type": "object",
172
+ "additionalProperties": true,
173
+ "properties": {
174
+ "created-on": {
175
+ "type": "string",
176
+ "format": "date-time"
177
+ }
178
+ },
179
+ "required": [
180
+ "created-on"
181
+ ]
182
+ },
183
+ "body": {
184
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
185
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/definitions/NewRequest",
186
+ "type": "object",
187
+ "additionalProperties": false,
188
+ "required": [
189
+ "messageId",
190
+ "feeDetails"
191
+ ],
192
+ "description": "The incoming message request data received from the network to be processed.",
193
+ "properties": {
194
+ "messageId": {
195
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
196
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/definitions/MessageId",
197
+ "description": "Uniquely identifies a message stored in the platform.\n\nA message's request and response are stored and retrieved separately using this identifier.\n",
198
+ "type": "string"
199
+ },
200
+ "feeDetails": {
201
+ "type": "array",
202
+ "description": "Details about the fees that went into the transaction and settlement fee amounts",
203
+ "items": {
204
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
205
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/definitions/Fee",
206
+ "type": "object",
207
+ "description": "Details about the fees applied to the transaction and settlement amounts.",
208
+ "additionalProperties": false,
209
+ "required": [
210
+ "type",
211
+ "application",
212
+ "transaction",
213
+ "settlement"
214
+ ],
215
+ "properties": {
216
+ "type": {
217
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
218
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/definitions/FeeType",
219
+ "type": "string",
220
+ "description": "The type of fee being applied to the transaction.",
221
+ "enum": [
222
+ "CONVENIENCE",
223
+ "TRANSACTION",
224
+ "CURRENCY CONVERSION ASSESSMENT",
225
+ "ISSUER CURRENCY CONVERSION ASSESSMENT",
226
+ "SURCHARGE",
227
+ "OPTIONAL ISSUER",
228
+ "PROCESSING",
229
+ "FOREIGN EXCHANGE"
230
+ ]
231
+ },
232
+ "application": {
233
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
234
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/definitions/FeeApplication",
235
+ "type": "string",
236
+ "description": "Indicates whether the fee should be applied to a cardholder's account (SETTLE) or recorded for information\npurposes only (MEMO). Examples of MEMO fees are currency conversion fees (already in the settlement amount) and\ninterchange fees.\n",
237
+ "enum": [
238
+ "MEMO",
239
+ "SETTLE"
240
+ ]
241
+ },
242
+ "transaction": {
243
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
244
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/definitions/Amount",
245
+ "type": "object",
246
+ "additionalProperties": false,
247
+ "description": "An amount of money in the smallest monetary unit of the specified currency.\n",
248
+ "required": [
249
+ "amount",
250
+ "currency"
251
+ ],
252
+ "properties": {
253
+ "amount": {
254
+ "type": "string",
255
+ "pattern": "^[0-9]+$",
256
+ "description": "The amount of money in the smallest monetary unit of the specified currency."
257
+ },
258
+ "currency": {
259
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
260
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/definitions/Currency",
261
+ "type": "string",
262
+ "description": "The alphabetic code that represents the currency.\n",
263
+ "enum": [
264
+ "AED",
265
+ "AFN"
266
+ ]
267
+ }
268
+ }
269
+ },
270
+ "settlement": {
271
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
272
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/definitions/Amount",
273
+ "type": "object",
274
+ "additionalProperties": false,
275
+ "description": "An amount of money in the smallest monetary unit of the specified currency.\n",
276
+ "required": [
277
+ "amount",
278
+ "currency"
279
+ ],
280
+ "properties": {
281
+ "amount": {
282
+ "type": "string",
283
+ "pattern": "^[0-9]+$",
284
+ "description": "The amount of money in the smallest monetary unit of the specified currency."
285
+ },
286
+ "currency": {
287
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
288
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/definitions/Currency",
289
+ "type": "string",
290
+ "description": "The alphabetic code that represents the currency.\n",
291
+ "enum": [
292
+ "AED",
293
+ "AFN"
294
+ ]
295
+ }
296
+ }
297
+ }
298
+ }
299
+ }
300
+ }
301
+ }
302
+ }
303
+ },
304
+ "required": [
305
+ "params",
306
+ "headers",
307
+ "body"
308
+ ],
309
+ "additionalProperties": false
310
+ },
311
+ "responses": {
312
+ "204": {
313
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
314
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/api/RequestPutResponseNoContent",
315
+ "type": "object",
316
+ "properties": {
317
+ "headers": {
318
+ "type": "object",
319
+ "properties": {
320
+ "created-on": {
321
+ "type": "string",
322
+ "format": "date-time"
323
+ },
324
+ "updated-on": {
325
+ "type": "string",
326
+ "format": "date-time"
327
+ }
328
+ },
329
+ "required": [
330
+ "created-on",
331
+ "updated-on"
332
+ ]
333
+ }
334
+ },
335
+ "required": [
336
+ "headers"
337
+ ],
338
+ "additionalProperties": false
339
+ },
340
+ "default": {
341
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
342
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/api/RequestPutResponseDefault",
343
+ "type": "object",
344
+ "properties": {
345
+ "headers": {
346
+ "type": "object",
347
+ "additionalProperties": true
348
+ },
349
+ "body": {
350
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
351
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/definitions/Error",
352
+ "type": "object",
353
+ "additionalProperties": false,
354
+ "description": "Error message",
355
+ "properties": {
356
+ "message": {
357
+ "type": "string"
358
+ },
359
+ "code": {
360
+ "type": "string"
361
+ }
362
+ }
363
+ }
364
+ },
365
+ "required": [
366
+ "body"
367
+ ],
368
+ "additionalProperties": false
369
+ }
370
+ }
371
+ }
372
+ },
373
+ "/eslint-athena-plugin/v1/entry/:entryId": {
374
+ "get": {
375
+ "request": {
376
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
377
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/api/EntryGetRequestContext",
378
+ "type": "object",
379
+ "properties": {
380
+ "params": {
381
+ "type": "object",
382
+ "additionalProperties": false,
383
+ "properties": {
384
+ "entryId": {
385
+ "type": "string"
386
+ }
387
+ },
388
+ "required": [
389
+ "entryId"
390
+ ]
391
+ },
392
+ "query": {
393
+ "type": "object",
394
+ "additionalProperties": false,
395
+ "properties": {
396
+ "at": {
397
+ "type": "string",
398
+ "format": "date-time"
399
+ }
400
+ },
401
+ "required": [
402
+ "at"
403
+ ]
404
+ },
405
+ "headers": {
406
+ "type": "object",
407
+ "additionalProperties": true
408
+ }
409
+ },
410
+ "required": [
411
+ "params",
412
+ "query"
413
+ ],
414
+ "additionalProperties": false
415
+ },
416
+ "responses": {
417
+ "200": {
418
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
419
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/api/EntryGetResponseOK",
420
+ "type": "object",
421
+ "properties": {
422
+ "headers": {
423
+ "type": "object",
424
+ "properties": {
425
+ "created-on": {
426
+ "type": "string",
427
+ "format": "date-time"
428
+ },
429
+ "updated-on": {
430
+ "type": "string",
431
+ "format": "date-time"
432
+ },
433
+ "last-modified": {
434
+ "type": "string",
435
+ "format": "date-time"
436
+ }
437
+ },
438
+ "required": [
439
+ "created-on",
440
+ "updated-on",
441
+ "last-modified"
442
+ ]
443
+ },
444
+ "body": {
445
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
446
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/definitions/ResponseEntry",
447
+ "type": "object",
448
+ "additionalProperties": false,
449
+ "required": [
450
+ "entryId",
451
+ "createdOn",
452
+ "postings"
453
+ ],
454
+ "properties": {
455
+ "entryId": {
456
+ "type": "string",
457
+ "description": "Journal entry ID"
458
+ },
459
+ "createdOn": {
460
+ "type": "string",
461
+ "format": "date-time",
462
+ "description": "Journal entry creation date/time"
463
+ },
464
+ "postings": {
465
+ "type": "array",
466
+ "items": {
467
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
468
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/definitions/ResponsePost",
469
+ "type": "object",
470
+ "additionalProperties": false,
471
+ "required": [
472
+ "amount",
473
+ "currency",
474
+ "type",
475
+ "accountId",
476
+ "createdOn"
477
+ ],
478
+ "properties": {
479
+ "amount": {
480
+ "type": "string"
481
+ },
482
+ "currency": {
483
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
484
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/definitions/Currency",
485
+ "type": "string",
486
+ "description": "The alphabetic code that represents the currency.\n",
487
+ "enum": [
488
+ "AED",
489
+ "AFN"
490
+ ]
491
+ },
492
+ "type": {
493
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
494
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/definitions/Type",
495
+ "type": "string",
496
+ "description": "CREDIT or DEBIT",
497
+ "enum": [
498
+ "CREDIT",
499
+ "DEBIT"
500
+ ]
501
+ },
502
+ "createdOn": {
503
+ "type": "string",
504
+ "format": "date-time"
505
+ },
506
+ "accountId": {
507
+ "type": "string",
508
+ "description": "account ID"
509
+ }
510
+ }
511
+ }
512
+ }
513
+ }
514
+ }
515
+ },
516
+ "required": [
517
+ "headers",
518
+ "body"
519
+ ],
520
+ "additionalProperties": false
521
+ },
522
+ "404": {
523
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
524
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/api/EntryGetResponseNotFound",
525
+ "type": "object",
526
+ "properties": {
527
+ "headers": {
528
+ "type": "object",
529
+ "additionalProperties": true
530
+ }
531
+ },
532
+ "required": [],
533
+ "additionalProperties": false
534
+ },
535
+ "default": {
536
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
537
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/api/EntryGetResponseDefault",
538
+ "type": "object",
539
+ "properties": {
540
+ "headers": {
541
+ "type": "object",
542
+ "additionalProperties": true
543
+ },
544
+ "body": {
545
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
546
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/definitions/Error",
547
+ "type": "object",
548
+ "additionalProperties": false,
549
+ "description": "Error message",
550
+ "properties": {
551
+ "message": {
552
+ "type": "string"
553
+ },
554
+ "code": {
555
+ "type": "string"
556
+ }
557
+ }
558
+ }
559
+ },
560
+ "required": [
561
+ "body"
562
+ ],
563
+ "additionalProperties": false
564
+ }
565
+ }
566
+ },
567
+ "put": {
568
+ "request": {
569
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
570
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/api/EntryPutRequestContext",
571
+ "type": "object",
572
+ "properties": {
573
+ "params": {
574
+ "type": "object",
575
+ "additionalProperties": false,
576
+ "properties": {
577
+ "entryId": {
578
+ "type": "string"
579
+ }
580
+ },
581
+ "required": [
582
+ "entryId"
583
+ ]
584
+ },
585
+ "headers": {
586
+ "type": "object",
587
+ "additionalProperties": true,
588
+ "properties": {
589
+ "if-match": {
590
+ "type": "string"
591
+ },
592
+ "created-on": {
593
+ "type": "string",
594
+ "format": "date-time"
595
+ },
596
+ "last-modified": {
597
+ "type": "string",
598
+ "format": "date-time"
599
+ }
600
+ },
601
+ "required": [
602
+ "created-on"
603
+ ]
604
+ },
605
+ "body": {
606
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
607
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/definitions/NewEntry",
608
+ "type": "object",
609
+ "additionalProperties": false,
610
+ "required": [
611
+ "postings"
612
+ ],
613
+ "properties": {
614
+ "postings": {
615
+ "type": "array",
616
+ "description": "List of posts contained within the journal entry.",
617
+ "items": {
618
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
619
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/definitions/Post",
620
+ "type": "object",
621
+ "additionalProperties": false,
622
+ "required": [
623
+ "amount",
624
+ "currency",
625
+ "type",
626
+ "createdOn",
627
+ "accountId"
628
+ ],
629
+ "properties": {
630
+ "amount": {
631
+ "type": "string"
632
+ },
633
+ "currency": {
634
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
635
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/definitions/Currency",
636
+ "type": "string",
637
+ "description": "The alphabetic code that represents the currency.\n",
638
+ "enum": [
639
+ "AED",
640
+ "AFN"
641
+ ]
642
+ },
643
+ "type": {
644
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
645
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/definitions/Type",
646
+ "type": "string",
647
+ "description": "CREDIT or DEBIT",
648
+ "enum": [
649
+ "CREDIT",
650
+ "DEBIT"
651
+ ]
652
+ },
653
+ "createdOn": {
654
+ "type": "string",
655
+ "format": "date-time"
656
+ },
657
+ "accountId": {
658
+ "type": "string",
659
+ "description": "account ID"
660
+ }
661
+ }
662
+ }
663
+ },
664
+ "v1OnlyNewEntryProperty": {
665
+ "type": "string",
666
+ "description": "This is a v1-only property for NewEntry schema."
667
+ }
668
+ }
669
+ }
670
+ },
671
+ "required": [
672
+ "params",
673
+ "headers",
674
+ "body"
675
+ ],
676
+ "additionalProperties": false
677
+ },
678
+ "responses": {
679
+ "204": {
680
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
681
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/api/EntryPutResponseNoContent",
682
+ "type": "object",
683
+ "properties": {
684
+ "headers": {
685
+ "type": "object",
686
+ "properties": {
687
+ "created-on": {
688
+ "type": "string",
689
+ "format": "date-time"
690
+ },
691
+ "updated-on": {
692
+ "type": "string",
693
+ "format": "date-time"
694
+ },
695
+ "last-modified": {
696
+ "type": "string",
697
+ "format": "date-time"
698
+ }
699
+ },
700
+ "required": [
701
+ "created-on",
702
+ "updated-on",
703
+ "last-modified"
704
+ ]
705
+ }
706
+ },
707
+ "required": [
708
+ "headers"
709
+ ],
710
+ "additionalProperties": false
711
+ },
712
+ "409": {
713
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
714
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/api/EntryPutResponseConflict",
715
+ "type": "object",
716
+ "properties": {
717
+ "headers": {
718
+ "type": "object",
719
+ "additionalProperties": true
720
+ }
721
+ },
722
+ "required": [],
723
+ "additionalProperties": false
724
+ },
725
+ "412": {
726
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
727
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/api/EntryPutResponsePreconditionFailed",
728
+ "type": "object",
729
+ "properties": {
730
+ "headers": {
731
+ "type": "object",
732
+ "additionalProperties": true
733
+ }
734
+ },
735
+ "required": [],
736
+ "additionalProperties": false
737
+ },
738
+ "default": {
739
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
740
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/api/EntryPutResponseDefault",
741
+ "type": "object",
742
+ "properties": {
743
+ "headers": {
744
+ "type": "object",
745
+ "additionalProperties": true
746
+ },
747
+ "body": {
748
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
749
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/definitions/Error",
750
+ "type": "object",
751
+ "additionalProperties": false,
752
+ "description": "Error message",
753
+ "properties": {
754
+ "message": {
755
+ "type": "string"
756
+ },
757
+ "code": {
758
+ "type": "string"
759
+ }
760
+ }
761
+ }
762
+ },
763
+ "required": [
764
+ "body"
765
+ ],
766
+ "additionalProperties": false
767
+ }
768
+ }
769
+ }
770
+ },
771
+ "/eslint-athena-plugin/v1/card/:cardId": {
772
+ "get": {
773
+ "request": {
774
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
775
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/api/CardGetRequestContext",
776
+ "type": "object",
777
+ "properties": {
778
+ "params": {
779
+ "type": "object",
780
+ "additionalProperties": false,
781
+ "properties": {
782
+ "cardId": {
783
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
784
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/definitions/CardId",
785
+ "type": "string",
786
+ "description": "Card identifier",
787
+ "format": "uuid"
788
+ }
789
+ },
790
+ "required": [
791
+ "cardId"
792
+ ]
793
+ },
794
+ "query": {
795
+ "type": "object",
796
+ "additionalProperties": false,
797
+ "properties": {
798
+ "at": {
799
+ "type": "string",
800
+ "format": "date-time"
801
+ },
802
+ "publicKeyHashQuery": {
803
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
804
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/definitions/Hash",
805
+ "type": "string",
806
+ "format": "uuid",
807
+ "example": "15a85f64-5717-4562-b3fc-2c963f66afa6",
808
+ "description": "UUID derived using @checkdigit/hash"
809
+ }
810
+ },
811
+ "required": [
812
+ "at"
813
+ ]
814
+ },
815
+ "headers": {
816
+ "type": "object",
817
+ "additionalProperties": true
818
+ }
819
+ },
820
+ "required": [
821
+ "params",
822
+ "query"
823
+ ],
824
+ "additionalProperties": false
825
+ },
826
+ "responses": {
827
+ "200": {
828
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
829
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/api/CardGetResponseOK",
830
+ "type": "object",
831
+ "properties": {
832
+ "headers": {
833
+ "type": "object",
834
+ "properties": {
835
+ "last-modified": {
836
+ "type": "string",
837
+ "format": "date-time"
838
+ },
839
+ "created-on": {
840
+ "type": "string",
841
+ "format": "date-time"
842
+ },
843
+ "updated-on": {
844
+ "type": "string",
845
+ "format": "date-time"
846
+ },
847
+ "etag": {
848
+ "type": "string"
849
+ }
850
+ },
851
+ "required": [
852
+ "last-modified",
853
+ "created-on",
854
+ "updated-on",
855
+ "etag"
856
+ ]
857
+ },
858
+ "body": {
859
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
860
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/definitions/CardResponse",
861
+ "type": "object",
862
+ "additionalProperties": false,
863
+ "required": [
864
+ "dataEncryptionKeyId",
865
+ "storageKeyId",
866
+ "card"
867
+ ],
868
+ "properties": {
869
+ "encryptedDataEncryptionKey": {
870
+ "description": "Encrypted DEK matching the publicKeyHash sent in the request. Used to decrypt values in the Card object.\n",
871
+ "type": "string"
872
+ },
873
+ "card": {
874
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
875
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/definitions/Card",
876
+ "type": "object",
877
+ "additionalProperties": false,
878
+ "required": [
879
+ "last4",
880
+ "cardNumber",
881
+ "applicationTransactionCounter"
882
+ ],
883
+ "properties": {
884
+ "last4": {
885
+ "type": "string",
886
+ "pattern": "^\\d+$",
887
+ "description": "Last four digits of the card number",
888
+ "minLength": 4,
889
+ "maxLength": 4
890
+ },
891
+ "cardNumber": {
892
+ "type": "string",
893
+ "description": "Encrypted card number (PAN)"
894
+ },
895
+ "applicationTransactionCounter": {
896
+ "type": "integer",
897
+ "description": "Application transaction counter (ATC) for the card"
898
+ }
899
+ }
900
+ }
901
+ }
902
+ }
903
+ },
904
+ "required": [
905
+ "headers",
906
+ "body"
907
+ ],
908
+ "additionalProperties": false
909
+ },
910
+ "404": {
911
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
912
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/api/CardGetResponseNotFound",
913
+ "type": "object",
914
+ "properties": {
915
+ "headers": {
916
+ "type": "object",
917
+ "additionalProperties": true
918
+ }
919
+ },
920
+ "required": [],
921
+ "additionalProperties": false
922
+ },
923
+ "default": {
924
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
925
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/api/CardGetResponseDefault",
926
+ "type": "object",
927
+ "properties": {
928
+ "headers": {
929
+ "type": "object",
930
+ "additionalProperties": true
931
+ },
932
+ "body": {
933
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
934
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/definitions/Error",
935
+ "type": "object",
936
+ "additionalProperties": false,
937
+ "description": "Error message",
938
+ "properties": {
939
+ "message": {
940
+ "type": "string"
941
+ },
942
+ "code": {
943
+ "type": "string"
944
+ }
945
+ }
946
+ }
947
+ },
948
+ "required": [
949
+ "body"
950
+ ],
951
+ "additionalProperties": false
952
+ }
953
+ }
954
+ },
955
+ "put": {
956
+ "request": {
957
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
958
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/api/CardPutRequestContext",
959
+ "type": "object",
960
+ "properties": {
961
+ "params": {
962
+ "type": "object",
963
+ "additionalProperties": false,
964
+ "properties": {
965
+ "cardId": {
966
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
967
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/definitions/CardId",
968
+ "type": "string",
969
+ "description": "Card identifier",
970
+ "format": "uuid"
971
+ }
972
+ },
973
+ "required": [
974
+ "cardId"
975
+ ]
976
+ },
977
+ "headers": {
978
+ "type": "object",
979
+ "additionalProperties": true,
980
+ "properties": {
981
+ "created-on": {
982
+ "type": "string",
983
+ "format": "date-time"
984
+ },
985
+ "last-modified": {
986
+ "type": "string",
987
+ "format": "date-time"
988
+ }
989
+ },
990
+ "required": [
991
+ "created-on"
992
+ ]
993
+ },
994
+ "body": {
995
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
996
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/definitions/NewCardRequest",
997
+ "type": "object",
998
+ "required": [
999
+ "dataEncryptionKeyId",
1000
+ "cardNumberLength",
1001
+ "newCard"
1002
+ ],
1003
+ "additionalProperties": false,
1004
+ "properties": {
1005
+ "dataEncryptionKeyId": {
1006
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
1007
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/definitions/DataEncryptionKeyId",
1008
+ "type": "string",
1009
+ "description": "Reference to encryption keys Payment Card Service will use to encrypt the Card object.\n",
1010
+ "format": "uuid"
1011
+ },
1012
+ "cardNumberLength": {
1013
+ "type": "integer",
1014
+ "description": "Desired number of digits in the card number.",
1015
+ "minimum": 15,
1016
+ "maximum": 19
1017
+ },
1018
+ "newCard": {
1019
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
1020
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/definitions/NewCard",
1021
+ "type": "object",
1022
+ "additionalProperties": false,
1023
+ "required": [
1024
+ "serviceCode",
1025
+ "sequenceNumber"
1026
+ ],
1027
+ "properties": {
1028
+ "serviceCode": {
1029
+ "type": "string",
1030
+ "pattern": "^\\d+$",
1031
+ "description": "Used to set general guidelines for how the card can be used, e.g. domestic only or international, online authorizations only, etc.\n",
1032
+ "minLength": 3,
1033
+ "maxLength": 3
1034
+ },
1035
+ "sequenceNumber": {
1036
+ "type": "integer",
1037
+ "description": "Used to differentiate issuing the same card and expiration date on multiple plastics.",
1038
+ "minimum": 0,
1039
+ "maximum": 10
1040
+ }
1041
+ }
1042
+ }
1043
+ }
1044
+ }
1045
+ },
1046
+ "required": [
1047
+ "params",
1048
+ "headers",
1049
+ "body"
1050
+ ],
1051
+ "additionalProperties": false
1052
+ },
1053
+ "responses": {
1054
+ "200": {
1055
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
1056
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/api/CardPutResponseOK",
1057
+ "type": "object",
1058
+ "properties": {
1059
+ "headers": {
1060
+ "type": "object",
1061
+ "properties": {
1062
+ "last-modified": {
1063
+ "type": "string",
1064
+ "format": "date-time"
1065
+ },
1066
+ "created-on": {
1067
+ "type": "string",
1068
+ "format": "date-time"
1069
+ },
1070
+ "updated-on": {
1071
+ "type": "string",
1072
+ "format": "date-time"
1073
+ },
1074
+ "etag": {
1075
+ "type": "string"
1076
+ }
1077
+ },
1078
+ "required": [
1079
+ "last-modified",
1080
+ "created-on",
1081
+ "updated-on",
1082
+ "etag"
1083
+ ]
1084
+ },
1085
+ "body": {
1086
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
1087
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/definitions/CardResponse",
1088
+ "type": "object",
1089
+ "additionalProperties": false,
1090
+ "required": [
1091
+ "dataEncryptionKeyId",
1092
+ "storageKeyId",
1093
+ "card"
1094
+ ],
1095
+ "properties": {
1096
+ "encryptedDataEncryptionKey": {
1097
+ "description": "Encrypted DEK matching the publicKeyHash sent in the request. Used to decrypt values in the Card object.\n",
1098
+ "type": "string"
1099
+ },
1100
+ "card": {
1101
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
1102
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/definitions/Card",
1103
+ "type": "object",
1104
+ "additionalProperties": false,
1105
+ "required": [
1106
+ "last4",
1107
+ "cardNumber",
1108
+ "applicationTransactionCounter"
1109
+ ],
1110
+ "properties": {
1111
+ "last4": {
1112
+ "type": "string",
1113
+ "pattern": "^\\d+$",
1114
+ "description": "Last four digits of the card number",
1115
+ "minLength": 4,
1116
+ "maxLength": 4
1117
+ },
1118
+ "cardNumber": {
1119
+ "type": "string",
1120
+ "description": "Encrypted card number (PAN)"
1121
+ },
1122
+ "applicationTransactionCounter": {
1123
+ "type": "integer",
1124
+ "description": "Application transaction counter (ATC) for the card"
1125
+ }
1126
+ }
1127
+ }
1128
+ }
1129
+ }
1130
+ },
1131
+ "required": [
1132
+ "headers",
1133
+ "body"
1134
+ ],
1135
+ "additionalProperties": false
1136
+ },
1137
+ "409": {
1138
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
1139
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/api/CardPutResponseConflict",
1140
+ "type": "object",
1141
+ "properties": {
1142
+ "headers": {
1143
+ "type": "object",
1144
+ "additionalProperties": true
1145
+ }
1146
+ },
1147
+ "required": [],
1148
+ "additionalProperties": false
1149
+ },
1150
+ "412": {
1151
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
1152
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/api/CardPutResponsePreconditionFailed",
1153
+ "type": "object",
1154
+ "properties": {
1155
+ "headers": {
1156
+ "type": "object",
1157
+ "additionalProperties": true
1158
+ }
1159
+ },
1160
+ "required": [],
1161
+ "additionalProperties": false
1162
+ },
1163
+ "default": {
1164
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
1165
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/api/CardPutResponseDefault",
1166
+ "type": "object",
1167
+ "properties": {
1168
+ "headers": {
1169
+ "type": "object",
1170
+ "additionalProperties": true
1171
+ },
1172
+ "body": {
1173
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
1174
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/definitions/Error",
1175
+ "type": "object",
1176
+ "additionalProperties": false,
1177
+ "description": "Error message",
1178
+ "properties": {
1179
+ "message": {
1180
+ "type": "string"
1181
+ },
1182
+ "code": {
1183
+ "type": "string"
1184
+ }
1185
+ }
1186
+ }
1187
+ },
1188
+ "required": [
1189
+ "body"
1190
+ ],
1191
+ "additionalProperties": false
1192
+ }
1193
+ }
1194
+ }
1195
+ }
1196
+ },
1197
+ "definitions": {
1198
+ "Ping": {
1199
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
1200
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/definitions/Ping",
1201
+ "type": "object",
1202
+ "additionalProperties": false,
1203
+ "required": [
1204
+ "serverTime",
1205
+ "v1Only"
1206
+ ],
1207
+ "properties": {
1208
+ "serverTime": {
1209
+ "type": "string",
1210
+ "format": "date-time",
1211
+ "description": "Current server time"
1212
+ },
1213
+ "v1Only": {
1214
+ "type": "boolean",
1215
+ "description": "Indicates if the server is running in v1-only mode"
1216
+ }
1217
+ }
1218
+ },
1219
+ "Error": {
1220
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
1221
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/definitions/Error",
1222
+ "type": "object",
1223
+ "additionalProperties": false,
1224
+ "description": "Error message",
1225
+ "properties": {
1226
+ "message": {
1227
+ "type": "string"
1228
+ },
1229
+ "code": {
1230
+ "type": "string"
1231
+ }
1232
+ }
1233
+ },
1234
+ "MessageId": {
1235
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
1236
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/definitions/MessageId",
1237
+ "description": "Uniquely identifies a message stored in the platform.\n\nA message's request and response are stored and retrieved separately using this identifier.\n",
1238
+ "type": "string"
1239
+ },
1240
+ "NewRequest": {
1241
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
1242
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/definitions/NewRequest",
1243
+ "type": "object",
1244
+ "additionalProperties": false,
1245
+ "required": [
1246
+ "messageId",
1247
+ "feeDetails"
1248
+ ],
1249
+ "description": "The incoming message request data received from the network to be processed.",
1250
+ "properties": {
1251
+ "messageId": {
1252
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
1253
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/definitions/MessageId",
1254
+ "description": "Uniquely identifies a message stored in the platform.\n\nA message's request and response are stored and retrieved separately using this identifier.\n",
1255
+ "type": "string"
1256
+ },
1257
+ "feeDetails": {
1258
+ "type": "array",
1259
+ "description": "Details about the fees that went into the transaction and settlement fee amounts",
1260
+ "items": {
1261
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
1262
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/definitions/Fee",
1263
+ "type": "object",
1264
+ "description": "Details about the fees applied to the transaction and settlement amounts.",
1265
+ "additionalProperties": false,
1266
+ "required": [
1267
+ "type",
1268
+ "application",
1269
+ "transaction",
1270
+ "settlement"
1271
+ ],
1272
+ "properties": {
1273
+ "type": {
1274
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
1275
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/definitions/FeeType",
1276
+ "type": "string",
1277
+ "description": "The type of fee being applied to the transaction.",
1278
+ "enum": [
1279
+ "CONVENIENCE",
1280
+ "TRANSACTION",
1281
+ "CURRENCY CONVERSION ASSESSMENT",
1282
+ "ISSUER CURRENCY CONVERSION ASSESSMENT",
1283
+ "SURCHARGE",
1284
+ "OPTIONAL ISSUER",
1285
+ "PROCESSING",
1286
+ "FOREIGN EXCHANGE"
1287
+ ]
1288
+ },
1289
+ "application": {
1290
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
1291
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/definitions/FeeApplication",
1292
+ "type": "string",
1293
+ "description": "Indicates whether the fee should be applied to a cardholder's account (SETTLE) or recorded for information\npurposes only (MEMO). Examples of MEMO fees are currency conversion fees (already in the settlement amount) and\ninterchange fees.\n",
1294
+ "enum": [
1295
+ "MEMO",
1296
+ "SETTLE"
1297
+ ]
1298
+ },
1299
+ "transaction": {
1300
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
1301
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/definitions/Amount",
1302
+ "type": "object",
1303
+ "additionalProperties": false,
1304
+ "description": "An amount of money in the smallest monetary unit of the specified currency.\n",
1305
+ "required": [
1306
+ "amount",
1307
+ "currency"
1308
+ ],
1309
+ "properties": {
1310
+ "amount": {
1311
+ "type": "string",
1312
+ "pattern": "^[0-9]+$",
1313
+ "description": "The amount of money in the smallest monetary unit of the specified currency."
1314
+ },
1315
+ "currency": {
1316
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
1317
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/definitions/Currency",
1318
+ "type": "string",
1319
+ "description": "The alphabetic code that represents the currency.\n",
1320
+ "enum": [
1321
+ "AED",
1322
+ "AFN"
1323
+ ]
1324
+ }
1325
+ }
1326
+ },
1327
+ "settlement": {
1328
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
1329
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/definitions/Amount",
1330
+ "type": "object",
1331
+ "additionalProperties": false,
1332
+ "description": "An amount of money in the smallest monetary unit of the specified currency.\n",
1333
+ "required": [
1334
+ "amount",
1335
+ "currency"
1336
+ ],
1337
+ "properties": {
1338
+ "amount": {
1339
+ "type": "string",
1340
+ "pattern": "^[0-9]+$",
1341
+ "description": "The amount of money in the smallest monetary unit of the specified currency."
1342
+ },
1343
+ "currency": {
1344
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
1345
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/definitions/Currency",
1346
+ "type": "string",
1347
+ "description": "The alphabetic code that represents the currency.\n",
1348
+ "enum": [
1349
+ "AED",
1350
+ "AFN"
1351
+ ]
1352
+ }
1353
+ }
1354
+ }
1355
+ }
1356
+ }
1357
+ }
1358
+ }
1359
+ },
1360
+ "Fee": {
1361
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
1362
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/definitions/Fee",
1363
+ "type": "object",
1364
+ "description": "Details about the fees applied to the transaction and settlement amounts.",
1365
+ "additionalProperties": false,
1366
+ "required": [
1367
+ "type",
1368
+ "application",
1369
+ "transaction",
1370
+ "settlement"
1371
+ ],
1372
+ "properties": {
1373
+ "type": {
1374
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
1375
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/definitions/FeeType",
1376
+ "type": "string",
1377
+ "description": "The type of fee being applied to the transaction.",
1378
+ "enum": [
1379
+ "CONVENIENCE",
1380
+ "TRANSACTION",
1381
+ "CURRENCY CONVERSION ASSESSMENT",
1382
+ "ISSUER CURRENCY CONVERSION ASSESSMENT",
1383
+ "SURCHARGE",
1384
+ "OPTIONAL ISSUER",
1385
+ "PROCESSING",
1386
+ "FOREIGN EXCHANGE"
1387
+ ]
1388
+ },
1389
+ "application": {
1390
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
1391
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/definitions/FeeApplication",
1392
+ "type": "string",
1393
+ "description": "Indicates whether the fee should be applied to a cardholder's account (SETTLE) or recorded for information\npurposes only (MEMO). Examples of MEMO fees are currency conversion fees (already in the settlement amount) and\ninterchange fees.\n",
1394
+ "enum": [
1395
+ "MEMO",
1396
+ "SETTLE"
1397
+ ]
1398
+ },
1399
+ "transaction": {
1400
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
1401
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/definitions/Amount",
1402
+ "type": "object",
1403
+ "additionalProperties": false,
1404
+ "description": "An amount of money in the smallest monetary unit of the specified currency.\n",
1405
+ "required": [
1406
+ "amount",
1407
+ "currency"
1408
+ ],
1409
+ "properties": {
1410
+ "amount": {
1411
+ "type": "string",
1412
+ "pattern": "^[0-9]+$",
1413
+ "description": "The amount of money in the smallest monetary unit of the specified currency."
1414
+ },
1415
+ "currency": {
1416
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
1417
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/definitions/Currency",
1418
+ "type": "string",
1419
+ "description": "The alphabetic code that represents the currency.\n",
1420
+ "enum": [
1421
+ "AED",
1422
+ "AFN"
1423
+ ]
1424
+ }
1425
+ }
1426
+ },
1427
+ "settlement": {
1428
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
1429
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/definitions/Amount",
1430
+ "type": "object",
1431
+ "additionalProperties": false,
1432
+ "description": "An amount of money in the smallest monetary unit of the specified currency.\n",
1433
+ "required": [
1434
+ "amount",
1435
+ "currency"
1436
+ ],
1437
+ "properties": {
1438
+ "amount": {
1439
+ "type": "string",
1440
+ "pattern": "^[0-9]+$",
1441
+ "description": "The amount of money in the smallest monetary unit of the specified currency."
1442
+ },
1443
+ "currency": {
1444
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
1445
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/definitions/Currency",
1446
+ "type": "string",
1447
+ "description": "The alphabetic code that represents the currency.\n",
1448
+ "enum": [
1449
+ "AED",
1450
+ "AFN"
1451
+ ]
1452
+ }
1453
+ }
1454
+ }
1455
+ }
1456
+ },
1457
+ "FeeType": {
1458
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
1459
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/definitions/FeeType",
1460
+ "type": "string",
1461
+ "description": "The type of fee being applied to the transaction.",
1462
+ "enum": [
1463
+ "CONVENIENCE",
1464
+ "TRANSACTION",
1465
+ "CURRENCY CONVERSION ASSESSMENT",
1466
+ "ISSUER CURRENCY CONVERSION ASSESSMENT",
1467
+ "SURCHARGE",
1468
+ "OPTIONAL ISSUER",
1469
+ "PROCESSING",
1470
+ "FOREIGN EXCHANGE"
1471
+ ]
1472
+ },
1473
+ "FeeApplication": {
1474
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
1475
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/definitions/FeeApplication",
1476
+ "type": "string",
1477
+ "description": "Indicates whether the fee should be applied to a cardholder's account (SETTLE) or recorded for information\npurposes only (MEMO). Examples of MEMO fees are currency conversion fees (already in the settlement amount) and\ninterchange fees.\n",
1478
+ "enum": [
1479
+ "MEMO",
1480
+ "SETTLE"
1481
+ ]
1482
+ },
1483
+ "Amount": {
1484
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
1485
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/definitions/Amount",
1486
+ "type": "object",
1487
+ "additionalProperties": false,
1488
+ "description": "An amount of money in the smallest monetary unit of the specified currency.\n",
1489
+ "required": [
1490
+ "amount",
1491
+ "currency"
1492
+ ],
1493
+ "properties": {
1494
+ "amount": {
1495
+ "type": "string",
1496
+ "pattern": "^[0-9]+$",
1497
+ "description": "The amount of money in the smallest monetary unit of the specified currency."
1498
+ },
1499
+ "currency": {
1500
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
1501
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/definitions/Currency",
1502
+ "type": "string",
1503
+ "description": "The alphabetic code that represents the currency.\n",
1504
+ "enum": [
1505
+ "AED",
1506
+ "AFN"
1507
+ ]
1508
+ }
1509
+ }
1510
+ },
1511
+ "Currency": {
1512
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
1513
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/definitions/Currency",
1514
+ "type": "string",
1515
+ "description": "The alphabetic code that represents the currency.\n",
1516
+ "enum": [
1517
+ "AED",
1518
+ "AFN"
1519
+ ]
1520
+ },
1521
+ "ResponseEntry": {
1522
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
1523
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/definitions/ResponseEntry",
1524
+ "type": "object",
1525
+ "additionalProperties": false,
1526
+ "required": [
1527
+ "entryId",
1528
+ "createdOn",
1529
+ "postings"
1530
+ ],
1531
+ "properties": {
1532
+ "entryId": {
1533
+ "type": "string",
1534
+ "description": "Journal entry ID"
1535
+ },
1536
+ "createdOn": {
1537
+ "type": "string",
1538
+ "format": "date-time",
1539
+ "description": "Journal entry creation date/time"
1540
+ },
1541
+ "postings": {
1542
+ "type": "array",
1543
+ "items": {
1544
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
1545
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/definitions/ResponsePost",
1546
+ "type": "object",
1547
+ "additionalProperties": false,
1548
+ "required": [
1549
+ "amount",
1550
+ "currency",
1551
+ "type",
1552
+ "accountId",
1553
+ "createdOn"
1554
+ ],
1555
+ "properties": {
1556
+ "amount": {
1557
+ "type": "string"
1558
+ },
1559
+ "currency": {
1560
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
1561
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/definitions/Currency",
1562
+ "type": "string",
1563
+ "description": "The alphabetic code that represents the currency.\n",
1564
+ "enum": [
1565
+ "AED",
1566
+ "AFN"
1567
+ ]
1568
+ },
1569
+ "type": {
1570
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
1571
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/definitions/Type",
1572
+ "type": "string",
1573
+ "description": "CREDIT or DEBIT",
1574
+ "enum": [
1575
+ "CREDIT",
1576
+ "DEBIT"
1577
+ ]
1578
+ },
1579
+ "createdOn": {
1580
+ "type": "string",
1581
+ "format": "date-time"
1582
+ },
1583
+ "accountId": {
1584
+ "type": "string",
1585
+ "description": "account ID"
1586
+ }
1587
+ }
1588
+ }
1589
+ }
1590
+ }
1591
+ },
1592
+ "NewEntry": {
1593
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
1594
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/definitions/NewEntry",
1595
+ "type": "object",
1596
+ "additionalProperties": false,
1597
+ "required": [
1598
+ "postings"
1599
+ ],
1600
+ "properties": {
1601
+ "postings": {
1602
+ "type": "array",
1603
+ "description": "List of posts contained within the journal entry.",
1604
+ "items": {
1605
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
1606
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/definitions/Post",
1607
+ "type": "object",
1608
+ "additionalProperties": false,
1609
+ "required": [
1610
+ "amount",
1611
+ "currency",
1612
+ "type",
1613
+ "createdOn",
1614
+ "accountId"
1615
+ ],
1616
+ "properties": {
1617
+ "amount": {
1618
+ "type": "string"
1619
+ },
1620
+ "currency": {
1621
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
1622
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/definitions/Currency",
1623
+ "type": "string",
1624
+ "description": "The alphabetic code that represents the currency.\n",
1625
+ "enum": [
1626
+ "AED",
1627
+ "AFN"
1628
+ ]
1629
+ },
1630
+ "type": {
1631
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
1632
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/definitions/Type",
1633
+ "type": "string",
1634
+ "description": "CREDIT or DEBIT",
1635
+ "enum": [
1636
+ "CREDIT",
1637
+ "DEBIT"
1638
+ ]
1639
+ },
1640
+ "createdOn": {
1641
+ "type": "string",
1642
+ "format": "date-time"
1643
+ },
1644
+ "accountId": {
1645
+ "type": "string",
1646
+ "description": "account ID"
1647
+ }
1648
+ }
1649
+ }
1650
+ },
1651
+ "v1OnlyNewEntryProperty": {
1652
+ "type": "string",
1653
+ "description": "This is a v1-only property for NewEntry schema."
1654
+ }
1655
+ }
1656
+ },
1657
+ "Post": {
1658
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
1659
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/definitions/Post",
1660
+ "type": "object",
1661
+ "additionalProperties": false,
1662
+ "required": [
1663
+ "amount",
1664
+ "currency",
1665
+ "type",
1666
+ "createdOn",
1667
+ "accountId"
1668
+ ],
1669
+ "properties": {
1670
+ "amount": {
1671
+ "type": "string"
1672
+ },
1673
+ "currency": {
1674
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
1675
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/definitions/Currency",
1676
+ "type": "string",
1677
+ "description": "The alphabetic code that represents the currency.\n",
1678
+ "enum": [
1679
+ "AED",
1680
+ "AFN"
1681
+ ]
1682
+ },
1683
+ "type": {
1684
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
1685
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/definitions/Type",
1686
+ "type": "string",
1687
+ "description": "CREDIT or DEBIT",
1688
+ "enum": [
1689
+ "CREDIT",
1690
+ "DEBIT"
1691
+ ]
1692
+ },
1693
+ "createdOn": {
1694
+ "type": "string",
1695
+ "format": "date-time"
1696
+ },
1697
+ "accountId": {
1698
+ "type": "string",
1699
+ "description": "account ID"
1700
+ }
1701
+ }
1702
+ },
1703
+ "ResponsePost": {
1704
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
1705
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/definitions/ResponsePost",
1706
+ "type": "object",
1707
+ "additionalProperties": false,
1708
+ "required": [
1709
+ "amount",
1710
+ "currency",
1711
+ "type",
1712
+ "accountId",
1713
+ "createdOn"
1714
+ ],
1715
+ "properties": {
1716
+ "amount": {
1717
+ "type": "string"
1718
+ },
1719
+ "currency": {
1720
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
1721
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/definitions/Currency",
1722
+ "type": "string",
1723
+ "description": "The alphabetic code that represents the currency.\n",
1724
+ "enum": [
1725
+ "AED",
1726
+ "AFN"
1727
+ ]
1728
+ },
1729
+ "type": {
1730
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
1731
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/definitions/Type",
1732
+ "type": "string",
1733
+ "description": "CREDIT or DEBIT",
1734
+ "enum": [
1735
+ "CREDIT",
1736
+ "DEBIT"
1737
+ ]
1738
+ },
1739
+ "createdOn": {
1740
+ "type": "string",
1741
+ "format": "date-time"
1742
+ },
1743
+ "accountId": {
1744
+ "type": "string",
1745
+ "description": "account ID"
1746
+ }
1747
+ }
1748
+ },
1749
+ "Type": {
1750
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
1751
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/definitions/Type",
1752
+ "type": "string",
1753
+ "description": "CREDIT or DEBIT",
1754
+ "enum": [
1755
+ "CREDIT",
1756
+ "DEBIT"
1757
+ ]
1758
+ },
1759
+ "CardId": {
1760
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
1761
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/definitions/CardId",
1762
+ "type": "string",
1763
+ "description": "Card identifier",
1764
+ "format": "uuid"
1765
+ },
1766
+ "Hash": {
1767
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
1768
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/definitions/Hash",
1769
+ "type": "string",
1770
+ "format": "uuid",
1771
+ "example": "15a85f64-5717-4562-b3fc-2c963f66afa6",
1772
+ "description": "UUID derived using @checkdigit/hash"
1773
+ },
1774
+ "CardResponse": {
1775
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
1776
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/definitions/CardResponse",
1777
+ "type": "object",
1778
+ "additionalProperties": false,
1779
+ "required": [
1780
+ "dataEncryptionKeyId",
1781
+ "storageKeyId",
1782
+ "card"
1783
+ ],
1784
+ "properties": {
1785
+ "encryptedDataEncryptionKey": {
1786
+ "description": "Encrypted DEK matching the publicKeyHash sent in the request. Used to decrypt values in the Card object.\n",
1787
+ "type": "string"
1788
+ },
1789
+ "card": {
1790
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
1791
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/definitions/Card",
1792
+ "type": "object",
1793
+ "additionalProperties": false,
1794
+ "required": [
1795
+ "last4",
1796
+ "cardNumber",
1797
+ "applicationTransactionCounter"
1798
+ ],
1799
+ "properties": {
1800
+ "last4": {
1801
+ "type": "string",
1802
+ "pattern": "^\\d+$",
1803
+ "description": "Last four digits of the card number",
1804
+ "minLength": 4,
1805
+ "maxLength": 4
1806
+ },
1807
+ "cardNumber": {
1808
+ "type": "string",
1809
+ "description": "Encrypted card number (PAN)"
1810
+ },
1811
+ "applicationTransactionCounter": {
1812
+ "type": "integer",
1813
+ "description": "Application transaction counter (ATC) for the card"
1814
+ }
1815
+ }
1816
+ }
1817
+ }
1818
+ },
1819
+ "Card": {
1820
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
1821
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/definitions/Card",
1822
+ "type": "object",
1823
+ "additionalProperties": false,
1824
+ "required": [
1825
+ "last4",
1826
+ "cardNumber",
1827
+ "applicationTransactionCounter"
1828
+ ],
1829
+ "properties": {
1830
+ "last4": {
1831
+ "type": "string",
1832
+ "pattern": "^\\d+$",
1833
+ "description": "Last four digits of the card number",
1834
+ "minLength": 4,
1835
+ "maxLength": 4
1836
+ },
1837
+ "cardNumber": {
1838
+ "type": "string",
1839
+ "description": "Encrypted card number (PAN)"
1840
+ },
1841
+ "applicationTransactionCounter": {
1842
+ "type": "integer",
1843
+ "description": "Application transaction counter (ATC) for the card"
1844
+ }
1845
+ }
1846
+ },
1847
+ "NewCardRequest": {
1848
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
1849
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/definitions/NewCardRequest",
1850
+ "type": "object",
1851
+ "required": [
1852
+ "dataEncryptionKeyId",
1853
+ "cardNumberLength",
1854
+ "newCard"
1855
+ ],
1856
+ "additionalProperties": false,
1857
+ "properties": {
1858
+ "dataEncryptionKeyId": {
1859
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
1860
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/definitions/DataEncryptionKeyId",
1861
+ "type": "string",
1862
+ "description": "Reference to encryption keys Payment Card Service will use to encrypt the Card object.\n",
1863
+ "format": "uuid"
1864
+ },
1865
+ "cardNumberLength": {
1866
+ "type": "integer",
1867
+ "description": "Desired number of digits in the card number.",
1868
+ "minimum": 15,
1869
+ "maximum": 19
1870
+ },
1871
+ "newCard": {
1872
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
1873
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/definitions/NewCard",
1874
+ "type": "object",
1875
+ "additionalProperties": false,
1876
+ "required": [
1877
+ "serviceCode",
1878
+ "sequenceNumber"
1879
+ ],
1880
+ "properties": {
1881
+ "serviceCode": {
1882
+ "type": "string",
1883
+ "pattern": "^\\d+$",
1884
+ "description": "Used to set general guidelines for how the card can be used, e.g. domestic only or international, online authorizations only, etc.\n",
1885
+ "minLength": 3,
1886
+ "maxLength": 3
1887
+ },
1888
+ "sequenceNumber": {
1889
+ "type": "integer",
1890
+ "description": "Used to differentiate issuing the same card and expiration date on multiple plastics.",
1891
+ "minimum": 0,
1892
+ "maximum": 10
1893
+ }
1894
+ }
1895
+ }
1896
+ }
1897
+ },
1898
+ "DataEncryptionKeyId": {
1899
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
1900
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/definitions/DataEncryptionKeyId",
1901
+ "type": "string",
1902
+ "description": "Reference to encryption keys Payment Card Service will use to encrypt the Card object.\n",
1903
+ "format": "uuid"
1904
+ },
1905
+ "NewCard": {
1906
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
1907
+ "$id": "https://eslint-athena-plugin.checkdigit/eslint-athena-plugin/v1/schemas/definitions/NewCard",
1908
+ "type": "object",
1909
+ "additionalProperties": false,
1910
+ "required": [
1911
+ "serviceCode",
1912
+ "sequenceNumber"
1913
+ ],
1914
+ "properties": {
1915
+ "serviceCode": {
1916
+ "type": "string",
1917
+ "pattern": "^\\d+$",
1918
+ "description": "Used to set general guidelines for how the card can be used, e.g. domestic only or international, online authorizations only, etc.\n",
1919
+ "minLength": 3,
1920
+ "maxLength": 3
1921
+ },
1922
+ "sequenceNumber": {
1923
+ "type": "integer",
1924
+ "description": "Used to differentiate issuing the same card and expiration date on multiple plastics.",
1925
+ "minimum": 0,
1926
+ "maximum": 10
1927
+ }
1928
+ }
1929
+ }
1930
+ }
1931
+ }