@natch-the-storage/heathershaw-platform-types 1.22.1 → 1.22.3

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.
@@ -344,6 +344,25 @@ export type ChargeAndCreateOrderBody = {
344
344
  sca: ScaResult;
345
345
  cardType?: string;
346
346
  customerIp?: string;
347
+ reference: string;
348
+ amount: number;
349
+ };
350
+ /** Used for ChargeAndCreateOrder endpoint, the expected result */
351
+ export type ChargeAndCreateOrderResult = {
352
+ success: true;
353
+ data: Order;
354
+ transactionId: string;
355
+ } | {
356
+ success: false;
357
+ message: string;
358
+ paymentTaken?: undefined;
359
+ }
360
+ /** Charged but not created. Surface transactionId; do NOT retry. */
361
+ | {
362
+ success: false;
363
+ paymentTaken: true;
364
+ transactionId: string;
365
+ message: string;
347
366
  };
348
367
  /** Links to scaResultSchema in the API */
349
368
  export type ScaResult = {
@@ -356,19 +375,13 @@ export type ScaResult = {
356
375
  directoryServerTxnId?: string | null;
357
376
  threedsVersion?: string | null;
358
377
  };
359
- export interface ChargeOrderLegacy {
360
- cardNumber: string;
361
- cardHolder: string;
362
- cardExpiry: string;
363
- cvv: string;
364
- customerIp?: string;
365
- }
366
378
  /** Links to chargeOrderBodySchema in the API */
367
379
  export type ChargeOrder = chargeUpdateFields & {
368
380
  cardToken: string;
369
381
  sca: ScaResult;
370
382
  cardType?: string;
371
383
  customerIp?: string;
384
+ reference: string;
372
385
  };
373
386
  /** Links to chargeOrderMotoBodySchema in the API */
374
387
  export type ChargeOrderMotoBody = chargeUpdateFields & PaymentCardDetails;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@natch-the-storage/heathershaw-platform-types",
3
- "version": "1.22.1",
3
+ "version": "1.22.3",
4
4
  "description": "Interfaces and routes to use on the client",
5
5
  "license": "ISC",
6
6
  "author": "Natch Surana",