@checkdigit/eslint-plugin 7.17.1 → 7.18.0-PR.143-8290
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist-mjs/athena/api-locator.mjs +30 -0
- package/dist-mjs/athena/api-matcher.mjs +108 -0
- package/dist-mjs/athena/athena.mjs +331 -0
- package/dist-mjs/athena/column.mjs +1 -0
- package/dist-mjs/athena/context.mjs +21 -0
- package/dist-mjs/athena/index.mjs +1 -0
- package/dist-mjs/athena/service-table.mjs +32 -0
- package/dist-mjs/athena/types.mjs +1 -0
- package/dist-mjs/athena/visitor.mjs +258 -0
- package/dist-mjs/index.mjs +8 -4
- package/dist-mjs/no-status-code-assert.mjs +1 -1
- package/dist-mjs/openapi/deref-schema.mjs +14 -0
- package/dist-mjs/openapi/generate-schema.mjs +273 -0
- package/dist-mjs/openapi/service-schema-generator.mjs +147 -0
- package/dist-mjs/peggy/athena-peggy.mjs +20629 -0
- package/dist-types/athena/api-locator.d.ts +2 -0
- package/dist-types/athena/api-matcher.d.ts +14 -0
- package/dist-types/athena/athena.d.ts +6 -0
- package/dist-types/athena/column.d.ts +1 -0
- package/dist-types/athena/context.d.ts +21 -0
- package/dist-types/athena/index.d.ts +8 -0
- package/dist-types/athena/service-table.d.ts +8 -0
- package/dist-types/athena/types.d.ts +474 -0
- package/dist-types/athena/visitor.d.ts +63 -0
- package/dist-types/no-status-code-assert.d.ts +1 -1
- package/dist-types/openapi/deref-schema.d.ts +1 -0
- package/dist-types/openapi/generate-schema.d.ts +33 -0
- package/dist-types/openapi/service-schema-generator.d.ts +5 -0
- package/dist-types/peggy/athena-peggy.d.ts +13 -0
- package/package.json +1 -96
- package/src/athena/ATHENA.md +387 -0
- package/src/athena/PLAN.md +355 -0
- package/src/athena/api-locator.ts +39 -0
- package/src/athena/api-matcher.ts +169 -0
- package/src/athena/athena.ts +491 -0
- package/src/athena/column.ts +2 -0
- package/src/athena/context.ts +47 -0
- package/src/athena/index.ts +11 -0
- package/src/athena/service-table.ts +55 -0
- package/src/athena/types.ts +526 -0
- package/src/athena/visitor.ts +365 -0
- package/src/index.ts +4 -0
- package/src/no-side-effects.ts +1 -1
- package/src/no-status-code-assert.ts +2 -2
- package/src/openapi/deref-schema.ts +14 -0
- package/src/openapi/generate-schema.ts +422 -0
- package/src/openapi/service-schema-generator.ts +189 -0
- package/src/peggy/athena-chat.peggy +608 -0
- package/src/peggy/athena-peggy.ts +22078 -0
- package/src/peggy/athena.peggy +2967 -0
- package/src/require-service-call-response-declaration.ts +2 -2
- package/src/services/interchange/v1/swagger.schema.deref.json +849 -0
- package/src/services/interchange/v1/swagger.schema.json +473 -0
- package/src/services/interchange/v1/swagger.yml +414 -0
- package/src/services/ledger/v1/swagger.schema.deref.json +6694 -0
- package/src/services/ledger/v1/swagger.schema.json +1820 -0
- package/src/services/ledger/v1/swagger.yml +1094 -0
- package/src/services/link/v1/swagger.schema.deref.json +648 -0
- package/src/services/link/v1/swagger.schema.json +444 -0
- package/src/services/link/v1/swagger.yml +343 -0
- package/src/services/message/v1/swagger.schema.deref.json +22049 -0
- package/src/services/message/v1/swagger.schema.json +3470 -0
- package/src/services/message/v1/swagger.yml +2798 -0
- package/src/services/message/v2/swagger.schema.deref.json +72221 -0
- package/src/services/message/v2/swagger.schema.json +3558 -0
- package/src/services/message/v2/swagger.yml +3009 -0
- package/src/services/paymentCard/v1/swagger.schema.deref.json +4346 -0
- package/src/services/paymentCard/v1/swagger.schema.json +2181 -0
- package/src/services/paymentCard/v1/swagger.yml +1161 -0
- package/src/services/paymentCard/v2/swagger.schema.deref.json +4336 -0
- package/src/services/paymentCard/v2/swagger.schema.json +2155 -0
- package/src/services/paymentCard/v2/swagger.yml +1149 -0
- package/src/services/person/v1/swagger.schema.deref.json +6786 -0
- package/src/services/person/v1/swagger.schema.json +1445 -0
- package/src/services/person/v1/swagger.yml +1157 -0
- package/src/services/teampayApproval/v1/swagger.schema.deref.json +9898 -0
- package/src/services/teampayCardManagement/v1/swagger.schema.deref.json +6187 -0
- package/src/services/teampayClientManagement/v1/swagger.schema.deref.json +4914 -0
- package/src/services/teampayClientManagement/v1/swagger.schema.json +1964 -0
- package/src/services/teampayClientManagement/v1/swagger.yml +1376 -0
|
@@ -0,0 +1,4346 @@
|
|
|
1
|
+
{
|
|
2
|
+
"apis": {
|
|
3
|
+
"/payment-card/v1/ping": {
|
|
4
|
+
"get": {
|
|
5
|
+
"request": {
|
|
6
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
7
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/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-plugin.checkdigit/payment-card/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-plugin.checkdigit/payment-card/v1/schemas/definitions/Ping",
|
|
31
|
+
"type": "object",
|
|
32
|
+
"additionalProperties": false,
|
|
33
|
+
"required": ["serverTime"],
|
|
34
|
+
"properties": {
|
|
35
|
+
"serverTime": {
|
|
36
|
+
"type": "string",
|
|
37
|
+
"format": "date-time",
|
|
38
|
+
"description": "Current server time",
|
|
39
|
+
"example": "1970-01-01T00:00:00.000Z"
|
|
40
|
+
}
|
|
41
|
+
}
|
|
42
|
+
}
|
|
43
|
+
},
|
|
44
|
+
"required": ["body"],
|
|
45
|
+
"additionalProperties": false
|
|
46
|
+
},
|
|
47
|
+
"default": {
|
|
48
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
49
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/api/PingGetResponseDefault",
|
|
50
|
+
"type": "object",
|
|
51
|
+
"properties": {
|
|
52
|
+
"headers": {
|
|
53
|
+
"type": "object",
|
|
54
|
+
"additionalProperties": true
|
|
55
|
+
},
|
|
56
|
+
"body": {
|
|
57
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
58
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/Error",
|
|
59
|
+
"type": "object",
|
|
60
|
+
"additionalProperties": false,
|
|
61
|
+
"description": "Server error message",
|
|
62
|
+
"properties": {
|
|
63
|
+
"message": {
|
|
64
|
+
"type": "string"
|
|
65
|
+
},
|
|
66
|
+
"code": {
|
|
67
|
+
"type": "string"
|
|
68
|
+
}
|
|
69
|
+
}
|
|
70
|
+
}
|
|
71
|
+
},
|
|
72
|
+
"required": ["body"],
|
|
73
|
+
"additionalProperties": false
|
|
74
|
+
}
|
|
75
|
+
}
|
|
76
|
+
}
|
|
77
|
+
},
|
|
78
|
+
"/payment-card/v1/public-key": {
|
|
79
|
+
"get": {
|
|
80
|
+
"request": {
|
|
81
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
82
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/api/PublicKeyGetRequestContext",
|
|
83
|
+
"type": "object",
|
|
84
|
+
"properties": {
|
|
85
|
+
"headers": {
|
|
86
|
+
"type": "object",
|
|
87
|
+
"additionalProperties": true
|
|
88
|
+
}
|
|
89
|
+
},
|
|
90
|
+
"required": [],
|
|
91
|
+
"additionalProperties": false
|
|
92
|
+
},
|
|
93
|
+
"responses": {
|
|
94
|
+
"200": {
|
|
95
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
96
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/api/PublicKeyGetResponseOK",
|
|
97
|
+
"type": "object",
|
|
98
|
+
"properties": {
|
|
99
|
+
"headers": {
|
|
100
|
+
"type": "object",
|
|
101
|
+
"properties": {
|
|
102
|
+
"created-on": {
|
|
103
|
+
"type": "string",
|
|
104
|
+
"format": "date-time"
|
|
105
|
+
},
|
|
106
|
+
"updated-on": {
|
|
107
|
+
"type": "string",
|
|
108
|
+
"format": "date-time"
|
|
109
|
+
}
|
|
110
|
+
}
|
|
111
|
+
},
|
|
112
|
+
"body": {
|
|
113
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
114
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/PublicKeyResponse",
|
|
115
|
+
"description": "This object contains the rsa generated public key for the Payment Card Service. This public key must be used\nwhen transmitting encrypted data to Payment Card Service APIs.\n",
|
|
116
|
+
"type": "object",
|
|
117
|
+
"required": ["publicKey"],
|
|
118
|
+
"properties": {
|
|
119
|
+
"publicKey": {
|
|
120
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
121
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/PublicKey",
|
|
122
|
+
"description": "Public key in PEM format",
|
|
123
|
+
"type": "string",
|
|
124
|
+
"example": "-----BEGIN PUBLIC KEY-----\nMIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAwm2sxmRdTF7ZIBA6+ngO\n8jOTCHmID0PpQB1q85+hrcLSfB1rWY9bzNNLabBo/ajDnA4Pcadq/x6gpg70qZcR\n9Wxm6TttKzBPZsxasGXgSTDqEi2KcYZgq1mL4qyxUvyIms7/llGy+W9b5huZaVcO\nxdT1tw/zctbOhb6S2t5vH+zkta/2ncUXjG7i8XdLsJ1qe4K1kYbA4KVkOMmAtw7O\n4STk0TZDD0YARdmrciorJjbIVt0Xj1CrYQ5QbDGrlfeXgrcZwX5f9wT2MnKlY5oZ\n5Wtb57oGtLkVf8g6vN/2jGtAmOmHK2hHwNd/+zUet5G/S5uwEli4RgMPP4pUoKgd\nGQIDAQAB\n-----END PUBLIC KEY-----\n"
|
|
125
|
+
}
|
|
126
|
+
}
|
|
127
|
+
}
|
|
128
|
+
},
|
|
129
|
+
"required": ["body"],
|
|
130
|
+
"additionalProperties": false
|
|
131
|
+
},
|
|
132
|
+
"default": {
|
|
133
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
134
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/api/PublicKeyGetResponseDefault",
|
|
135
|
+
"type": "object",
|
|
136
|
+
"properties": {
|
|
137
|
+
"headers": {
|
|
138
|
+
"type": "object",
|
|
139
|
+
"additionalProperties": true
|
|
140
|
+
},
|
|
141
|
+
"body": {
|
|
142
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
143
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/Error",
|
|
144
|
+
"type": "object",
|
|
145
|
+
"additionalProperties": false,
|
|
146
|
+
"description": "Server error message",
|
|
147
|
+
"properties": {
|
|
148
|
+
"message": {
|
|
149
|
+
"type": "string"
|
|
150
|
+
},
|
|
151
|
+
"code": {
|
|
152
|
+
"type": "string"
|
|
153
|
+
}
|
|
154
|
+
}
|
|
155
|
+
}
|
|
156
|
+
},
|
|
157
|
+
"required": ["body"],
|
|
158
|
+
"additionalProperties": false
|
|
159
|
+
}
|
|
160
|
+
}
|
|
161
|
+
}
|
|
162
|
+
},
|
|
163
|
+
"/payment-card/v1/data-encryption-key/:dataEncryptionKeyId": {
|
|
164
|
+
"get": {
|
|
165
|
+
"request": {
|
|
166
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
167
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/api/DataEncryptionKeyGetRequestContext",
|
|
168
|
+
"type": "object",
|
|
169
|
+
"properties": {
|
|
170
|
+
"params": {
|
|
171
|
+
"type": "object",
|
|
172
|
+
"additionalProperties": false,
|
|
173
|
+
"properties": {
|
|
174
|
+
"dataEncryptionKeyId": {
|
|
175
|
+
"type": "string",
|
|
176
|
+
"format": "uuid"
|
|
177
|
+
}
|
|
178
|
+
},
|
|
179
|
+
"required": ["dataEncryptionKeyId"]
|
|
180
|
+
},
|
|
181
|
+
"headers": {
|
|
182
|
+
"type": "object",
|
|
183
|
+
"additionalProperties": true
|
|
184
|
+
}
|
|
185
|
+
},
|
|
186
|
+
"required": ["params"],
|
|
187
|
+
"additionalProperties": false
|
|
188
|
+
},
|
|
189
|
+
"responses": {
|
|
190
|
+
"200": {
|
|
191
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
192
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/api/DataEncryptionKeyGetResponseOK",
|
|
193
|
+
"type": "object",
|
|
194
|
+
"properties": {
|
|
195
|
+
"headers": {
|
|
196
|
+
"type": "object",
|
|
197
|
+
"properties": {
|
|
198
|
+
"created-on": {
|
|
199
|
+
"type": "string",
|
|
200
|
+
"format": "date-time"
|
|
201
|
+
},
|
|
202
|
+
"updated-on": {
|
|
203
|
+
"type": "string",
|
|
204
|
+
"format": "date-time"
|
|
205
|
+
}
|
|
206
|
+
}
|
|
207
|
+
},
|
|
208
|
+
"body": {
|
|
209
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
210
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/DataEncryptionKeyResponse",
|
|
211
|
+
"type": "object",
|
|
212
|
+
"required": ["transmissionKey", "encryptedDataEncryptionKeys", "createdOn", "lastModified"],
|
|
213
|
+
"properties": {
|
|
214
|
+
"createdOn": {
|
|
215
|
+
"description": "Time data was first stored",
|
|
216
|
+
"type": "string",
|
|
217
|
+
"format": "date-time"
|
|
218
|
+
},
|
|
219
|
+
"lastModified": {
|
|
220
|
+
"description": "Time data was last modified",
|
|
221
|
+
"type": "string",
|
|
222
|
+
"format": "date-time"
|
|
223
|
+
},
|
|
224
|
+
"encryptedDataEncryptionKeys": {
|
|
225
|
+
"type": "array",
|
|
226
|
+
"items": {
|
|
227
|
+
"type": "object",
|
|
228
|
+
"additionalProperties": false,
|
|
229
|
+
"description": "An object that includes an encrypted data encryption key and a hashed version of the public key used to encrypt it.\nThe publicKeyHash string is derived using @checkdigit/hash and the caller's public key included in DataEncryptionKeyRequest.\n",
|
|
230
|
+
"required": ["publicKeyHash", "encryptedDataEncryptionKey"],
|
|
231
|
+
"properties": {
|
|
232
|
+
"publicKeyHash": {
|
|
233
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
234
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/Hash",
|
|
235
|
+
"type": "string",
|
|
236
|
+
"format": "uuid",
|
|
237
|
+
"example": "15a85f64-5717-4562-b3fc-2c963f66afa6",
|
|
238
|
+
"description": "UUID derived using @checkdigit/hash"
|
|
239
|
+
},
|
|
240
|
+
"encryptedDataEncryptionKey": {
|
|
241
|
+
"type": "string",
|
|
242
|
+
"description": "RSA encrypted data encryption key used to AES sensitive data in the Card object."
|
|
243
|
+
}
|
|
244
|
+
}
|
|
245
|
+
}
|
|
246
|
+
},
|
|
247
|
+
"transmissionKey": {
|
|
248
|
+
"type": "string",
|
|
249
|
+
"description": "A public key in PEM format.\nWhen creating a card with a specific card number (i.e. /card/{cardId}/number), use the transmissionKey to\nencrypt the data encryption key used to encrypt the card number.\n"
|
|
250
|
+
}
|
|
251
|
+
}
|
|
252
|
+
}
|
|
253
|
+
},
|
|
254
|
+
"required": ["body"],
|
|
255
|
+
"additionalProperties": false
|
|
256
|
+
},
|
|
257
|
+
"404": {
|
|
258
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
259
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/api/DataEncryptionKeyGetResponseNotFound",
|
|
260
|
+
"type": "object",
|
|
261
|
+
"properties": {
|
|
262
|
+
"headers": {
|
|
263
|
+
"type": "object",
|
|
264
|
+
"additionalProperties": true
|
|
265
|
+
}
|
|
266
|
+
},
|
|
267
|
+
"required": [],
|
|
268
|
+
"additionalProperties": false
|
|
269
|
+
},
|
|
270
|
+
"default": {
|
|
271
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
272
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/api/DataEncryptionKeyGetResponseDefault",
|
|
273
|
+
"type": "object",
|
|
274
|
+
"properties": {
|
|
275
|
+
"headers": {
|
|
276
|
+
"type": "object",
|
|
277
|
+
"additionalProperties": true
|
|
278
|
+
},
|
|
279
|
+
"body": {
|
|
280
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
281
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/Error",
|
|
282
|
+
"type": "object",
|
|
283
|
+
"additionalProperties": false,
|
|
284
|
+
"description": "Server error message",
|
|
285
|
+
"properties": {
|
|
286
|
+
"message": {
|
|
287
|
+
"type": "string"
|
|
288
|
+
},
|
|
289
|
+
"code": {
|
|
290
|
+
"type": "string"
|
|
291
|
+
}
|
|
292
|
+
}
|
|
293
|
+
}
|
|
294
|
+
},
|
|
295
|
+
"required": ["body"],
|
|
296
|
+
"additionalProperties": false
|
|
297
|
+
}
|
|
298
|
+
}
|
|
299
|
+
},
|
|
300
|
+
"put": {
|
|
301
|
+
"request": {
|
|
302
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
303
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/api/DataEncryptionKeyPutRequestContext",
|
|
304
|
+
"type": "object",
|
|
305
|
+
"properties": {
|
|
306
|
+
"params": {
|
|
307
|
+
"type": "object",
|
|
308
|
+
"additionalProperties": false,
|
|
309
|
+
"properties": {
|
|
310
|
+
"dataEncryptionKeyId": {
|
|
311
|
+
"type": "string",
|
|
312
|
+
"format": "uuid"
|
|
313
|
+
}
|
|
314
|
+
},
|
|
315
|
+
"required": ["dataEncryptionKeyId"]
|
|
316
|
+
},
|
|
317
|
+
"headers": {
|
|
318
|
+
"type": "object",
|
|
319
|
+
"additionalProperties": true
|
|
320
|
+
},
|
|
321
|
+
"body": {
|
|
322
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
323
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/DataEncryptionKeyRequest",
|
|
324
|
+
"type": "object",
|
|
325
|
+
"additionalProperties": false,
|
|
326
|
+
"required": ["publicKeys"],
|
|
327
|
+
"properties": {
|
|
328
|
+
"publicKeys": {
|
|
329
|
+
"type": "array",
|
|
330
|
+
"minItems": 1,
|
|
331
|
+
"description": "List of public keys in PEM format.\n\nAssociated private keys can be used to decrypt card data encrypted by Payment Card Service.\n",
|
|
332
|
+
"items": {
|
|
333
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
334
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/PublicKey",
|
|
335
|
+
"description": "Public key in PEM format",
|
|
336
|
+
"type": "string",
|
|
337
|
+
"example": "-----BEGIN PUBLIC KEY-----\nMIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAwm2sxmRdTF7ZIBA6+ngO\n8jOTCHmID0PpQB1q85+hrcLSfB1rWY9bzNNLabBo/ajDnA4Pcadq/x6gpg70qZcR\n9Wxm6TttKzBPZsxasGXgSTDqEi2KcYZgq1mL4qyxUvyIms7/llGy+W9b5huZaVcO\nxdT1tw/zctbOhb6S2t5vH+zkta/2ncUXjG7i8XdLsJ1qe4K1kYbA4KVkOMmAtw7O\n4STk0TZDD0YARdmrciorJjbIVt0Xj1CrYQ5QbDGrlfeXgrcZwX5f9wT2MnKlY5oZ\n5Wtb57oGtLkVf8g6vN/2jGtAmOmHK2hHwNd/+zUet5G/S5uwEli4RgMPP4pUoKgd\nGQIDAQAB\n-----END PUBLIC KEY-----\n"
|
|
338
|
+
}
|
|
339
|
+
}
|
|
340
|
+
}
|
|
341
|
+
}
|
|
342
|
+
},
|
|
343
|
+
"required": ["params", "body"],
|
|
344
|
+
"additionalProperties": false
|
|
345
|
+
},
|
|
346
|
+
"responses": {
|
|
347
|
+
"200": {
|
|
348
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
349
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/api/DataEncryptionKeyPutResponseOK",
|
|
350
|
+
"type": "object",
|
|
351
|
+
"properties": {
|
|
352
|
+
"headers": {
|
|
353
|
+
"type": "object",
|
|
354
|
+
"properties": {
|
|
355
|
+
"created-on": {
|
|
356
|
+
"type": "string",
|
|
357
|
+
"format": "date-time"
|
|
358
|
+
},
|
|
359
|
+
"updated-on": {
|
|
360
|
+
"type": "string",
|
|
361
|
+
"format": "date-time"
|
|
362
|
+
}
|
|
363
|
+
}
|
|
364
|
+
},
|
|
365
|
+
"body": {
|
|
366
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
367
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/DataEncryptionKeyResponse",
|
|
368
|
+
"type": "object",
|
|
369
|
+
"required": ["transmissionKey", "encryptedDataEncryptionKeys", "createdOn", "lastModified"],
|
|
370
|
+
"properties": {
|
|
371
|
+
"createdOn": {
|
|
372
|
+
"description": "Time data was first stored",
|
|
373
|
+
"type": "string",
|
|
374
|
+
"format": "date-time"
|
|
375
|
+
},
|
|
376
|
+
"lastModified": {
|
|
377
|
+
"description": "Time data was last modified",
|
|
378
|
+
"type": "string",
|
|
379
|
+
"format": "date-time"
|
|
380
|
+
},
|
|
381
|
+
"encryptedDataEncryptionKeys": {
|
|
382
|
+
"type": "array",
|
|
383
|
+
"items": {
|
|
384
|
+
"type": "object",
|
|
385
|
+
"additionalProperties": false,
|
|
386
|
+
"description": "An object that includes an encrypted data encryption key and a hashed version of the public key used to encrypt it.\nThe publicKeyHash string is derived using @checkdigit/hash and the caller's public key included in DataEncryptionKeyRequest.\n",
|
|
387
|
+
"required": ["publicKeyHash", "encryptedDataEncryptionKey"],
|
|
388
|
+
"properties": {
|
|
389
|
+
"publicKeyHash": {
|
|
390
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
391
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/Hash",
|
|
392
|
+
"type": "string",
|
|
393
|
+
"format": "uuid",
|
|
394
|
+
"example": "15a85f64-5717-4562-b3fc-2c963f66afa6",
|
|
395
|
+
"description": "UUID derived using @checkdigit/hash"
|
|
396
|
+
},
|
|
397
|
+
"encryptedDataEncryptionKey": {
|
|
398
|
+
"type": "string",
|
|
399
|
+
"description": "RSA encrypted data encryption key used to AES sensitive data in the Card object."
|
|
400
|
+
}
|
|
401
|
+
}
|
|
402
|
+
}
|
|
403
|
+
},
|
|
404
|
+
"transmissionKey": {
|
|
405
|
+
"type": "string",
|
|
406
|
+
"description": "A public key in PEM format.\nWhen creating a card with a specific card number (i.e. /card/{cardId}/number), use the transmissionKey to\nencrypt the data encryption key used to encrypt the card number.\n"
|
|
407
|
+
}
|
|
408
|
+
}
|
|
409
|
+
}
|
|
410
|
+
},
|
|
411
|
+
"required": ["body"],
|
|
412
|
+
"additionalProperties": false
|
|
413
|
+
},
|
|
414
|
+
"default": {
|
|
415
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
416
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/api/DataEncryptionKeyPutResponseDefault",
|
|
417
|
+
"type": "object",
|
|
418
|
+
"properties": {
|
|
419
|
+
"headers": {
|
|
420
|
+
"type": "object",
|
|
421
|
+
"additionalProperties": true
|
|
422
|
+
},
|
|
423
|
+
"body": {
|
|
424
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
425
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/Error",
|
|
426
|
+
"type": "object",
|
|
427
|
+
"additionalProperties": false,
|
|
428
|
+
"description": "Server error message",
|
|
429
|
+
"properties": {
|
|
430
|
+
"message": {
|
|
431
|
+
"type": "string"
|
|
432
|
+
},
|
|
433
|
+
"code": {
|
|
434
|
+
"type": "string"
|
|
435
|
+
}
|
|
436
|
+
}
|
|
437
|
+
}
|
|
438
|
+
},
|
|
439
|
+
"required": ["body"],
|
|
440
|
+
"additionalProperties": false
|
|
441
|
+
}
|
|
442
|
+
}
|
|
443
|
+
}
|
|
444
|
+
},
|
|
445
|
+
"/payment-card/v1/card": {
|
|
446
|
+
"get": {
|
|
447
|
+
"request": {
|
|
448
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
449
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/api/CardQueryRequestContext",
|
|
450
|
+
"type": "object",
|
|
451
|
+
"properties": {
|
|
452
|
+
"params": {
|
|
453
|
+
"type": "object",
|
|
454
|
+
"additionalProperties": false,
|
|
455
|
+
"properties": {
|
|
456
|
+
"cardNumberHash": {
|
|
457
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
458
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/Hash",
|
|
459
|
+
"type": "string",
|
|
460
|
+
"format": "uuid",
|
|
461
|
+
"example": "15a85f64-5717-4562-b3fc-2c963f66afa6",
|
|
462
|
+
"description": "UUID derived using @checkdigit/hash"
|
|
463
|
+
},
|
|
464
|
+
"at": {
|
|
465
|
+
"type": "string",
|
|
466
|
+
"format": "date-time"
|
|
467
|
+
}
|
|
468
|
+
},
|
|
469
|
+
"required": ["cardNumberHash", "at"]
|
|
470
|
+
},
|
|
471
|
+
"headers": {
|
|
472
|
+
"type": "object",
|
|
473
|
+
"additionalProperties": true
|
|
474
|
+
}
|
|
475
|
+
},
|
|
476
|
+
"required": ["query"],
|
|
477
|
+
"additionalProperties": false
|
|
478
|
+
},
|
|
479
|
+
"responses": {
|
|
480
|
+
"200": {
|
|
481
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
482
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/api/CardQueryResponseOK",
|
|
483
|
+
"type": "object",
|
|
484
|
+
"properties": {
|
|
485
|
+
"headers": {
|
|
486
|
+
"type": "object",
|
|
487
|
+
"additionalProperties": true
|
|
488
|
+
},
|
|
489
|
+
"body": {
|
|
490
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
491
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/Query",
|
|
492
|
+
"description": "Response from querying /card by cardNumberHash",
|
|
493
|
+
"type": "object",
|
|
494
|
+
"required": ["cards"],
|
|
495
|
+
"properties": {
|
|
496
|
+
"cards": {
|
|
497
|
+
"type": "array",
|
|
498
|
+
"items": {
|
|
499
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
500
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/CardQueryResponse",
|
|
501
|
+
"type": "object",
|
|
502
|
+
"additionalProperties": false,
|
|
503
|
+
"required": ["dataEncryptionKeyId", "storageKeyId", "cardId", "card"],
|
|
504
|
+
"properties": {
|
|
505
|
+
"dataEncryptionKeyId": {
|
|
506
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
507
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/DataEncryptionKeyId",
|
|
508
|
+
"type": "string",
|
|
509
|
+
"description": "Reference to encryption keys Payment Card Service will use to encrypt the Card object.\n",
|
|
510
|
+
"format": "uuid"
|
|
511
|
+
},
|
|
512
|
+
"storageKeyId": {
|
|
513
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
514
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/StorageKeyId",
|
|
515
|
+
"type": "string",
|
|
516
|
+
"description": "DEK's non-derived identifier to be used by Check Digit services only.\n"
|
|
517
|
+
},
|
|
518
|
+
"encryptedDataEncryptionKey": {
|
|
519
|
+
"description": "Encrypted DEK matching the publicKeyHash sent in the request. Used to decrypt values in the Card object.\n",
|
|
520
|
+
"type": "string"
|
|
521
|
+
},
|
|
522
|
+
"cardId": {
|
|
523
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
524
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/CardId",
|
|
525
|
+
"type": "string",
|
|
526
|
+
"description": "Card identifier",
|
|
527
|
+
"format": "uuid"
|
|
528
|
+
},
|
|
529
|
+
"card": {
|
|
530
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
531
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/Card",
|
|
532
|
+
"type": "object",
|
|
533
|
+
"additionalProperties": false,
|
|
534
|
+
"required": [
|
|
535
|
+
"bin",
|
|
536
|
+
"last4",
|
|
537
|
+
"expirationDate",
|
|
538
|
+
"cardNumber",
|
|
539
|
+
"serviceCode",
|
|
540
|
+
"pinOffset",
|
|
541
|
+
"applicationTransactionCounter",
|
|
542
|
+
"sequenceNumber",
|
|
543
|
+
"state",
|
|
544
|
+
"active",
|
|
545
|
+
"block",
|
|
546
|
+
"lock",
|
|
547
|
+
"capture",
|
|
548
|
+
"createdOn",
|
|
549
|
+
"updatedOn",
|
|
550
|
+
"lastModified"
|
|
551
|
+
],
|
|
552
|
+
"properties": {
|
|
553
|
+
"bin": {
|
|
554
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
555
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/Bin",
|
|
556
|
+
"type": "string",
|
|
557
|
+
"pattern": "^\\d+$",
|
|
558
|
+
"description": "Bank Identification Number",
|
|
559
|
+
"minLength": 6,
|
|
560
|
+
"maxLength": 8
|
|
561
|
+
},
|
|
562
|
+
"last4": {
|
|
563
|
+
"type": "string",
|
|
564
|
+
"pattern": "^\\d+$",
|
|
565
|
+
"description": "Last four digits of the card number",
|
|
566
|
+
"minLength": 4,
|
|
567
|
+
"maxLength": 4
|
|
568
|
+
},
|
|
569
|
+
"expirationDate": {
|
|
570
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
571
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/ExpirationDate",
|
|
572
|
+
"type": "string",
|
|
573
|
+
"pattern": "([0-9][0-9])(0[1-9]|1[0-2])",
|
|
574
|
+
"format": "YYMM",
|
|
575
|
+
"description": "Expiration date for the card and will be assumed to be the last millisecond of the month",
|
|
576
|
+
"minLength": 4,
|
|
577
|
+
"maxLength": 4
|
|
578
|
+
},
|
|
579
|
+
"cardNumber": {
|
|
580
|
+
"type": "string",
|
|
581
|
+
"description": "Encrypted card number (PAN)"
|
|
582
|
+
},
|
|
583
|
+
"serviceCode": {
|
|
584
|
+
"type": "string",
|
|
585
|
+
"pattern": "^\\d+$",
|
|
586
|
+
"description": "Service code for the card",
|
|
587
|
+
"minLength": 3,
|
|
588
|
+
"maxLength": 3
|
|
589
|
+
},
|
|
590
|
+
"pinOffset": {
|
|
591
|
+
"type": "string",
|
|
592
|
+
"description": "Encrypted pin offset for the card"
|
|
593
|
+
},
|
|
594
|
+
"applicationTransactionCounter": {
|
|
595
|
+
"type": "integer",
|
|
596
|
+
"description": "Application transaction counter (ATC) for the card"
|
|
597
|
+
},
|
|
598
|
+
"sequenceNumber": {
|
|
599
|
+
"type": "integer",
|
|
600
|
+
"description": "Used to differentiate issuing the same card and expiration date on multiple plastics"
|
|
601
|
+
},
|
|
602
|
+
"state": {
|
|
603
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
604
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/StateStatus",
|
|
605
|
+
"description": "The current state of the card",
|
|
606
|
+
"type": "string",
|
|
607
|
+
"enum": ["CURRENT", "REISSUED", "RETIRED", "FORCED"]
|
|
608
|
+
},
|
|
609
|
+
"active": {
|
|
610
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
611
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/ActiveStatus",
|
|
612
|
+
"description": "The active/inactive status for the card",
|
|
613
|
+
"type": "string",
|
|
614
|
+
"enum": ["INACTIVE", "ACTIVE"]
|
|
615
|
+
},
|
|
616
|
+
"block": {
|
|
617
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
618
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/BlockStatus",
|
|
619
|
+
"type": "string",
|
|
620
|
+
"description": "Whether the card is open or blocked for various reasons",
|
|
621
|
+
"enum": ["OPEN", "BLOCKED LOST OR STOLEN", "BLOCKED NO FRAUD", "BLOCKED WITH FRAUD"]
|
|
622
|
+
},
|
|
623
|
+
"lock": {
|
|
624
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
625
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/LockStatus",
|
|
626
|
+
"type": "string",
|
|
627
|
+
"description": "A cardholder initiated status. A locked card will fail authorization. Locked cards can be unlocked.\n\nA cardholder may choose to lock a card while temporarily misplaced.\n",
|
|
628
|
+
"enum": ["LOCKED", "UNLOCKED"]
|
|
629
|
+
},
|
|
630
|
+
"capture": {
|
|
631
|
+
"type": "boolean",
|
|
632
|
+
"description": "Whether the card should be captured at next use"
|
|
633
|
+
},
|
|
634
|
+
"updatedOn": {
|
|
635
|
+
"type": "string",
|
|
636
|
+
"description": "Time data was last updated",
|
|
637
|
+
"format": "date-time"
|
|
638
|
+
},
|
|
639
|
+
"lastModified": {
|
|
640
|
+
"type": "string",
|
|
641
|
+
"description": "Time data was last modified (Deprecated. Use updatedOn)",
|
|
642
|
+
"format": "date-time"
|
|
643
|
+
},
|
|
644
|
+
"createdOn": {
|
|
645
|
+
"description": "Time encrypted data was first stored",
|
|
646
|
+
"type": "string",
|
|
647
|
+
"format": "date-time"
|
|
648
|
+
}
|
|
649
|
+
}
|
|
650
|
+
}
|
|
651
|
+
}
|
|
652
|
+
}
|
|
653
|
+
}
|
|
654
|
+
}
|
|
655
|
+
}
|
|
656
|
+
},
|
|
657
|
+
"required": ["body"],
|
|
658
|
+
"additionalProperties": false
|
|
659
|
+
},
|
|
660
|
+
"default": {
|
|
661
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
662
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/api/CardQueryResponseDefault",
|
|
663
|
+
"type": "object",
|
|
664
|
+
"properties": {
|
|
665
|
+
"headers": {
|
|
666
|
+
"type": "object",
|
|
667
|
+
"additionalProperties": true
|
|
668
|
+
},
|
|
669
|
+
"body": {
|
|
670
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
671
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/Error",
|
|
672
|
+
"type": "object",
|
|
673
|
+
"additionalProperties": false,
|
|
674
|
+
"description": "Server error message",
|
|
675
|
+
"properties": {
|
|
676
|
+
"message": {
|
|
677
|
+
"type": "string"
|
|
678
|
+
},
|
|
679
|
+
"code": {
|
|
680
|
+
"type": "string"
|
|
681
|
+
}
|
|
682
|
+
}
|
|
683
|
+
}
|
|
684
|
+
},
|
|
685
|
+
"required": ["body"],
|
|
686
|
+
"additionalProperties": false
|
|
687
|
+
}
|
|
688
|
+
}
|
|
689
|
+
}
|
|
690
|
+
},
|
|
691
|
+
"/payment-card/v1/card/:cardId": {
|
|
692
|
+
"get": {
|
|
693
|
+
"request": {
|
|
694
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
695
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/api/CardGetRequestContext",
|
|
696
|
+
"type": "object",
|
|
697
|
+
"properties": {
|
|
698
|
+
"params": {
|
|
699
|
+
"type": "object",
|
|
700
|
+
"additionalProperties": false,
|
|
701
|
+
"properties": {
|
|
702
|
+
"at": {
|
|
703
|
+
"type": "string",
|
|
704
|
+
"format": "date-time"
|
|
705
|
+
},
|
|
706
|
+
"publicKeyHashQuery": {
|
|
707
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
708
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/Hash",
|
|
709
|
+
"type": "string",
|
|
710
|
+
"format": "uuid",
|
|
711
|
+
"example": "15a85f64-5717-4562-b3fc-2c963f66afa6",
|
|
712
|
+
"description": "UUID derived using @checkdigit/hash"
|
|
713
|
+
}
|
|
714
|
+
},
|
|
715
|
+
"required": ["at"]
|
|
716
|
+
},
|
|
717
|
+
"headers": {
|
|
718
|
+
"type": "object",
|
|
719
|
+
"additionalProperties": true
|
|
720
|
+
}
|
|
721
|
+
},
|
|
722
|
+
"required": ["params", "query"],
|
|
723
|
+
"additionalProperties": false
|
|
724
|
+
},
|
|
725
|
+
"responses": {
|
|
726
|
+
"200": {
|
|
727
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
728
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/api/CardGetResponseOK",
|
|
729
|
+
"type": "object",
|
|
730
|
+
"properties": {
|
|
731
|
+
"headers": {
|
|
732
|
+
"type": "object",
|
|
733
|
+
"properties": {
|
|
734
|
+
"last-modified": {
|
|
735
|
+
"type": "string",
|
|
736
|
+
"format": "date-time"
|
|
737
|
+
},
|
|
738
|
+
"created-on": {
|
|
739
|
+
"type": "string",
|
|
740
|
+
"format": "date-time"
|
|
741
|
+
},
|
|
742
|
+
"updated-on": {
|
|
743
|
+
"type": "string",
|
|
744
|
+
"format": "date-time"
|
|
745
|
+
},
|
|
746
|
+
"etag": {
|
|
747
|
+
"type": "string"
|
|
748
|
+
}
|
|
749
|
+
}
|
|
750
|
+
},
|
|
751
|
+
"body": {
|
|
752
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
753
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/CardResponse",
|
|
754
|
+
"type": "object",
|
|
755
|
+
"additionalProperties": false,
|
|
756
|
+
"required": ["dataEncryptionKeyId", "storageKeyId", "card"],
|
|
757
|
+
"properties": {
|
|
758
|
+
"dataEncryptionKeyId": {
|
|
759
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
760
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/DataEncryptionKeyId",
|
|
761
|
+
"type": "string",
|
|
762
|
+
"description": "Reference to encryption keys Payment Card Service will use to encrypt the Card object.\n",
|
|
763
|
+
"format": "uuid"
|
|
764
|
+
},
|
|
765
|
+
"storageKeyId": {
|
|
766
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
767
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/StorageKeyId",
|
|
768
|
+
"type": "string",
|
|
769
|
+
"description": "DEK's non-derived identifier to be used by Check Digit services only.\n"
|
|
770
|
+
},
|
|
771
|
+
"encryptedDataEncryptionKey": {
|
|
772
|
+
"description": "Encrypted DEK matching the publicKeyHash sent in the request. Used to decrypt values in the Card object.\n",
|
|
773
|
+
"type": "string"
|
|
774
|
+
},
|
|
775
|
+
"card": {
|
|
776
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
777
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/Card",
|
|
778
|
+
"type": "object",
|
|
779
|
+
"additionalProperties": false,
|
|
780
|
+
"required": [
|
|
781
|
+
"bin",
|
|
782
|
+
"last4",
|
|
783
|
+
"expirationDate",
|
|
784
|
+
"cardNumber",
|
|
785
|
+
"serviceCode",
|
|
786
|
+
"pinOffset",
|
|
787
|
+
"applicationTransactionCounter",
|
|
788
|
+
"sequenceNumber",
|
|
789
|
+
"state",
|
|
790
|
+
"active",
|
|
791
|
+
"block",
|
|
792
|
+
"lock",
|
|
793
|
+
"capture",
|
|
794
|
+
"createdOn",
|
|
795
|
+
"updatedOn",
|
|
796
|
+
"lastModified"
|
|
797
|
+
],
|
|
798
|
+
"properties": {
|
|
799
|
+
"bin": {
|
|
800
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
801
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/Bin",
|
|
802
|
+
"type": "string",
|
|
803
|
+
"pattern": "^\\d+$",
|
|
804
|
+
"description": "Bank Identification Number",
|
|
805
|
+
"minLength": 6,
|
|
806
|
+
"maxLength": 8
|
|
807
|
+
},
|
|
808
|
+
"last4": {
|
|
809
|
+
"type": "string",
|
|
810
|
+
"pattern": "^\\d+$",
|
|
811
|
+
"description": "Last four digits of the card number",
|
|
812
|
+
"minLength": 4,
|
|
813
|
+
"maxLength": 4
|
|
814
|
+
},
|
|
815
|
+
"expirationDate": {
|
|
816
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
817
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/ExpirationDate",
|
|
818
|
+
"type": "string",
|
|
819
|
+
"pattern": "([0-9][0-9])(0[1-9]|1[0-2])",
|
|
820
|
+
"format": "YYMM",
|
|
821
|
+
"description": "Expiration date for the card and will be assumed to be the last millisecond of the month",
|
|
822
|
+
"minLength": 4,
|
|
823
|
+
"maxLength": 4
|
|
824
|
+
},
|
|
825
|
+
"cardNumber": {
|
|
826
|
+
"type": "string",
|
|
827
|
+
"description": "Encrypted card number (PAN)"
|
|
828
|
+
},
|
|
829
|
+
"serviceCode": {
|
|
830
|
+
"type": "string",
|
|
831
|
+
"pattern": "^\\d+$",
|
|
832
|
+
"description": "Service code for the card",
|
|
833
|
+
"minLength": 3,
|
|
834
|
+
"maxLength": 3
|
|
835
|
+
},
|
|
836
|
+
"pinOffset": {
|
|
837
|
+
"type": "string",
|
|
838
|
+
"description": "Encrypted pin offset for the card"
|
|
839
|
+
},
|
|
840
|
+
"applicationTransactionCounter": {
|
|
841
|
+
"type": "integer",
|
|
842
|
+
"description": "Application transaction counter (ATC) for the card"
|
|
843
|
+
},
|
|
844
|
+
"sequenceNumber": {
|
|
845
|
+
"type": "integer",
|
|
846
|
+
"description": "Used to differentiate issuing the same card and expiration date on multiple plastics"
|
|
847
|
+
},
|
|
848
|
+
"state": {
|
|
849
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
850
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/StateStatus",
|
|
851
|
+
"description": "The current state of the card",
|
|
852
|
+
"type": "string",
|
|
853
|
+
"enum": ["CURRENT", "REISSUED", "RETIRED", "FORCED"]
|
|
854
|
+
},
|
|
855
|
+
"active": {
|
|
856
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
857
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/ActiveStatus",
|
|
858
|
+
"description": "The active/inactive status for the card",
|
|
859
|
+
"type": "string",
|
|
860
|
+
"enum": ["INACTIVE", "ACTIVE"]
|
|
861
|
+
},
|
|
862
|
+
"block": {
|
|
863
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
864
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/BlockStatus",
|
|
865
|
+
"type": "string",
|
|
866
|
+
"description": "Whether the card is open or blocked for various reasons",
|
|
867
|
+
"enum": ["OPEN", "BLOCKED LOST OR STOLEN", "BLOCKED NO FRAUD", "BLOCKED WITH FRAUD"]
|
|
868
|
+
},
|
|
869
|
+
"lock": {
|
|
870
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
871
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/LockStatus",
|
|
872
|
+
"type": "string",
|
|
873
|
+
"description": "A cardholder initiated status. A locked card will fail authorization. Locked cards can be unlocked.\n\nA cardholder may choose to lock a card while temporarily misplaced.\n",
|
|
874
|
+
"enum": ["LOCKED", "UNLOCKED"]
|
|
875
|
+
},
|
|
876
|
+
"capture": {
|
|
877
|
+
"type": "boolean",
|
|
878
|
+
"description": "Whether the card should be captured at next use"
|
|
879
|
+
},
|
|
880
|
+
"updatedOn": {
|
|
881
|
+
"type": "string",
|
|
882
|
+
"description": "Time data was last updated",
|
|
883
|
+
"format": "date-time"
|
|
884
|
+
},
|
|
885
|
+
"lastModified": {
|
|
886
|
+
"type": "string",
|
|
887
|
+
"description": "Time data was last modified (Deprecated. Use updatedOn)",
|
|
888
|
+
"format": "date-time"
|
|
889
|
+
},
|
|
890
|
+
"createdOn": {
|
|
891
|
+
"description": "Time encrypted data was first stored",
|
|
892
|
+
"type": "string",
|
|
893
|
+
"format": "date-time"
|
|
894
|
+
}
|
|
895
|
+
}
|
|
896
|
+
}
|
|
897
|
+
}
|
|
898
|
+
}
|
|
899
|
+
},
|
|
900
|
+
"required": ["body"],
|
|
901
|
+
"additionalProperties": false
|
|
902
|
+
},
|
|
903
|
+
"404": {
|
|
904
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
905
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/api/CardGetResponseNotFound",
|
|
906
|
+
"type": "object",
|
|
907
|
+
"properties": {
|
|
908
|
+
"headers": {
|
|
909
|
+
"type": "object",
|
|
910
|
+
"additionalProperties": true
|
|
911
|
+
}
|
|
912
|
+
},
|
|
913
|
+
"required": [],
|
|
914
|
+
"additionalProperties": false
|
|
915
|
+
},
|
|
916
|
+
"default": {
|
|
917
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
918
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/api/CardGetResponseDefault",
|
|
919
|
+
"type": "object",
|
|
920
|
+
"properties": {
|
|
921
|
+
"headers": {
|
|
922
|
+
"type": "object",
|
|
923
|
+
"additionalProperties": true
|
|
924
|
+
},
|
|
925
|
+
"body": {
|
|
926
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
927
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/Error",
|
|
928
|
+
"type": "object",
|
|
929
|
+
"additionalProperties": false,
|
|
930
|
+
"description": "Server error message",
|
|
931
|
+
"properties": {
|
|
932
|
+
"message": {
|
|
933
|
+
"type": "string"
|
|
934
|
+
},
|
|
935
|
+
"code": {
|
|
936
|
+
"type": "string"
|
|
937
|
+
}
|
|
938
|
+
}
|
|
939
|
+
}
|
|
940
|
+
},
|
|
941
|
+
"required": ["body"],
|
|
942
|
+
"additionalProperties": false
|
|
943
|
+
}
|
|
944
|
+
}
|
|
945
|
+
},
|
|
946
|
+
"put": {
|
|
947
|
+
"request": {
|
|
948
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
949
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/api/CardPutRequestContext",
|
|
950
|
+
"type": "object",
|
|
951
|
+
"properties": {
|
|
952
|
+
"params": {
|
|
953
|
+
"type": "object",
|
|
954
|
+
"additionalProperties": false,
|
|
955
|
+
"properties": {
|
|
956
|
+
"cardId": {
|
|
957
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
958
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/CardId",
|
|
959
|
+
"type": "string",
|
|
960
|
+
"description": "Card identifier",
|
|
961
|
+
"format": "uuid"
|
|
962
|
+
}
|
|
963
|
+
},
|
|
964
|
+
"required": ["cardId"]
|
|
965
|
+
},
|
|
966
|
+
"headers": {
|
|
967
|
+
"type": "object",
|
|
968
|
+
"additionalProperties": true,
|
|
969
|
+
"properties": {
|
|
970
|
+
"created-on": {
|
|
971
|
+
"type": "string",
|
|
972
|
+
"format": "date-time"
|
|
973
|
+
},
|
|
974
|
+
"last-modified": {
|
|
975
|
+
"type": "string",
|
|
976
|
+
"format": "date-time"
|
|
977
|
+
}
|
|
978
|
+
}
|
|
979
|
+
},
|
|
980
|
+
"body": {
|
|
981
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
982
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/NewCardRequest",
|
|
983
|
+
"type": "object",
|
|
984
|
+
"required": ["dataEncryptionKeyId", "cardNumberLength", "newCard"],
|
|
985
|
+
"additionalProperties": false,
|
|
986
|
+
"properties": {
|
|
987
|
+
"dataEncryptionKeyId": {
|
|
988
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
989
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/DataEncryptionKeyId",
|
|
990
|
+
"type": "string",
|
|
991
|
+
"description": "Reference to encryption keys Payment Card Service will use to encrypt the Card object.\n",
|
|
992
|
+
"format": "uuid"
|
|
993
|
+
},
|
|
994
|
+
"cardNumberLength": {
|
|
995
|
+
"type": "integer",
|
|
996
|
+
"description": "Desired number of digits in the card number.",
|
|
997
|
+
"minimum": 15,
|
|
998
|
+
"maximum": 19
|
|
999
|
+
},
|
|
1000
|
+
"newCard": {
|
|
1001
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
1002
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/NewCard",
|
|
1003
|
+
"type": "object",
|
|
1004
|
+
"additionalProperties": false,
|
|
1005
|
+
"required": [
|
|
1006
|
+
"bin",
|
|
1007
|
+
"expirationDate",
|
|
1008
|
+
"serviceCode",
|
|
1009
|
+
"sequenceNumber",
|
|
1010
|
+
"state",
|
|
1011
|
+
"active",
|
|
1012
|
+
"block",
|
|
1013
|
+
"lock"
|
|
1014
|
+
],
|
|
1015
|
+
"properties": {
|
|
1016
|
+
"bin": {
|
|
1017
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
1018
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/Bin",
|
|
1019
|
+
"type": "string",
|
|
1020
|
+
"pattern": "^\\d+$",
|
|
1021
|
+
"description": "Bank Identification Number",
|
|
1022
|
+
"minLength": 6,
|
|
1023
|
+
"maxLength": 8
|
|
1024
|
+
},
|
|
1025
|
+
"expirationDate": {
|
|
1026
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
1027
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/ExpirationDate",
|
|
1028
|
+
"type": "string",
|
|
1029
|
+
"pattern": "([0-9][0-9])(0[1-9]|1[0-2])",
|
|
1030
|
+
"format": "YYMM",
|
|
1031
|
+
"description": "Expiration date for the card and will be assumed to be the last millisecond of the month",
|
|
1032
|
+
"minLength": 4,
|
|
1033
|
+
"maxLength": 4
|
|
1034
|
+
},
|
|
1035
|
+
"serviceCode": {
|
|
1036
|
+
"type": "string",
|
|
1037
|
+
"pattern": "^\\d+$",
|
|
1038
|
+
"description": "Used to set general guidelines for how the card can be used, e.g. domestic only or international, online authorizations only, etc.\n",
|
|
1039
|
+
"minLength": 3,
|
|
1040
|
+
"maxLength": 3
|
|
1041
|
+
},
|
|
1042
|
+
"sequenceNumber": {
|
|
1043
|
+
"type": "integer",
|
|
1044
|
+
"description": "Used to differentiate issuing the same card and expiration date on multiple plastics.",
|
|
1045
|
+
"minimum": 0,
|
|
1046
|
+
"maximum": 10
|
|
1047
|
+
},
|
|
1048
|
+
"state": {
|
|
1049
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
1050
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/StateStatus",
|
|
1051
|
+
"description": "The current state of the card",
|
|
1052
|
+
"type": "string",
|
|
1053
|
+
"enum": ["CURRENT", "REISSUED", "RETIRED", "FORCED"]
|
|
1054
|
+
},
|
|
1055
|
+
"active": {
|
|
1056
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
1057
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/ActiveStatus",
|
|
1058
|
+
"description": "The active/inactive status for the card",
|
|
1059
|
+
"type": "string",
|
|
1060
|
+
"enum": ["INACTIVE", "ACTIVE"]
|
|
1061
|
+
},
|
|
1062
|
+
"block": {
|
|
1063
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
1064
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/BlockStatus",
|
|
1065
|
+
"type": "string",
|
|
1066
|
+
"description": "Whether the card is open or blocked for various reasons",
|
|
1067
|
+
"enum": ["OPEN", "BLOCKED LOST OR STOLEN", "BLOCKED NO FRAUD", "BLOCKED WITH FRAUD"]
|
|
1068
|
+
},
|
|
1069
|
+
"lock": {
|
|
1070
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
1071
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/LockStatus",
|
|
1072
|
+
"type": "string",
|
|
1073
|
+
"description": "A cardholder initiated status. A locked card will fail authorization. Locked cards can be unlocked.\n\nA cardholder may choose to lock a card while temporarily misplaced.\n",
|
|
1074
|
+
"enum": ["LOCKED", "UNLOCKED"]
|
|
1075
|
+
}
|
|
1076
|
+
}
|
|
1077
|
+
}
|
|
1078
|
+
}
|
|
1079
|
+
}
|
|
1080
|
+
},
|
|
1081
|
+
"required": ["params", "body"],
|
|
1082
|
+
"additionalProperties": false
|
|
1083
|
+
},
|
|
1084
|
+
"responses": {
|
|
1085
|
+
"200": {
|
|
1086
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
1087
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/api/CardPutResponseOK",
|
|
1088
|
+
"type": "object",
|
|
1089
|
+
"properties": {
|
|
1090
|
+
"headers": {
|
|
1091
|
+
"type": "object",
|
|
1092
|
+
"properties": {
|
|
1093
|
+
"last-modified": {
|
|
1094
|
+
"type": "string",
|
|
1095
|
+
"format": "date-time"
|
|
1096
|
+
},
|
|
1097
|
+
"created-on": {
|
|
1098
|
+
"type": "string",
|
|
1099
|
+
"format": "date-time"
|
|
1100
|
+
},
|
|
1101
|
+
"updated-on": {
|
|
1102
|
+
"type": "string",
|
|
1103
|
+
"format": "date-time"
|
|
1104
|
+
},
|
|
1105
|
+
"etag": {
|
|
1106
|
+
"type": "string"
|
|
1107
|
+
}
|
|
1108
|
+
}
|
|
1109
|
+
},
|
|
1110
|
+
"body": {
|
|
1111
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
1112
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/CardResponse",
|
|
1113
|
+
"type": "object",
|
|
1114
|
+
"additionalProperties": false,
|
|
1115
|
+
"required": ["dataEncryptionKeyId", "storageKeyId", "card"],
|
|
1116
|
+
"properties": {
|
|
1117
|
+
"dataEncryptionKeyId": {
|
|
1118
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
1119
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/DataEncryptionKeyId",
|
|
1120
|
+
"type": "string",
|
|
1121
|
+
"description": "Reference to encryption keys Payment Card Service will use to encrypt the Card object.\n",
|
|
1122
|
+
"format": "uuid"
|
|
1123
|
+
},
|
|
1124
|
+
"storageKeyId": {
|
|
1125
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
1126
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/StorageKeyId",
|
|
1127
|
+
"type": "string",
|
|
1128
|
+
"description": "DEK's non-derived identifier to be used by Check Digit services only.\n"
|
|
1129
|
+
},
|
|
1130
|
+
"encryptedDataEncryptionKey": {
|
|
1131
|
+
"description": "Encrypted DEK matching the publicKeyHash sent in the request. Used to decrypt values in the Card object.\n",
|
|
1132
|
+
"type": "string"
|
|
1133
|
+
},
|
|
1134
|
+
"card": {
|
|
1135
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
1136
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/Card",
|
|
1137
|
+
"type": "object",
|
|
1138
|
+
"additionalProperties": false,
|
|
1139
|
+
"required": [
|
|
1140
|
+
"bin",
|
|
1141
|
+
"last4",
|
|
1142
|
+
"expirationDate",
|
|
1143
|
+
"cardNumber",
|
|
1144
|
+
"serviceCode",
|
|
1145
|
+
"pinOffset",
|
|
1146
|
+
"applicationTransactionCounter",
|
|
1147
|
+
"sequenceNumber",
|
|
1148
|
+
"state",
|
|
1149
|
+
"active",
|
|
1150
|
+
"block",
|
|
1151
|
+
"lock",
|
|
1152
|
+
"capture",
|
|
1153
|
+
"createdOn",
|
|
1154
|
+
"updatedOn",
|
|
1155
|
+
"lastModified"
|
|
1156
|
+
],
|
|
1157
|
+
"properties": {
|
|
1158
|
+
"bin": {
|
|
1159
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
1160
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/Bin",
|
|
1161
|
+
"type": "string",
|
|
1162
|
+
"pattern": "^\\d+$",
|
|
1163
|
+
"description": "Bank Identification Number",
|
|
1164
|
+
"minLength": 6,
|
|
1165
|
+
"maxLength": 8
|
|
1166
|
+
},
|
|
1167
|
+
"last4": {
|
|
1168
|
+
"type": "string",
|
|
1169
|
+
"pattern": "^\\d+$",
|
|
1170
|
+
"description": "Last four digits of the card number",
|
|
1171
|
+
"minLength": 4,
|
|
1172
|
+
"maxLength": 4
|
|
1173
|
+
},
|
|
1174
|
+
"expirationDate": {
|
|
1175
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
1176
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/ExpirationDate",
|
|
1177
|
+
"type": "string",
|
|
1178
|
+
"pattern": "([0-9][0-9])(0[1-9]|1[0-2])",
|
|
1179
|
+
"format": "YYMM",
|
|
1180
|
+
"description": "Expiration date for the card and will be assumed to be the last millisecond of the month",
|
|
1181
|
+
"minLength": 4,
|
|
1182
|
+
"maxLength": 4
|
|
1183
|
+
},
|
|
1184
|
+
"cardNumber": {
|
|
1185
|
+
"type": "string",
|
|
1186
|
+
"description": "Encrypted card number (PAN)"
|
|
1187
|
+
},
|
|
1188
|
+
"serviceCode": {
|
|
1189
|
+
"type": "string",
|
|
1190
|
+
"pattern": "^\\d+$",
|
|
1191
|
+
"description": "Service code for the card",
|
|
1192
|
+
"minLength": 3,
|
|
1193
|
+
"maxLength": 3
|
|
1194
|
+
},
|
|
1195
|
+
"pinOffset": {
|
|
1196
|
+
"type": "string",
|
|
1197
|
+
"description": "Encrypted pin offset for the card"
|
|
1198
|
+
},
|
|
1199
|
+
"applicationTransactionCounter": {
|
|
1200
|
+
"type": "integer",
|
|
1201
|
+
"description": "Application transaction counter (ATC) for the card"
|
|
1202
|
+
},
|
|
1203
|
+
"sequenceNumber": {
|
|
1204
|
+
"type": "integer",
|
|
1205
|
+
"description": "Used to differentiate issuing the same card and expiration date on multiple plastics"
|
|
1206
|
+
},
|
|
1207
|
+
"state": {
|
|
1208
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
1209
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/StateStatus",
|
|
1210
|
+
"description": "The current state of the card",
|
|
1211
|
+
"type": "string",
|
|
1212
|
+
"enum": ["CURRENT", "REISSUED", "RETIRED", "FORCED"]
|
|
1213
|
+
},
|
|
1214
|
+
"active": {
|
|
1215
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
1216
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/ActiveStatus",
|
|
1217
|
+
"description": "The active/inactive status for the card",
|
|
1218
|
+
"type": "string",
|
|
1219
|
+
"enum": ["INACTIVE", "ACTIVE"]
|
|
1220
|
+
},
|
|
1221
|
+
"block": {
|
|
1222
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
1223
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/BlockStatus",
|
|
1224
|
+
"type": "string",
|
|
1225
|
+
"description": "Whether the card is open or blocked for various reasons",
|
|
1226
|
+
"enum": ["OPEN", "BLOCKED LOST OR STOLEN", "BLOCKED NO FRAUD", "BLOCKED WITH FRAUD"]
|
|
1227
|
+
},
|
|
1228
|
+
"lock": {
|
|
1229
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
1230
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/LockStatus",
|
|
1231
|
+
"type": "string",
|
|
1232
|
+
"description": "A cardholder initiated status. A locked card will fail authorization. Locked cards can be unlocked.\n\nA cardholder may choose to lock a card while temporarily misplaced.\n",
|
|
1233
|
+
"enum": ["LOCKED", "UNLOCKED"]
|
|
1234
|
+
},
|
|
1235
|
+
"capture": {
|
|
1236
|
+
"type": "boolean",
|
|
1237
|
+
"description": "Whether the card should be captured at next use"
|
|
1238
|
+
},
|
|
1239
|
+
"updatedOn": {
|
|
1240
|
+
"type": "string",
|
|
1241
|
+
"description": "Time data was last updated",
|
|
1242
|
+
"format": "date-time"
|
|
1243
|
+
},
|
|
1244
|
+
"lastModified": {
|
|
1245
|
+
"type": "string",
|
|
1246
|
+
"description": "Time data was last modified (Deprecated. Use updatedOn)",
|
|
1247
|
+
"format": "date-time"
|
|
1248
|
+
},
|
|
1249
|
+
"createdOn": {
|
|
1250
|
+
"description": "Time encrypted data was first stored",
|
|
1251
|
+
"type": "string",
|
|
1252
|
+
"format": "date-time"
|
|
1253
|
+
}
|
|
1254
|
+
}
|
|
1255
|
+
}
|
|
1256
|
+
}
|
|
1257
|
+
}
|
|
1258
|
+
},
|
|
1259
|
+
"required": ["body"],
|
|
1260
|
+
"additionalProperties": false
|
|
1261
|
+
},
|
|
1262
|
+
"409": {
|
|
1263
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
1264
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/api/CardPutResponseConflict",
|
|
1265
|
+
"type": "object",
|
|
1266
|
+
"properties": {
|
|
1267
|
+
"headers": {
|
|
1268
|
+
"type": "object",
|
|
1269
|
+
"additionalProperties": true
|
|
1270
|
+
}
|
|
1271
|
+
},
|
|
1272
|
+
"required": [],
|
|
1273
|
+
"additionalProperties": false
|
|
1274
|
+
},
|
|
1275
|
+
"412": {
|
|
1276
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
1277
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/api/CardPutResponsePreconditionFailed",
|
|
1278
|
+
"type": "object",
|
|
1279
|
+
"properties": {
|
|
1280
|
+
"headers": {
|
|
1281
|
+
"type": "object",
|
|
1282
|
+
"additionalProperties": true
|
|
1283
|
+
}
|
|
1284
|
+
},
|
|
1285
|
+
"required": [],
|
|
1286
|
+
"additionalProperties": false
|
|
1287
|
+
},
|
|
1288
|
+
"default": {
|
|
1289
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
1290
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/api/CardPutResponseDefault",
|
|
1291
|
+
"type": "object",
|
|
1292
|
+
"properties": {
|
|
1293
|
+
"headers": {
|
|
1294
|
+
"type": "object",
|
|
1295
|
+
"additionalProperties": true
|
|
1296
|
+
},
|
|
1297
|
+
"body": {
|
|
1298
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
1299
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/Error",
|
|
1300
|
+
"type": "object",
|
|
1301
|
+
"additionalProperties": false,
|
|
1302
|
+
"description": "Server error message",
|
|
1303
|
+
"properties": {
|
|
1304
|
+
"message": {
|
|
1305
|
+
"type": "string"
|
|
1306
|
+
},
|
|
1307
|
+
"code": {
|
|
1308
|
+
"type": "string"
|
|
1309
|
+
}
|
|
1310
|
+
}
|
|
1311
|
+
}
|
|
1312
|
+
},
|
|
1313
|
+
"required": ["body"],
|
|
1314
|
+
"additionalProperties": false
|
|
1315
|
+
}
|
|
1316
|
+
}
|
|
1317
|
+
}
|
|
1318
|
+
},
|
|
1319
|
+
"/payment-card/v1/card/:cardId/number": {
|
|
1320
|
+
"put": {
|
|
1321
|
+
"request": {
|
|
1322
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
1323
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/api/CardNumberPutRequestContext",
|
|
1324
|
+
"type": "object",
|
|
1325
|
+
"properties": {
|
|
1326
|
+
"params": {
|
|
1327
|
+
"type": "object",
|
|
1328
|
+
"additionalProperties": false,
|
|
1329
|
+
"properties": {
|
|
1330
|
+
"cardId": {
|
|
1331
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
1332
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/CardId",
|
|
1333
|
+
"type": "string",
|
|
1334
|
+
"description": "Card identifier",
|
|
1335
|
+
"format": "uuid"
|
|
1336
|
+
}
|
|
1337
|
+
},
|
|
1338
|
+
"required": ["cardId"]
|
|
1339
|
+
},
|
|
1340
|
+
"headers": {
|
|
1341
|
+
"type": "object",
|
|
1342
|
+
"additionalProperties": true,
|
|
1343
|
+
"properties": {
|
|
1344
|
+
"created-on": {
|
|
1345
|
+
"type": "string",
|
|
1346
|
+
"format": "date-time"
|
|
1347
|
+
},
|
|
1348
|
+
"last-modified": {
|
|
1349
|
+
"type": "string",
|
|
1350
|
+
"format": "date-time"
|
|
1351
|
+
}
|
|
1352
|
+
}
|
|
1353
|
+
},
|
|
1354
|
+
"body": {
|
|
1355
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
1356
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/NewCardRequestWithCardNumber",
|
|
1357
|
+
"type": "object",
|
|
1358
|
+
"required": ["encryptedCardNumber", "encryptedDataEncryptionKey", "dataEncryptionKeyId", "newCard"],
|
|
1359
|
+
"properties": {
|
|
1360
|
+
"encryptedCardNumber": {
|
|
1361
|
+
"type": "string"
|
|
1362
|
+
},
|
|
1363
|
+
"encryptedDataEncryptionKey": {
|
|
1364
|
+
"description": "RSA encrypted data encryption key used to AES encrypt encryptedCardNumber",
|
|
1365
|
+
"type": "string"
|
|
1366
|
+
},
|
|
1367
|
+
"dataEncryptionKeyId": {
|
|
1368
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
1369
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/DataEncryptionKeyId",
|
|
1370
|
+
"type": "string",
|
|
1371
|
+
"description": "Reference to encryption keys Payment Card Service will use to encrypt the Card object.\n",
|
|
1372
|
+
"format": "uuid"
|
|
1373
|
+
},
|
|
1374
|
+
"newCard": {
|
|
1375
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
1376
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/NewCard",
|
|
1377
|
+
"type": "object",
|
|
1378
|
+
"additionalProperties": false,
|
|
1379
|
+
"required": [
|
|
1380
|
+
"bin",
|
|
1381
|
+
"expirationDate",
|
|
1382
|
+
"serviceCode",
|
|
1383
|
+
"sequenceNumber",
|
|
1384
|
+
"state",
|
|
1385
|
+
"active",
|
|
1386
|
+
"block",
|
|
1387
|
+
"lock"
|
|
1388
|
+
],
|
|
1389
|
+
"properties": {
|
|
1390
|
+
"bin": {
|
|
1391
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
1392
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/Bin",
|
|
1393
|
+
"type": "string",
|
|
1394
|
+
"pattern": "^\\d+$",
|
|
1395
|
+
"description": "Bank Identification Number",
|
|
1396
|
+
"minLength": 6,
|
|
1397
|
+
"maxLength": 8
|
|
1398
|
+
},
|
|
1399
|
+
"expirationDate": {
|
|
1400
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
1401
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/ExpirationDate",
|
|
1402
|
+
"type": "string",
|
|
1403
|
+
"pattern": "([0-9][0-9])(0[1-9]|1[0-2])",
|
|
1404
|
+
"format": "YYMM",
|
|
1405
|
+
"description": "Expiration date for the card and will be assumed to be the last millisecond of the month",
|
|
1406
|
+
"minLength": 4,
|
|
1407
|
+
"maxLength": 4
|
|
1408
|
+
},
|
|
1409
|
+
"serviceCode": {
|
|
1410
|
+
"type": "string",
|
|
1411
|
+
"pattern": "^\\d+$",
|
|
1412
|
+
"description": "Used to set general guidelines for how the card can be used, e.g. domestic only or international, online authorizations only, etc.\n",
|
|
1413
|
+
"minLength": 3,
|
|
1414
|
+
"maxLength": 3
|
|
1415
|
+
},
|
|
1416
|
+
"sequenceNumber": {
|
|
1417
|
+
"type": "integer",
|
|
1418
|
+
"description": "Used to differentiate issuing the same card and expiration date on multiple plastics.",
|
|
1419
|
+
"minimum": 0,
|
|
1420
|
+
"maximum": 10
|
|
1421
|
+
},
|
|
1422
|
+
"state": {
|
|
1423
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
1424
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/StateStatus",
|
|
1425
|
+
"description": "The current state of the card",
|
|
1426
|
+
"type": "string",
|
|
1427
|
+
"enum": ["CURRENT", "REISSUED", "RETIRED", "FORCED"]
|
|
1428
|
+
},
|
|
1429
|
+
"active": {
|
|
1430
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
1431
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/ActiveStatus",
|
|
1432
|
+
"description": "The active/inactive status for the card",
|
|
1433
|
+
"type": "string",
|
|
1434
|
+
"enum": ["INACTIVE", "ACTIVE"]
|
|
1435
|
+
},
|
|
1436
|
+
"block": {
|
|
1437
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
1438
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/BlockStatus",
|
|
1439
|
+
"type": "string",
|
|
1440
|
+
"description": "Whether the card is open or blocked for various reasons",
|
|
1441
|
+
"enum": ["OPEN", "BLOCKED LOST OR STOLEN", "BLOCKED NO FRAUD", "BLOCKED WITH FRAUD"]
|
|
1442
|
+
},
|
|
1443
|
+
"lock": {
|
|
1444
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
1445
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/LockStatus",
|
|
1446
|
+
"type": "string",
|
|
1447
|
+
"description": "A cardholder initiated status. A locked card will fail authorization. Locked cards can be unlocked.\n\nA cardholder may choose to lock a card while temporarily misplaced.\n",
|
|
1448
|
+
"enum": ["LOCKED", "UNLOCKED"]
|
|
1449
|
+
}
|
|
1450
|
+
}
|
|
1451
|
+
}
|
|
1452
|
+
},
|
|
1453
|
+
"additionalProperties": false
|
|
1454
|
+
}
|
|
1455
|
+
},
|
|
1456
|
+
"required": ["params", "body"],
|
|
1457
|
+
"additionalProperties": false
|
|
1458
|
+
},
|
|
1459
|
+
"responses": {
|
|
1460
|
+
"200": {
|
|
1461
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
1462
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/api/CardNumberPutResponseOK",
|
|
1463
|
+
"type": "object",
|
|
1464
|
+
"properties": {
|
|
1465
|
+
"headers": {
|
|
1466
|
+
"type": "object",
|
|
1467
|
+
"properties": {
|
|
1468
|
+
"last-modified": {
|
|
1469
|
+
"type": "string",
|
|
1470
|
+
"format": "date-time"
|
|
1471
|
+
},
|
|
1472
|
+
"created-on": {
|
|
1473
|
+
"type": "string",
|
|
1474
|
+
"format": "date-time"
|
|
1475
|
+
},
|
|
1476
|
+
"updated-on": {
|
|
1477
|
+
"type": "string",
|
|
1478
|
+
"format": "date-time"
|
|
1479
|
+
},
|
|
1480
|
+
"etag": {
|
|
1481
|
+
"type": "string"
|
|
1482
|
+
}
|
|
1483
|
+
}
|
|
1484
|
+
},
|
|
1485
|
+
"body": {
|
|
1486
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
1487
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/CardResponse",
|
|
1488
|
+
"type": "object",
|
|
1489
|
+
"additionalProperties": false,
|
|
1490
|
+
"required": ["dataEncryptionKeyId", "storageKeyId", "card"],
|
|
1491
|
+
"properties": {
|
|
1492
|
+
"dataEncryptionKeyId": {
|
|
1493
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
1494
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/DataEncryptionKeyId",
|
|
1495
|
+
"type": "string",
|
|
1496
|
+
"description": "Reference to encryption keys Payment Card Service will use to encrypt the Card object.\n",
|
|
1497
|
+
"format": "uuid"
|
|
1498
|
+
},
|
|
1499
|
+
"storageKeyId": {
|
|
1500
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
1501
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/StorageKeyId",
|
|
1502
|
+
"type": "string",
|
|
1503
|
+
"description": "DEK's non-derived identifier to be used by Check Digit services only.\n"
|
|
1504
|
+
},
|
|
1505
|
+
"encryptedDataEncryptionKey": {
|
|
1506
|
+
"description": "Encrypted DEK matching the publicKeyHash sent in the request. Used to decrypt values in the Card object.\n",
|
|
1507
|
+
"type": "string"
|
|
1508
|
+
},
|
|
1509
|
+
"card": {
|
|
1510
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
1511
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/Card",
|
|
1512
|
+
"type": "object",
|
|
1513
|
+
"additionalProperties": false,
|
|
1514
|
+
"required": [
|
|
1515
|
+
"bin",
|
|
1516
|
+
"last4",
|
|
1517
|
+
"expirationDate",
|
|
1518
|
+
"cardNumber",
|
|
1519
|
+
"serviceCode",
|
|
1520
|
+
"pinOffset",
|
|
1521
|
+
"applicationTransactionCounter",
|
|
1522
|
+
"sequenceNumber",
|
|
1523
|
+
"state",
|
|
1524
|
+
"active",
|
|
1525
|
+
"block",
|
|
1526
|
+
"lock",
|
|
1527
|
+
"capture",
|
|
1528
|
+
"createdOn",
|
|
1529
|
+
"updatedOn",
|
|
1530
|
+
"lastModified"
|
|
1531
|
+
],
|
|
1532
|
+
"properties": {
|
|
1533
|
+
"bin": {
|
|
1534
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
1535
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/Bin",
|
|
1536
|
+
"type": "string",
|
|
1537
|
+
"pattern": "^\\d+$",
|
|
1538
|
+
"description": "Bank Identification Number",
|
|
1539
|
+
"minLength": 6,
|
|
1540
|
+
"maxLength": 8
|
|
1541
|
+
},
|
|
1542
|
+
"last4": {
|
|
1543
|
+
"type": "string",
|
|
1544
|
+
"pattern": "^\\d+$",
|
|
1545
|
+
"description": "Last four digits of the card number",
|
|
1546
|
+
"minLength": 4,
|
|
1547
|
+
"maxLength": 4
|
|
1548
|
+
},
|
|
1549
|
+
"expirationDate": {
|
|
1550
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
1551
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/ExpirationDate",
|
|
1552
|
+
"type": "string",
|
|
1553
|
+
"pattern": "([0-9][0-9])(0[1-9]|1[0-2])",
|
|
1554
|
+
"format": "YYMM",
|
|
1555
|
+
"description": "Expiration date for the card and will be assumed to be the last millisecond of the month",
|
|
1556
|
+
"minLength": 4,
|
|
1557
|
+
"maxLength": 4
|
|
1558
|
+
},
|
|
1559
|
+
"cardNumber": {
|
|
1560
|
+
"type": "string",
|
|
1561
|
+
"description": "Encrypted card number (PAN)"
|
|
1562
|
+
},
|
|
1563
|
+
"serviceCode": {
|
|
1564
|
+
"type": "string",
|
|
1565
|
+
"pattern": "^\\d+$",
|
|
1566
|
+
"description": "Service code for the card",
|
|
1567
|
+
"minLength": 3,
|
|
1568
|
+
"maxLength": 3
|
|
1569
|
+
},
|
|
1570
|
+
"pinOffset": {
|
|
1571
|
+
"type": "string",
|
|
1572
|
+
"description": "Encrypted pin offset for the card"
|
|
1573
|
+
},
|
|
1574
|
+
"applicationTransactionCounter": {
|
|
1575
|
+
"type": "integer",
|
|
1576
|
+
"description": "Application transaction counter (ATC) for the card"
|
|
1577
|
+
},
|
|
1578
|
+
"sequenceNumber": {
|
|
1579
|
+
"type": "integer",
|
|
1580
|
+
"description": "Used to differentiate issuing the same card and expiration date on multiple plastics"
|
|
1581
|
+
},
|
|
1582
|
+
"state": {
|
|
1583
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
1584
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/StateStatus",
|
|
1585
|
+
"description": "The current state of the card",
|
|
1586
|
+
"type": "string",
|
|
1587
|
+
"enum": ["CURRENT", "REISSUED", "RETIRED", "FORCED"]
|
|
1588
|
+
},
|
|
1589
|
+
"active": {
|
|
1590
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
1591
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/ActiveStatus",
|
|
1592
|
+
"description": "The active/inactive status for the card",
|
|
1593
|
+
"type": "string",
|
|
1594
|
+
"enum": ["INACTIVE", "ACTIVE"]
|
|
1595
|
+
},
|
|
1596
|
+
"block": {
|
|
1597
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
1598
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/BlockStatus",
|
|
1599
|
+
"type": "string",
|
|
1600
|
+
"description": "Whether the card is open or blocked for various reasons",
|
|
1601
|
+
"enum": ["OPEN", "BLOCKED LOST OR STOLEN", "BLOCKED NO FRAUD", "BLOCKED WITH FRAUD"]
|
|
1602
|
+
},
|
|
1603
|
+
"lock": {
|
|
1604
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
1605
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/LockStatus",
|
|
1606
|
+
"type": "string",
|
|
1607
|
+
"description": "A cardholder initiated status. A locked card will fail authorization. Locked cards can be unlocked.\n\nA cardholder may choose to lock a card while temporarily misplaced.\n",
|
|
1608
|
+
"enum": ["LOCKED", "UNLOCKED"]
|
|
1609
|
+
},
|
|
1610
|
+
"capture": {
|
|
1611
|
+
"type": "boolean",
|
|
1612
|
+
"description": "Whether the card should be captured at next use"
|
|
1613
|
+
},
|
|
1614
|
+
"updatedOn": {
|
|
1615
|
+
"type": "string",
|
|
1616
|
+
"description": "Time data was last updated",
|
|
1617
|
+
"format": "date-time"
|
|
1618
|
+
},
|
|
1619
|
+
"lastModified": {
|
|
1620
|
+
"type": "string",
|
|
1621
|
+
"description": "Time data was last modified (Deprecated. Use updatedOn)",
|
|
1622
|
+
"format": "date-time"
|
|
1623
|
+
},
|
|
1624
|
+
"createdOn": {
|
|
1625
|
+
"description": "Time encrypted data was first stored",
|
|
1626
|
+
"type": "string",
|
|
1627
|
+
"format": "date-time"
|
|
1628
|
+
}
|
|
1629
|
+
}
|
|
1630
|
+
}
|
|
1631
|
+
}
|
|
1632
|
+
}
|
|
1633
|
+
},
|
|
1634
|
+
"required": ["body"],
|
|
1635
|
+
"additionalProperties": false
|
|
1636
|
+
},
|
|
1637
|
+
"409": {
|
|
1638
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
1639
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/api/CardNumberPutResponseConflict",
|
|
1640
|
+
"type": "object",
|
|
1641
|
+
"properties": {
|
|
1642
|
+
"headers": {
|
|
1643
|
+
"type": "object",
|
|
1644
|
+
"additionalProperties": true
|
|
1645
|
+
}
|
|
1646
|
+
},
|
|
1647
|
+
"required": [],
|
|
1648
|
+
"additionalProperties": false
|
|
1649
|
+
},
|
|
1650
|
+
"412": {
|
|
1651
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
1652
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/api/CardNumberPutResponsePreconditionFailed",
|
|
1653
|
+
"type": "object",
|
|
1654
|
+
"properties": {
|
|
1655
|
+
"headers": {
|
|
1656
|
+
"type": "object",
|
|
1657
|
+
"additionalProperties": true
|
|
1658
|
+
}
|
|
1659
|
+
},
|
|
1660
|
+
"required": [],
|
|
1661
|
+
"additionalProperties": false
|
|
1662
|
+
},
|
|
1663
|
+
"default": {
|
|
1664
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
1665
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/api/CardNumberPutResponseDefault",
|
|
1666
|
+
"type": "object",
|
|
1667
|
+
"properties": {
|
|
1668
|
+
"headers": {
|
|
1669
|
+
"type": "object",
|
|
1670
|
+
"additionalProperties": true
|
|
1671
|
+
},
|
|
1672
|
+
"body": {
|
|
1673
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
1674
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/Error",
|
|
1675
|
+
"type": "object",
|
|
1676
|
+
"additionalProperties": false,
|
|
1677
|
+
"description": "Server error message",
|
|
1678
|
+
"properties": {
|
|
1679
|
+
"message": {
|
|
1680
|
+
"type": "string"
|
|
1681
|
+
},
|
|
1682
|
+
"code": {
|
|
1683
|
+
"type": "string"
|
|
1684
|
+
}
|
|
1685
|
+
}
|
|
1686
|
+
}
|
|
1687
|
+
},
|
|
1688
|
+
"required": ["body"],
|
|
1689
|
+
"additionalProperties": false
|
|
1690
|
+
}
|
|
1691
|
+
}
|
|
1692
|
+
}
|
|
1693
|
+
},
|
|
1694
|
+
"/payment-card/v1/card/:cardId/active/:activeStatus": {
|
|
1695
|
+
"put": {
|
|
1696
|
+
"request": {
|
|
1697
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
1698
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/api/CardActivePutRequestContext",
|
|
1699
|
+
"type": "object",
|
|
1700
|
+
"properties": {
|
|
1701
|
+
"params": {
|
|
1702
|
+
"type": "object",
|
|
1703
|
+
"additionalProperties": false,
|
|
1704
|
+
"properties": {
|
|
1705
|
+
"cardId": {
|
|
1706
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
1707
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/CardId",
|
|
1708
|
+
"type": "string",
|
|
1709
|
+
"description": "Card identifier",
|
|
1710
|
+
"format": "uuid"
|
|
1711
|
+
},
|
|
1712
|
+
"activeStatus": {
|
|
1713
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
1714
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/ActiveStatus",
|
|
1715
|
+
"description": "The active/inactive status for the card",
|
|
1716
|
+
"type": "string",
|
|
1717
|
+
"enum": ["INACTIVE", "ACTIVE"]
|
|
1718
|
+
}
|
|
1719
|
+
},
|
|
1720
|
+
"required": ["cardId", "activeStatus"]
|
|
1721
|
+
},
|
|
1722
|
+
"headers": {
|
|
1723
|
+
"type": "object",
|
|
1724
|
+
"additionalProperties": true,
|
|
1725
|
+
"properties": {
|
|
1726
|
+
"created-on": {
|
|
1727
|
+
"type": "string",
|
|
1728
|
+
"format": "date-time"
|
|
1729
|
+
},
|
|
1730
|
+
"last-modified": {
|
|
1731
|
+
"type": "string",
|
|
1732
|
+
"format": "date-time"
|
|
1733
|
+
},
|
|
1734
|
+
"if-match": {
|
|
1735
|
+
"type": "string"
|
|
1736
|
+
}
|
|
1737
|
+
},
|
|
1738
|
+
"required": ["If-Match"]
|
|
1739
|
+
}
|
|
1740
|
+
},
|
|
1741
|
+
"required": ["params", "headers"],
|
|
1742
|
+
"additionalProperties": false
|
|
1743
|
+
},
|
|
1744
|
+
"responses": {
|
|
1745
|
+
"204": {
|
|
1746
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
1747
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/api/CardActivePutResponseNoContent",
|
|
1748
|
+
"type": "object",
|
|
1749
|
+
"properties": {
|
|
1750
|
+
"headers": {
|
|
1751
|
+
"type": "object",
|
|
1752
|
+
"properties": {
|
|
1753
|
+
"last-modified": {
|
|
1754
|
+
"type": "string",
|
|
1755
|
+
"format": "date-time"
|
|
1756
|
+
},
|
|
1757
|
+
"created-on": {
|
|
1758
|
+
"type": "string",
|
|
1759
|
+
"format": "date-time"
|
|
1760
|
+
},
|
|
1761
|
+
"updated-on": {
|
|
1762
|
+
"type": "string",
|
|
1763
|
+
"format": "date-time"
|
|
1764
|
+
},
|
|
1765
|
+
"etag": {
|
|
1766
|
+
"type": "string"
|
|
1767
|
+
}
|
|
1768
|
+
}
|
|
1769
|
+
}
|
|
1770
|
+
},
|
|
1771
|
+
"required": [],
|
|
1772
|
+
"additionalProperties": false
|
|
1773
|
+
},
|
|
1774
|
+
"409": {
|
|
1775
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
1776
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/api/CardActivePutResponseConflict",
|
|
1777
|
+
"type": "object",
|
|
1778
|
+
"properties": {
|
|
1779
|
+
"headers": {
|
|
1780
|
+
"type": "object",
|
|
1781
|
+
"additionalProperties": true
|
|
1782
|
+
}
|
|
1783
|
+
},
|
|
1784
|
+
"required": [],
|
|
1785
|
+
"additionalProperties": false
|
|
1786
|
+
},
|
|
1787
|
+
"412": {
|
|
1788
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
1789
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/api/CardActivePutResponsePreconditionFailed",
|
|
1790
|
+
"type": "object",
|
|
1791
|
+
"properties": {
|
|
1792
|
+
"headers": {
|
|
1793
|
+
"type": "object",
|
|
1794
|
+
"additionalProperties": true
|
|
1795
|
+
}
|
|
1796
|
+
},
|
|
1797
|
+
"required": [],
|
|
1798
|
+
"additionalProperties": false
|
|
1799
|
+
},
|
|
1800
|
+
"default": {
|
|
1801
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
1802
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/api/CardActivePutResponseDefault",
|
|
1803
|
+
"type": "object",
|
|
1804
|
+
"properties": {
|
|
1805
|
+
"headers": {
|
|
1806
|
+
"type": "object",
|
|
1807
|
+
"additionalProperties": true
|
|
1808
|
+
},
|
|
1809
|
+
"body": {
|
|
1810
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
1811
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/Error",
|
|
1812
|
+
"type": "object",
|
|
1813
|
+
"additionalProperties": false,
|
|
1814
|
+
"description": "Server error message",
|
|
1815
|
+
"properties": {
|
|
1816
|
+
"message": {
|
|
1817
|
+
"type": "string"
|
|
1818
|
+
},
|
|
1819
|
+
"code": {
|
|
1820
|
+
"type": "string"
|
|
1821
|
+
}
|
|
1822
|
+
}
|
|
1823
|
+
}
|
|
1824
|
+
},
|
|
1825
|
+
"required": ["body"],
|
|
1826
|
+
"additionalProperties": false
|
|
1827
|
+
}
|
|
1828
|
+
}
|
|
1829
|
+
}
|
|
1830
|
+
},
|
|
1831
|
+
"/payment-card/v1/card/:cardId/application-transaction-counter/:applicationTransactionCounter": {
|
|
1832
|
+
"put": {
|
|
1833
|
+
"request": {
|
|
1834
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
1835
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/api/CardApplicationTransactionCounterPutRequestContext",
|
|
1836
|
+
"type": "object",
|
|
1837
|
+
"properties": {
|
|
1838
|
+
"params": {
|
|
1839
|
+
"type": "object",
|
|
1840
|
+
"additionalProperties": false,
|
|
1841
|
+
"properties": {
|
|
1842
|
+
"cardId": {
|
|
1843
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
1844
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/CardId",
|
|
1845
|
+
"type": "string",
|
|
1846
|
+
"description": "Card identifier",
|
|
1847
|
+
"format": "uuid"
|
|
1848
|
+
},
|
|
1849
|
+
"applicationTransactionCounter": {
|
|
1850
|
+
"type": "integer"
|
|
1851
|
+
}
|
|
1852
|
+
},
|
|
1853
|
+
"required": ["cardId", "applicationTransactionCounter"]
|
|
1854
|
+
},
|
|
1855
|
+
"headers": {
|
|
1856
|
+
"type": "object",
|
|
1857
|
+
"additionalProperties": true,
|
|
1858
|
+
"properties": {
|
|
1859
|
+
"created-on": {
|
|
1860
|
+
"type": "string",
|
|
1861
|
+
"format": "date-time"
|
|
1862
|
+
},
|
|
1863
|
+
"last-modified": {
|
|
1864
|
+
"type": "string",
|
|
1865
|
+
"format": "date-time"
|
|
1866
|
+
},
|
|
1867
|
+
"if-match": {
|
|
1868
|
+
"type": "string"
|
|
1869
|
+
}
|
|
1870
|
+
},
|
|
1871
|
+
"required": ["If-Match"]
|
|
1872
|
+
}
|
|
1873
|
+
},
|
|
1874
|
+
"required": ["params", "headers"],
|
|
1875
|
+
"additionalProperties": false
|
|
1876
|
+
},
|
|
1877
|
+
"responses": {
|
|
1878
|
+
"204": {
|
|
1879
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
1880
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/api/CardApplicationTransactionCounterPutResponseNoContent",
|
|
1881
|
+
"type": "object",
|
|
1882
|
+
"properties": {
|
|
1883
|
+
"headers": {
|
|
1884
|
+
"type": "object",
|
|
1885
|
+
"properties": {
|
|
1886
|
+
"last-modified": {
|
|
1887
|
+
"type": "string",
|
|
1888
|
+
"format": "date-time"
|
|
1889
|
+
},
|
|
1890
|
+
"created-on": {
|
|
1891
|
+
"type": "string",
|
|
1892
|
+
"format": "date-time"
|
|
1893
|
+
},
|
|
1894
|
+
"updated-on": {
|
|
1895
|
+
"type": "string",
|
|
1896
|
+
"format": "date-time"
|
|
1897
|
+
},
|
|
1898
|
+
"etag": {
|
|
1899
|
+
"type": "string"
|
|
1900
|
+
}
|
|
1901
|
+
}
|
|
1902
|
+
}
|
|
1903
|
+
},
|
|
1904
|
+
"required": [],
|
|
1905
|
+
"additionalProperties": false
|
|
1906
|
+
},
|
|
1907
|
+
"409": {
|
|
1908
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
1909
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/api/CardApplicationTransactionCounterPutResponseConflict",
|
|
1910
|
+
"type": "object",
|
|
1911
|
+
"properties": {
|
|
1912
|
+
"headers": {
|
|
1913
|
+
"type": "object",
|
|
1914
|
+
"additionalProperties": true
|
|
1915
|
+
}
|
|
1916
|
+
},
|
|
1917
|
+
"required": [],
|
|
1918
|
+
"additionalProperties": false
|
|
1919
|
+
},
|
|
1920
|
+
"412": {
|
|
1921
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
1922
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/api/CardApplicationTransactionCounterPutResponsePreconditionFailed",
|
|
1923
|
+
"type": "object",
|
|
1924
|
+
"properties": {
|
|
1925
|
+
"headers": {
|
|
1926
|
+
"type": "object",
|
|
1927
|
+
"additionalProperties": true
|
|
1928
|
+
}
|
|
1929
|
+
},
|
|
1930
|
+
"required": [],
|
|
1931
|
+
"additionalProperties": false
|
|
1932
|
+
},
|
|
1933
|
+
"default": {
|
|
1934
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
1935
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/api/CardApplicationTransactionCounterPutResponseDefault",
|
|
1936
|
+
"type": "object",
|
|
1937
|
+
"properties": {
|
|
1938
|
+
"headers": {
|
|
1939
|
+
"type": "object",
|
|
1940
|
+
"additionalProperties": true
|
|
1941
|
+
},
|
|
1942
|
+
"body": {
|
|
1943
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
1944
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/Error",
|
|
1945
|
+
"type": "object",
|
|
1946
|
+
"additionalProperties": false,
|
|
1947
|
+
"description": "Server error message",
|
|
1948
|
+
"properties": {
|
|
1949
|
+
"message": {
|
|
1950
|
+
"type": "string"
|
|
1951
|
+
},
|
|
1952
|
+
"code": {
|
|
1953
|
+
"type": "string"
|
|
1954
|
+
}
|
|
1955
|
+
}
|
|
1956
|
+
}
|
|
1957
|
+
},
|
|
1958
|
+
"required": ["body"],
|
|
1959
|
+
"additionalProperties": false
|
|
1960
|
+
}
|
|
1961
|
+
}
|
|
1962
|
+
}
|
|
1963
|
+
},
|
|
1964
|
+
"/payment-card/v1/card/:cardId/block/:blockStatus": {
|
|
1965
|
+
"put": {
|
|
1966
|
+
"request": {
|
|
1967
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
1968
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/api/CardBlockPutRequestContext",
|
|
1969
|
+
"type": "object",
|
|
1970
|
+
"properties": {
|
|
1971
|
+
"params": {
|
|
1972
|
+
"type": "object",
|
|
1973
|
+
"additionalProperties": false,
|
|
1974
|
+
"properties": {
|
|
1975
|
+
"cardId": {
|
|
1976
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
1977
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/CardId",
|
|
1978
|
+
"type": "string",
|
|
1979
|
+
"description": "Card identifier",
|
|
1980
|
+
"format": "uuid"
|
|
1981
|
+
},
|
|
1982
|
+
"blockStatus": {
|
|
1983
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
1984
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/BlockStatus",
|
|
1985
|
+
"type": "string",
|
|
1986
|
+
"description": "Whether the card is open or blocked for various reasons",
|
|
1987
|
+
"enum": ["OPEN", "BLOCKED LOST OR STOLEN", "BLOCKED NO FRAUD", "BLOCKED WITH FRAUD"]
|
|
1988
|
+
}
|
|
1989
|
+
},
|
|
1990
|
+
"required": ["cardId", "blockStatus"]
|
|
1991
|
+
},
|
|
1992
|
+
"headers": {
|
|
1993
|
+
"type": "object",
|
|
1994
|
+
"additionalProperties": true,
|
|
1995
|
+
"properties": {
|
|
1996
|
+
"created-on": {
|
|
1997
|
+
"type": "string",
|
|
1998
|
+
"format": "date-time"
|
|
1999
|
+
},
|
|
2000
|
+
"last-modified": {
|
|
2001
|
+
"type": "string",
|
|
2002
|
+
"format": "date-time"
|
|
2003
|
+
},
|
|
2004
|
+
"if-match": {
|
|
2005
|
+
"type": "string"
|
|
2006
|
+
}
|
|
2007
|
+
},
|
|
2008
|
+
"required": ["If-Match"]
|
|
2009
|
+
}
|
|
2010
|
+
},
|
|
2011
|
+
"required": ["params", "headers"],
|
|
2012
|
+
"additionalProperties": false
|
|
2013
|
+
},
|
|
2014
|
+
"responses": {
|
|
2015
|
+
"204": {
|
|
2016
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
2017
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/api/CardBlockPutResponseNoContent",
|
|
2018
|
+
"type": "object",
|
|
2019
|
+
"properties": {
|
|
2020
|
+
"headers": {
|
|
2021
|
+
"type": "object",
|
|
2022
|
+
"properties": {
|
|
2023
|
+
"last-modified": {
|
|
2024
|
+
"type": "string",
|
|
2025
|
+
"format": "date-time"
|
|
2026
|
+
},
|
|
2027
|
+
"created-on": {
|
|
2028
|
+
"type": "string",
|
|
2029
|
+
"format": "date-time"
|
|
2030
|
+
},
|
|
2031
|
+
"updated-on": {
|
|
2032
|
+
"type": "string",
|
|
2033
|
+
"format": "date-time"
|
|
2034
|
+
},
|
|
2035
|
+
"etag": {
|
|
2036
|
+
"type": "string"
|
|
2037
|
+
}
|
|
2038
|
+
}
|
|
2039
|
+
}
|
|
2040
|
+
},
|
|
2041
|
+
"required": [],
|
|
2042
|
+
"additionalProperties": false
|
|
2043
|
+
},
|
|
2044
|
+
"409": {
|
|
2045
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
2046
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/api/CardBlockPutResponseConflict",
|
|
2047
|
+
"type": "object",
|
|
2048
|
+
"properties": {
|
|
2049
|
+
"headers": {
|
|
2050
|
+
"type": "object",
|
|
2051
|
+
"additionalProperties": true
|
|
2052
|
+
}
|
|
2053
|
+
},
|
|
2054
|
+
"required": [],
|
|
2055
|
+
"additionalProperties": false
|
|
2056
|
+
},
|
|
2057
|
+
"412": {
|
|
2058
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
2059
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/api/CardBlockPutResponsePreconditionFailed",
|
|
2060
|
+
"type": "object",
|
|
2061
|
+
"properties": {
|
|
2062
|
+
"headers": {
|
|
2063
|
+
"type": "object",
|
|
2064
|
+
"additionalProperties": true
|
|
2065
|
+
}
|
|
2066
|
+
},
|
|
2067
|
+
"required": [],
|
|
2068
|
+
"additionalProperties": false
|
|
2069
|
+
},
|
|
2070
|
+
"default": {
|
|
2071
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
2072
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/api/CardBlockPutResponseDefault",
|
|
2073
|
+
"type": "object",
|
|
2074
|
+
"properties": {
|
|
2075
|
+
"headers": {
|
|
2076
|
+
"type": "object",
|
|
2077
|
+
"additionalProperties": true
|
|
2078
|
+
},
|
|
2079
|
+
"body": {
|
|
2080
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
2081
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/Error",
|
|
2082
|
+
"type": "object",
|
|
2083
|
+
"additionalProperties": false,
|
|
2084
|
+
"description": "Server error message",
|
|
2085
|
+
"properties": {
|
|
2086
|
+
"message": {
|
|
2087
|
+
"type": "string"
|
|
2088
|
+
},
|
|
2089
|
+
"code": {
|
|
2090
|
+
"type": "string"
|
|
2091
|
+
}
|
|
2092
|
+
}
|
|
2093
|
+
}
|
|
2094
|
+
},
|
|
2095
|
+
"required": ["body"],
|
|
2096
|
+
"additionalProperties": false
|
|
2097
|
+
}
|
|
2098
|
+
}
|
|
2099
|
+
}
|
|
2100
|
+
},
|
|
2101
|
+
"/payment-card/v1/card/:cardId/capture/:captureStatus": {
|
|
2102
|
+
"put": {
|
|
2103
|
+
"request": {
|
|
2104
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
2105
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/api/CardCapturePutRequestContext",
|
|
2106
|
+
"type": "object",
|
|
2107
|
+
"properties": {
|
|
2108
|
+
"params": {
|
|
2109
|
+
"type": "object",
|
|
2110
|
+
"additionalProperties": false,
|
|
2111
|
+
"properties": {
|
|
2112
|
+
"cardId": {
|
|
2113
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
2114
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/CardId",
|
|
2115
|
+
"type": "string",
|
|
2116
|
+
"description": "Card identifier",
|
|
2117
|
+
"format": "uuid"
|
|
2118
|
+
},
|
|
2119
|
+
"captureStatus": {
|
|
2120
|
+
"type": "boolean"
|
|
2121
|
+
}
|
|
2122
|
+
},
|
|
2123
|
+
"required": ["cardId", "captureStatus"]
|
|
2124
|
+
},
|
|
2125
|
+
"headers": {
|
|
2126
|
+
"type": "object",
|
|
2127
|
+
"additionalProperties": true,
|
|
2128
|
+
"properties": {
|
|
2129
|
+
"created-on": {
|
|
2130
|
+
"type": "string",
|
|
2131
|
+
"format": "date-time"
|
|
2132
|
+
},
|
|
2133
|
+
"last-modified": {
|
|
2134
|
+
"type": "string",
|
|
2135
|
+
"format": "date-time"
|
|
2136
|
+
},
|
|
2137
|
+
"if-match": {
|
|
2138
|
+
"type": "string"
|
|
2139
|
+
}
|
|
2140
|
+
},
|
|
2141
|
+
"required": ["If-Match"]
|
|
2142
|
+
}
|
|
2143
|
+
},
|
|
2144
|
+
"required": ["params", "headers"],
|
|
2145
|
+
"additionalProperties": false
|
|
2146
|
+
},
|
|
2147
|
+
"responses": {
|
|
2148
|
+
"204": {
|
|
2149
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
2150
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/api/CardCapturePutResponseNoContent",
|
|
2151
|
+
"type": "object",
|
|
2152
|
+
"properties": {
|
|
2153
|
+
"headers": {
|
|
2154
|
+
"type": "object",
|
|
2155
|
+
"properties": {
|
|
2156
|
+
"last-modified": {
|
|
2157
|
+
"type": "string",
|
|
2158
|
+
"format": "date-time"
|
|
2159
|
+
},
|
|
2160
|
+
"created-on": {
|
|
2161
|
+
"type": "string",
|
|
2162
|
+
"format": "date-time"
|
|
2163
|
+
},
|
|
2164
|
+
"updated-on": {
|
|
2165
|
+
"type": "string",
|
|
2166
|
+
"format": "date-time"
|
|
2167
|
+
},
|
|
2168
|
+
"etag": {
|
|
2169
|
+
"type": "string"
|
|
2170
|
+
}
|
|
2171
|
+
}
|
|
2172
|
+
}
|
|
2173
|
+
},
|
|
2174
|
+
"required": [],
|
|
2175
|
+
"additionalProperties": false
|
|
2176
|
+
},
|
|
2177
|
+
"409": {
|
|
2178
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
2179
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/api/CardCapturePutResponseConflict",
|
|
2180
|
+
"type": "object",
|
|
2181
|
+
"properties": {
|
|
2182
|
+
"headers": {
|
|
2183
|
+
"type": "object",
|
|
2184
|
+
"additionalProperties": true
|
|
2185
|
+
}
|
|
2186
|
+
},
|
|
2187
|
+
"required": [],
|
|
2188
|
+
"additionalProperties": false
|
|
2189
|
+
},
|
|
2190
|
+
"412": {
|
|
2191
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
2192
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/api/CardCapturePutResponsePreconditionFailed",
|
|
2193
|
+
"type": "object",
|
|
2194
|
+
"properties": {
|
|
2195
|
+
"headers": {
|
|
2196
|
+
"type": "object",
|
|
2197
|
+
"additionalProperties": true
|
|
2198
|
+
}
|
|
2199
|
+
},
|
|
2200
|
+
"required": [],
|
|
2201
|
+
"additionalProperties": false
|
|
2202
|
+
},
|
|
2203
|
+
"default": {
|
|
2204
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
2205
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/api/CardCapturePutResponseDefault",
|
|
2206
|
+
"type": "object",
|
|
2207
|
+
"properties": {
|
|
2208
|
+
"headers": {
|
|
2209
|
+
"type": "object",
|
|
2210
|
+
"additionalProperties": true
|
|
2211
|
+
},
|
|
2212
|
+
"body": {
|
|
2213
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
2214
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/Error",
|
|
2215
|
+
"type": "object",
|
|
2216
|
+
"additionalProperties": false,
|
|
2217
|
+
"description": "Server error message",
|
|
2218
|
+
"properties": {
|
|
2219
|
+
"message": {
|
|
2220
|
+
"type": "string"
|
|
2221
|
+
},
|
|
2222
|
+
"code": {
|
|
2223
|
+
"type": "string"
|
|
2224
|
+
}
|
|
2225
|
+
}
|
|
2226
|
+
}
|
|
2227
|
+
},
|
|
2228
|
+
"required": ["body"],
|
|
2229
|
+
"additionalProperties": false
|
|
2230
|
+
}
|
|
2231
|
+
}
|
|
2232
|
+
}
|
|
2233
|
+
},
|
|
2234
|
+
"/payment-card/v1/card/:cardId/history": {
|
|
2235
|
+
"get": {
|
|
2236
|
+
"request": {
|
|
2237
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
2238
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/api/CardHistoryGetRequestContext",
|
|
2239
|
+
"type": "object",
|
|
2240
|
+
"properties": {
|
|
2241
|
+
"params": {
|
|
2242
|
+
"type": "object",
|
|
2243
|
+
"additionalProperties": false,
|
|
2244
|
+
"properties": {
|
|
2245
|
+
"fromDate": {
|
|
2246
|
+
"type": "string",
|
|
2247
|
+
"format": "date-time"
|
|
2248
|
+
},
|
|
2249
|
+
"toDate": {
|
|
2250
|
+
"type": "string",
|
|
2251
|
+
"format": "date-time"
|
|
2252
|
+
},
|
|
2253
|
+
"publicKeyHashQuery": {
|
|
2254
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
2255
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/Hash",
|
|
2256
|
+
"type": "string",
|
|
2257
|
+
"format": "uuid",
|
|
2258
|
+
"example": "15a85f64-5717-4562-b3fc-2c963f66afa6",
|
|
2259
|
+
"description": "UUID derived using @checkdigit/hash"
|
|
2260
|
+
}
|
|
2261
|
+
},
|
|
2262
|
+
"required": ["toDate"]
|
|
2263
|
+
},
|
|
2264
|
+
"headers": {
|
|
2265
|
+
"type": "object",
|
|
2266
|
+
"additionalProperties": true
|
|
2267
|
+
}
|
|
2268
|
+
},
|
|
2269
|
+
"required": ["params", "query"],
|
|
2270
|
+
"additionalProperties": false
|
|
2271
|
+
},
|
|
2272
|
+
"responses": {
|
|
2273
|
+
"200": {
|
|
2274
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
2275
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/api/CardHistoryGetResponseOK",
|
|
2276
|
+
"type": "object",
|
|
2277
|
+
"properties": {
|
|
2278
|
+
"headers": {
|
|
2279
|
+
"type": "object",
|
|
2280
|
+
"additionalProperties": true
|
|
2281
|
+
},
|
|
2282
|
+
"body": {
|
|
2283
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
2284
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/History",
|
|
2285
|
+
"description": "The History object represents the updates to a Card object over time.\n",
|
|
2286
|
+
"type": "object",
|
|
2287
|
+
"required": ["updates"],
|
|
2288
|
+
"properties": {
|
|
2289
|
+
"dataEncryptionKeyId": {
|
|
2290
|
+
"type": "string",
|
|
2291
|
+
"description": "Reference to encryption keys Payment Card Service used to encrypt the Card object.\n",
|
|
2292
|
+
"format": "uuid"
|
|
2293
|
+
},
|
|
2294
|
+
"storageKeyId": {
|
|
2295
|
+
"type": "string",
|
|
2296
|
+
"description": "DEK's non-derived identifier to be used by Check Digit services only.\n"
|
|
2297
|
+
},
|
|
2298
|
+
"encryptedDataEncryptionKey": {
|
|
2299
|
+
"description": "RSA encrypted data encryption key used to decrypt AES encrypted values in Card objects.\n",
|
|
2300
|
+
"type": "string"
|
|
2301
|
+
},
|
|
2302
|
+
"updates": {
|
|
2303
|
+
"type": "array",
|
|
2304
|
+
"items": {
|
|
2305
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
2306
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/Card",
|
|
2307
|
+
"type": "object",
|
|
2308
|
+
"additionalProperties": false,
|
|
2309
|
+
"required": [
|
|
2310
|
+
"bin",
|
|
2311
|
+
"last4",
|
|
2312
|
+
"expirationDate",
|
|
2313
|
+
"cardNumber",
|
|
2314
|
+
"serviceCode",
|
|
2315
|
+
"pinOffset",
|
|
2316
|
+
"applicationTransactionCounter",
|
|
2317
|
+
"sequenceNumber",
|
|
2318
|
+
"state",
|
|
2319
|
+
"active",
|
|
2320
|
+
"block",
|
|
2321
|
+
"lock",
|
|
2322
|
+
"capture",
|
|
2323
|
+
"createdOn",
|
|
2324
|
+
"updatedOn",
|
|
2325
|
+
"lastModified"
|
|
2326
|
+
],
|
|
2327
|
+
"properties": {
|
|
2328
|
+
"bin": {
|
|
2329
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
2330
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/Bin",
|
|
2331
|
+
"type": "string",
|
|
2332
|
+
"pattern": "^\\d+$",
|
|
2333
|
+
"description": "Bank Identification Number",
|
|
2334
|
+
"minLength": 6,
|
|
2335
|
+
"maxLength": 8
|
|
2336
|
+
},
|
|
2337
|
+
"last4": {
|
|
2338
|
+
"type": "string",
|
|
2339
|
+
"pattern": "^\\d+$",
|
|
2340
|
+
"description": "Last four digits of the card number",
|
|
2341
|
+
"minLength": 4,
|
|
2342
|
+
"maxLength": 4
|
|
2343
|
+
},
|
|
2344
|
+
"expirationDate": {
|
|
2345
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
2346
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/ExpirationDate",
|
|
2347
|
+
"type": "string",
|
|
2348
|
+
"pattern": "([0-9][0-9])(0[1-9]|1[0-2])",
|
|
2349
|
+
"format": "YYMM",
|
|
2350
|
+
"description": "Expiration date for the card and will be assumed to be the last millisecond of the month",
|
|
2351
|
+
"minLength": 4,
|
|
2352
|
+
"maxLength": 4
|
|
2353
|
+
},
|
|
2354
|
+
"cardNumber": {
|
|
2355
|
+
"type": "string",
|
|
2356
|
+
"description": "Encrypted card number (PAN)"
|
|
2357
|
+
},
|
|
2358
|
+
"serviceCode": {
|
|
2359
|
+
"type": "string",
|
|
2360
|
+
"pattern": "^\\d+$",
|
|
2361
|
+
"description": "Service code for the card",
|
|
2362
|
+
"minLength": 3,
|
|
2363
|
+
"maxLength": 3
|
|
2364
|
+
},
|
|
2365
|
+
"pinOffset": {
|
|
2366
|
+
"type": "string",
|
|
2367
|
+
"description": "Encrypted pin offset for the card"
|
|
2368
|
+
},
|
|
2369
|
+
"applicationTransactionCounter": {
|
|
2370
|
+
"type": "integer",
|
|
2371
|
+
"description": "Application transaction counter (ATC) for the card"
|
|
2372
|
+
},
|
|
2373
|
+
"sequenceNumber": {
|
|
2374
|
+
"type": "integer",
|
|
2375
|
+
"description": "Used to differentiate issuing the same card and expiration date on multiple plastics"
|
|
2376
|
+
},
|
|
2377
|
+
"state": {
|
|
2378
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
2379
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/StateStatus",
|
|
2380
|
+
"description": "The current state of the card",
|
|
2381
|
+
"type": "string",
|
|
2382
|
+
"enum": ["CURRENT", "REISSUED", "RETIRED", "FORCED"]
|
|
2383
|
+
},
|
|
2384
|
+
"active": {
|
|
2385
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
2386
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/ActiveStatus",
|
|
2387
|
+
"description": "The active/inactive status for the card",
|
|
2388
|
+
"type": "string",
|
|
2389
|
+
"enum": ["INACTIVE", "ACTIVE"]
|
|
2390
|
+
},
|
|
2391
|
+
"block": {
|
|
2392
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
2393
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/BlockStatus",
|
|
2394
|
+
"type": "string",
|
|
2395
|
+
"description": "Whether the card is open or blocked for various reasons",
|
|
2396
|
+
"enum": ["OPEN", "BLOCKED LOST OR STOLEN", "BLOCKED NO FRAUD", "BLOCKED WITH FRAUD"]
|
|
2397
|
+
},
|
|
2398
|
+
"lock": {
|
|
2399
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
2400
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/LockStatus",
|
|
2401
|
+
"type": "string",
|
|
2402
|
+
"description": "A cardholder initiated status. A locked card will fail authorization. Locked cards can be unlocked.\n\nA cardholder may choose to lock a card while temporarily misplaced.\n",
|
|
2403
|
+
"enum": ["LOCKED", "UNLOCKED"]
|
|
2404
|
+
},
|
|
2405
|
+
"capture": {
|
|
2406
|
+
"type": "boolean",
|
|
2407
|
+
"description": "Whether the card should be captured at next use"
|
|
2408
|
+
},
|
|
2409
|
+
"updatedOn": {
|
|
2410
|
+
"type": "string",
|
|
2411
|
+
"description": "Time data was last updated",
|
|
2412
|
+
"format": "date-time"
|
|
2413
|
+
},
|
|
2414
|
+
"lastModified": {
|
|
2415
|
+
"type": "string",
|
|
2416
|
+
"description": "Time data was last modified (Deprecated. Use updatedOn)",
|
|
2417
|
+
"format": "date-time"
|
|
2418
|
+
},
|
|
2419
|
+
"createdOn": {
|
|
2420
|
+
"description": "Time encrypted data was first stored",
|
|
2421
|
+
"type": "string",
|
|
2422
|
+
"format": "date-time"
|
|
2423
|
+
}
|
|
2424
|
+
}
|
|
2425
|
+
}
|
|
2426
|
+
}
|
|
2427
|
+
}
|
|
2428
|
+
}
|
|
2429
|
+
},
|
|
2430
|
+
"required": ["body"],
|
|
2431
|
+
"additionalProperties": false
|
|
2432
|
+
},
|
|
2433
|
+
"404": {
|
|
2434
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
2435
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/api/CardHistoryGetResponseNotFound",
|
|
2436
|
+
"type": "object",
|
|
2437
|
+
"properties": {
|
|
2438
|
+
"headers": {
|
|
2439
|
+
"type": "object",
|
|
2440
|
+
"additionalProperties": true
|
|
2441
|
+
}
|
|
2442
|
+
},
|
|
2443
|
+
"required": [],
|
|
2444
|
+
"additionalProperties": false
|
|
2445
|
+
},
|
|
2446
|
+
"default": {
|
|
2447
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
2448
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/api/CardHistoryGetResponseDefault",
|
|
2449
|
+
"type": "object",
|
|
2450
|
+
"properties": {
|
|
2451
|
+
"headers": {
|
|
2452
|
+
"type": "object",
|
|
2453
|
+
"additionalProperties": true
|
|
2454
|
+
},
|
|
2455
|
+
"body": {
|
|
2456
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
2457
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/Error",
|
|
2458
|
+
"type": "object",
|
|
2459
|
+
"additionalProperties": false,
|
|
2460
|
+
"description": "Server error message",
|
|
2461
|
+
"properties": {
|
|
2462
|
+
"message": {
|
|
2463
|
+
"type": "string"
|
|
2464
|
+
},
|
|
2465
|
+
"code": {
|
|
2466
|
+
"type": "string"
|
|
2467
|
+
}
|
|
2468
|
+
}
|
|
2469
|
+
}
|
|
2470
|
+
},
|
|
2471
|
+
"required": ["body"],
|
|
2472
|
+
"additionalProperties": false
|
|
2473
|
+
}
|
|
2474
|
+
}
|
|
2475
|
+
}
|
|
2476
|
+
},
|
|
2477
|
+
"/payment-card/v1/card/:cardId/lock/:lockStatus": {
|
|
2478
|
+
"put": {
|
|
2479
|
+
"request": {
|
|
2480
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
2481
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/api/CardLockPutRequestContext",
|
|
2482
|
+
"type": "object",
|
|
2483
|
+
"properties": {
|
|
2484
|
+
"params": {
|
|
2485
|
+
"type": "object",
|
|
2486
|
+
"additionalProperties": false,
|
|
2487
|
+
"properties": {
|
|
2488
|
+
"cardId": {
|
|
2489
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
2490
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/CardId",
|
|
2491
|
+
"type": "string",
|
|
2492
|
+
"description": "Card identifier",
|
|
2493
|
+
"format": "uuid"
|
|
2494
|
+
},
|
|
2495
|
+
"lockStatus": {
|
|
2496
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
2497
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/LockStatus",
|
|
2498
|
+
"type": "string",
|
|
2499
|
+
"description": "A cardholder initiated status. A locked card will fail authorization. Locked cards can be unlocked.\n\nA cardholder may choose to lock a card while temporarily misplaced.\n",
|
|
2500
|
+
"enum": ["LOCKED", "UNLOCKED"]
|
|
2501
|
+
}
|
|
2502
|
+
},
|
|
2503
|
+
"required": ["cardId", "lockStatus"]
|
|
2504
|
+
},
|
|
2505
|
+
"headers": {
|
|
2506
|
+
"type": "object",
|
|
2507
|
+
"additionalProperties": true,
|
|
2508
|
+
"properties": {
|
|
2509
|
+
"created-on": {
|
|
2510
|
+
"type": "string",
|
|
2511
|
+
"format": "date-time"
|
|
2512
|
+
},
|
|
2513
|
+
"last-modified": {
|
|
2514
|
+
"type": "string",
|
|
2515
|
+
"format": "date-time"
|
|
2516
|
+
},
|
|
2517
|
+
"if-match": {
|
|
2518
|
+
"type": "string"
|
|
2519
|
+
}
|
|
2520
|
+
},
|
|
2521
|
+
"required": ["If-Match"]
|
|
2522
|
+
}
|
|
2523
|
+
},
|
|
2524
|
+
"required": ["params", "headers"],
|
|
2525
|
+
"additionalProperties": false
|
|
2526
|
+
},
|
|
2527
|
+
"responses": {
|
|
2528
|
+
"204": {
|
|
2529
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
2530
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/api/CardLockPutResponseNoContent",
|
|
2531
|
+
"type": "object",
|
|
2532
|
+
"properties": {
|
|
2533
|
+
"headers": {
|
|
2534
|
+
"type": "object",
|
|
2535
|
+
"properties": {
|
|
2536
|
+
"last-modified": {
|
|
2537
|
+
"type": "string",
|
|
2538
|
+
"format": "date-time"
|
|
2539
|
+
},
|
|
2540
|
+
"created-on": {
|
|
2541
|
+
"type": "string",
|
|
2542
|
+
"format": "date-time"
|
|
2543
|
+
},
|
|
2544
|
+
"updated-on": {
|
|
2545
|
+
"type": "string",
|
|
2546
|
+
"format": "date-time"
|
|
2547
|
+
},
|
|
2548
|
+
"etag": {
|
|
2549
|
+
"type": "string"
|
|
2550
|
+
}
|
|
2551
|
+
}
|
|
2552
|
+
}
|
|
2553
|
+
},
|
|
2554
|
+
"required": [],
|
|
2555
|
+
"additionalProperties": false
|
|
2556
|
+
},
|
|
2557
|
+
"409": {
|
|
2558
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
2559
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/api/CardLockPutResponseConflict",
|
|
2560
|
+
"type": "object",
|
|
2561
|
+
"properties": {
|
|
2562
|
+
"headers": {
|
|
2563
|
+
"type": "object",
|
|
2564
|
+
"additionalProperties": true
|
|
2565
|
+
}
|
|
2566
|
+
},
|
|
2567
|
+
"required": [],
|
|
2568
|
+
"additionalProperties": false
|
|
2569
|
+
},
|
|
2570
|
+
"412": {
|
|
2571
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
2572
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/api/CardLockPutResponsePreconditionFailed",
|
|
2573
|
+
"type": "object",
|
|
2574
|
+
"properties": {
|
|
2575
|
+
"headers": {
|
|
2576
|
+
"type": "object",
|
|
2577
|
+
"additionalProperties": true
|
|
2578
|
+
}
|
|
2579
|
+
},
|
|
2580
|
+
"required": [],
|
|
2581
|
+
"additionalProperties": false
|
|
2582
|
+
},
|
|
2583
|
+
"default": {
|
|
2584
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
2585
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/api/CardLockPutResponseDefault",
|
|
2586
|
+
"type": "object",
|
|
2587
|
+
"properties": {
|
|
2588
|
+
"headers": {
|
|
2589
|
+
"type": "object",
|
|
2590
|
+
"additionalProperties": true
|
|
2591
|
+
},
|
|
2592
|
+
"body": {
|
|
2593
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
2594
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/Error",
|
|
2595
|
+
"type": "object",
|
|
2596
|
+
"additionalProperties": false,
|
|
2597
|
+
"description": "Server error message",
|
|
2598
|
+
"properties": {
|
|
2599
|
+
"message": {
|
|
2600
|
+
"type": "string"
|
|
2601
|
+
},
|
|
2602
|
+
"code": {
|
|
2603
|
+
"type": "string"
|
|
2604
|
+
}
|
|
2605
|
+
}
|
|
2606
|
+
}
|
|
2607
|
+
},
|
|
2608
|
+
"required": ["body"],
|
|
2609
|
+
"additionalProperties": false
|
|
2610
|
+
}
|
|
2611
|
+
}
|
|
2612
|
+
}
|
|
2613
|
+
},
|
|
2614
|
+
"/payment-card/v1/card/:cardId/pin-offset": {
|
|
2615
|
+
"put": {
|
|
2616
|
+
"request": {
|
|
2617
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
2618
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/api/CardPinOffsetPutRequestContext",
|
|
2619
|
+
"type": "object",
|
|
2620
|
+
"properties": {
|
|
2621
|
+
"params": {
|
|
2622
|
+
"type": "object",
|
|
2623
|
+
"additionalProperties": false,
|
|
2624
|
+
"properties": {
|
|
2625
|
+
"cardId": {
|
|
2626
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
2627
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/CardId",
|
|
2628
|
+
"type": "string",
|
|
2629
|
+
"description": "Card identifier",
|
|
2630
|
+
"format": "uuid"
|
|
2631
|
+
}
|
|
2632
|
+
},
|
|
2633
|
+
"required": ["cardId"]
|
|
2634
|
+
},
|
|
2635
|
+
"headers": {
|
|
2636
|
+
"type": "object",
|
|
2637
|
+
"additionalProperties": true,
|
|
2638
|
+
"properties": {
|
|
2639
|
+
"created-on": {
|
|
2640
|
+
"type": "string",
|
|
2641
|
+
"format": "date-time"
|
|
2642
|
+
},
|
|
2643
|
+
"last-modified": {
|
|
2644
|
+
"type": "string",
|
|
2645
|
+
"format": "date-time"
|
|
2646
|
+
},
|
|
2647
|
+
"if-match": {
|
|
2648
|
+
"type": "string"
|
|
2649
|
+
}
|
|
2650
|
+
},
|
|
2651
|
+
"required": ["If-Match"]
|
|
2652
|
+
},
|
|
2653
|
+
"body": {
|
|
2654
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
2655
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/PinOffsetRequest",
|
|
2656
|
+
"type": "object",
|
|
2657
|
+
"additionalProperties": false,
|
|
2658
|
+
"required": ["encryptedDataEncryptionKey", "pinOffsetKeyId", "encryptedUserDefinedPin"],
|
|
2659
|
+
"properties": {
|
|
2660
|
+
"pinOffsetKeyId": {
|
|
2661
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
2662
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/PinOffsetKeyId",
|
|
2663
|
+
"type": "string",
|
|
2664
|
+
"format": "uuid",
|
|
2665
|
+
"description": "Identifier for the PinOffsetKey used to encrypt the data encryption key."
|
|
2666
|
+
},
|
|
2667
|
+
"encryptedDataEncryptionKey": {
|
|
2668
|
+
"description": "A RSA encrypted (using transmissionKey) data encryption key that encrypted the encryptedUserDefinedPin.",
|
|
2669
|
+
"type": "string"
|
|
2670
|
+
},
|
|
2671
|
+
"encryptedUserDefinedPin": {
|
|
2672
|
+
"type": "string",
|
|
2673
|
+
"description": "User Defined PIN encrypted with an AES generated data encryption key. This is the PIN to be used for new\noffset calculation. (plaintext pin has minLength = 4, maxLength = 12)\n"
|
|
2674
|
+
}
|
|
2675
|
+
}
|
|
2676
|
+
}
|
|
2677
|
+
},
|
|
2678
|
+
"required": ["params", "headers", "body"],
|
|
2679
|
+
"additionalProperties": false
|
|
2680
|
+
},
|
|
2681
|
+
"responses": {
|
|
2682
|
+
"204": {
|
|
2683
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
2684
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/api/CardPinOffsetPutResponseNoContent",
|
|
2685
|
+
"type": "object",
|
|
2686
|
+
"properties": {
|
|
2687
|
+
"headers": {
|
|
2688
|
+
"type": "object",
|
|
2689
|
+
"properties": {
|
|
2690
|
+
"last-modified": {
|
|
2691
|
+
"type": "string",
|
|
2692
|
+
"format": "date-time"
|
|
2693
|
+
},
|
|
2694
|
+
"created-on": {
|
|
2695
|
+
"type": "string",
|
|
2696
|
+
"format": "date-time"
|
|
2697
|
+
},
|
|
2698
|
+
"updated-on": {
|
|
2699
|
+
"type": "string",
|
|
2700
|
+
"format": "date-time"
|
|
2701
|
+
},
|
|
2702
|
+
"etag": {
|
|
2703
|
+
"type": "string"
|
|
2704
|
+
}
|
|
2705
|
+
}
|
|
2706
|
+
}
|
|
2707
|
+
},
|
|
2708
|
+
"required": [],
|
|
2709
|
+
"additionalProperties": false
|
|
2710
|
+
},
|
|
2711
|
+
"default": {
|
|
2712
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
2713
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/api/CardPinOffsetPutResponseDefault",
|
|
2714
|
+
"type": "object",
|
|
2715
|
+
"properties": {
|
|
2716
|
+
"headers": {
|
|
2717
|
+
"type": "object",
|
|
2718
|
+
"additionalProperties": true
|
|
2719
|
+
},
|
|
2720
|
+
"body": {
|
|
2721
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
2722
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/Error",
|
|
2723
|
+
"type": "object",
|
|
2724
|
+
"additionalProperties": false,
|
|
2725
|
+
"description": "Server error message",
|
|
2726
|
+
"properties": {
|
|
2727
|
+
"message": {
|
|
2728
|
+
"type": "string"
|
|
2729
|
+
},
|
|
2730
|
+
"code": {
|
|
2731
|
+
"type": "string"
|
|
2732
|
+
}
|
|
2733
|
+
}
|
|
2734
|
+
}
|
|
2735
|
+
},
|
|
2736
|
+
"required": ["body"],
|
|
2737
|
+
"additionalProperties": false
|
|
2738
|
+
}
|
|
2739
|
+
}
|
|
2740
|
+
}
|
|
2741
|
+
},
|
|
2742
|
+
"/payment-card/v1/card/:cardId/state/:stateStatus": {
|
|
2743
|
+
"put": {
|
|
2744
|
+
"request": {
|
|
2745
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
2746
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/api/CardStatePutRequestContext",
|
|
2747
|
+
"type": "object",
|
|
2748
|
+
"properties": {
|
|
2749
|
+
"params": {
|
|
2750
|
+
"type": "object",
|
|
2751
|
+
"additionalProperties": false,
|
|
2752
|
+
"properties": {
|
|
2753
|
+
"cardId": {
|
|
2754
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
2755
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/CardId",
|
|
2756
|
+
"type": "string",
|
|
2757
|
+
"description": "Card identifier",
|
|
2758
|
+
"format": "uuid"
|
|
2759
|
+
},
|
|
2760
|
+
"stateStatus": {
|
|
2761
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
2762
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/StateStatus",
|
|
2763
|
+
"description": "The current state of the card",
|
|
2764
|
+
"type": "string",
|
|
2765
|
+
"enum": ["CURRENT", "REISSUED", "RETIRED", "FORCED"]
|
|
2766
|
+
}
|
|
2767
|
+
},
|
|
2768
|
+
"required": ["cardId", "stateStatus"]
|
|
2769
|
+
},
|
|
2770
|
+
"headers": {
|
|
2771
|
+
"type": "object",
|
|
2772
|
+
"additionalProperties": true,
|
|
2773
|
+
"properties": {
|
|
2774
|
+
"created-on": {
|
|
2775
|
+
"type": "string",
|
|
2776
|
+
"format": "date-time"
|
|
2777
|
+
},
|
|
2778
|
+
"last-modified": {
|
|
2779
|
+
"type": "string",
|
|
2780
|
+
"format": "date-time"
|
|
2781
|
+
},
|
|
2782
|
+
"if-match": {
|
|
2783
|
+
"type": "string"
|
|
2784
|
+
}
|
|
2785
|
+
},
|
|
2786
|
+
"required": ["If-Match"]
|
|
2787
|
+
}
|
|
2788
|
+
},
|
|
2789
|
+
"required": ["params", "headers"],
|
|
2790
|
+
"additionalProperties": false
|
|
2791
|
+
},
|
|
2792
|
+
"responses": {
|
|
2793
|
+
"204": {
|
|
2794
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
2795
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/api/CardStatePutResponseNoContent",
|
|
2796
|
+
"type": "object",
|
|
2797
|
+
"properties": {
|
|
2798
|
+
"headers": {
|
|
2799
|
+
"type": "object",
|
|
2800
|
+
"properties": {
|
|
2801
|
+
"last-modified": {
|
|
2802
|
+
"type": "string",
|
|
2803
|
+
"format": "date-time"
|
|
2804
|
+
},
|
|
2805
|
+
"created-on": {
|
|
2806
|
+
"type": "string",
|
|
2807
|
+
"format": "date-time"
|
|
2808
|
+
},
|
|
2809
|
+
"updated-on": {
|
|
2810
|
+
"type": "string",
|
|
2811
|
+
"format": "date-time"
|
|
2812
|
+
},
|
|
2813
|
+
"etag": {
|
|
2814
|
+
"type": "string"
|
|
2815
|
+
}
|
|
2816
|
+
}
|
|
2817
|
+
}
|
|
2818
|
+
},
|
|
2819
|
+
"required": [],
|
|
2820
|
+
"additionalProperties": false
|
|
2821
|
+
},
|
|
2822
|
+
"409": {
|
|
2823
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
2824
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/api/CardStatePutResponseConflict",
|
|
2825
|
+
"type": "object",
|
|
2826
|
+
"properties": {
|
|
2827
|
+
"headers": {
|
|
2828
|
+
"type": "object",
|
|
2829
|
+
"additionalProperties": true
|
|
2830
|
+
}
|
|
2831
|
+
},
|
|
2832
|
+
"required": [],
|
|
2833
|
+
"additionalProperties": false
|
|
2834
|
+
},
|
|
2835
|
+
"412": {
|
|
2836
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
2837
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/api/CardStatePutResponsePreconditionFailed",
|
|
2838
|
+
"type": "object",
|
|
2839
|
+
"properties": {
|
|
2840
|
+
"headers": {
|
|
2841
|
+
"type": "object",
|
|
2842
|
+
"additionalProperties": true
|
|
2843
|
+
}
|
|
2844
|
+
},
|
|
2845
|
+
"required": [],
|
|
2846
|
+
"additionalProperties": false
|
|
2847
|
+
},
|
|
2848
|
+
"default": {
|
|
2849
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
2850
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/api/CardStatePutResponseDefault",
|
|
2851
|
+
"type": "object",
|
|
2852
|
+
"properties": {
|
|
2853
|
+
"headers": {
|
|
2854
|
+
"type": "object",
|
|
2855
|
+
"additionalProperties": true
|
|
2856
|
+
},
|
|
2857
|
+
"body": {
|
|
2858
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
2859
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/Error",
|
|
2860
|
+
"type": "object",
|
|
2861
|
+
"additionalProperties": false,
|
|
2862
|
+
"description": "Server error message",
|
|
2863
|
+
"properties": {
|
|
2864
|
+
"message": {
|
|
2865
|
+
"type": "string"
|
|
2866
|
+
},
|
|
2867
|
+
"code": {
|
|
2868
|
+
"type": "string"
|
|
2869
|
+
}
|
|
2870
|
+
}
|
|
2871
|
+
}
|
|
2872
|
+
},
|
|
2873
|
+
"required": ["body"],
|
|
2874
|
+
"additionalProperties": false
|
|
2875
|
+
}
|
|
2876
|
+
}
|
|
2877
|
+
}
|
|
2878
|
+
},
|
|
2879
|
+
"/payment-card/v1/card-number/:cardId/key/:publicKeyHashPath": {
|
|
2880
|
+
"put": {
|
|
2881
|
+
"request": {
|
|
2882
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
2883
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/api/CardNumberKeyPutRequestContext",
|
|
2884
|
+
"type": "object",
|
|
2885
|
+
"properties": {
|
|
2886
|
+
"params": {
|
|
2887
|
+
"type": "object",
|
|
2888
|
+
"additionalProperties": false,
|
|
2889
|
+
"properties": {
|
|
2890
|
+
"cardId": {
|
|
2891
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
2892
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/CardId",
|
|
2893
|
+
"type": "string",
|
|
2894
|
+
"description": "Card identifier",
|
|
2895
|
+
"format": "uuid"
|
|
2896
|
+
},
|
|
2897
|
+
"publicKeyHashPath": {
|
|
2898
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
2899
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/Hash",
|
|
2900
|
+
"type": "string",
|
|
2901
|
+
"format": "uuid",
|
|
2902
|
+
"example": "15a85f64-5717-4562-b3fc-2c963f66afa6",
|
|
2903
|
+
"description": "UUID derived using @checkdigit/hash"
|
|
2904
|
+
}
|
|
2905
|
+
},
|
|
2906
|
+
"required": ["cardId", "publicKeyHashPath"]
|
|
2907
|
+
},
|
|
2908
|
+
"headers": {
|
|
2909
|
+
"type": "object",
|
|
2910
|
+
"additionalProperties": true
|
|
2911
|
+
},
|
|
2912
|
+
"body": {
|
|
2913
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
2914
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/CardNumberRequest",
|
|
2915
|
+
"type": "object",
|
|
2916
|
+
"additionalProperties": false,
|
|
2917
|
+
"required": ["publicKey"],
|
|
2918
|
+
"properties": {
|
|
2919
|
+
"publicKey": {
|
|
2920
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
2921
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/PublicKey",
|
|
2922
|
+
"description": "Public key in PEM format",
|
|
2923
|
+
"type": "string",
|
|
2924
|
+
"example": "-----BEGIN PUBLIC KEY-----\nMIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAwm2sxmRdTF7ZIBA6+ngO\n8jOTCHmID0PpQB1q85+hrcLSfB1rWY9bzNNLabBo/ajDnA4Pcadq/x6gpg70qZcR\n9Wxm6TttKzBPZsxasGXgSTDqEi2KcYZgq1mL4qyxUvyIms7/llGy+W9b5huZaVcO\nxdT1tw/zctbOhb6S2t5vH+zkta/2ncUXjG7i8XdLsJ1qe4K1kYbA4KVkOMmAtw7O\n4STk0TZDD0YARdmrciorJjbIVt0Xj1CrYQ5QbDGrlfeXgrcZwX5f9wT2MnKlY5oZ\n5Wtb57oGtLkVf8g6vN/2jGtAmOmHK2hHwNd/+zUet5G/S5uwEli4RgMPP4pUoKgd\nGQIDAQAB\n-----END PUBLIC KEY-----\n"
|
|
2925
|
+
}
|
|
2926
|
+
}
|
|
2927
|
+
}
|
|
2928
|
+
},
|
|
2929
|
+
"required": ["params", "body"],
|
|
2930
|
+
"additionalProperties": false
|
|
2931
|
+
},
|
|
2932
|
+
"responses": {
|
|
2933
|
+
"200": {
|
|
2934
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
2935
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/api/CardNumberKeyPutResponseOK",
|
|
2936
|
+
"type": "object",
|
|
2937
|
+
"properties": {
|
|
2938
|
+
"headers": {
|
|
2939
|
+
"type": "object",
|
|
2940
|
+
"additionalProperties": true
|
|
2941
|
+
},
|
|
2942
|
+
"body": {
|
|
2943
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
2944
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/EncryptedCardNumber",
|
|
2945
|
+
"type": "object",
|
|
2946
|
+
"additionalProperties": false,
|
|
2947
|
+
"required": ["encryptedDataEncryptionKey", "cardNumber"],
|
|
2948
|
+
"properties": {
|
|
2949
|
+
"encryptedDataEncryptionKey": {
|
|
2950
|
+
"description": "RSA encrypted data encryption key used to AES encrypt cardNumber.",
|
|
2951
|
+
"type": "string"
|
|
2952
|
+
},
|
|
2953
|
+
"cardNumber": {
|
|
2954
|
+
"type": "string",
|
|
2955
|
+
"description": "AES-256 encrypted card number"
|
|
2956
|
+
}
|
|
2957
|
+
}
|
|
2958
|
+
}
|
|
2959
|
+
},
|
|
2960
|
+
"required": ["body"],
|
|
2961
|
+
"additionalProperties": false
|
|
2962
|
+
},
|
|
2963
|
+
"default": {
|
|
2964
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
2965
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/api/CardNumberKeyPutResponseDefault",
|
|
2966
|
+
"type": "object",
|
|
2967
|
+
"properties": {
|
|
2968
|
+
"headers": {
|
|
2969
|
+
"type": "object",
|
|
2970
|
+
"additionalProperties": true
|
|
2971
|
+
},
|
|
2972
|
+
"body": {
|
|
2973
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
2974
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/Error",
|
|
2975
|
+
"type": "object",
|
|
2976
|
+
"additionalProperties": false,
|
|
2977
|
+
"description": "Server error message",
|
|
2978
|
+
"properties": {
|
|
2979
|
+
"message": {
|
|
2980
|
+
"type": "string"
|
|
2981
|
+
},
|
|
2982
|
+
"code": {
|
|
2983
|
+
"type": "string"
|
|
2984
|
+
}
|
|
2985
|
+
}
|
|
2986
|
+
}
|
|
2987
|
+
},
|
|
2988
|
+
"required": ["body"],
|
|
2989
|
+
"additionalProperties": false
|
|
2990
|
+
}
|
|
2991
|
+
}
|
|
2992
|
+
}
|
|
2993
|
+
},
|
|
2994
|
+
"/payment-card/v1/pin-offset-key/:pinOffsetKeyId": {
|
|
2995
|
+
"put": {
|
|
2996
|
+
"request": {
|
|
2997
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
2998
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/api/PinOffsetKeyPutRequestContext",
|
|
2999
|
+
"type": "object",
|
|
3000
|
+
"properties": {
|
|
3001
|
+
"params": {
|
|
3002
|
+
"type": "object",
|
|
3003
|
+
"additionalProperties": false,
|
|
3004
|
+
"properties": {
|
|
3005
|
+
"pinOffsetKeyId": {
|
|
3006
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3007
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/PinOffsetKeyId",
|
|
3008
|
+
"type": "string",
|
|
3009
|
+
"format": "uuid",
|
|
3010
|
+
"description": "Identifier for the PinOffsetKey used to encrypt the data encryption key."
|
|
3011
|
+
}
|
|
3012
|
+
},
|
|
3013
|
+
"required": ["pinOffsetKeyId"]
|
|
3014
|
+
},
|
|
3015
|
+
"headers": {
|
|
3016
|
+
"type": "object",
|
|
3017
|
+
"additionalProperties": true
|
|
3018
|
+
}
|
|
3019
|
+
},
|
|
3020
|
+
"required": ["params"],
|
|
3021
|
+
"additionalProperties": false
|
|
3022
|
+
},
|
|
3023
|
+
"responses": {
|
|
3024
|
+
"200": {
|
|
3025
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3026
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/api/PinOffsetKeyPutResponseOK",
|
|
3027
|
+
"type": "object",
|
|
3028
|
+
"properties": {
|
|
3029
|
+
"headers": {
|
|
3030
|
+
"type": "object",
|
|
3031
|
+
"additionalProperties": true
|
|
3032
|
+
},
|
|
3033
|
+
"body": {
|
|
3034
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3035
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/PinOffsetKey",
|
|
3036
|
+
"type": "object",
|
|
3037
|
+
"additionalProperties": false,
|
|
3038
|
+
"required": ["transmissionKey"],
|
|
3039
|
+
"properties": {
|
|
3040
|
+
"transmissionKey": {
|
|
3041
|
+
"description": "A PEM formatted public key to be used to RSA encrypt a data encryption key.",
|
|
3042
|
+
"type": "string"
|
|
3043
|
+
}
|
|
3044
|
+
}
|
|
3045
|
+
}
|
|
3046
|
+
},
|
|
3047
|
+
"required": ["body"],
|
|
3048
|
+
"additionalProperties": false
|
|
3049
|
+
},
|
|
3050
|
+
"default": {
|
|
3051
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3052
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/api/PinOffsetKeyPutResponseDefault",
|
|
3053
|
+
"type": "object",
|
|
3054
|
+
"properties": {
|
|
3055
|
+
"headers": {
|
|
3056
|
+
"type": "object",
|
|
3057
|
+
"additionalProperties": true
|
|
3058
|
+
},
|
|
3059
|
+
"body": {
|
|
3060
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3061
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/Error",
|
|
3062
|
+
"type": "object",
|
|
3063
|
+
"additionalProperties": false,
|
|
3064
|
+
"description": "Server error message",
|
|
3065
|
+
"properties": {
|
|
3066
|
+
"message": {
|
|
3067
|
+
"type": "string"
|
|
3068
|
+
},
|
|
3069
|
+
"code": {
|
|
3070
|
+
"type": "string"
|
|
3071
|
+
}
|
|
3072
|
+
}
|
|
3073
|
+
}
|
|
3074
|
+
},
|
|
3075
|
+
"required": ["body"],
|
|
3076
|
+
"additionalProperties": false
|
|
3077
|
+
}
|
|
3078
|
+
}
|
|
3079
|
+
}
|
|
3080
|
+
}
|
|
3081
|
+
},
|
|
3082
|
+
"definitions": {
|
|
3083
|
+
"ActiveStatus": {
|
|
3084
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3085
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/ActiveStatus",
|
|
3086
|
+
"description": "The active/inactive status for the card",
|
|
3087
|
+
"type": "string",
|
|
3088
|
+
"enum": ["INACTIVE", "ACTIVE"]
|
|
3089
|
+
},
|
|
3090
|
+
"Bin": {
|
|
3091
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3092
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/Bin",
|
|
3093
|
+
"type": "string",
|
|
3094
|
+
"pattern": "^\\d+$",
|
|
3095
|
+
"description": "Bank Identification Number",
|
|
3096
|
+
"minLength": 6,
|
|
3097
|
+
"maxLength": 8
|
|
3098
|
+
},
|
|
3099
|
+
"BlockStatus": {
|
|
3100
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3101
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/BlockStatus",
|
|
3102
|
+
"type": "string",
|
|
3103
|
+
"description": "Whether the card is open or blocked for various reasons",
|
|
3104
|
+
"enum": ["OPEN", "BLOCKED LOST OR STOLEN", "BLOCKED NO FRAUD", "BLOCKED WITH FRAUD"]
|
|
3105
|
+
},
|
|
3106
|
+
"Card": {
|
|
3107
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3108
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/Card",
|
|
3109
|
+
"type": "object",
|
|
3110
|
+
"additionalProperties": false,
|
|
3111
|
+
"required": [
|
|
3112
|
+
"bin",
|
|
3113
|
+
"last4",
|
|
3114
|
+
"expirationDate",
|
|
3115
|
+
"cardNumber",
|
|
3116
|
+
"serviceCode",
|
|
3117
|
+
"pinOffset",
|
|
3118
|
+
"applicationTransactionCounter",
|
|
3119
|
+
"sequenceNumber",
|
|
3120
|
+
"state",
|
|
3121
|
+
"active",
|
|
3122
|
+
"block",
|
|
3123
|
+
"lock",
|
|
3124
|
+
"capture",
|
|
3125
|
+
"createdOn",
|
|
3126
|
+
"updatedOn",
|
|
3127
|
+
"lastModified"
|
|
3128
|
+
],
|
|
3129
|
+
"properties": {
|
|
3130
|
+
"bin": {
|
|
3131
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3132
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/Bin",
|
|
3133
|
+
"type": "string",
|
|
3134
|
+
"pattern": "^\\d+$",
|
|
3135
|
+
"description": "Bank Identification Number",
|
|
3136
|
+
"minLength": 6,
|
|
3137
|
+
"maxLength": 8
|
|
3138
|
+
},
|
|
3139
|
+
"last4": {
|
|
3140
|
+
"type": "string",
|
|
3141
|
+
"pattern": "^\\d+$",
|
|
3142
|
+
"description": "Last four digits of the card number",
|
|
3143
|
+
"minLength": 4,
|
|
3144
|
+
"maxLength": 4
|
|
3145
|
+
},
|
|
3146
|
+
"expirationDate": {
|
|
3147
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3148
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/ExpirationDate",
|
|
3149
|
+
"type": "string",
|
|
3150
|
+
"pattern": "([0-9][0-9])(0[1-9]|1[0-2])",
|
|
3151
|
+
"format": "YYMM",
|
|
3152
|
+
"description": "Expiration date for the card and will be assumed to be the last millisecond of the month",
|
|
3153
|
+
"minLength": 4,
|
|
3154
|
+
"maxLength": 4
|
|
3155
|
+
},
|
|
3156
|
+
"cardNumber": {
|
|
3157
|
+
"type": "string",
|
|
3158
|
+
"description": "Encrypted card number (PAN)"
|
|
3159
|
+
},
|
|
3160
|
+
"serviceCode": {
|
|
3161
|
+
"type": "string",
|
|
3162
|
+
"pattern": "^\\d+$",
|
|
3163
|
+
"description": "Service code for the card",
|
|
3164
|
+
"minLength": 3,
|
|
3165
|
+
"maxLength": 3
|
|
3166
|
+
},
|
|
3167
|
+
"pinOffset": {
|
|
3168
|
+
"type": "string",
|
|
3169
|
+
"description": "Encrypted pin offset for the card"
|
|
3170
|
+
},
|
|
3171
|
+
"applicationTransactionCounter": {
|
|
3172
|
+
"type": "integer",
|
|
3173
|
+
"description": "Application transaction counter (ATC) for the card"
|
|
3174
|
+
},
|
|
3175
|
+
"sequenceNumber": {
|
|
3176
|
+
"type": "integer",
|
|
3177
|
+
"description": "Used to differentiate issuing the same card and expiration date on multiple plastics"
|
|
3178
|
+
},
|
|
3179
|
+
"state": {
|
|
3180
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3181
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/StateStatus",
|
|
3182
|
+
"description": "The current state of the card",
|
|
3183
|
+
"type": "string",
|
|
3184
|
+
"enum": ["CURRENT", "REISSUED", "RETIRED", "FORCED"]
|
|
3185
|
+
},
|
|
3186
|
+
"active": {
|
|
3187
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3188
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/ActiveStatus",
|
|
3189
|
+
"description": "The active/inactive status for the card",
|
|
3190
|
+
"type": "string",
|
|
3191
|
+
"enum": ["INACTIVE", "ACTIVE"]
|
|
3192
|
+
},
|
|
3193
|
+
"block": {
|
|
3194
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3195
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/BlockStatus",
|
|
3196
|
+
"type": "string",
|
|
3197
|
+
"description": "Whether the card is open or blocked for various reasons",
|
|
3198
|
+
"enum": ["OPEN", "BLOCKED LOST OR STOLEN", "BLOCKED NO FRAUD", "BLOCKED WITH FRAUD"]
|
|
3199
|
+
},
|
|
3200
|
+
"lock": {
|
|
3201
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3202
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/LockStatus",
|
|
3203
|
+
"type": "string",
|
|
3204
|
+
"description": "A cardholder initiated status. A locked card will fail authorization. Locked cards can be unlocked.\n\nA cardholder may choose to lock a card while temporarily misplaced.\n",
|
|
3205
|
+
"enum": ["LOCKED", "UNLOCKED"]
|
|
3206
|
+
},
|
|
3207
|
+
"capture": {
|
|
3208
|
+
"type": "boolean",
|
|
3209
|
+
"description": "Whether the card should be captured at next use"
|
|
3210
|
+
},
|
|
3211
|
+
"updatedOn": {
|
|
3212
|
+
"type": "string",
|
|
3213
|
+
"description": "Time data was last updated",
|
|
3214
|
+
"format": "date-time"
|
|
3215
|
+
},
|
|
3216
|
+
"lastModified": {
|
|
3217
|
+
"type": "string",
|
|
3218
|
+
"description": "Time data was last modified (Deprecated. Use updatedOn)",
|
|
3219
|
+
"format": "date-time"
|
|
3220
|
+
},
|
|
3221
|
+
"createdOn": {
|
|
3222
|
+
"description": "Time encrypted data was first stored",
|
|
3223
|
+
"type": "string",
|
|
3224
|
+
"format": "date-time"
|
|
3225
|
+
}
|
|
3226
|
+
}
|
|
3227
|
+
},
|
|
3228
|
+
"CardResponse": {
|
|
3229
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3230
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/CardResponse",
|
|
3231
|
+
"type": "object",
|
|
3232
|
+
"additionalProperties": false,
|
|
3233
|
+
"required": ["dataEncryptionKeyId", "storageKeyId", "card"],
|
|
3234
|
+
"properties": {
|
|
3235
|
+
"dataEncryptionKeyId": {
|
|
3236
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3237
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/DataEncryptionKeyId",
|
|
3238
|
+
"type": "string",
|
|
3239
|
+
"description": "Reference to encryption keys Payment Card Service will use to encrypt the Card object.\n",
|
|
3240
|
+
"format": "uuid"
|
|
3241
|
+
},
|
|
3242
|
+
"storageKeyId": {
|
|
3243
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3244
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/StorageKeyId",
|
|
3245
|
+
"type": "string",
|
|
3246
|
+
"description": "DEK's non-derived identifier to be used by Check Digit services only.\n"
|
|
3247
|
+
},
|
|
3248
|
+
"encryptedDataEncryptionKey": {
|
|
3249
|
+
"description": "Encrypted DEK matching the publicKeyHash sent in the request. Used to decrypt values in the Card object.\n",
|
|
3250
|
+
"type": "string"
|
|
3251
|
+
},
|
|
3252
|
+
"card": {
|
|
3253
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3254
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/Card",
|
|
3255
|
+
"type": "object",
|
|
3256
|
+
"additionalProperties": false,
|
|
3257
|
+
"required": [
|
|
3258
|
+
"bin",
|
|
3259
|
+
"last4",
|
|
3260
|
+
"expirationDate",
|
|
3261
|
+
"cardNumber",
|
|
3262
|
+
"serviceCode",
|
|
3263
|
+
"pinOffset",
|
|
3264
|
+
"applicationTransactionCounter",
|
|
3265
|
+
"sequenceNumber",
|
|
3266
|
+
"state",
|
|
3267
|
+
"active",
|
|
3268
|
+
"block",
|
|
3269
|
+
"lock",
|
|
3270
|
+
"capture",
|
|
3271
|
+
"createdOn",
|
|
3272
|
+
"updatedOn",
|
|
3273
|
+
"lastModified"
|
|
3274
|
+
],
|
|
3275
|
+
"properties": {
|
|
3276
|
+
"bin": {
|
|
3277
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3278
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/Bin",
|
|
3279
|
+
"type": "string",
|
|
3280
|
+
"pattern": "^\\d+$",
|
|
3281
|
+
"description": "Bank Identification Number",
|
|
3282
|
+
"minLength": 6,
|
|
3283
|
+
"maxLength": 8
|
|
3284
|
+
},
|
|
3285
|
+
"last4": {
|
|
3286
|
+
"type": "string",
|
|
3287
|
+
"pattern": "^\\d+$",
|
|
3288
|
+
"description": "Last four digits of the card number",
|
|
3289
|
+
"minLength": 4,
|
|
3290
|
+
"maxLength": 4
|
|
3291
|
+
},
|
|
3292
|
+
"expirationDate": {
|
|
3293
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3294
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/ExpirationDate",
|
|
3295
|
+
"type": "string",
|
|
3296
|
+
"pattern": "([0-9][0-9])(0[1-9]|1[0-2])",
|
|
3297
|
+
"format": "YYMM",
|
|
3298
|
+
"description": "Expiration date for the card and will be assumed to be the last millisecond of the month",
|
|
3299
|
+
"minLength": 4,
|
|
3300
|
+
"maxLength": 4
|
|
3301
|
+
},
|
|
3302
|
+
"cardNumber": {
|
|
3303
|
+
"type": "string",
|
|
3304
|
+
"description": "Encrypted card number (PAN)"
|
|
3305
|
+
},
|
|
3306
|
+
"serviceCode": {
|
|
3307
|
+
"type": "string",
|
|
3308
|
+
"pattern": "^\\d+$",
|
|
3309
|
+
"description": "Service code for the card",
|
|
3310
|
+
"minLength": 3,
|
|
3311
|
+
"maxLength": 3
|
|
3312
|
+
},
|
|
3313
|
+
"pinOffset": {
|
|
3314
|
+
"type": "string",
|
|
3315
|
+
"description": "Encrypted pin offset for the card"
|
|
3316
|
+
},
|
|
3317
|
+
"applicationTransactionCounter": {
|
|
3318
|
+
"type": "integer",
|
|
3319
|
+
"description": "Application transaction counter (ATC) for the card"
|
|
3320
|
+
},
|
|
3321
|
+
"sequenceNumber": {
|
|
3322
|
+
"type": "integer",
|
|
3323
|
+
"description": "Used to differentiate issuing the same card and expiration date on multiple plastics"
|
|
3324
|
+
},
|
|
3325
|
+
"state": {
|
|
3326
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3327
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/StateStatus",
|
|
3328
|
+
"description": "The current state of the card",
|
|
3329
|
+
"type": "string",
|
|
3330
|
+
"enum": ["CURRENT", "REISSUED", "RETIRED", "FORCED"]
|
|
3331
|
+
},
|
|
3332
|
+
"active": {
|
|
3333
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3334
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/ActiveStatus",
|
|
3335
|
+
"description": "The active/inactive status for the card",
|
|
3336
|
+
"type": "string",
|
|
3337
|
+
"enum": ["INACTIVE", "ACTIVE"]
|
|
3338
|
+
},
|
|
3339
|
+
"block": {
|
|
3340
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3341
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/BlockStatus",
|
|
3342
|
+
"type": "string",
|
|
3343
|
+
"description": "Whether the card is open or blocked for various reasons",
|
|
3344
|
+
"enum": ["OPEN", "BLOCKED LOST OR STOLEN", "BLOCKED NO FRAUD", "BLOCKED WITH FRAUD"]
|
|
3345
|
+
},
|
|
3346
|
+
"lock": {
|
|
3347
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3348
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/LockStatus",
|
|
3349
|
+
"type": "string",
|
|
3350
|
+
"description": "A cardholder initiated status. A locked card will fail authorization. Locked cards can be unlocked.\n\nA cardholder may choose to lock a card while temporarily misplaced.\n",
|
|
3351
|
+
"enum": ["LOCKED", "UNLOCKED"]
|
|
3352
|
+
},
|
|
3353
|
+
"capture": {
|
|
3354
|
+
"type": "boolean",
|
|
3355
|
+
"description": "Whether the card should be captured at next use"
|
|
3356
|
+
},
|
|
3357
|
+
"updatedOn": {
|
|
3358
|
+
"type": "string",
|
|
3359
|
+
"description": "Time data was last updated",
|
|
3360
|
+
"format": "date-time"
|
|
3361
|
+
},
|
|
3362
|
+
"lastModified": {
|
|
3363
|
+
"type": "string",
|
|
3364
|
+
"description": "Time data was last modified (Deprecated. Use updatedOn)",
|
|
3365
|
+
"format": "date-time"
|
|
3366
|
+
},
|
|
3367
|
+
"createdOn": {
|
|
3368
|
+
"description": "Time encrypted data was first stored",
|
|
3369
|
+
"type": "string",
|
|
3370
|
+
"format": "date-time"
|
|
3371
|
+
}
|
|
3372
|
+
}
|
|
3373
|
+
}
|
|
3374
|
+
}
|
|
3375
|
+
},
|
|
3376
|
+
"CardQueryResponse": {
|
|
3377
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3378
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/CardQueryResponse",
|
|
3379
|
+
"type": "object",
|
|
3380
|
+
"additionalProperties": false,
|
|
3381
|
+
"required": ["dataEncryptionKeyId", "storageKeyId", "cardId", "card"],
|
|
3382
|
+
"properties": {
|
|
3383
|
+
"dataEncryptionKeyId": {
|
|
3384
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3385
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/DataEncryptionKeyId",
|
|
3386
|
+
"type": "string",
|
|
3387
|
+
"description": "Reference to encryption keys Payment Card Service will use to encrypt the Card object.\n",
|
|
3388
|
+
"format": "uuid"
|
|
3389
|
+
},
|
|
3390
|
+
"storageKeyId": {
|
|
3391
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3392
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/StorageKeyId",
|
|
3393
|
+
"type": "string",
|
|
3394
|
+
"description": "DEK's non-derived identifier to be used by Check Digit services only.\n"
|
|
3395
|
+
},
|
|
3396
|
+
"encryptedDataEncryptionKey": {
|
|
3397
|
+
"description": "Encrypted DEK matching the publicKeyHash sent in the request. Used to decrypt values in the Card object.\n",
|
|
3398
|
+
"type": "string"
|
|
3399
|
+
},
|
|
3400
|
+
"cardId": {
|
|
3401
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3402
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/CardId",
|
|
3403
|
+
"type": "string",
|
|
3404
|
+
"description": "Card identifier",
|
|
3405
|
+
"format": "uuid"
|
|
3406
|
+
},
|
|
3407
|
+
"card": {
|
|
3408
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3409
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/Card",
|
|
3410
|
+
"type": "object",
|
|
3411
|
+
"additionalProperties": false,
|
|
3412
|
+
"required": [
|
|
3413
|
+
"bin",
|
|
3414
|
+
"last4",
|
|
3415
|
+
"expirationDate",
|
|
3416
|
+
"cardNumber",
|
|
3417
|
+
"serviceCode",
|
|
3418
|
+
"pinOffset",
|
|
3419
|
+
"applicationTransactionCounter",
|
|
3420
|
+
"sequenceNumber",
|
|
3421
|
+
"state",
|
|
3422
|
+
"active",
|
|
3423
|
+
"block",
|
|
3424
|
+
"lock",
|
|
3425
|
+
"capture",
|
|
3426
|
+
"createdOn",
|
|
3427
|
+
"updatedOn",
|
|
3428
|
+
"lastModified"
|
|
3429
|
+
],
|
|
3430
|
+
"properties": {
|
|
3431
|
+
"bin": {
|
|
3432
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3433
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/Bin",
|
|
3434
|
+
"type": "string",
|
|
3435
|
+
"pattern": "^\\d+$",
|
|
3436
|
+
"description": "Bank Identification Number",
|
|
3437
|
+
"minLength": 6,
|
|
3438
|
+
"maxLength": 8
|
|
3439
|
+
},
|
|
3440
|
+
"last4": {
|
|
3441
|
+
"type": "string",
|
|
3442
|
+
"pattern": "^\\d+$",
|
|
3443
|
+
"description": "Last four digits of the card number",
|
|
3444
|
+
"minLength": 4,
|
|
3445
|
+
"maxLength": 4
|
|
3446
|
+
},
|
|
3447
|
+
"expirationDate": {
|
|
3448
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3449
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/ExpirationDate",
|
|
3450
|
+
"type": "string",
|
|
3451
|
+
"pattern": "([0-9][0-9])(0[1-9]|1[0-2])",
|
|
3452
|
+
"format": "YYMM",
|
|
3453
|
+
"description": "Expiration date for the card and will be assumed to be the last millisecond of the month",
|
|
3454
|
+
"minLength": 4,
|
|
3455
|
+
"maxLength": 4
|
|
3456
|
+
},
|
|
3457
|
+
"cardNumber": {
|
|
3458
|
+
"type": "string",
|
|
3459
|
+
"description": "Encrypted card number (PAN)"
|
|
3460
|
+
},
|
|
3461
|
+
"serviceCode": {
|
|
3462
|
+
"type": "string",
|
|
3463
|
+
"pattern": "^\\d+$",
|
|
3464
|
+
"description": "Service code for the card",
|
|
3465
|
+
"minLength": 3,
|
|
3466
|
+
"maxLength": 3
|
|
3467
|
+
},
|
|
3468
|
+
"pinOffset": {
|
|
3469
|
+
"type": "string",
|
|
3470
|
+
"description": "Encrypted pin offset for the card"
|
|
3471
|
+
},
|
|
3472
|
+
"applicationTransactionCounter": {
|
|
3473
|
+
"type": "integer",
|
|
3474
|
+
"description": "Application transaction counter (ATC) for the card"
|
|
3475
|
+
},
|
|
3476
|
+
"sequenceNumber": {
|
|
3477
|
+
"type": "integer",
|
|
3478
|
+
"description": "Used to differentiate issuing the same card and expiration date on multiple plastics"
|
|
3479
|
+
},
|
|
3480
|
+
"state": {
|
|
3481
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3482
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/StateStatus",
|
|
3483
|
+
"description": "The current state of the card",
|
|
3484
|
+
"type": "string",
|
|
3485
|
+
"enum": ["CURRENT", "REISSUED", "RETIRED", "FORCED"]
|
|
3486
|
+
},
|
|
3487
|
+
"active": {
|
|
3488
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3489
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/ActiveStatus",
|
|
3490
|
+
"description": "The active/inactive status for the card",
|
|
3491
|
+
"type": "string",
|
|
3492
|
+
"enum": ["INACTIVE", "ACTIVE"]
|
|
3493
|
+
},
|
|
3494
|
+
"block": {
|
|
3495
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3496
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/BlockStatus",
|
|
3497
|
+
"type": "string",
|
|
3498
|
+
"description": "Whether the card is open or blocked for various reasons",
|
|
3499
|
+
"enum": ["OPEN", "BLOCKED LOST OR STOLEN", "BLOCKED NO FRAUD", "BLOCKED WITH FRAUD"]
|
|
3500
|
+
},
|
|
3501
|
+
"lock": {
|
|
3502
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3503
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/LockStatus",
|
|
3504
|
+
"type": "string",
|
|
3505
|
+
"description": "A cardholder initiated status. A locked card will fail authorization. Locked cards can be unlocked.\n\nA cardholder may choose to lock a card while temporarily misplaced.\n",
|
|
3506
|
+
"enum": ["LOCKED", "UNLOCKED"]
|
|
3507
|
+
},
|
|
3508
|
+
"capture": {
|
|
3509
|
+
"type": "boolean",
|
|
3510
|
+
"description": "Whether the card should be captured at next use"
|
|
3511
|
+
},
|
|
3512
|
+
"updatedOn": {
|
|
3513
|
+
"type": "string",
|
|
3514
|
+
"description": "Time data was last updated",
|
|
3515
|
+
"format": "date-time"
|
|
3516
|
+
},
|
|
3517
|
+
"lastModified": {
|
|
3518
|
+
"type": "string",
|
|
3519
|
+
"description": "Time data was last modified (Deprecated. Use updatedOn)",
|
|
3520
|
+
"format": "date-time"
|
|
3521
|
+
},
|
|
3522
|
+
"createdOn": {
|
|
3523
|
+
"description": "Time encrypted data was first stored",
|
|
3524
|
+
"type": "string",
|
|
3525
|
+
"format": "date-time"
|
|
3526
|
+
}
|
|
3527
|
+
}
|
|
3528
|
+
}
|
|
3529
|
+
}
|
|
3530
|
+
},
|
|
3531
|
+
"CardId": {
|
|
3532
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3533
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/CardId",
|
|
3534
|
+
"type": "string",
|
|
3535
|
+
"description": "Card identifier",
|
|
3536
|
+
"format": "uuid"
|
|
3537
|
+
},
|
|
3538
|
+
"Query": {
|
|
3539
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3540
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/Query",
|
|
3541
|
+
"description": "Response from querying /card by cardNumberHash",
|
|
3542
|
+
"type": "object",
|
|
3543
|
+
"required": ["cards"],
|
|
3544
|
+
"properties": {
|
|
3545
|
+
"cards": {
|
|
3546
|
+
"type": "array",
|
|
3547
|
+
"items": {
|
|
3548
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3549
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/CardQueryResponse",
|
|
3550
|
+
"type": "object",
|
|
3551
|
+
"additionalProperties": false,
|
|
3552
|
+
"required": ["dataEncryptionKeyId", "storageKeyId", "cardId", "card"],
|
|
3553
|
+
"properties": {
|
|
3554
|
+
"dataEncryptionKeyId": {
|
|
3555
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3556
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/DataEncryptionKeyId",
|
|
3557
|
+
"type": "string",
|
|
3558
|
+
"description": "Reference to encryption keys Payment Card Service will use to encrypt the Card object.\n",
|
|
3559
|
+
"format": "uuid"
|
|
3560
|
+
},
|
|
3561
|
+
"storageKeyId": {
|
|
3562
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3563
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/StorageKeyId",
|
|
3564
|
+
"type": "string",
|
|
3565
|
+
"description": "DEK's non-derived identifier to be used by Check Digit services only.\n"
|
|
3566
|
+
},
|
|
3567
|
+
"encryptedDataEncryptionKey": {
|
|
3568
|
+
"description": "Encrypted DEK matching the publicKeyHash sent in the request. Used to decrypt values in the Card object.\n",
|
|
3569
|
+
"type": "string"
|
|
3570
|
+
},
|
|
3571
|
+
"cardId": {
|
|
3572
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3573
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/CardId",
|
|
3574
|
+
"type": "string",
|
|
3575
|
+
"description": "Card identifier",
|
|
3576
|
+
"format": "uuid"
|
|
3577
|
+
},
|
|
3578
|
+
"card": {
|
|
3579
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3580
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/Card",
|
|
3581
|
+
"type": "object",
|
|
3582
|
+
"additionalProperties": false,
|
|
3583
|
+
"required": [
|
|
3584
|
+
"bin",
|
|
3585
|
+
"last4",
|
|
3586
|
+
"expirationDate",
|
|
3587
|
+
"cardNumber",
|
|
3588
|
+
"serviceCode",
|
|
3589
|
+
"pinOffset",
|
|
3590
|
+
"applicationTransactionCounter",
|
|
3591
|
+
"sequenceNumber",
|
|
3592
|
+
"state",
|
|
3593
|
+
"active",
|
|
3594
|
+
"block",
|
|
3595
|
+
"lock",
|
|
3596
|
+
"capture",
|
|
3597
|
+
"createdOn",
|
|
3598
|
+
"updatedOn",
|
|
3599
|
+
"lastModified"
|
|
3600
|
+
],
|
|
3601
|
+
"properties": {
|
|
3602
|
+
"bin": {
|
|
3603
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3604
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/Bin",
|
|
3605
|
+
"type": "string",
|
|
3606
|
+
"pattern": "^\\d+$",
|
|
3607
|
+
"description": "Bank Identification Number",
|
|
3608
|
+
"minLength": 6,
|
|
3609
|
+
"maxLength": 8
|
|
3610
|
+
},
|
|
3611
|
+
"last4": {
|
|
3612
|
+
"type": "string",
|
|
3613
|
+
"pattern": "^\\d+$",
|
|
3614
|
+
"description": "Last four digits of the card number",
|
|
3615
|
+
"minLength": 4,
|
|
3616
|
+
"maxLength": 4
|
|
3617
|
+
},
|
|
3618
|
+
"expirationDate": {
|
|
3619
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3620
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/ExpirationDate",
|
|
3621
|
+
"type": "string",
|
|
3622
|
+
"pattern": "([0-9][0-9])(0[1-9]|1[0-2])",
|
|
3623
|
+
"format": "YYMM",
|
|
3624
|
+
"description": "Expiration date for the card and will be assumed to be the last millisecond of the month",
|
|
3625
|
+
"minLength": 4,
|
|
3626
|
+
"maxLength": 4
|
|
3627
|
+
},
|
|
3628
|
+
"cardNumber": {
|
|
3629
|
+
"type": "string",
|
|
3630
|
+
"description": "Encrypted card number (PAN)"
|
|
3631
|
+
},
|
|
3632
|
+
"serviceCode": {
|
|
3633
|
+
"type": "string",
|
|
3634
|
+
"pattern": "^\\d+$",
|
|
3635
|
+
"description": "Service code for the card",
|
|
3636
|
+
"minLength": 3,
|
|
3637
|
+
"maxLength": 3
|
|
3638
|
+
},
|
|
3639
|
+
"pinOffset": {
|
|
3640
|
+
"type": "string",
|
|
3641
|
+
"description": "Encrypted pin offset for the card"
|
|
3642
|
+
},
|
|
3643
|
+
"applicationTransactionCounter": {
|
|
3644
|
+
"type": "integer",
|
|
3645
|
+
"description": "Application transaction counter (ATC) for the card"
|
|
3646
|
+
},
|
|
3647
|
+
"sequenceNumber": {
|
|
3648
|
+
"type": "integer",
|
|
3649
|
+
"description": "Used to differentiate issuing the same card and expiration date on multiple plastics"
|
|
3650
|
+
},
|
|
3651
|
+
"state": {
|
|
3652
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3653
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/StateStatus",
|
|
3654
|
+
"description": "The current state of the card",
|
|
3655
|
+
"type": "string",
|
|
3656
|
+
"enum": ["CURRENT", "REISSUED", "RETIRED", "FORCED"]
|
|
3657
|
+
},
|
|
3658
|
+
"active": {
|
|
3659
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3660
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/ActiveStatus",
|
|
3661
|
+
"description": "The active/inactive status for the card",
|
|
3662
|
+
"type": "string",
|
|
3663
|
+
"enum": ["INACTIVE", "ACTIVE"]
|
|
3664
|
+
},
|
|
3665
|
+
"block": {
|
|
3666
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3667
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/BlockStatus",
|
|
3668
|
+
"type": "string",
|
|
3669
|
+
"description": "Whether the card is open or blocked for various reasons",
|
|
3670
|
+
"enum": ["OPEN", "BLOCKED LOST OR STOLEN", "BLOCKED NO FRAUD", "BLOCKED WITH FRAUD"]
|
|
3671
|
+
},
|
|
3672
|
+
"lock": {
|
|
3673
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3674
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/LockStatus",
|
|
3675
|
+
"type": "string",
|
|
3676
|
+
"description": "A cardholder initiated status. A locked card will fail authorization. Locked cards can be unlocked.\n\nA cardholder may choose to lock a card while temporarily misplaced.\n",
|
|
3677
|
+
"enum": ["LOCKED", "UNLOCKED"]
|
|
3678
|
+
},
|
|
3679
|
+
"capture": {
|
|
3680
|
+
"type": "boolean",
|
|
3681
|
+
"description": "Whether the card should be captured at next use"
|
|
3682
|
+
},
|
|
3683
|
+
"updatedOn": {
|
|
3684
|
+
"type": "string",
|
|
3685
|
+
"description": "Time data was last updated",
|
|
3686
|
+
"format": "date-time"
|
|
3687
|
+
},
|
|
3688
|
+
"lastModified": {
|
|
3689
|
+
"type": "string",
|
|
3690
|
+
"description": "Time data was last modified (Deprecated. Use updatedOn)",
|
|
3691
|
+
"format": "date-time"
|
|
3692
|
+
},
|
|
3693
|
+
"createdOn": {
|
|
3694
|
+
"description": "Time encrypted data was first stored",
|
|
3695
|
+
"type": "string",
|
|
3696
|
+
"format": "date-time"
|
|
3697
|
+
}
|
|
3698
|
+
}
|
|
3699
|
+
}
|
|
3700
|
+
}
|
|
3701
|
+
}
|
|
3702
|
+
}
|
|
3703
|
+
}
|
|
3704
|
+
},
|
|
3705
|
+
"CardNumberRequest": {
|
|
3706
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3707
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/CardNumberRequest",
|
|
3708
|
+
"type": "object",
|
|
3709
|
+
"additionalProperties": false,
|
|
3710
|
+
"required": ["publicKey"],
|
|
3711
|
+
"properties": {
|
|
3712
|
+
"publicKey": {
|
|
3713
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3714
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/PublicKey",
|
|
3715
|
+
"description": "Public key in PEM format",
|
|
3716
|
+
"type": "string",
|
|
3717
|
+
"example": "-----BEGIN PUBLIC KEY-----\nMIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAwm2sxmRdTF7ZIBA6+ngO\n8jOTCHmID0PpQB1q85+hrcLSfB1rWY9bzNNLabBo/ajDnA4Pcadq/x6gpg70qZcR\n9Wxm6TttKzBPZsxasGXgSTDqEi2KcYZgq1mL4qyxUvyIms7/llGy+W9b5huZaVcO\nxdT1tw/zctbOhb6S2t5vH+zkta/2ncUXjG7i8XdLsJ1qe4K1kYbA4KVkOMmAtw7O\n4STk0TZDD0YARdmrciorJjbIVt0Xj1CrYQ5QbDGrlfeXgrcZwX5f9wT2MnKlY5oZ\n5Wtb57oGtLkVf8g6vN/2jGtAmOmHK2hHwNd/+zUet5G/S5uwEli4RgMPP4pUoKgd\nGQIDAQAB\n-----END PUBLIC KEY-----\n"
|
|
3718
|
+
}
|
|
3719
|
+
}
|
|
3720
|
+
},
|
|
3721
|
+
"EncryptedCardNumber": {
|
|
3722
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3723
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/EncryptedCardNumber",
|
|
3724
|
+
"type": "object",
|
|
3725
|
+
"additionalProperties": false,
|
|
3726
|
+
"required": ["encryptedDataEncryptionKey", "cardNumber"],
|
|
3727
|
+
"properties": {
|
|
3728
|
+
"encryptedDataEncryptionKey": {
|
|
3729
|
+
"description": "RSA encrypted data encryption key used to AES encrypt cardNumber.",
|
|
3730
|
+
"type": "string"
|
|
3731
|
+
},
|
|
3732
|
+
"cardNumber": {
|
|
3733
|
+
"type": "string",
|
|
3734
|
+
"description": "AES-256 encrypted card number"
|
|
3735
|
+
}
|
|
3736
|
+
}
|
|
3737
|
+
},
|
|
3738
|
+
"Error": {
|
|
3739
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3740
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/Error",
|
|
3741
|
+
"type": "object",
|
|
3742
|
+
"additionalProperties": false,
|
|
3743
|
+
"description": "Server error message",
|
|
3744
|
+
"properties": {
|
|
3745
|
+
"message": {
|
|
3746
|
+
"type": "string"
|
|
3747
|
+
},
|
|
3748
|
+
"code": {
|
|
3749
|
+
"type": "string"
|
|
3750
|
+
}
|
|
3751
|
+
}
|
|
3752
|
+
},
|
|
3753
|
+
"ExpirationDate": {
|
|
3754
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3755
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/ExpirationDate",
|
|
3756
|
+
"type": "string",
|
|
3757
|
+
"pattern": "([0-9][0-9])(0[1-9]|1[0-2])",
|
|
3758
|
+
"format": "YYMM",
|
|
3759
|
+
"description": "Expiration date for the card and will be assumed to be the last millisecond of the month",
|
|
3760
|
+
"minLength": 4,
|
|
3761
|
+
"maxLength": 4
|
|
3762
|
+
},
|
|
3763
|
+
"DataEncryptionKeyId": {
|
|
3764
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3765
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/DataEncryptionKeyId",
|
|
3766
|
+
"type": "string",
|
|
3767
|
+
"description": "Reference to encryption keys Payment Card Service will use to encrypt the Card object.\n",
|
|
3768
|
+
"format": "uuid"
|
|
3769
|
+
},
|
|
3770
|
+
"DataEncryptionKeyRequest": {
|
|
3771
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3772
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/DataEncryptionKeyRequest",
|
|
3773
|
+
"type": "object",
|
|
3774
|
+
"additionalProperties": false,
|
|
3775
|
+
"required": ["publicKeys"],
|
|
3776
|
+
"properties": {
|
|
3777
|
+
"publicKeys": {
|
|
3778
|
+
"type": "array",
|
|
3779
|
+
"minItems": 1,
|
|
3780
|
+
"description": "List of public keys in PEM format.\n\nAssociated private keys can be used to decrypt card data encrypted by Payment Card Service.\n",
|
|
3781
|
+
"items": {
|
|
3782
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3783
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/PublicKey",
|
|
3784
|
+
"description": "Public key in PEM format",
|
|
3785
|
+
"type": "string",
|
|
3786
|
+
"example": "-----BEGIN PUBLIC KEY-----\nMIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAwm2sxmRdTF7ZIBA6+ngO\n8jOTCHmID0PpQB1q85+hrcLSfB1rWY9bzNNLabBo/ajDnA4Pcadq/x6gpg70qZcR\n9Wxm6TttKzBPZsxasGXgSTDqEi2KcYZgq1mL4qyxUvyIms7/llGy+W9b5huZaVcO\nxdT1tw/zctbOhb6S2t5vH+zkta/2ncUXjG7i8XdLsJ1qe4K1kYbA4KVkOMmAtw7O\n4STk0TZDD0YARdmrciorJjbIVt0Xj1CrYQ5QbDGrlfeXgrcZwX5f9wT2MnKlY5oZ\n5Wtb57oGtLkVf8g6vN/2jGtAmOmHK2hHwNd/+zUet5G/S5uwEli4RgMPP4pUoKgd\nGQIDAQAB\n-----END PUBLIC KEY-----\n"
|
|
3787
|
+
}
|
|
3788
|
+
}
|
|
3789
|
+
}
|
|
3790
|
+
},
|
|
3791
|
+
"DataEncryptionKeyResponse": {
|
|
3792
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3793
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/DataEncryptionKeyResponse",
|
|
3794
|
+
"type": "object",
|
|
3795
|
+
"required": ["transmissionKey", "encryptedDataEncryptionKeys", "createdOn", "lastModified"],
|
|
3796
|
+
"properties": {
|
|
3797
|
+
"createdOn": {
|
|
3798
|
+
"description": "Time data was first stored",
|
|
3799
|
+
"type": "string",
|
|
3800
|
+
"format": "date-time"
|
|
3801
|
+
},
|
|
3802
|
+
"lastModified": {
|
|
3803
|
+
"description": "Time data was last modified",
|
|
3804
|
+
"type": "string",
|
|
3805
|
+
"format": "date-time"
|
|
3806
|
+
},
|
|
3807
|
+
"encryptedDataEncryptionKeys": {
|
|
3808
|
+
"type": "array",
|
|
3809
|
+
"items": {
|
|
3810
|
+
"type": "object",
|
|
3811
|
+
"additionalProperties": false,
|
|
3812
|
+
"description": "An object that includes an encrypted data encryption key and a hashed version of the public key used to encrypt it.\nThe publicKeyHash string is derived using @checkdigit/hash and the caller's public key included in DataEncryptionKeyRequest.\n",
|
|
3813
|
+
"required": ["publicKeyHash", "encryptedDataEncryptionKey"],
|
|
3814
|
+
"properties": {
|
|
3815
|
+
"publicKeyHash": {
|
|
3816
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3817
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/Hash",
|
|
3818
|
+
"type": "string",
|
|
3819
|
+
"format": "uuid",
|
|
3820
|
+
"example": "15a85f64-5717-4562-b3fc-2c963f66afa6",
|
|
3821
|
+
"description": "UUID derived using @checkdigit/hash"
|
|
3822
|
+
},
|
|
3823
|
+
"encryptedDataEncryptionKey": {
|
|
3824
|
+
"type": "string",
|
|
3825
|
+
"description": "RSA encrypted data encryption key used to AES sensitive data in the Card object."
|
|
3826
|
+
}
|
|
3827
|
+
}
|
|
3828
|
+
}
|
|
3829
|
+
},
|
|
3830
|
+
"transmissionKey": {
|
|
3831
|
+
"type": "string",
|
|
3832
|
+
"description": "A public key in PEM format.\nWhen creating a card with a specific card number (i.e. /card/{cardId}/number), use the transmissionKey to\nencrypt the data encryption key used to encrypt the card number.\n"
|
|
3833
|
+
}
|
|
3834
|
+
}
|
|
3835
|
+
},
|
|
3836
|
+
"History": {
|
|
3837
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3838
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/History",
|
|
3839
|
+
"description": "The History object represents the updates to a Card object over time.\n",
|
|
3840
|
+
"type": "object",
|
|
3841
|
+
"required": ["updates"],
|
|
3842
|
+
"properties": {
|
|
3843
|
+
"dataEncryptionKeyId": {
|
|
3844
|
+
"type": "string",
|
|
3845
|
+
"description": "Reference to encryption keys Payment Card Service used to encrypt the Card object.\n",
|
|
3846
|
+
"format": "uuid"
|
|
3847
|
+
},
|
|
3848
|
+
"storageKeyId": {
|
|
3849
|
+
"type": "string",
|
|
3850
|
+
"description": "DEK's non-derived identifier to be used by Check Digit services only.\n"
|
|
3851
|
+
},
|
|
3852
|
+
"encryptedDataEncryptionKey": {
|
|
3853
|
+
"description": "RSA encrypted data encryption key used to decrypt AES encrypted values in Card objects.\n",
|
|
3854
|
+
"type": "string"
|
|
3855
|
+
},
|
|
3856
|
+
"updates": {
|
|
3857
|
+
"type": "array",
|
|
3858
|
+
"items": {
|
|
3859
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3860
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/Card",
|
|
3861
|
+
"type": "object",
|
|
3862
|
+
"additionalProperties": false,
|
|
3863
|
+
"required": [
|
|
3864
|
+
"bin",
|
|
3865
|
+
"last4",
|
|
3866
|
+
"expirationDate",
|
|
3867
|
+
"cardNumber",
|
|
3868
|
+
"serviceCode",
|
|
3869
|
+
"pinOffset",
|
|
3870
|
+
"applicationTransactionCounter",
|
|
3871
|
+
"sequenceNumber",
|
|
3872
|
+
"state",
|
|
3873
|
+
"active",
|
|
3874
|
+
"block",
|
|
3875
|
+
"lock",
|
|
3876
|
+
"capture",
|
|
3877
|
+
"createdOn",
|
|
3878
|
+
"updatedOn",
|
|
3879
|
+
"lastModified"
|
|
3880
|
+
],
|
|
3881
|
+
"properties": {
|
|
3882
|
+
"bin": {
|
|
3883
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3884
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/Bin",
|
|
3885
|
+
"type": "string",
|
|
3886
|
+
"pattern": "^\\d+$",
|
|
3887
|
+
"description": "Bank Identification Number",
|
|
3888
|
+
"minLength": 6,
|
|
3889
|
+
"maxLength": 8
|
|
3890
|
+
},
|
|
3891
|
+
"last4": {
|
|
3892
|
+
"type": "string",
|
|
3893
|
+
"pattern": "^\\d+$",
|
|
3894
|
+
"description": "Last four digits of the card number",
|
|
3895
|
+
"minLength": 4,
|
|
3896
|
+
"maxLength": 4
|
|
3897
|
+
},
|
|
3898
|
+
"expirationDate": {
|
|
3899
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3900
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/ExpirationDate",
|
|
3901
|
+
"type": "string",
|
|
3902
|
+
"pattern": "([0-9][0-9])(0[1-9]|1[0-2])",
|
|
3903
|
+
"format": "YYMM",
|
|
3904
|
+
"description": "Expiration date for the card and will be assumed to be the last millisecond of the month",
|
|
3905
|
+
"minLength": 4,
|
|
3906
|
+
"maxLength": 4
|
|
3907
|
+
},
|
|
3908
|
+
"cardNumber": {
|
|
3909
|
+
"type": "string",
|
|
3910
|
+
"description": "Encrypted card number (PAN)"
|
|
3911
|
+
},
|
|
3912
|
+
"serviceCode": {
|
|
3913
|
+
"type": "string",
|
|
3914
|
+
"pattern": "^\\d+$",
|
|
3915
|
+
"description": "Service code for the card",
|
|
3916
|
+
"minLength": 3,
|
|
3917
|
+
"maxLength": 3
|
|
3918
|
+
},
|
|
3919
|
+
"pinOffset": {
|
|
3920
|
+
"type": "string",
|
|
3921
|
+
"description": "Encrypted pin offset for the card"
|
|
3922
|
+
},
|
|
3923
|
+
"applicationTransactionCounter": {
|
|
3924
|
+
"type": "integer",
|
|
3925
|
+
"description": "Application transaction counter (ATC) for the card"
|
|
3926
|
+
},
|
|
3927
|
+
"sequenceNumber": {
|
|
3928
|
+
"type": "integer",
|
|
3929
|
+
"description": "Used to differentiate issuing the same card and expiration date on multiple plastics"
|
|
3930
|
+
},
|
|
3931
|
+
"state": {
|
|
3932
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3933
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/StateStatus",
|
|
3934
|
+
"description": "The current state of the card",
|
|
3935
|
+
"type": "string",
|
|
3936
|
+
"enum": ["CURRENT", "REISSUED", "RETIRED", "FORCED"]
|
|
3937
|
+
},
|
|
3938
|
+
"active": {
|
|
3939
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3940
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/ActiveStatus",
|
|
3941
|
+
"description": "The active/inactive status for the card",
|
|
3942
|
+
"type": "string",
|
|
3943
|
+
"enum": ["INACTIVE", "ACTIVE"]
|
|
3944
|
+
},
|
|
3945
|
+
"block": {
|
|
3946
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3947
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/BlockStatus",
|
|
3948
|
+
"type": "string",
|
|
3949
|
+
"description": "Whether the card is open or blocked for various reasons",
|
|
3950
|
+
"enum": ["OPEN", "BLOCKED LOST OR STOLEN", "BLOCKED NO FRAUD", "BLOCKED WITH FRAUD"]
|
|
3951
|
+
},
|
|
3952
|
+
"lock": {
|
|
3953
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3954
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/LockStatus",
|
|
3955
|
+
"type": "string",
|
|
3956
|
+
"description": "A cardholder initiated status. A locked card will fail authorization. Locked cards can be unlocked.\n\nA cardholder may choose to lock a card while temporarily misplaced.\n",
|
|
3957
|
+
"enum": ["LOCKED", "UNLOCKED"]
|
|
3958
|
+
},
|
|
3959
|
+
"capture": {
|
|
3960
|
+
"type": "boolean",
|
|
3961
|
+
"description": "Whether the card should be captured at next use"
|
|
3962
|
+
},
|
|
3963
|
+
"updatedOn": {
|
|
3964
|
+
"type": "string",
|
|
3965
|
+
"description": "Time data was last updated",
|
|
3966
|
+
"format": "date-time"
|
|
3967
|
+
},
|
|
3968
|
+
"lastModified": {
|
|
3969
|
+
"type": "string",
|
|
3970
|
+
"description": "Time data was last modified (Deprecated. Use updatedOn)",
|
|
3971
|
+
"format": "date-time"
|
|
3972
|
+
},
|
|
3973
|
+
"createdOn": {
|
|
3974
|
+
"description": "Time encrypted data was first stored",
|
|
3975
|
+
"type": "string",
|
|
3976
|
+
"format": "date-time"
|
|
3977
|
+
}
|
|
3978
|
+
}
|
|
3979
|
+
}
|
|
3980
|
+
}
|
|
3981
|
+
}
|
|
3982
|
+
},
|
|
3983
|
+
"LockStatus": {
|
|
3984
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3985
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/LockStatus",
|
|
3986
|
+
"type": "string",
|
|
3987
|
+
"description": "A cardholder initiated status. A locked card will fail authorization. Locked cards can be unlocked.\n\nA cardholder may choose to lock a card while temporarily misplaced.\n",
|
|
3988
|
+
"enum": ["LOCKED", "UNLOCKED"]
|
|
3989
|
+
},
|
|
3990
|
+
"Ping": {
|
|
3991
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3992
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/Ping",
|
|
3993
|
+
"type": "object",
|
|
3994
|
+
"additionalProperties": false,
|
|
3995
|
+
"required": ["serverTime"],
|
|
3996
|
+
"properties": {
|
|
3997
|
+
"serverTime": {
|
|
3998
|
+
"type": "string",
|
|
3999
|
+
"format": "date-time",
|
|
4000
|
+
"description": "Current server time",
|
|
4001
|
+
"example": "1970-01-01T00:00:00.000Z"
|
|
4002
|
+
}
|
|
4003
|
+
}
|
|
4004
|
+
},
|
|
4005
|
+
"PinOffsetKey": {
|
|
4006
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
4007
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/PinOffsetKey",
|
|
4008
|
+
"type": "object",
|
|
4009
|
+
"additionalProperties": false,
|
|
4010
|
+
"required": ["transmissionKey"],
|
|
4011
|
+
"properties": {
|
|
4012
|
+
"transmissionKey": {
|
|
4013
|
+
"description": "A PEM formatted public key to be used to RSA encrypt a data encryption key.",
|
|
4014
|
+
"type": "string"
|
|
4015
|
+
}
|
|
4016
|
+
}
|
|
4017
|
+
},
|
|
4018
|
+
"PinOffsetKeyId": {
|
|
4019
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
4020
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/PinOffsetKeyId",
|
|
4021
|
+
"type": "string",
|
|
4022
|
+
"format": "uuid",
|
|
4023
|
+
"description": "Identifier for the PinOffsetKey used to encrypt the data encryption key."
|
|
4024
|
+
},
|
|
4025
|
+
"PinOffsetRequest": {
|
|
4026
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
4027
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/PinOffsetRequest",
|
|
4028
|
+
"type": "object",
|
|
4029
|
+
"additionalProperties": false,
|
|
4030
|
+
"required": ["encryptedDataEncryptionKey", "pinOffsetKeyId", "encryptedUserDefinedPin"],
|
|
4031
|
+
"properties": {
|
|
4032
|
+
"pinOffsetKeyId": {
|
|
4033
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
4034
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/PinOffsetKeyId",
|
|
4035
|
+
"type": "string",
|
|
4036
|
+
"format": "uuid",
|
|
4037
|
+
"description": "Identifier for the PinOffsetKey used to encrypt the data encryption key."
|
|
4038
|
+
},
|
|
4039
|
+
"encryptedDataEncryptionKey": {
|
|
4040
|
+
"description": "A RSA encrypted (using transmissionKey) data encryption key that encrypted the encryptedUserDefinedPin.",
|
|
4041
|
+
"type": "string"
|
|
4042
|
+
},
|
|
4043
|
+
"encryptedUserDefinedPin": {
|
|
4044
|
+
"type": "string",
|
|
4045
|
+
"description": "User Defined PIN encrypted with an AES generated data encryption key. This is the PIN to be used for new\noffset calculation. (plaintext pin has minLength = 4, maxLength = 12)\n"
|
|
4046
|
+
}
|
|
4047
|
+
}
|
|
4048
|
+
},
|
|
4049
|
+
"Hash": {
|
|
4050
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
4051
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/Hash",
|
|
4052
|
+
"type": "string",
|
|
4053
|
+
"format": "uuid",
|
|
4054
|
+
"example": "15a85f64-5717-4562-b3fc-2c963f66afa6",
|
|
4055
|
+
"description": "UUID derived using @checkdigit/hash"
|
|
4056
|
+
},
|
|
4057
|
+
"NewCard": {
|
|
4058
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
4059
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/NewCard",
|
|
4060
|
+
"type": "object",
|
|
4061
|
+
"additionalProperties": false,
|
|
4062
|
+
"required": ["bin", "expirationDate", "serviceCode", "sequenceNumber", "state", "active", "block", "lock"],
|
|
4063
|
+
"properties": {
|
|
4064
|
+
"bin": {
|
|
4065
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
4066
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/Bin",
|
|
4067
|
+
"type": "string",
|
|
4068
|
+
"pattern": "^\\d+$",
|
|
4069
|
+
"description": "Bank Identification Number",
|
|
4070
|
+
"minLength": 6,
|
|
4071
|
+
"maxLength": 8
|
|
4072
|
+
},
|
|
4073
|
+
"expirationDate": {
|
|
4074
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
4075
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/ExpirationDate",
|
|
4076
|
+
"type": "string",
|
|
4077
|
+
"pattern": "([0-9][0-9])(0[1-9]|1[0-2])",
|
|
4078
|
+
"format": "YYMM",
|
|
4079
|
+
"description": "Expiration date for the card and will be assumed to be the last millisecond of the month",
|
|
4080
|
+
"minLength": 4,
|
|
4081
|
+
"maxLength": 4
|
|
4082
|
+
},
|
|
4083
|
+
"serviceCode": {
|
|
4084
|
+
"type": "string",
|
|
4085
|
+
"pattern": "^\\d+$",
|
|
4086
|
+
"description": "Used to set general guidelines for how the card can be used, e.g. domestic only or international, online authorizations only, etc.\n",
|
|
4087
|
+
"minLength": 3,
|
|
4088
|
+
"maxLength": 3
|
|
4089
|
+
},
|
|
4090
|
+
"sequenceNumber": {
|
|
4091
|
+
"type": "integer",
|
|
4092
|
+
"description": "Used to differentiate issuing the same card and expiration date on multiple plastics.",
|
|
4093
|
+
"minimum": 0,
|
|
4094
|
+
"maximum": 10
|
|
4095
|
+
},
|
|
4096
|
+
"state": {
|
|
4097
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
4098
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/StateStatus",
|
|
4099
|
+
"description": "The current state of the card",
|
|
4100
|
+
"type": "string",
|
|
4101
|
+
"enum": ["CURRENT", "REISSUED", "RETIRED", "FORCED"]
|
|
4102
|
+
},
|
|
4103
|
+
"active": {
|
|
4104
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
4105
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/ActiveStatus",
|
|
4106
|
+
"description": "The active/inactive status for the card",
|
|
4107
|
+
"type": "string",
|
|
4108
|
+
"enum": ["INACTIVE", "ACTIVE"]
|
|
4109
|
+
},
|
|
4110
|
+
"block": {
|
|
4111
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
4112
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/BlockStatus",
|
|
4113
|
+
"type": "string",
|
|
4114
|
+
"description": "Whether the card is open or blocked for various reasons",
|
|
4115
|
+
"enum": ["OPEN", "BLOCKED LOST OR STOLEN", "BLOCKED NO FRAUD", "BLOCKED WITH FRAUD"]
|
|
4116
|
+
},
|
|
4117
|
+
"lock": {
|
|
4118
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
4119
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/LockStatus",
|
|
4120
|
+
"type": "string",
|
|
4121
|
+
"description": "A cardholder initiated status. A locked card will fail authorization. Locked cards can be unlocked.\n\nA cardholder may choose to lock a card while temporarily misplaced.\n",
|
|
4122
|
+
"enum": ["LOCKED", "UNLOCKED"]
|
|
4123
|
+
}
|
|
4124
|
+
}
|
|
4125
|
+
},
|
|
4126
|
+
"NewCardRequest": {
|
|
4127
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
4128
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/NewCardRequest",
|
|
4129
|
+
"type": "object",
|
|
4130
|
+
"required": ["dataEncryptionKeyId", "cardNumberLength", "newCard"],
|
|
4131
|
+
"additionalProperties": false,
|
|
4132
|
+
"properties": {
|
|
4133
|
+
"dataEncryptionKeyId": {
|
|
4134
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
4135
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/DataEncryptionKeyId",
|
|
4136
|
+
"type": "string",
|
|
4137
|
+
"description": "Reference to encryption keys Payment Card Service will use to encrypt the Card object.\n",
|
|
4138
|
+
"format": "uuid"
|
|
4139
|
+
},
|
|
4140
|
+
"cardNumberLength": {
|
|
4141
|
+
"type": "integer",
|
|
4142
|
+
"description": "Desired number of digits in the card number.",
|
|
4143
|
+
"minimum": 15,
|
|
4144
|
+
"maximum": 19
|
|
4145
|
+
},
|
|
4146
|
+
"newCard": {
|
|
4147
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
4148
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/NewCard",
|
|
4149
|
+
"type": "object",
|
|
4150
|
+
"additionalProperties": false,
|
|
4151
|
+
"required": ["bin", "expirationDate", "serviceCode", "sequenceNumber", "state", "active", "block", "lock"],
|
|
4152
|
+
"properties": {
|
|
4153
|
+
"bin": {
|
|
4154
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
4155
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/Bin",
|
|
4156
|
+
"type": "string",
|
|
4157
|
+
"pattern": "^\\d+$",
|
|
4158
|
+
"description": "Bank Identification Number",
|
|
4159
|
+
"minLength": 6,
|
|
4160
|
+
"maxLength": 8
|
|
4161
|
+
},
|
|
4162
|
+
"expirationDate": {
|
|
4163
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
4164
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/ExpirationDate",
|
|
4165
|
+
"type": "string",
|
|
4166
|
+
"pattern": "([0-9][0-9])(0[1-9]|1[0-2])",
|
|
4167
|
+
"format": "YYMM",
|
|
4168
|
+
"description": "Expiration date for the card and will be assumed to be the last millisecond of the month",
|
|
4169
|
+
"minLength": 4,
|
|
4170
|
+
"maxLength": 4
|
|
4171
|
+
},
|
|
4172
|
+
"serviceCode": {
|
|
4173
|
+
"type": "string",
|
|
4174
|
+
"pattern": "^\\d+$",
|
|
4175
|
+
"description": "Used to set general guidelines for how the card can be used, e.g. domestic only or international, online authorizations only, etc.\n",
|
|
4176
|
+
"minLength": 3,
|
|
4177
|
+
"maxLength": 3
|
|
4178
|
+
},
|
|
4179
|
+
"sequenceNumber": {
|
|
4180
|
+
"type": "integer",
|
|
4181
|
+
"description": "Used to differentiate issuing the same card and expiration date on multiple plastics.",
|
|
4182
|
+
"minimum": 0,
|
|
4183
|
+
"maximum": 10
|
|
4184
|
+
},
|
|
4185
|
+
"state": {
|
|
4186
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
4187
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/StateStatus",
|
|
4188
|
+
"description": "The current state of the card",
|
|
4189
|
+
"type": "string",
|
|
4190
|
+
"enum": ["CURRENT", "REISSUED", "RETIRED", "FORCED"]
|
|
4191
|
+
},
|
|
4192
|
+
"active": {
|
|
4193
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
4194
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/ActiveStatus",
|
|
4195
|
+
"description": "The active/inactive status for the card",
|
|
4196
|
+
"type": "string",
|
|
4197
|
+
"enum": ["INACTIVE", "ACTIVE"]
|
|
4198
|
+
},
|
|
4199
|
+
"block": {
|
|
4200
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
4201
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/BlockStatus",
|
|
4202
|
+
"type": "string",
|
|
4203
|
+
"description": "Whether the card is open or blocked for various reasons",
|
|
4204
|
+
"enum": ["OPEN", "BLOCKED LOST OR STOLEN", "BLOCKED NO FRAUD", "BLOCKED WITH FRAUD"]
|
|
4205
|
+
},
|
|
4206
|
+
"lock": {
|
|
4207
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
4208
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/LockStatus",
|
|
4209
|
+
"type": "string",
|
|
4210
|
+
"description": "A cardholder initiated status. A locked card will fail authorization. Locked cards can be unlocked.\n\nA cardholder may choose to lock a card while temporarily misplaced.\n",
|
|
4211
|
+
"enum": ["LOCKED", "UNLOCKED"]
|
|
4212
|
+
}
|
|
4213
|
+
}
|
|
4214
|
+
}
|
|
4215
|
+
}
|
|
4216
|
+
},
|
|
4217
|
+
"NewCardRequestWithCardNumber": {
|
|
4218
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
4219
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/NewCardRequestWithCardNumber",
|
|
4220
|
+
"type": "object",
|
|
4221
|
+
"required": ["encryptedCardNumber", "encryptedDataEncryptionKey", "dataEncryptionKeyId", "newCard"],
|
|
4222
|
+
"properties": {
|
|
4223
|
+
"encryptedCardNumber": {
|
|
4224
|
+
"type": "string"
|
|
4225
|
+
},
|
|
4226
|
+
"encryptedDataEncryptionKey": {
|
|
4227
|
+
"description": "RSA encrypted data encryption key used to AES encrypt encryptedCardNumber",
|
|
4228
|
+
"type": "string"
|
|
4229
|
+
},
|
|
4230
|
+
"dataEncryptionKeyId": {
|
|
4231
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
4232
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/DataEncryptionKeyId",
|
|
4233
|
+
"type": "string",
|
|
4234
|
+
"description": "Reference to encryption keys Payment Card Service will use to encrypt the Card object.\n",
|
|
4235
|
+
"format": "uuid"
|
|
4236
|
+
},
|
|
4237
|
+
"newCard": {
|
|
4238
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
4239
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/NewCard",
|
|
4240
|
+
"type": "object",
|
|
4241
|
+
"additionalProperties": false,
|
|
4242
|
+
"required": ["bin", "expirationDate", "serviceCode", "sequenceNumber", "state", "active", "block", "lock"],
|
|
4243
|
+
"properties": {
|
|
4244
|
+
"bin": {
|
|
4245
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
4246
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/Bin",
|
|
4247
|
+
"type": "string",
|
|
4248
|
+
"pattern": "^\\d+$",
|
|
4249
|
+
"description": "Bank Identification Number",
|
|
4250
|
+
"minLength": 6,
|
|
4251
|
+
"maxLength": 8
|
|
4252
|
+
},
|
|
4253
|
+
"expirationDate": {
|
|
4254
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
4255
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/ExpirationDate",
|
|
4256
|
+
"type": "string",
|
|
4257
|
+
"pattern": "([0-9][0-9])(0[1-9]|1[0-2])",
|
|
4258
|
+
"format": "YYMM",
|
|
4259
|
+
"description": "Expiration date for the card and will be assumed to be the last millisecond of the month",
|
|
4260
|
+
"minLength": 4,
|
|
4261
|
+
"maxLength": 4
|
|
4262
|
+
},
|
|
4263
|
+
"serviceCode": {
|
|
4264
|
+
"type": "string",
|
|
4265
|
+
"pattern": "^\\d+$",
|
|
4266
|
+
"description": "Used to set general guidelines for how the card can be used, e.g. domestic only or international, online authorizations only, etc.\n",
|
|
4267
|
+
"minLength": 3,
|
|
4268
|
+
"maxLength": 3
|
|
4269
|
+
},
|
|
4270
|
+
"sequenceNumber": {
|
|
4271
|
+
"type": "integer",
|
|
4272
|
+
"description": "Used to differentiate issuing the same card and expiration date on multiple plastics.",
|
|
4273
|
+
"minimum": 0,
|
|
4274
|
+
"maximum": 10
|
|
4275
|
+
},
|
|
4276
|
+
"state": {
|
|
4277
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
4278
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/StateStatus",
|
|
4279
|
+
"description": "The current state of the card",
|
|
4280
|
+
"type": "string",
|
|
4281
|
+
"enum": ["CURRENT", "REISSUED", "RETIRED", "FORCED"]
|
|
4282
|
+
},
|
|
4283
|
+
"active": {
|
|
4284
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
4285
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/ActiveStatus",
|
|
4286
|
+
"description": "The active/inactive status for the card",
|
|
4287
|
+
"type": "string",
|
|
4288
|
+
"enum": ["INACTIVE", "ACTIVE"]
|
|
4289
|
+
},
|
|
4290
|
+
"block": {
|
|
4291
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
4292
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/BlockStatus",
|
|
4293
|
+
"type": "string",
|
|
4294
|
+
"description": "Whether the card is open or blocked for various reasons",
|
|
4295
|
+
"enum": ["OPEN", "BLOCKED LOST OR STOLEN", "BLOCKED NO FRAUD", "BLOCKED WITH FRAUD"]
|
|
4296
|
+
},
|
|
4297
|
+
"lock": {
|
|
4298
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
4299
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/LockStatus",
|
|
4300
|
+
"type": "string",
|
|
4301
|
+
"description": "A cardholder initiated status. A locked card will fail authorization. Locked cards can be unlocked.\n\nA cardholder may choose to lock a card while temporarily misplaced.\n",
|
|
4302
|
+
"enum": ["LOCKED", "UNLOCKED"]
|
|
4303
|
+
}
|
|
4304
|
+
}
|
|
4305
|
+
}
|
|
4306
|
+
},
|
|
4307
|
+
"additionalProperties": false
|
|
4308
|
+
},
|
|
4309
|
+
"PublicKey": {
|
|
4310
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
4311
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/PublicKey",
|
|
4312
|
+
"description": "Public key in PEM format",
|
|
4313
|
+
"type": "string",
|
|
4314
|
+
"example": "-----BEGIN PUBLIC KEY-----\nMIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAwm2sxmRdTF7ZIBA6+ngO\n8jOTCHmID0PpQB1q85+hrcLSfB1rWY9bzNNLabBo/ajDnA4Pcadq/x6gpg70qZcR\n9Wxm6TttKzBPZsxasGXgSTDqEi2KcYZgq1mL4qyxUvyIms7/llGy+W9b5huZaVcO\nxdT1tw/zctbOhb6S2t5vH+zkta/2ncUXjG7i8XdLsJ1qe4K1kYbA4KVkOMmAtw7O\n4STk0TZDD0YARdmrciorJjbIVt0Xj1CrYQ5QbDGrlfeXgrcZwX5f9wT2MnKlY5oZ\n5Wtb57oGtLkVf8g6vN/2jGtAmOmHK2hHwNd/+zUet5G/S5uwEli4RgMPP4pUoKgd\nGQIDAQAB\n-----END PUBLIC KEY-----\n"
|
|
4315
|
+
},
|
|
4316
|
+
"PublicKeyResponse": {
|
|
4317
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
4318
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/PublicKeyResponse",
|
|
4319
|
+
"description": "This object contains the rsa generated public key for the Payment Card Service. This public key must be used\nwhen transmitting encrypted data to Payment Card Service APIs.\n",
|
|
4320
|
+
"type": "object",
|
|
4321
|
+
"required": ["publicKey"],
|
|
4322
|
+
"properties": {
|
|
4323
|
+
"publicKey": {
|
|
4324
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
4325
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/PublicKey",
|
|
4326
|
+
"description": "Public key in PEM format",
|
|
4327
|
+
"type": "string",
|
|
4328
|
+
"example": "-----BEGIN PUBLIC KEY-----\nMIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAwm2sxmRdTF7ZIBA6+ngO\n8jOTCHmID0PpQB1q85+hrcLSfB1rWY9bzNNLabBo/ajDnA4Pcadq/x6gpg70qZcR\n9Wxm6TttKzBPZsxasGXgSTDqEi2KcYZgq1mL4qyxUvyIms7/llGy+W9b5huZaVcO\nxdT1tw/zctbOhb6S2t5vH+zkta/2ncUXjG7i8XdLsJ1qe4K1kYbA4KVkOMmAtw7O\n4STk0TZDD0YARdmrciorJjbIVt0Xj1CrYQ5QbDGrlfeXgrcZwX5f9wT2MnKlY5oZ\n5Wtb57oGtLkVf8g6vN/2jGtAmOmHK2hHwNd/+zUet5G/S5uwEli4RgMPP4pUoKgd\nGQIDAQAB\n-----END PUBLIC KEY-----\n"
|
|
4329
|
+
}
|
|
4330
|
+
}
|
|
4331
|
+
},
|
|
4332
|
+
"StateStatus": {
|
|
4333
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
4334
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/StateStatus",
|
|
4335
|
+
"description": "The current state of the card",
|
|
4336
|
+
"type": "string",
|
|
4337
|
+
"enum": ["CURRENT", "REISSUED", "RETIRED", "FORCED"]
|
|
4338
|
+
},
|
|
4339
|
+
"StorageKeyId": {
|
|
4340
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
4341
|
+
"$id": "https://eslint-plugin.checkdigit/payment-card/v1/schemas/definitions/StorageKeyId",
|
|
4342
|
+
"type": "string",
|
|
4343
|
+
"description": "DEK's non-derived identifier to be used by Check Digit services only.\n"
|
|
4344
|
+
}
|
|
4345
|
+
}
|
|
4346
|
+
}
|