@alogram/payrisk 0.1.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (152) hide show
  1. package/AI.md +37 -0
  2. package/LICENSE +201 -0
  3. package/README.md +129 -0
  4. package/dist/_generated/apis/PayriskApi.d.ts +108 -0
  5. package/dist/_generated/apis/PayriskApi.js +342 -0
  6. package/dist/_generated/apis/index.d.ts +1 -0
  7. package/dist/_generated/apis/index.js +19 -0
  8. package/dist/_generated/index.d.ts +3 -0
  9. package/dist/_generated/index.js +21 -0
  10. package/dist/_generated/models/Account.d.ts +59 -0
  11. package/dist/_generated/models/Account.js +57 -0
  12. package/dist/_generated/models/AccountCheckRequest.d.ts +64 -0
  13. package/dist/_generated/models/AccountCheckRequest.js +72 -0
  14. package/dist/_generated/models/AvsResultEnum.d.ts +54 -0
  15. package/dist/_generated/models/AvsResultEnum.js +82 -0
  16. package/dist/_generated/models/BankTransfer.d.ts +39 -0
  17. package/dist/_generated/models/BankTransfer.js +59 -0
  18. package/dist/_generated/models/Card.d.ts +93 -0
  19. package/dist/_generated/models/Card.js +81 -0
  20. package/dist/_generated/models/CardNetworkEnum.d.ts +30 -0
  21. package/dist/_generated/models/CardNetworkEnum.js +58 -0
  22. package/dist/_generated/models/CategorySignal.d.ts +45 -0
  23. package/dist/_generated/models/CategorySignal.js +55 -0
  24. package/dist/_generated/models/ChannelEnum.d.ts +28 -0
  25. package/dist/_generated/models/ChannelEnum.js +56 -0
  26. package/dist/_generated/models/CheckRequest.d.ts +66 -0
  27. package/dist/_generated/models/CheckRequest.js +72 -0
  28. package/dist/_generated/models/ConfidenceEnum.d.ts +26 -0
  29. package/dist/_generated/models/ConfidenceEnum.js +54 -0
  30. package/dist/_generated/models/Crypto.d.ts +39 -0
  31. package/dist/_generated/models/Crypto.js +59 -0
  32. package/dist/_generated/models/CvvResultEnum.d.ts +33 -0
  33. package/dist/_generated/models/CvvResultEnum.js +61 -0
  34. package/dist/_generated/models/DecisionResponse.d.ts +128 -0
  35. package/dist/_generated/models/DecisionResponse.js +107 -0
  36. package/dist/_generated/models/DeviceInfo.d.ts +54 -0
  37. package/dist/_generated/models/DeviceInfo.js +56 -0
  38. package/dist/_generated/models/EntityIds.d.ts +113 -0
  39. package/dist/_generated/models/EntityIds.js +70 -0
  40. package/dist/_generated/models/EntryMethodEnum.d.ts +30 -0
  41. package/dist/_generated/models/EntryMethodEnum.js +58 -0
  42. package/dist/_generated/models/FraudScore.d.ts +52 -0
  43. package/dist/_generated/models/FraudScore.js +58 -0
  44. package/dist/_generated/models/Identity.d.ts +71 -0
  45. package/dist/_generated/models/Identity.js +57 -0
  46. package/dist/_generated/models/Integrity.d.ts +68 -0
  47. package/dist/_generated/models/Integrity.js +58 -0
  48. package/dist/_generated/models/Interaction.d.ts +59 -0
  49. package/dist/_generated/models/Interaction.js +60 -0
  50. package/dist/_generated/models/InteractionTypeEnum.d.ts +29 -0
  51. package/dist/_generated/models/InteractionTypeEnum.js +57 -0
  52. package/dist/_generated/models/Invoice.d.ts +39 -0
  53. package/dist/_generated/models/Invoice.js +59 -0
  54. package/dist/_generated/models/IpInfo.d.ts +101 -0
  55. package/dist/_generated/models/IpInfo.js +78 -0
  56. package/dist/_generated/models/KycCheckRequest.d.ts +64 -0
  57. package/dist/_generated/models/KycCheckRequest.js +74 -0
  58. package/dist/_generated/models/KycPayload.d.ts +84 -0
  59. package/dist/_generated/models/KycPayload.js +82 -0
  60. package/dist/_generated/models/MerchantContext.d.ts +38 -0
  61. package/dist/_generated/models/MerchantContext.js +50 -0
  62. package/dist/_generated/models/OrderContext.d.ts +60 -0
  63. package/dist/_generated/models/OrderContext.js +65 -0
  64. package/dist/_generated/models/PayerTypeEnum.d.ts +25 -0
  65. package/dist/_generated/models/PayerTypeEnum.js +53 -0
  66. package/dist/_generated/models/PaymentAuthorizationOutcome.d.ts +38 -0
  67. package/dist/_generated/models/PaymentAuthorizationOutcome.js +50 -0
  68. package/dist/_generated/models/PaymentCaptureOutcome.d.ts +42 -0
  69. package/dist/_generated/models/PaymentCaptureOutcome.js +60 -0
  70. package/dist/_generated/models/PaymentCardTypeEnum.d.ts +26 -0
  71. package/dist/_generated/models/PaymentCardTypeEnum.js +54 -0
  72. package/dist/_generated/models/PaymentChargeback.d.ts +32 -0
  73. package/dist/_generated/models/PaymentChargeback.js +48 -0
  74. package/dist/_generated/models/PaymentChargebackOutcome.d.ts +42 -0
  75. package/dist/_generated/models/PaymentChargebackOutcome.js +60 -0
  76. package/dist/_generated/models/PaymentDisputeOutcome.d.ts +43 -0
  77. package/dist/_generated/models/PaymentDisputeOutcome.js +61 -0
  78. package/dist/_generated/models/PaymentEvent.d.ts +72 -0
  79. package/dist/_generated/models/PaymentEvent.js +68 -0
  80. package/dist/_generated/models/PaymentEventType.d.ts +30 -0
  81. package/dist/_generated/models/PaymentEventType.js +58 -0
  82. package/dist/_generated/models/PaymentMethod.d.ts +39 -0
  83. package/dist/_generated/models/PaymentMethod.js +73 -0
  84. package/dist/_generated/models/PaymentMethodBase.d.ts +44 -0
  85. package/dist/_generated/models/PaymentMethodBase.js +64 -0
  86. package/dist/_generated/models/PaymentOutcome.d.ts +69 -0
  87. package/dist/_generated/models/PaymentOutcome.js +64 -0
  88. package/dist/_generated/models/PaymentRealtimeTypeEnum.d.ts +28 -0
  89. package/dist/_generated/models/PaymentRealtimeTypeEnum.js +56 -0
  90. package/dist/_generated/models/PaymentRefundOutcome.d.ts +41 -0
  91. package/dist/_generated/models/PaymentRefundOutcome.js +59 -0
  92. package/dist/_generated/models/PaymentWalletTypeEnum.d.ts +28 -0
  93. package/dist/_generated/models/PaymentWalletTypeEnum.js +56 -0
  94. package/dist/_generated/models/PostalAddress.d.ts +65 -0
  95. package/dist/_generated/models/PostalAddress.js +58 -0
  96. package/dist/_generated/models/Problem.d.ts +62 -0
  97. package/dist/_generated/models/Problem.js +62 -0
  98. package/dist/_generated/models/Purchase.d.ts +122 -0
  99. package/dist/_generated/models/Purchase.js +88 -0
  100. package/dist/_generated/models/PurchaseInitiatorEnum.d.ts +25 -0
  101. package/dist/_generated/models/PurchaseInitiatorEnum.js +53 -0
  102. package/dist/_generated/models/PurchaseSequenceEnum.d.ts +25 -0
  103. package/dist/_generated/models/PurchaseSequenceEnum.js +53 -0
  104. package/dist/_generated/models/PurchaseUsageEnum.d.ts +27 -0
  105. package/dist/_generated/models/PurchaseUsageEnum.js +55 -0
  106. package/dist/_generated/models/Realtime.d.ts +46 -0
  107. package/dist/_generated/models/Realtime.js +62 -0
  108. package/dist/_generated/models/ReasonDetail.d.ts +57 -0
  109. package/dist/_generated/models/ReasonDetail.js +63 -0
  110. package/dist/_generated/models/RiskBreakdown.d.ts +51 -0
  111. package/dist/_generated/models/RiskBreakdown.js +55 -0
  112. package/dist/_generated/models/RiskCategoryEnum.d.ts +27 -0
  113. package/dist/_generated/models/RiskCategoryEnum.js +55 -0
  114. package/dist/_generated/models/RiskLevelEnum.d.ts +26 -0
  115. package/dist/_generated/models/RiskLevelEnum.js +54 -0
  116. package/dist/_generated/models/ScaMethodEnum.d.ts +30 -0
  117. package/dist/_generated/models/ScaMethodEnum.js +58 -0
  118. package/dist/_generated/models/ScoreRecord.d.ts +107 -0
  119. package/dist/_generated/models/ScoreRecord.js +92 -0
  120. package/dist/_generated/models/ScoresSuccessResponse.d.ts +39 -0
  121. package/dist/_generated/models/ScoresSuccessResponse.js +51 -0
  122. package/dist/_generated/models/SignalsAccountVariant.d.ts +53 -0
  123. package/dist/_generated/models/SignalsAccountVariant.js +69 -0
  124. package/dist/_generated/models/SignalsInteractionVariant.d.ts +53 -0
  125. package/dist/_generated/models/SignalsInteractionVariant.js +69 -0
  126. package/dist/_generated/models/SignalsRequest.d.ts +28 -0
  127. package/dist/_generated/models/SignalsRequest.js +53 -0
  128. package/dist/_generated/models/StoredCredentialContext.d.ts +47 -0
  129. package/dist/_generated/models/StoredCredentialContext.js +55 -0
  130. package/dist/_generated/models/ThreeDSData.d.ts +68 -0
  131. package/dist/_generated/models/ThreeDSData.js +66 -0
  132. package/dist/_generated/models/Wallet.d.ts +46 -0
  133. package/dist/_generated/models/Wallet.js +62 -0
  134. package/dist/_generated/models/index.d.ts +62 -0
  135. package/dist/_generated/models/index.js +80 -0
  136. package/dist/_generated/runtime.d.ts +184 -0
  137. package/dist/_generated/runtime.js +338 -0
  138. package/dist/client.d.ts +69 -0
  139. package/dist/client.js +281 -0
  140. package/dist/exceptions.d.ts +24 -0
  141. package/dist/exceptions.js +59 -0
  142. package/dist/index.d.ts +5 -0
  143. package/dist/index.js +23 -0
  144. package/dist/testing.d.ts +24 -0
  145. package/dist/testing.js +100 -0
  146. package/dist/webhooks.d.ts +10 -0
  147. package/dist/webhooks.js +32 -0
  148. package/examples/asyncSignalIngestion.ts +52 -0
  149. package/examples/checkRisk.ts +26 -0
  150. package/examples/productionErrorHandling.ts +52 -0
  151. package/examples/webhookVerification.ts +29 -0
  152. package/package.json +64 -0
