@gr4vy/sdk 1.9.20 → 1.10.0

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 (106) hide show
  1. package/README.md +11 -0
  2. package/examples/package-lock.json +1 -1
  3. package/funcs/merchantAccountsThreeDsConfigurationCreate.d.ts +18 -0
  4. package/funcs/merchantAccountsThreeDsConfigurationCreate.d.ts.map +1 -0
  5. package/funcs/merchantAccountsThreeDsConfigurationCreate.js +141 -0
  6. package/funcs/merchantAccountsThreeDsConfigurationCreate.js.map +1 -0
  7. package/funcs/merchantAccountsThreeDsConfigurationDelete.d.ts +17 -0
  8. package/funcs/merchantAccountsThreeDsConfigurationDelete.d.ts.map +1 -0
  9. package/funcs/merchantAccountsThreeDsConfigurationDelete.js +141 -0
  10. package/funcs/merchantAccountsThreeDsConfigurationDelete.js.map +1 -0
  11. package/funcs/merchantAccountsThreeDsConfigurationList.d.ts +18 -0
  12. package/funcs/merchantAccountsThreeDsConfigurationList.d.ts.map +1 -0
  13. package/funcs/merchantAccountsThreeDsConfigurationList.js +154 -0
  14. package/funcs/merchantAccountsThreeDsConfigurationList.js.map +1 -0
  15. package/funcs/merchantAccountsThreeDsConfigurationUpdate.d.ts +18 -0
  16. package/funcs/merchantAccountsThreeDsConfigurationUpdate.d.ts.map +1 -0
  17. package/funcs/merchantAccountsThreeDsConfigurationUpdate.js +143 -0
  18. package/funcs/merchantAccountsThreeDsConfigurationUpdate.js.map +1 -0
  19. package/funcs/transactionsCapture.d.ts +1 -2
  20. package/funcs/transactionsCapture.d.ts.map +1 -1
  21. package/funcs/transactionsCapture.js +6 -11
  22. package/funcs/transactionsCapture.js.map +1 -1
  23. package/jsr.json +1 -1
  24. package/lib/config.d.ts +3 -3
  25. package/lib/config.js +3 -3
  26. package/models/components/index.d.ts +4 -0
  27. package/models/components/index.d.ts.map +1 -1
  28. package/models/components/index.js +4 -0
  29. package/models/components/index.js.map +1 -1
  30. package/models/components/merchantaccountthreedsconfiguration.d.ts +62 -0
  31. package/models/components/merchantaccountthreedsconfiguration.d.ts.map +1 -0
  32. package/models/components/merchantaccountthreedsconfiguration.js +77 -0
  33. package/models/components/merchantaccountthreedsconfiguration.js.map +1 -0
  34. package/models/components/merchantaccountthreedsconfigurationcreate.d.ts +54 -0
  35. package/models/components/merchantaccountthreedsconfigurationcreate.d.ts.map +1 -0
  36. package/models/components/merchantaccountthreedsconfigurationcreate.js +68 -0
  37. package/models/components/merchantaccountthreedsconfigurationcreate.js.map +1 -0
  38. package/models/components/merchantaccountthreedsconfigurations.d.ts +14 -0
  39. package/models/components/merchantaccountthreedsconfigurations.d.ts.map +1 -0
  40. package/models/components/merchantaccountthreedsconfigurations.js +51 -0
  41. package/models/components/merchantaccountthreedsconfigurations.js.map +1 -0
  42. package/models/components/merchantaccountthreedsconfigurationupdate.d.ts +57 -0
  43. package/models/components/merchantaccountthreedsconfigurationupdate.d.ts.map +1 -0
  44. package/models/components/merchantaccountthreedsconfigurationupdate.js +68 -0
  45. package/models/components/merchantaccountthreedsconfigurationupdate.js.map +1 -0
  46. package/models/operations/capturetransaction.d.ts +8 -3
  47. package/models/operations/capturetransaction.d.ts.map +1 -1
  48. package/models/operations/capturetransaction.js +7 -5
  49. package/models/operations/capturetransaction.js.map +1 -1
  50. package/models/operations/createthreedsconfiguration.d.ts +18 -0
  51. package/models/operations/createthreedsconfiguration.d.ts.map +1 -0
  52. package/models/operations/createthreedsconfiguration.js +57 -0
  53. package/models/operations/createthreedsconfiguration.js.map +1 -0
  54. package/models/operations/deletethreedsconfiguration.d.ts +20 -0
  55. package/models/operations/deletethreedsconfiguration.d.ts.map +1 -0
  56. package/models/operations/deletethreedsconfiguration.js +56 -0
  57. package/models/operations/deletethreedsconfiguration.js.map +1 -0
  58. package/models/operations/editthreedsconfiguration.d.ts +23 -0
  59. package/models/operations/editthreedsconfiguration.d.ts.map +1 -0
  60. package/models/operations/editthreedsconfiguration.js +59 -0
  61. package/models/operations/editthreedsconfiguration.js.map +1 -0
  62. package/models/operations/getmerchantaccount.d.ts +1 -1
  63. package/models/operations/index.d.ts +4 -0
  64. package/models/operations/index.d.ts.map +1 -1
  65. package/models/operations/index.js +4 -0
  66. package/models/operations/index.js.map +1 -1
  67. package/models/operations/listthreedsconfigurations.d.ts +20 -0
  68. package/models/operations/listthreedsconfigurations.d.ts.map +1 -0
  69. package/models/operations/listthreedsconfigurations.js +55 -0
  70. package/models/operations/listthreedsconfigurations.js.map +1 -0
  71. package/models/operations/updatemerchantaccount.d.ts +1 -1
  72. package/package.json +1 -1
  73. package/sdk/merchantaccounts.d.ts +3 -0
  74. package/sdk/merchantaccounts.d.ts.map +1 -1
  75. package/sdk/merchantaccounts.js +4 -0
  76. package/sdk/merchantaccounts.js.map +1 -1
  77. package/sdk/threedsconfiguration.d.ts +33 -0
  78. package/sdk/threedsconfiguration.d.ts.map +1 -0
  79. package/sdk/threedsconfiguration.js +52 -0
  80. package/sdk/threedsconfiguration.js.map +1 -0
  81. package/sdk/transactions.d.ts +1 -1
  82. package/sdk/transactions.d.ts.map +1 -1
  83. package/sdk/transactions.js +2 -2
  84. package/sdk/transactions.js.map +1 -1
  85. package/src/funcs/merchantAccountsThreeDsConfigurationCreate.ts +255 -0
  86. package/src/funcs/merchantAccountsThreeDsConfigurationDelete.ts +252 -0
  87. package/src/funcs/merchantAccountsThreeDsConfigurationList.ts +262 -0
  88. package/src/funcs/merchantAccountsThreeDsConfigurationUpdate.ts +264 -0
  89. package/src/funcs/transactionsCapture.ts +13 -25
  90. package/src/lib/config.ts +3 -3
  91. package/src/models/components/index.ts +4 -0
  92. package/src/models/components/merchantaccountthreedsconfiguration.ts +110 -0
  93. package/src/models/components/merchantaccountthreedsconfigurationcreate.ts +91 -0
  94. package/src/models/components/merchantaccountthreedsconfigurations.ts +39 -0
  95. package/src/models/components/merchantaccountthreedsconfigurationupdate.ts +94 -0
  96. package/src/models/operations/capturetransaction.ts +14 -7
  97. package/src/models/operations/createthreedsconfiguration.ts +50 -0
  98. package/src/models/operations/deletethreedsconfiguration.ts +48 -0
  99. package/src/models/operations/editthreedsconfiguration.ts +57 -0
  100. package/src/models/operations/getmerchantaccount.ts +1 -1
  101. package/src/models/operations/index.ts +4 -0
  102. package/src/models/operations/listthreedsconfigurations.ts +47 -0
  103. package/src/models/operations/updatemerchantaccount.ts +1 -1
  104. package/src/sdk/merchantaccounts.ts +8 -0
  105. package/src/sdk/threedsconfiguration.ts +93 -0
  106. package/src/sdk/transactions.ts +3 -9