@@ -0,0 +1,50 @@
1
+ "use strict";
2
+ /* tslint:disable */
3
+ /* eslint-disable */
4
+ /**
5
+ * Payments Risk API
6
+ * API for detecting and scoring fraud for purchases, with lifecycle labeling and behavioral signals. v1 focuses on purchases only (`/risk/check`), with future account/session and KYC checks stubbed below.
7
+ *
8
+ * The version of the OpenAPI document: 0.1.6-rc.3
9
+ * Contact: support@alogram.ai
10
+ *
11
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
12
+ * https://openapi-generator.tech
13
+ * Do not edit the class manually.
14
+ */
15
+ Object.defineProperty(exports, "__esModule", { value: true });
16
+ exports.instanceOfPaymentAuthorizationOutcome = instanceOfPaymentAuthorizationOutcome;
17
+ exports.PaymentAuthorizationOutcomeFromJSON = PaymentAuthorizationOutcomeFromJSON;
18
+ exports.PaymentAuthorizationOutcomeFromJSONTyped = PaymentAuthorizationOutcomeFromJSONTyped;
19
+ exports.PaymentAuthorizationOutcomeToJSON = PaymentAuthorizationOutcomeToJSON;
20
+ exports.PaymentAuthorizationOutcomeToJSONTyped = PaymentAuthorizationOutcomeToJSONTyped;
21
+ /**
22
+ * Check if a given object implements the PaymentAuthorizationOutcome interface.
23
+ */
24
+ function instanceOfPaymentAuthorizationOutcome(value) {
25
+ return true;
26
+ }
27
+ function PaymentAuthorizationOutcomeFromJSON(json) {
28
+ return PaymentAuthorizationOutcomeFromJSONTyped(json, false);
29
+ }
30
+ function PaymentAuthorizationOutcomeFromJSONTyped(json, ignoreDiscriminator) {
31
+ if (json == null) {
32
+ return json;
33
+ }
34
+ return {
35
+ 'approved': json['approved'] == null ? undefined : json['approved'],
36
+ 'responseCode': json['responseCode'] == null ? undefined : json['responseCode'],
37
+ };
38
+ }
39
+ function PaymentAuthorizationOutcomeToJSON(json) {
40
+ return PaymentAuthorizationOutcomeToJSONTyped(json, false);
41
+ }
42
+ function PaymentAuthorizationOutcomeToJSONTyped(value, ignoreDiscriminator = false) {
43
+ if (value == null) {
44
+ return value;
45
+ }
46
+ return {
47
+ 'approved': value['approved'],
48
+ 'responseCode': value['responseCode'],
49
+ };
50
+ }
@@ -0,0 +1,42 @@
1
+ /**
2
+ * Payments Risk API
3
+ * API for detecting and scoring fraud for purchases, with lifecycle labeling and behavioral signals. v1 focuses on purchases only (`/risk/check`), with future account/session and KYC checks stubbed below.
4
+ *
5
+ * The version of the OpenAPI document: 0.1.6-rc.3
6
+ * Contact: support@alogram.ai
7
+ *
8
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
9
+ * https://openapi-generator.tech
10
+ * Do not edit the class manually.
11
+ */
12
+ /**
13
+ * Capture outcome details.
14
+ * @export
15
+ * @interface PaymentCaptureOutcome
16
+ */
17
+ export interface PaymentCaptureOutcome {
18
+ /**
19
+ * Capture status.
20
+ * @type {string}
21
+ * @memberof PaymentCaptureOutcome
22
+ */
23
+ status?: PaymentCaptureOutcomeStatusEnum;
24
+ }
25
+ /**
26
+ * @export
27
+ * @enum {string}
28
+ */
29
+ export declare enum PaymentCaptureOutcomeStatusEnum {
30
+ None = "none",
31
+ Partial = "partial",
32
+ Full = "full",
33
+ Failed = "failed"
34
+ }
35
+ /**
36
+ * Check if a given object implements the PaymentCaptureOutcome interface.
37
+ */
38
+ export declare function instanceOfPaymentCaptureOutcome(value: object): value is PaymentCaptureOutcome;
39
+ export declare function PaymentCaptureOutcomeFromJSON(json: any): PaymentCaptureOutcome;
40
+ export declare function PaymentCaptureOutcomeFromJSONTyped(json: any, ignoreDiscriminator: boolean): PaymentCaptureOutcome;
41
+ export declare function PaymentCaptureOutcomeToJSON(json: any): PaymentCaptureOutcome;
42
+ export declare function PaymentCaptureOutcomeToJSONTyped(value?: PaymentCaptureOutcome | null, ignoreDiscriminator?: boolean): any;
@@ -0,0 +1,60 @@
1
+ "use strict";
2
+ /* tslint:disable */
3
+ /* eslint-disable */
4
+ /**
5
+ * Payments Risk API
6
+ * API for detecting and scoring fraud for purchases, with lifecycle labeling and behavioral signals. v1 focuses on purchases only (`/risk/check`), with future account/session and KYC checks stubbed below.
7
+ *
8
+ * The version of the OpenAPI document: 0.1.6-rc.3
9
+ * Contact: support@alogram.ai
10
+ *
11
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
12
+ * https://openapi-generator.tech
13
+ * Do not edit the class manually.
14
+ */
15
+ Object.defineProperty(exports, "__esModule", { value: true });
16
+ exports.PaymentCaptureOutcomeStatusEnum = void 0;
17
+ exports.instanceOfPaymentCaptureOutcome = instanceOfPaymentCaptureOutcome;
18
+ exports.PaymentCaptureOutcomeFromJSON = PaymentCaptureOutcomeFromJSON;
19
+ exports.PaymentCaptureOutcomeFromJSONTyped = PaymentCaptureOutcomeFromJSONTyped;
20
+ exports.PaymentCaptureOutcomeToJSON = PaymentCaptureOutcomeToJSON;
21
+ exports.PaymentCaptureOutcomeToJSONTyped = PaymentCaptureOutcomeToJSONTyped;
22
+ /**
23
+ * @export
24
+ * @enum {string}
25
+ */
26
+ var PaymentCaptureOutcomeStatusEnum;
27
+ (function (PaymentCaptureOutcomeStatusEnum) {
28
+ PaymentCaptureOutcomeStatusEnum["None"] = "none";
29
+ PaymentCaptureOutcomeStatusEnum["Partial"] = "partial";
30
+ PaymentCaptureOutcomeStatusEnum["Full"] = "full";
31
+ PaymentCaptureOutcomeStatusEnum["Failed"] = "failed";
32
+ })(PaymentCaptureOutcomeStatusEnum || (exports.PaymentCaptureOutcomeStatusEnum = PaymentCaptureOutcomeStatusEnum = {}));
33
+ /**
34
+ * Check if a given object implements the PaymentCaptureOutcome interface.
35
+ */
36
+ function instanceOfPaymentCaptureOutcome(value) {
37
+ return true;
38
+ }
39
+ function PaymentCaptureOutcomeFromJSON(json) {
40
+ return PaymentCaptureOutcomeFromJSONTyped(json, false);
41
+ }
42
+ function PaymentCaptureOutcomeFromJSONTyped(json, ignoreDiscriminator) {
43
+ if (json == null) {
44
+ return json;
45
+ }
46
+ return {
47
+ 'status': json['status'] == null ? undefined : json['status'],
48
+ };
49
+ }
50
+ function PaymentCaptureOutcomeToJSON(json) {
51
+ return PaymentCaptureOutcomeToJSONTyped(json, false);
52
+ }
53
+ function PaymentCaptureOutcomeToJSONTyped(value, ignoreDiscriminator = false) {
54
+ if (value == null) {
55
+ return value;
56
+ }
57
+ return {
58
+ 'status': value['status'],
59
+ };
60
+ }
@@ -0,0 +1,26 @@
1
+ /**
2
+ * Payments Risk API
3
+ * API for detecting and scoring fraud for purchases, with lifecycle labeling and behavioral signals. v1 focuses on purchases only (`/risk/check`), with future account/session and KYC checks stubbed below.
4
+ *
5
+ * The version of the OpenAPI document: 0.1.6-rc.3
6
+ * Contact: support@alogram.ai
7
+ *
8
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
9
+ * https://openapi-generator.tech
10
+ * Do not edit the class manually.
11
+ */
12
+ /**
13
+ * The type of card used for the payment.
14
+ * @export
15
+ * @enum {string}
16
+ */
17
+ export declare enum PaymentCardTypeEnum {
18
+ Credit = "credit",
19
+ Debit = "debit",
20
+ Prepaid = "prepaid"
21
+ }
22
+ export declare function instanceOfPaymentCardTypeEnum(value: any): boolean;
23
+ export declare function PaymentCardTypeEnumFromJSON(json: any): PaymentCardTypeEnum;
24
+ export declare function PaymentCardTypeEnumFromJSONTyped(json: any, ignoreDiscriminator: boolean): PaymentCardTypeEnum;
25
+ export declare function PaymentCardTypeEnumToJSON(value?: PaymentCardTypeEnum | null): any;
26
+ export declare function PaymentCardTypeEnumToJSONTyped(value: any, ignoreDiscriminator: boolean): PaymentCardTypeEnum;
@@ -0,0 +1,54 @@
1
+ "use strict";
2
+ /* tslint:disable */
3
+ /* eslint-disable */
4
+ /**
5
+ * Payments Risk API
6
+ * API for detecting and scoring fraud for purchases, with lifecycle labeling and behavioral signals. v1 focuses on purchases only (`/risk/check`), with future account/session and KYC checks stubbed below.
7
+ *
8
+ * The version of the OpenAPI document: 0.1.6-rc.3
9
+ * Contact: support@alogram.ai
10
+ *
11
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
12
+ * https://openapi-generator.tech
13
+ * Do not edit the class manually.
14
+ */
15
+ Object.defineProperty(exports, "__esModule", { value: true });
16
+ exports.PaymentCardTypeEnum = void 0;
17
+ exports.instanceOfPaymentCardTypeEnum = instanceOfPaymentCardTypeEnum;
18
+ exports.PaymentCardTypeEnumFromJSON = PaymentCardTypeEnumFromJSON;
19
+ exports.PaymentCardTypeEnumFromJSONTyped = PaymentCardTypeEnumFromJSONTyped;
20
+ exports.PaymentCardTypeEnumToJSON = PaymentCardTypeEnumToJSON;
21
+ exports.PaymentCardTypeEnumToJSONTyped = PaymentCardTypeEnumToJSONTyped;
22
+ /**
23
+ * The type of card used for the payment.
24
+ * @export
25
+ * @enum {string}
26
+ */
27
+ var PaymentCardTypeEnum;
28
+ (function (PaymentCardTypeEnum) {
29
+ PaymentCardTypeEnum["Credit"] = "credit";
30
+ PaymentCardTypeEnum["Debit"] = "debit";
31
+ PaymentCardTypeEnum["Prepaid"] = "prepaid";
32
+ })(PaymentCardTypeEnum || (exports.PaymentCardTypeEnum = PaymentCardTypeEnum = {}));
33
+ function instanceOfPaymentCardTypeEnum(value) {
34
+ for (const key in PaymentCardTypeEnum) {
35
+ if (Object.prototype.hasOwnProperty.call(PaymentCardTypeEnum, key)) {
36
+ if (PaymentCardTypeEnum[key] === value) {
37
+ return true;
38
+ }
39
+ }
40
+ }
41
+ return false;
42
+ }
43
+ function PaymentCardTypeEnumFromJSON(json) {
44
+ return PaymentCardTypeEnumFromJSONTyped(json, false);
45
+ }
46
+ function PaymentCardTypeEnumFromJSONTyped(json, ignoreDiscriminator) {
47
+ return json;
48
+ }
49
+ function PaymentCardTypeEnumToJSON(value) {
50
+ return value;
51
+ }
52
+ function PaymentCardTypeEnumToJSONTyped(value, ignoreDiscriminator) {
53
+ return value;
54
+ }
@@ -0,0 +1,32 @@
1
+ /**
2
+ * Payments Risk API
3
+ * API for detecting and scoring fraud for purchases, with lifecycle labeling and behavioral signals. v1 focuses on purchases only (`/risk/check`), with future account/session and KYC checks stubbed below.
4
+ *
5
+ * The version of the OpenAPI document: 0.1.6-rc.3
6
+ * Contact: support@alogram.ai
7
+ *
8
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
9
+ * https://openapi-generator.tech
10
+ * Do not edit the class manually.
11
+ */
12
+ /**
13
+ * Chargeback details, including reason code.
14
+ * @export
15
+ * @interface PaymentChargeback
16
+ */
17
+ export interface PaymentChargeback {
18
+ /**
19
+ * Chargeback reason code.
20
+ * @type {string}
21
+ * @memberof PaymentChargeback
22
+ */
23
+ reason?: string;
24
+ }
25
+ /**
26
+ * Check if a given object implements the PaymentChargeback interface.
27
+ */
28
+ export declare function instanceOfPaymentChargeback(value: object): value is PaymentChargeback;
29
+ export declare function PaymentChargebackFromJSON(json: any): PaymentChargeback;
30
+ export declare function PaymentChargebackFromJSONTyped(json: any, ignoreDiscriminator: boolean): PaymentChargeback;
31
+ export declare function PaymentChargebackToJSON(json: any): PaymentChargeback;
32
+ export declare function PaymentChargebackToJSONTyped(value?: PaymentChargeback | null, ignoreDiscriminator?: boolean): any;
@@ -0,0 +1,48 @@
1
+ "use strict";
2
+ /* tslint:disable */
3
+ /* eslint-disable */
4
+ /**
5
+ * Payments Risk API
6
+ * API for detecting and scoring fraud for purchases, with lifecycle labeling and behavioral signals. v1 focuses on purchases only (`/risk/check`), with future account/session and KYC checks stubbed below.
7
+ *
8
+ * The version of the OpenAPI document: 0.1.6-rc.3
9
+ * Contact: support@alogram.ai
10
+ *
11
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
12
+ * https://openapi-generator.tech
13
+ * Do not edit the class manually.
14
+ */
15
+ Object.defineProperty(exports, "__esModule", { value: true });
16
+ exports.instanceOfPaymentChargeback = instanceOfPaymentChargeback;
17
+ exports.PaymentChargebackFromJSON = PaymentChargebackFromJSON;
18
+ exports.PaymentChargebackFromJSONTyped = PaymentChargebackFromJSONTyped;
19
+ exports.PaymentChargebackToJSON = PaymentChargebackToJSON;
20
+ exports.PaymentChargebackToJSONTyped = PaymentChargebackToJSONTyped;
21
+ /**
22
+ * Check if a given object implements the PaymentChargeback interface.
23
+ */
24
+ function instanceOfPaymentChargeback(value) {
25
+ return true;
26
+ }
27
+ function PaymentChargebackFromJSON(json) {
28
+ return PaymentChargebackFromJSONTyped(json, false);
29
+ }
30
+ function PaymentChargebackFromJSONTyped(json, ignoreDiscriminator) {
31
+ if (json == null) {
32
+ return json;
33
+ }
34
+ return {
35
+ 'reason': json['reason'] == null ? undefined : json['reason'],
36
+ };
37
+ }
38
+ function PaymentChargebackToJSON(json) {
39
+ return PaymentChargebackToJSONTyped(json, false);
40
+ }
41
+ function PaymentChargebackToJSONTyped(value, ignoreDiscriminator = false) {
42
+ if (value == null) {
43
+ return value;
44
+ }
45
+ return {
46
+ 'reason': value['reason'],
47
+ };
48
+ }
@@ -0,0 +1,42 @@
1
+ /**
2
+ * Payments Risk API
3
+ * API for detecting and scoring fraud for purchases, with lifecycle labeling and behavioral signals. v1 focuses on purchases only (`/risk/check`), with future account/session and KYC checks stubbed below.
4
+ *
5
+ * The version of the OpenAPI document: 0.1.6-rc.3
6
+ * Contact: support@alogram.ai
7
+ *
8
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
9
+ * https://openapi-generator.tech
10
+ * Do not edit the class manually.
11
+ */
12
+ /**
13
+ * Final disposition of the chargeback after investigation/representment.
14
+ * @export
15
+ * @interface PaymentChargebackOutcome
16
+ */
17
+ export interface PaymentChargebackOutcome {
18
+ /**
19
+ * Outcome of the chargeback case.
20
+ * @type {string}
21
+ * @memberof PaymentChargebackOutcome
22
+ */
23
+ status?: PaymentChargebackOutcomeStatusEnum;
24
+ }
25
+ /**
26
+ * @export
27
+ * @enum {string}
28
+ */
29
+ export declare enum PaymentChargebackOutcomeStatusEnum {
30
+ Won = "won",
31
+ Lost = "lost",
32
+ Representment = "representment",
33
+ Reversed = "reversed"
34
+ }
35
+ /**
36
+ * Check if a given object implements the PaymentChargebackOutcome interface.
37
+ */
38
+ export declare function instanceOfPaymentChargebackOutcome(value: object): value is PaymentChargebackOutcome;
39
+ export declare function PaymentChargebackOutcomeFromJSON(json: any): PaymentChargebackOutcome;
40
+ export declare function PaymentChargebackOutcomeFromJSONTyped(json: any, ignoreDiscriminator: boolean): PaymentChargebackOutcome;
41
+ export declare function PaymentChargebackOutcomeToJSON(json: any): PaymentChargebackOutcome;
42
+ export declare function PaymentChargebackOutcomeToJSONTyped(value?: PaymentChargebackOutcome | null, ignoreDiscriminator?: boolean): any;
@@ -0,0 +1,60 @@
1
+ "use strict";
2
+ /* tslint:disable */
3
+ /* eslint-disable */
4
+ /**
5
+ * Payments Risk API
6
+ * API for detecting and scoring fraud for purchases, with lifecycle labeling and behavioral signals. v1 focuses on purchases only (`/risk/check`), with future account/session and KYC checks stubbed below.
7
+ *
8
+ * The version of the OpenAPI document: 0.1.6-rc.3
9
+ * Contact: support@alogram.ai
10
+ *
11
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
12
+ * https://openapi-generator.tech
13
+ * Do not edit the class manually.
14
+ */
15
+ Object.defineProperty(exports, "__esModule", { value: true });
16
+ exports.PaymentChargebackOutcomeStatusEnum = void 0;
17
+ exports.instanceOfPaymentChargebackOutcome = instanceOfPaymentChargebackOutcome;
18
+ exports.PaymentChargebackOutcomeFromJSON = PaymentChargebackOutcomeFromJSON;
19
+ exports.PaymentChargebackOutcomeFromJSONTyped = PaymentChargebackOutcomeFromJSONTyped;
20
+ exports.PaymentChargebackOutcomeToJSON = PaymentChargebackOutcomeToJSON;
21
+ exports.PaymentChargebackOutcomeToJSONTyped = PaymentChargebackOutcomeToJSONTyped;
22
+ /**
23
+ * @export
24
+ * @enum {string}
25
+ */
26
+ var PaymentChargebackOutcomeStatusEnum;
27
+ (function (PaymentChargebackOutcomeStatusEnum) {
28
+ PaymentChargebackOutcomeStatusEnum["Won"] = "won";
29
+ PaymentChargebackOutcomeStatusEnum["Lost"] = "lost";
30
+ PaymentChargebackOutcomeStatusEnum["Representment"] = "representment";
31
+ PaymentChargebackOutcomeStatusEnum["Reversed"] = "reversed";
32
+ })(PaymentChargebackOutcomeStatusEnum || (exports.PaymentChargebackOutcomeStatusEnum = PaymentChargebackOutcomeStatusEnum = {}));
33
+ /**
34
+ * Check if a given object implements the PaymentChargebackOutcome interface.
35
+ */
36
+ function instanceOfPaymentChargebackOutcome(value) {
37
+ return true;
38
+ }
39
+ function PaymentChargebackOutcomeFromJSON(json) {
40
+ return PaymentChargebackOutcomeFromJSONTyped(json, false);
41
+ }
42
+ function PaymentChargebackOutcomeFromJSONTyped(json, ignoreDiscriminator) {
43
+ if (json == null) {
44
+ return json;
45
+ }
46
+ return {
47
+ 'status': json['status'] == null ? undefined : json['status'],
48
+ };
49
+ }
50
+ function PaymentChargebackOutcomeToJSON(json) {
51
+ return PaymentChargebackOutcomeToJSONTyped(json, false);
52
+ }
53
+ function PaymentChargebackOutcomeToJSONTyped(value, ignoreDiscriminator = false) {
54
+ if (value == null) {
55
+ return value;
56
+ }
57
+ return {
58
+ 'status': value['status'],
59
+ };
60
+ }
@@ -0,0 +1,43 @@
1
+ /**
2
+ * Payments Risk API
3
+ * API for detecting and scoring fraud for purchases, with lifecycle labeling and behavioral signals. v1 focuses on purchases only (`/risk/check`), with future account/session and KYC checks stubbed below.
4
+ *
5
+ * The version of the OpenAPI document: 0.1.6-rc.3
6
+ * Contact: support@alogram.ai
7
+ *
8
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
9
+ * https://openapi-generator.tech
10
+ * Do not edit the class manually.
11
+ */
12
+ /**
13
+ * Dispute lifecycle status for the transaction.
14
+ * @export
15
+ * @interface PaymentDisputeOutcome
16
+ */
17
+ export interface PaymentDisputeOutcome {
18
+ /**
19
+ * Dispute status.
20
+ * @type {string}
21
+ * @memberof PaymentDisputeOutcome
22
+ */
23
+ status?: PaymentDisputeOutcomeStatusEnum;
24
+ }
25
+ /**
26
+ * @export
27
+ * @enum {string}
28
+ */
29
+ export declare enum PaymentDisputeOutcomeStatusEnum {
30
+ None = "none",
31
+ Open = "open",
32
+ Won = "won",
33
+ Lost = "lost",
34
+ Canceled = "canceled"
35
+ }
36
+ /**
37
+ * Check if a given object implements the PaymentDisputeOutcome interface.
38
+ */
39
+ export declare function instanceOfPaymentDisputeOutcome(value: object): value is PaymentDisputeOutcome;
40
+ export declare function PaymentDisputeOutcomeFromJSON(json: any): PaymentDisputeOutcome;
41
+ export declare function PaymentDisputeOutcomeFromJSONTyped(json: any, ignoreDiscriminator: boolean): PaymentDisputeOutcome;
42
+ export declare function PaymentDisputeOutcomeToJSON(json: any): PaymentDisputeOutcome;
43
+ export declare function PaymentDisputeOutcomeToJSONTyped(value?: PaymentDisputeOutcome | null, ignoreDiscriminator?: boolean): any;
@@ -0,0 +1,61 @@
1
+ "use strict";
2
+ /* tslint:disable */
3
+ /* eslint-disable */
4
+ /**
5
+ * Payments Risk API
6
+ * API for detecting and scoring fraud for purchases, with lifecycle labeling and behavioral signals. v1 focuses on purchases only (`/risk/check`), with future account/session and KYC checks stubbed below.
7
+ *
8
+ * The version of the OpenAPI document: 0.1.6-rc.3
9
+ * Contact: support@alogram.ai
10
+ *
11
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
12
+ * https://openapi-generator.tech
13
+ * Do not edit the class manually.
14
+ */
15
+ Object.defineProperty(exports, "__esModule", { value: true });
16
+ exports.PaymentDisputeOutcomeStatusEnum = void 0;
17
+ exports.instanceOfPaymentDisputeOutcome = instanceOfPaymentDisputeOutcome;
18
+ exports.PaymentDisputeOutcomeFromJSON = PaymentDisputeOutcomeFromJSON;
19
+ exports.PaymentDisputeOutcomeFromJSONTyped = PaymentDisputeOutcomeFromJSONTyped;
20
+ exports.PaymentDisputeOutcomeToJSON = PaymentDisputeOutcomeToJSON;
21
+ exports.PaymentDisputeOutcomeToJSONTyped = PaymentDisputeOutcomeToJSONTyped;
22
+ /**
23
+ * @export
24
+ * @enum {string}
25
+ */
26
+ var PaymentDisputeOutcomeStatusEnum;
27
+ (function (PaymentDisputeOutcomeStatusEnum) {
28
+ PaymentDisputeOutcomeStatusEnum["None"] = "none";
29
+ PaymentDisputeOutcomeStatusEnum["Open"] = "open";
30
+ PaymentDisputeOutcomeStatusEnum["Won"] = "won";
31
+ PaymentDisputeOutcomeStatusEnum["Lost"] = "lost";
32
+ PaymentDisputeOutcomeStatusEnum["Canceled"] = "canceled";
33
+ })(PaymentDisputeOutcomeStatusEnum || (exports.PaymentDisputeOutcomeStatusEnum = PaymentDisputeOutcomeStatusEnum = {}));
34
+ /**
35
+ * Check if a given object implements the PaymentDisputeOutcome interface.
36
+ */
37
+ function instanceOfPaymentDisputeOutcome(value) {
38
+ return true;
39
+ }
40
+ function PaymentDisputeOutcomeFromJSON(json) {
41
+ return PaymentDisputeOutcomeFromJSONTyped(json, false);
42
+ }
43
+ function PaymentDisputeOutcomeFromJSONTyped(json, ignoreDiscriminator) {
44
+ if (json == null) {
45
+ return json;
46
+ }
47
+ return {
48
+ 'status': json['status'] == null ? undefined : json['status'],
49
+ };
50
+ }
51
+ function PaymentDisputeOutcomeToJSON(json) {
52
+ return PaymentDisputeOutcomeToJSONTyped(json, false);
53
+ }
54
+ function PaymentDisputeOutcomeToJSONTyped(value, ignoreDiscriminator = false) {
55
+ if (value == null) {
56
+ return value;
57
+ }
58
+ return {
59
+ 'status': value['status'],
60
+ };
61
+ }
@@ -0,0 +1,72 @@
1
+ /**
2
+ * Payments Risk API
3
+ * API for detecting and scoring fraud for purchases, with lifecycle labeling and behavioral signals. v1 focuses on purchases only (`/risk/check`), with future account/session and KYC checks stubbed below.
4
+ *
5
+ * The version of the OpenAPI document: 0.1.6-rc.3
6
+ * Contact: support@alogram.ai
7
+ *
8
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
9
+ * https://openapi-generator.tech
10
+ * Do not edit the class manually.
11
+ */
12
+ import type { PaymentEventType } from './PaymentEventType';
13
+ import type { PaymentOutcome } from './PaymentOutcome';
14
+ /**
15
+ * Payment lifecycle event.
16
+ * @export
17
+ * @interface PaymentEvent
18
+ */
19
+ export interface PaymentEvent {
20
+ /**
21
+ * Server-minted unique payment identifier.
22
+ * @type {string}
23
+ * @memberof PaymentEvent
24
+ */
25
+ paymentIntentId: string;
26
+ /**
27
+ *
28
+ * @type {PaymentEventType}
29
+ * @memberof PaymentEvent
30
+ */
31
+ eventType: PaymentEventType;
32
+ /**
33
+ * RFC 3339 timestamp with timezone.
34
+ * @type {string}
35
+ * @memberof PaymentEvent
36
+ */
37
+ timestamp: string;
38
+ /**
39
+ * Value of the purchase in the specified currency. Must be a positive number with up to two decimal places.
40
+ *
41
+ * @type {number}
42
+ * @memberof PaymentEvent
43
+ */
44
+ amount?: number;
45
+ /**
46
+ * ISO 4217 currency code (e.g., 'USD').
47
+ * @type {string}
48
+ * @memberof PaymentEvent
49
+ */
50
+ currency?: string;
51
+ /**
52
+ *
53
+ * @type {PaymentOutcome}
54
+ * @memberof PaymentEvent
55
+ */
56
+ outcome?: PaymentOutcome;
57
+ /**
58
+ * Optional key-value pairs providing additional context for the request. Each key should be descriptive, and values should not exceed 2048 characters. Each key should be descriptive.
59
+ *
60
+ * @type {string}
61
+ * @memberof PaymentEvent
62
+ */
63
+ metadata?: string;
64
+ }
65
+ /**
66
+ * Check if a given object implements the PaymentEvent interface.
67
+ */
68
+ export declare function instanceOfPaymentEvent(value: object): value is PaymentEvent;
69
+ export declare function PaymentEventFromJSON(json: any): PaymentEvent;
70
+ export declare function PaymentEventFromJSONTyped(json: any, ignoreDiscriminator: boolean): PaymentEvent;
71
+ export declare function PaymentEventToJSON(json: any): PaymentEvent;
72
+ export declare function PaymentEventToJSONTyped(value?: PaymentEvent | null, ignoreDiscriminator?: boolean): any;
@@ -0,0 +1,68 @@
1
+ "use strict";
2
+ /* tslint:disable */
3
+ /* eslint-disable */
4
+ /**
5
+ * Payments Risk API
6
+ * API for detecting and scoring fraud for purchases, with lifecycle labeling and behavioral signals. v1 focuses on purchases only (`/risk/check`), with future account/session and KYC checks stubbed below.
7
+ *
8
+ * The version of the OpenAPI document: 0.1.6-rc.3
9
+ * Contact: support@alogram.ai
10
+ *
11
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
12
+ * https://openapi-generator.tech
13
+ * Do not edit the class manually.
14
+ */
15
+ Object.defineProperty(exports, "__esModule", { value: true });
16
+ exports.instanceOfPaymentEvent = instanceOfPaymentEvent;
17
+ exports.PaymentEventFromJSON = PaymentEventFromJSON;
18
+ exports.PaymentEventFromJSONTyped = PaymentEventFromJSONTyped;
19
+ exports.PaymentEventToJSON = PaymentEventToJSON;
20
+ exports.PaymentEventToJSONTyped = PaymentEventToJSONTyped;
21
+ const PaymentEventType_1 = require("./PaymentEventType");
22
+ const PaymentOutcome_1 = require("./PaymentOutcome");
23
+ /**
24
+ * Check if a given object implements the PaymentEvent interface.
25
+ */
26
+ function instanceOfPaymentEvent(value) {
27
+ if (!('paymentIntentId' in value) || value['paymentIntentId'] === undefined)
28
+ return false;
29
+ if (!('eventType' in value) || value['eventType'] === undefined)
30
+ return false;
31
+ if (!('timestamp' in value) || value['timestamp'] === undefined)
32
+ return false;
33
+ return true;
34
+ }
35
+ function PaymentEventFromJSON(json) {
36
+ return PaymentEventFromJSONTyped(json, false);
37
+ }
38
+ function PaymentEventFromJSONTyped(json, ignoreDiscriminator) {
39
+ if (json == null) {
40
+ return json;
41
+ }
42
+ return {
43
+ 'paymentIntentId': json['paymentIntentId'],
44
+ 'eventType': (0, PaymentEventType_1.PaymentEventTypeFromJSON)(json['eventType']),
45
+ 'timestamp': json['timestamp'],
46
+ 'amount': json['amount'] == null ? undefined : json['amount'],
47
+ 'currency': json['currency'] == null ? undefined : json['currency'],
48
+ 'outcome': json['outcome'] == null ? undefined : (0, PaymentOutcome_1.PaymentOutcomeFromJSON)(json['outcome']),
49
+ 'metadata': json['metadata'] == null ? undefined : json['metadata'],
50
+ };
51
+ }
52
+ function PaymentEventToJSON(json) {
53
+ return PaymentEventToJSONTyped(json, false);
54
+ }
55
+ function PaymentEventToJSONTyped(value, ignoreDiscriminator = false) {
56
+ if (value == null) {
57
+ return value;
58
+ }
59
+ return {
60
+ 'paymentIntentId': value['paymentIntentId'],
61
+ 'eventType': (0, PaymentEventType_1.PaymentEventTypeToJSON)(value['eventType']),
62
+ 'timestamp': value['timestamp'],
63
+ 'amount': value['amount'],
64
+ 'currency': value['currency'],
65
+ 'outcome': (0, PaymentOutcome_1.PaymentOutcomeToJSON)(value['outcome']),
66
+ 'metadata': value['metadata'],
67
+ };
68
+ }