@@ -0,0 +1,93 @@
1
+ /*
2
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
3
+ */
4
+
5
+ import { merchantAccountsThreeDsConfigurationCreate } from "../funcs/merchantAccountsThreeDsConfigurationCreate.js";
6
+ import { merchantAccountsThreeDsConfigurationDelete } from "../funcs/merchantAccountsThreeDsConfigurationDelete.js";
7
+ import { merchantAccountsThreeDsConfigurationList } from "../funcs/merchantAccountsThreeDsConfigurationList.js";
8
+ import { merchantAccountsThreeDsConfigurationUpdate } from "../funcs/merchantAccountsThreeDsConfigurationUpdate.js";
9
+ import { ClientSDK, RequestOptions } from "../lib/sdks.js";
10
+ import * as components from "../models/components/index.js";
11
+ import { unwrapAsync } from "../types/fp.js";
12
+
13
+ export class ThreeDsConfiguration extends ClientSDK {
14
+ /**
15
+ * Create 3DS configuration for merchant
16
+ *
17
+ * @remarks
18
+ * Create a new 3DS configuration for a merchant account.
19
+ */
20
+ async create(
21
+ merchantAccountThreeDSConfigurationCreate:
22
+ components.MerchantAccountThreeDSConfigurationCreate,
23
+ merchantAccountId: string,
24
+ options?: RequestOptions,
25
+ ): Promise<components.MerchantAccountThreeDSConfiguration> {
26
+ return unwrapAsync(merchantAccountsThreeDsConfigurationCreate(
27
+ this,
28
+ merchantAccountThreeDSConfigurationCreate,
29
+ merchantAccountId,
30
+ options,
31
+ ));
32
+ }
33
+
34
+ /**
35
+ * List 3DS configurations for merchant
36
+ *
37
+ * @remarks
38
+ * List all 3DS configurations for a merchant account.
39
+ */
40
+ async list(
41
+ merchantAccountId: string,
42
+ currency?: string | null | undefined,
43
+ options?: RequestOptions,
44
+ ): Promise<components.MerchantAccountThreeDSConfigurations> {
45
+ return unwrapAsync(merchantAccountsThreeDsConfigurationList(
46
+ this,
47
+ merchantAccountId,
48
+ currency,
49
+ options,
50
+ ));
51
+ }
52
+
53
+ /**
54
+ * Edit 3DS configuration
55
+ *
56
+ * @remarks
57
+ * Update the 3DS configuration for a merchant account.
58
+ */
59
+ async update(
60
+ merchantAccountThreeDSConfigurationUpdate:
61
+ components.MerchantAccountThreeDSConfigurationUpdate,
62
+ merchantAccountId: string,
63
+ threeDsConfigurationId: string,
64
+ options?: RequestOptions,
65
+ ): Promise<components.MerchantAccountThreeDSConfiguration> {
66
+ return unwrapAsync(merchantAccountsThreeDsConfigurationUpdate(
67
+ this,
68
+ merchantAccountThreeDSConfigurationUpdate,
69
+ merchantAccountId,
70
+ threeDsConfigurationId,
71
+ options,
72
+ ));
73
+ }
74
+
75
+ /**
76
+ * Delete 3DS configuration for a merchant
77
+ *
78
+ * @remarks
79
+ * Delete a 3DS configuration for a merchant account.
80
+ */
81
+ async delete(
82
+ merchantAccountId: string,
83
+ threeDsConfigurationId: string,
84
+ options?: RequestOptions,
85
+ ): Promise<void> {
86
+ return unwrapAsync(merchantAccountsThreeDsConfigurationDelete(
87
+ this,
88
+ merchantAccountId,
89
+ threeDsConfigurationId,
90
+ options,
91
+ ));
92
+ }
93
+ }
@@ -130,18 +130,12 @@ export class Transactions extends ClientSDK {
130
130
  * Captures a previously authorized transaction. You can capture the full or a partial amount, as long as it does not exceed the authorized amount (unless over-capture is enabled).
131
131
  */
132
132
  async capture(
133
- transactionCaptureCreate: components.TransactionCaptureCreate,
134
- transactionId: string,
135
- prefer?: Array<string> | null | undefined,
136
- merchantAccountId?: string | null | undefined,
133
+ request: operations.CaptureTransactionRequest,
137
134
  options?: RequestOptions,
138
- ): Promise<operations.CaptureTransactionResponseCaptureTransaction> {
135
+ ): Promise<operations.CaptureTransactionResponse200CaptureTransaction> {
139
136
  return unwrapAsync(transactionsCapture(
140
137
  this,
141
- transactionCaptureCreate,
142
- transactionId,
143
- prefer,
144
- merchantAccountId,
138
+ request,
145
139
  options,
146
140
  ));
147
141
  }