pkg-sdk-test 0.0.14 → 0.0.16
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/README.md +295 -0
- package/dist/cjs/BaseClient.js +3 -3
- package/dist/cjs/Client.d.ts +4 -4
- package/dist/cjs/Client.js +3 -3
- package/dist/cjs/api/errors/BadRequestError.d.ts +3 -3
- package/dist/cjs/api/errors/BadRequestError.js +1 -1
- package/dist/cjs/api/errors/InternalServerError.d.ts +3 -3
- package/dist/cjs/api/errors/InternalServerError.js +1 -1
- package/dist/cjs/api/errors/NotFoundError.d.ts +3 -3
- package/dist/cjs/api/errors/NotFoundError.js +1 -1
- package/dist/cjs/api/errors/UnauthorizedError.d.ts +3 -3
- package/dist/cjs/api/errors/UnauthorizedError.js +1 -1
- package/dist/cjs/api/resources/index.d.ts +1 -0
- package/dist/cjs/api/resources/index.js +1 -0
- package/dist/cjs/api/resources/payments/client/Client.d.ts +38 -23
- package/dist/cjs/api/resources/payments/client/Client.js +89 -36
- package/dist/cjs/api/resources/payments/client/requests/CryptopayCreatePaymentRequest.d.ts +3 -3
- package/dist/cjs/api/resources/payments/client/requests/CryptopaySimulatePaymentRequest.d.ts +2 -2
- package/dist/cjs/api/resources/payments/client/requests/GetV1PaymentsRequest.d.ts +3 -2
- package/dist/cjs/api/resources/payments/client/requests/PostV1PaymentsPaymentIdActivateRequest.d.ts +10 -0
- package/dist/cjs/api/resources/payments/client/requests/PostV1PaymentsPaymentIdActivateRequest.js +3 -0
- package/dist/cjs/api/resources/payments/client/requests/index.d.ts +1 -0
- package/dist/cjs/api/resources/payments/types/GetV1PaymentsPaymentIdResponse.d.ts +2 -2
- package/dist/cjs/api/resources/payments/types/GetV1PaymentsRequestOrder.d.ts +5 -0
- package/dist/cjs/api/resources/payments/types/GetV1PaymentsRequestOrder.js +8 -0
- package/dist/cjs/api/resources/payments/types/index.d.ts +1 -0
- package/dist/cjs/api/resources/payments/types/index.js +1 -0
- package/dist/cjs/api/resources/staticWallets/client/Client.d.ts +24 -23
- package/dist/cjs/api/resources/staticWallets/client/Client.js +59 -39
- package/dist/cjs/api/resources/staticWallets/client/requests/CryptopayCreateStaticWalletRequest.d.ts +2 -1
- package/dist/cjs/api/resources/staticWallets/client/requests/CryptopaySimulateStaticDepositRequest.d.ts +12 -2
- package/dist/cjs/api/resources/staticWallets/client/requests/CryptopaySimulateStaticDepositRequest.js +10 -0
- package/dist/cjs/api/resources/staticWallets/client/requests/CryptopayUpdateStaticWalletRequest.d.ts +2 -1
- package/dist/cjs/api/resources/staticWallets/client/requests/GetV1StaticWalletsRequest.d.ts +13 -0
- package/dist/cjs/api/resources/staticWallets/client/requests/GetV1StaticWalletsRequest.js +3 -0
- package/dist/cjs/api/resources/staticWallets/client/requests/GetV1StaticWalletsStaticWalletIdDepositsRequest.d.ts +7 -0
- package/dist/cjs/api/resources/staticWallets/client/requests/index.d.ts +2 -1
- package/dist/cjs/api/resources/staticWallets/client/requests/index.js +3 -0
- package/dist/cjs/api/resources/staticWallets/index.d.ts +1 -0
- package/dist/cjs/api/resources/staticWallets/index.js +1 -0
- package/dist/cjs/api/resources/staticWallets/types/GetV1StaticWalletsRequestOrder.d.ts +5 -0
- package/dist/cjs/api/resources/staticWallets/types/GetV1StaticWalletsRequestOrder.js +8 -0
- package/dist/cjs/api/resources/staticWallets/types/GetV1StaticWalletsStaticWalletIdDepositsRequestOrder.d.ts +5 -0
- package/dist/cjs/api/resources/staticWallets/types/GetV1StaticWalletsStaticWalletIdDepositsRequestOrder.js +8 -0
- package/dist/cjs/api/resources/staticWallets/types/index.d.ts +2 -0
- package/dist/cjs/api/resources/staticWallets/types/index.js +18 -0
- package/dist/cjs/api/types/CryptopayAssetId.d.ts +32 -0
- package/dist/cjs/api/types/CryptopayAssetId.js +35 -0
- package/dist/cjs/api/types/CryptopayListPaymentsResponse.d.ts +2 -2
- package/dist/cjs/api/types/CryptopayListStaticDepositsResponse.d.ts +2 -2
- package/dist/cjs/api/types/CryptopayListStaticWalletsResponse.d.ts +2 -2
- package/dist/cjs/api/types/CryptopayPaymentResponse.d.ts +6 -6
- package/dist/cjs/api/types/CryptopayPublicPaymentResponse.d.ts +5 -5
- package/dist/cjs/api/types/CryptopayRedirectConfigDto.d.ts +11 -1
- package/dist/cjs/api/types/CryptopayRedirectConfigDto.js +11 -0
- package/dist/cjs/api/types/CryptopayStaticDepositResponse.d.ts +13 -2
- package/dist/cjs/api/types/CryptopayStaticDepositResponse.js +11 -0
- package/dist/cjs/api/types/CryptopayStaticWalletResponse.d.ts +2 -1
- package/dist/cjs/api/types/index.d.ts +1 -0
- package/dist/cjs/api/types/index.js +1 -0
- package/dist/cjs/auth/HeaderAuthProvider.d.ts +1 -1
- package/dist/cjs/auth/HeaderAuthProvider.js +1 -1
- package/dist/cjs/errors/{SuwardApiError.d.ts → SuwardSDKError.d.ts} +1 -1
- package/dist/cjs/errors/{SuwardApiError.js → SuwardSDKError.js} +4 -4
- package/dist/{esm/errors/SuwardApiTimeoutError.d.mts → cjs/errors/SuwardSDKTimeoutError.d.ts} +1 -1
- package/dist/cjs/errors/{SuwardApiTimeoutError.js → SuwardSDKTimeoutError.js} +4 -4
- package/dist/cjs/errors/handleNonStatusCodeError.js +5 -5
- package/dist/cjs/errors/index.d.ts +2 -2
- package/dist/cjs/errors/index.js +5 -5
- package/dist/cjs/index.d.ts +3 -3
- package/dist/cjs/index.js +5 -5
- package/dist/cjs/version.d.ts +1 -1
- package/dist/cjs/version.js +1 -1
- package/dist/esm/BaseClient.mjs +3 -3
- package/dist/esm/Client.d.mts +4 -4
- package/dist/esm/Client.mjs +1 -1
- package/dist/esm/api/errors/BadRequestError.d.mts +3 -3
- package/dist/esm/api/errors/BadRequestError.mjs +1 -1
- package/dist/esm/api/errors/InternalServerError.d.mts +3 -3
- package/dist/esm/api/errors/InternalServerError.mjs +1 -1
- package/dist/esm/api/errors/NotFoundError.d.mts +3 -3
- package/dist/esm/api/errors/NotFoundError.mjs +1 -1
- package/dist/esm/api/errors/UnauthorizedError.d.mts +3 -3
- package/dist/esm/api/errors/UnauthorizedError.mjs +1 -1
- package/dist/esm/api/resources/index.d.mts +1 -0
- package/dist/esm/api/resources/index.mjs +1 -0
- package/dist/esm/api/resources/payments/client/Client.d.mts +38 -23
- package/dist/esm/api/resources/payments/client/Client.mjs +89 -36
- package/dist/esm/api/resources/payments/client/requests/CryptopayCreatePaymentRequest.d.mts +3 -3
- package/dist/esm/api/resources/payments/client/requests/CryptopaySimulatePaymentRequest.d.mts +2 -2
- package/dist/esm/api/resources/payments/client/requests/GetV1PaymentsRequest.d.mts +3 -2
- package/dist/esm/api/resources/payments/client/requests/PostV1PaymentsPaymentIdActivateRequest.d.mts +10 -0
- package/dist/esm/api/resources/payments/client/requests/PostV1PaymentsPaymentIdActivateRequest.mjs +2 -0
- package/dist/esm/api/resources/payments/client/requests/index.d.mts +1 -0
- package/dist/esm/api/resources/payments/types/GetV1PaymentsPaymentIdResponse.d.mts +2 -2
- package/dist/esm/api/resources/payments/types/GetV1PaymentsRequestOrder.d.mts +5 -0
- package/dist/esm/api/resources/payments/types/GetV1PaymentsRequestOrder.mjs +5 -0
- package/dist/esm/api/resources/payments/types/index.d.mts +1 -0
- package/dist/esm/api/resources/payments/types/index.mjs +1 -0
- package/dist/esm/api/resources/staticWallets/client/Client.d.mts +24 -23
- package/dist/esm/api/resources/staticWallets/client/Client.mjs +59 -39
- package/dist/esm/api/resources/staticWallets/client/requests/CryptopayCreateStaticWalletRequest.d.mts +2 -1
- package/dist/esm/api/resources/staticWallets/client/requests/CryptopaySimulateStaticDepositRequest.d.mts +12 -2
- package/dist/esm/api/resources/staticWallets/client/requests/CryptopaySimulateStaticDepositRequest.mjs +9 -1
- package/dist/esm/api/resources/staticWallets/client/requests/CryptopayUpdateStaticWalletRequest.d.mts +2 -1
- package/dist/esm/api/resources/staticWallets/client/requests/GetV1StaticWalletsRequest.d.mts +13 -0
- package/dist/esm/api/resources/staticWallets/client/requests/GetV1StaticWalletsRequest.mjs +2 -0
- package/dist/esm/api/resources/staticWallets/client/requests/GetV1StaticWalletsStaticWalletIdDepositsRequest.d.mts +7 -0
- package/dist/esm/api/resources/staticWallets/client/requests/index.d.mts +2 -1
- package/dist/esm/api/resources/staticWallets/client/requests/index.mjs +1 -1
- package/dist/esm/api/resources/staticWallets/index.d.mts +1 -0
- package/dist/esm/api/resources/staticWallets/index.mjs +1 -0
- package/dist/esm/api/resources/staticWallets/types/GetV1StaticWalletsRequestOrder.d.mts +5 -0
- package/dist/esm/api/resources/staticWallets/types/GetV1StaticWalletsRequestOrder.mjs +5 -0
- package/dist/esm/api/resources/staticWallets/types/GetV1StaticWalletsStaticWalletIdDepositsRequestOrder.d.mts +5 -0
- package/dist/esm/api/resources/staticWallets/types/GetV1StaticWalletsStaticWalletIdDepositsRequestOrder.mjs +5 -0
- package/dist/esm/api/resources/staticWallets/types/index.d.mts +2 -0
- package/dist/esm/api/resources/staticWallets/types/index.mjs +2 -0
- package/dist/esm/api/types/CryptopayAssetId.d.mts +32 -0
- package/dist/esm/api/types/CryptopayAssetId.mjs +32 -0
- package/dist/esm/api/types/CryptopayListPaymentsResponse.d.mts +2 -2
- package/dist/esm/api/types/CryptopayListStaticDepositsResponse.d.mts +2 -2
- package/dist/esm/api/types/CryptopayListStaticWalletsResponse.d.mts +2 -2
- package/dist/esm/api/types/CryptopayPaymentResponse.d.mts +6 -6
- package/dist/esm/api/types/CryptopayPublicPaymentResponse.d.mts +5 -5
- package/dist/esm/api/types/CryptopayRedirectConfigDto.d.mts +11 -1
- package/dist/esm/api/types/CryptopayRedirectConfigDto.mjs +10 -1
- package/dist/esm/api/types/CryptopayStaticDepositResponse.d.mts +13 -2
- package/dist/esm/api/types/CryptopayStaticDepositResponse.mjs +10 -1
- package/dist/esm/api/types/CryptopayStaticWalletResponse.d.mts +2 -1
- package/dist/esm/api/types/index.d.mts +1 -0
- package/dist/esm/api/types/index.mjs +1 -0
- package/dist/esm/auth/HeaderAuthProvider.d.mts +1 -1
- package/dist/esm/auth/HeaderAuthProvider.mjs +1 -1
- package/dist/esm/errors/{SuwardApiError.d.mts → SuwardSDKError.d.mts} +1 -1
- package/dist/esm/errors/{SuwardApiError.mjs → SuwardSDKError.mjs} +2 -2
- package/dist/{cjs/errors/SuwardApiTimeoutError.d.ts → esm/errors/SuwardSDKTimeoutError.d.mts} +1 -1
- package/dist/esm/errors/{SuwardApiTimeoutError.mjs → SuwardSDKTimeoutError.mjs} +2 -2
- package/dist/esm/errors/handleNonStatusCodeError.mjs +5 -5
- package/dist/esm/errors/index.d.mts +2 -2
- package/dist/esm/errors/index.mjs +2 -2
- package/dist/esm/index.d.mts +3 -3
- package/dist/esm/index.mjs +3 -3
- package/dist/esm/version.d.mts +1 -1
- package/dist/esm/version.mjs +1 -1
- package/package.json +86 -82
- package/reference.md +771 -0
|
@@ -24,32 +24,43 @@ import { mergeHeaders } from "../../../../core/headers.mjs";
|
|
|
24
24
|
import * as core from "../../../../core/index.mjs";
|
|
25
25
|
import { handleNonStatusCodeError } from "../../../../errors/handleNonStatusCodeError.mjs";
|
|
26
26
|
import * as errors from "../../../../errors/index.mjs";
|
|
27
|
-
import * as
|
|
27
|
+
import * as SuwardSDK from "../../../index.mjs";
|
|
28
28
|
export class StaticWalletsClient {
|
|
29
29
|
constructor(options) {
|
|
30
30
|
this._options = normalizeClientOptionsWithAuth(options);
|
|
31
31
|
}
|
|
32
32
|
/**
|
|
33
|
+
* @param {SuwardSDK.GetV1StaticWalletsRequest} request
|
|
33
34
|
* @param {StaticWalletsClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
34
35
|
*
|
|
35
|
-
* @throws {@link
|
|
36
|
+
* @throws {@link SuwardSDK.UnauthorizedError}
|
|
36
37
|
*
|
|
37
38
|
* @example
|
|
38
39
|
* await client.staticWallets.listStaticWallets()
|
|
39
40
|
*/
|
|
40
|
-
listStaticWallets(requestOptions) {
|
|
41
|
-
return core.HttpResponsePromise.fromPromise(this.__listStaticWallets(requestOptions));
|
|
41
|
+
listStaticWallets(request = {}, requestOptions) {
|
|
42
|
+
return core.HttpResponsePromise.fromPromise(this.__listStaticWallets(request, requestOptions));
|
|
42
43
|
}
|
|
43
|
-
__listStaticWallets(
|
|
44
|
-
return __awaiter(this,
|
|
44
|
+
__listStaticWallets() {
|
|
45
|
+
return __awaiter(this, arguments, void 0, function* (request = {}, requestOptions) {
|
|
45
46
|
var _a, _b, _c, _d, _e, _f, _g, _h;
|
|
47
|
+
const { order, limit, lastId } = request;
|
|
48
|
+
const _queryParams = {
|
|
49
|
+
order: order != null ? order : undefined,
|
|
50
|
+
limit,
|
|
51
|
+
lastId,
|
|
52
|
+
};
|
|
46
53
|
const _authRequest = yield this._options.authProvider.getAuthRequest();
|
|
47
54
|
const _headers = mergeHeaders(_authRequest.headers, (_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
48
55
|
const _response = yield core.fetcher({
|
|
49
56
|
url: core.url.join((_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment)), "v1/static-wallets"),
|
|
50
57
|
method: "GET",
|
|
51
58
|
headers: _headers,
|
|
52
|
-
queryString: core.url
|
|
59
|
+
queryString: core.url
|
|
60
|
+
.queryBuilder()
|
|
61
|
+
.addMany(_queryParams)
|
|
62
|
+
.mergeAdditional(requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams)
|
|
63
|
+
.build(),
|
|
53
64
|
timeoutMs: ((_e = (_c = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _c !== void 0 ? _c : (_d = this._options) === null || _d === void 0 ? void 0 : _d.timeoutInSeconds) !== null && _e !== void 0 ? _e : 60) * 1000,
|
|
54
65
|
maxRetries: (_f = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _f !== void 0 ? _f : (_g = this._options) === null || _g === void 0 ? void 0 : _g.maxRetries,
|
|
55
66
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
@@ -65,9 +76,9 @@ export class StaticWalletsClient {
|
|
|
65
76
|
if (_response.error.reason === "status-code") {
|
|
66
77
|
switch (_response.error.statusCode) {
|
|
67
78
|
case 401:
|
|
68
|
-
throw new
|
|
79
|
+
throw new SuwardSDK.UnauthorizedError(_response.error.body, _response.rawResponse);
|
|
69
80
|
default:
|
|
70
|
-
throw new errors.
|
|
81
|
+
throw new errors.SuwardSDKError({
|
|
71
82
|
statusCode: _response.error.statusCode,
|
|
72
83
|
body: _response.error.body,
|
|
73
84
|
rawResponse: _response.rawResponse,
|
|
@@ -80,11 +91,11 @@ export class StaticWalletsClient {
|
|
|
80
91
|
/**
|
|
81
92
|
* Create a reusable deposit address with an accepted-asset allow-list
|
|
82
93
|
*
|
|
83
|
-
* @param {
|
|
94
|
+
* @param {SuwardSDK.CryptopayCreateStaticWalletRequest} request
|
|
84
95
|
* @param {StaticWalletsClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
85
96
|
*
|
|
86
|
-
* @throws {@link
|
|
87
|
-
* @throws {@link
|
|
97
|
+
* @throws {@link SuwardSDK.BadRequestError}
|
|
98
|
+
* @throws {@link SuwardSDK.UnauthorizedError}
|
|
88
99
|
*
|
|
89
100
|
* @example
|
|
90
101
|
* await client.staticWallets.createStaticWallet()
|
|
@@ -120,11 +131,11 @@ export class StaticWalletsClient {
|
|
|
120
131
|
if (_response.error.reason === "status-code") {
|
|
121
132
|
switch (_response.error.statusCode) {
|
|
122
133
|
case 400:
|
|
123
|
-
throw new
|
|
134
|
+
throw new SuwardSDK.BadRequestError(_response.error.body, _response.rawResponse);
|
|
124
135
|
case 401:
|
|
125
|
-
throw new
|
|
136
|
+
throw new SuwardSDK.UnauthorizedError(_response.error.body, _response.rawResponse);
|
|
126
137
|
default:
|
|
127
|
-
throw new errors.
|
|
138
|
+
throw new errors.SuwardSDKError({
|
|
128
139
|
statusCode: _response.error.statusCode,
|
|
129
140
|
body: _response.error.body,
|
|
130
141
|
rawResponse: _response.rawResponse,
|
|
@@ -135,10 +146,10 @@ export class StaticWalletsClient {
|
|
|
135
146
|
});
|
|
136
147
|
}
|
|
137
148
|
/**
|
|
138
|
-
* @param {
|
|
149
|
+
* @param {SuwardSDK.GetV1StaticWalletsStaticWalletIdRequest} request
|
|
139
150
|
* @param {StaticWalletsClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
140
151
|
*
|
|
141
|
-
* @throws {@link
|
|
152
|
+
* @throws {@link SuwardSDK.NotFoundError}
|
|
142
153
|
*
|
|
143
154
|
* @example
|
|
144
155
|
* await client.staticWallets.getStaticWallet({
|
|
@@ -174,9 +185,9 @@ export class StaticWalletsClient {
|
|
|
174
185
|
if (_response.error.reason === "status-code") {
|
|
175
186
|
switch (_response.error.statusCode) {
|
|
176
187
|
case 404:
|
|
177
|
-
throw new
|
|
188
|
+
throw new SuwardSDK.NotFoundError(_response.error.body, _response.rawResponse);
|
|
178
189
|
default:
|
|
179
|
-
throw new errors.
|
|
190
|
+
throw new errors.SuwardSDKError({
|
|
180
191
|
statusCode: _response.error.statusCode,
|
|
181
192
|
body: _response.error.body,
|
|
182
193
|
rawResponse: _response.rawResponse,
|
|
@@ -187,10 +198,10 @@ export class StaticWalletsClient {
|
|
|
187
198
|
});
|
|
188
199
|
}
|
|
189
200
|
/**
|
|
190
|
-
* @param {
|
|
201
|
+
* @param {SuwardSDK.DeleteV1StaticWalletsStaticWalletIdRequest} request
|
|
191
202
|
* @param {StaticWalletsClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
192
203
|
*
|
|
193
|
-
* @throws {@link
|
|
204
|
+
* @throws {@link SuwardSDK.NotFoundError}
|
|
194
205
|
*
|
|
195
206
|
* @example
|
|
196
207
|
* await client.staticWallets.deleteStaticWallet({
|
|
@@ -223,9 +234,9 @@ export class StaticWalletsClient {
|
|
|
223
234
|
if (_response.error.reason === "status-code") {
|
|
224
235
|
switch (_response.error.statusCode) {
|
|
225
236
|
case 404:
|
|
226
|
-
throw new
|
|
237
|
+
throw new SuwardSDK.NotFoundError(_response.error.body, _response.rawResponse);
|
|
227
238
|
default:
|
|
228
|
-
throw new errors.
|
|
239
|
+
throw new errors.SuwardSDKError({
|
|
229
240
|
statusCode: _response.error.statusCode,
|
|
230
241
|
body: _response.error.body,
|
|
231
242
|
rawResponse: _response.rawResponse,
|
|
@@ -236,10 +247,10 @@ export class StaticWalletsClient {
|
|
|
236
247
|
});
|
|
237
248
|
}
|
|
238
249
|
/**
|
|
239
|
-
* @param {
|
|
250
|
+
* @param {SuwardSDK.CryptopayUpdateStaticWalletRequest} request
|
|
240
251
|
* @param {StaticWalletsClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
241
252
|
*
|
|
242
|
-
* @throws {@link
|
|
253
|
+
* @throws {@link SuwardSDK.BadRequestError}
|
|
243
254
|
*
|
|
244
255
|
* @example
|
|
245
256
|
* await client.staticWallets.updateStaticWallet({
|
|
@@ -278,9 +289,9 @@ export class StaticWalletsClient {
|
|
|
278
289
|
if (_response.error.reason === "status-code") {
|
|
279
290
|
switch (_response.error.statusCode) {
|
|
280
291
|
case 400:
|
|
281
|
-
throw new
|
|
292
|
+
throw new SuwardSDK.BadRequestError(_response.error.body, _response.rawResponse);
|
|
282
293
|
default:
|
|
283
|
-
throw new errors.
|
|
294
|
+
throw new errors.SuwardSDKError({
|
|
284
295
|
statusCode: _response.error.statusCode,
|
|
285
296
|
body: _response.error.body,
|
|
286
297
|
rawResponse: _response.rawResponse,
|
|
@@ -291,10 +302,10 @@ export class StaticWalletsClient {
|
|
|
291
302
|
});
|
|
292
303
|
}
|
|
293
304
|
/**
|
|
294
|
-
* @param {
|
|
305
|
+
* @param {SuwardSDK.GetV1StaticWalletsStaticWalletIdDepositsRequest} request
|
|
295
306
|
* @param {StaticWalletsClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
296
307
|
*
|
|
297
|
-
* @throws {@link
|
|
308
|
+
* @throws {@link SuwardSDK.NotFoundError}
|
|
298
309
|
*
|
|
299
310
|
* @example
|
|
300
311
|
* await client.staticWallets.listStaticWalletDeposits({
|
|
@@ -307,14 +318,23 @@ export class StaticWalletsClient {
|
|
|
307
318
|
__listStaticWalletDeposits(request, requestOptions) {
|
|
308
319
|
return __awaiter(this, void 0, void 0, function* () {
|
|
309
320
|
var _a, _b, _c, _d, _e, _f, _g, _h;
|
|
310
|
-
const { staticWalletId } = request;
|
|
321
|
+
const { staticWalletId, order, limit, lastId } = request;
|
|
322
|
+
const _queryParams = {
|
|
323
|
+
order: order != null ? order : undefined,
|
|
324
|
+
limit,
|
|
325
|
+
lastId,
|
|
326
|
+
};
|
|
311
327
|
const _authRequest = yield this._options.authProvider.getAuthRequest();
|
|
312
328
|
const _headers = mergeHeaders(_authRequest.headers, (_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
313
329
|
const _response = yield core.fetcher({
|
|
314
330
|
url: core.url.join((_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment)), `v1/static-wallets/${core.url.encodePathParam(staticWalletId)}/deposits`),
|
|
315
331
|
method: "GET",
|
|
316
332
|
headers: _headers,
|
|
317
|
-
queryString: core.url
|
|
333
|
+
queryString: core.url
|
|
334
|
+
.queryBuilder()
|
|
335
|
+
.addMany(_queryParams)
|
|
336
|
+
.mergeAdditional(requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams)
|
|
337
|
+
.build(),
|
|
318
338
|
timeoutMs: ((_e = (_c = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _c !== void 0 ? _c : (_d = this._options) === null || _d === void 0 ? void 0 : _d.timeoutInSeconds) !== null && _e !== void 0 ? _e : 60) * 1000,
|
|
319
339
|
maxRetries: (_f = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _f !== void 0 ? _f : (_g = this._options) === null || _g === void 0 ? void 0 : _g.maxRetries,
|
|
320
340
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
@@ -330,9 +350,9 @@ export class StaticWalletsClient {
|
|
|
330
350
|
if (_response.error.reason === "status-code") {
|
|
331
351
|
switch (_response.error.statusCode) {
|
|
332
352
|
case 404:
|
|
333
|
-
throw new
|
|
353
|
+
throw new SuwardSDK.NotFoundError(_response.error.body, _response.rawResponse);
|
|
334
354
|
default:
|
|
335
|
-
throw new errors.
|
|
355
|
+
throw new errors.SuwardSDKError({
|
|
336
356
|
statusCode: _response.error.statusCode,
|
|
337
357
|
body: _response.error.body,
|
|
338
358
|
rawResponse: _response.rawResponse,
|
|
@@ -345,11 +365,11 @@ export class StaticWalletsClient {
|
|
|
345
365
|
/**
|
|
346
366
|
* Drive a synthetic deposit through its lifecycle on a test wallet (no on-chain activity, no balance credit). Test wallets only.
|
|
347
367
|
*
|
|
348
|
-
* @param {
|
|
368
|
+
* @param {SuwardSDK.CryptopaySimulateStaticDepositRequest} request
|
|
349
369
|
* @param {StaticWalletsClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
350
370
|
*
|
|
351
|
-
* @throws {@link
|
|
352
|
-
* @throws {@link
|
|
371
|
+
* @throws {@link SuwardSDK.BadRequestError}
|
|
372
|
+
* @throws {@link SuwardSDK.NotFoundError}
|
|
353
373
|
*
|
|
354
374
|
* @example
|
|
355
375
|
* await client.staticWallets.simulateStaticWalletDeposit({
|
|
@@ -388,11 +408,11 @@ export class StaticWalletsClient {
|
|
|
388
408
|
if (_response.error.reason === "status-code") {
|
|
389
409
|
switch (_response.error.statusCode) {
|
|
390
410
|
case 400:
|
|
391
|
-
throw new
|
|
411
|
+
throw new SuwardSDK.BadRequestError(_response.error.body, _response.rawResponse);
|
|
392
412
|
case 404:
|
|
393
|
-
throw new
|
|
413
|
+
throw new SuwardSDK.NotFoundError(_response.error.body, _response.rawResponse);
|
|
394
414
|
default:
|
|
395
|
-
throw new errors.
|
|
415
|
+
throw new errors.SuwardSDKError({
|
|
396
416
|
statusCode: _response.error.statusCode,
|
|
397
417
|
body: _response.error.body,
|
|
398
418
|
rawResponse: _response.rawResponse,
|
|
@@ -1,9 +1,10 @@
|
|
|
1
|
+
import type * as SuwardSDK from "../../../../index.mjs";
|
|
1
2
|
/**
|
|
2
3
|
* @example
|
|
3
4
|
* {}
|
|
4
5
|
*/
|
|
5
6
|
export interface CryptopayCreateStaticWalletRequest {
|
|
6
|
-
allowedAssets?:
|
|
7
|
+
allowedAssets?: SuwardSDK.CryptopayAssetId[];
|
|
7
8
|
externalId?: string;
|
|
8
9
|
isTest?: boolean;
|
|
9
10
|
metadata?: Record<string, unknown>;
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import type * as SuwardSDK from "../../../../index.mjs";
|
|
1
2
|
/**
|
|
2
3
|
* @example
|
|
3
4
|
* {
|
|
@@ -8,8 +9,17 @@ export interface CryptopaySimulateStaticDepositRequest {
|
|
|
8
9
|
/** Static wallet ID */
|
|
9
10
|
staticWalletId: string;
|
|
10
11
|
amount?: string;
|
|
11
|
-
asset?:
|
|
12
|
-
status?:
|
|
12
|
+
asset?: SuwardSDK.CryptopayAssetId;
|
|
13
|
+
status?: CryptopaySimulateStaticDepositRequest.Status;
|
|
13
14
|
transferIndex?: string;
|
|
14
15
|
txHash?: string;
|
|
15
16
|
}
|
|
17
|
+
export declare namespace CryptopaySimulateStaticDepositRequest {
|
|
18
|
+
const Status: {
|
|
19
|
+
readonly Detected: "detected";
|
|
20
|
+
readonly Accepted: "accepted";
|
|
21
|
+
readonly Confirmed: "confirmed";
|
|
22
|
+
readonly Invalidated: "invalidated";
|
|
23
|
+
};
|
|
24
|
+
type Status = (typeof Status)[keyof typeof Status];
|
|
25
|
+
}
|
|
@@ -1,2 +1,10 @@
|
|
|
1
1
|
// This file was auto-generated by Fern from our API Definition.
|
|
2
|
-
export
|
|
2
|
+
export var CryptopaySimulateStaticDepositRequest;
|
|
3
|
+
(function (CryptopaySimulateStaticDepositRequest) {
|
|
4
|
+
CryptopaySimulateStaticDepositRequest.Status = {
|
|
5
|
+
Detected: "detected",
|
|
6
|
+
Accepted: "accepted",
|
|
7
|
+
Confirmed: "confirmed",
|
|
8
|
+
Invalidated: "invalidated",
|
|
9
|
+
};
|
|
10
|
+
})(CryptopaySimulateStaticDepositRequest || (CryptopaySimulateStaticDepositRequest = {}));
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import type * as SuwardSDK from "../../../../index.mjs";
|
|
1
2
|
/**
|
|
2
3
|
* @example
|
|
3
4
|
* {
|
|
@@ -7,7 +8,7 @@
|
|
|
7
8
|
export interface CryptopayUpdateStaticWalletRequest {
|
|
8
9
|
/** Static wallet ID */
|
|
9
10
|
staticWalletId: string;
|
|
10
|
-
allowedAssets?:
|
|
11
|
+
allowedAssets?: SuwardSDK.CryptopayAssetId[];
|
|
11
12
|
metadata?: Record<string, unknown>;
|
|
12
13
|
webhookUrl?: string;
|
|
13
14
|
}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import type * as SuwardSDK from "../../../../index.mjs";
|
|
2
|
+
/**
|
|
3
|
+
* @example
|
|
4
|
+
* {}
|
|
5
|
+
*/
|
|
6
|
+
export interface GetV1StaticWalletsRequest {
|
|
7
|
+
/** Sort order (asc/desc) */
|
|
8
|
+
order?: SuwardSDK.GetV1StaticWalletsRequestOrder;
|
|
9
|
+
/** Limit (default 20, max 100) */
|
|
10
|
+
limit?: number;
|
|
11
|
+
/** Last ID for pagination */
|
|
12
|
+
lastId?: string;
|
|
13
|
+
}
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import type * as SuwardSDK from "../../../../index.mjs";
|
|
1
2
|
/**
|
|
2
3
|
* @example
|
|
3
4
|
* {
|
|
@@ -7,4 +8,10 @@
|
|
|
7
8
|
export interface GetV1StaticWalletsStaticWalletIdDepositsRequest {
|
|
8
9
|
/** Static wallet ID */
|
|
9
10
|
staticWalletId: string;
|
|
11
|
+
/** Sort order (asc/desc) */
|
|
12
|
+
order?: SuwardSDK.GetV1StaticWalletsStaticWalletIdDepositsRequestOrder;
|
|
13
|
+
/** Limit (default 20, max 100) */
|
|
14
|
+
limit?: number;
|
|
15
|
+
/** Last ID for pagination */
|
|
16
|
+
lastId?: string;
|
|
10
17
|
}
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
export type { CryptopayCreateStaticWalletRequest } from "./CryptopayCreateStaticWalletRequest.mjs";
|
|
2
|
-
export
|
|
2
|
+
export { CryptopaySimulateStaticDepositRequest } from "./CryptopaySimulateStaticDepositRequest.mjs";
|
|
3
3
|
export type { CryptopayUpdateStaticWalletRequest } from "./CryptopayUpdateStaticWalletRequest.mjs";
|
|
4
4
|
export type { DeleteV1StaticWalletsStaticWalletIdRequest } from "./DeleteV1StaticWalletsStaticWalletIdRequest.mjs";
|
|
5
|
+
export type { GetV1StaticWalletsRequest } from "./GetV1StaticWalletsRequest.mjs";
|
|
5
6
|
export type { GetV1StaticWalletsStaticWalletIdDepositsRequest } from "./GetV1StaticWalletsStaticWalletIdDepositsRequest.mjs";
|
|
6
7
|
export type { GetV1StaticWalletsStaticWalletIdRequest } from "./GetV1StaticWalletsStaticWalletIdRequest.mjs";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export {};
|
|
1
|
+
export { CryptopaySimulateStaticDepositRequest } from "./CryptopaySimulateStaticDepositRequest.mjs";
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
export declare const GetV1StaticWalletsStaticWalletIdDepositsRequestOrder: {
|
|
2
|
+
readonly Asc: "asc";
|
|
3
|
+
readonly Desc: "desc";
|
|
4
|
+
};
|
|
5
|
+
export type GetV1StaticWalletsStaticWalletIdDepositsRequestOrder = (typeof GetV1StaticWalletsStaticWalletIdDepositsRequestOrder)[keyof typeof GetV1StaticWalletsStaticWalletIdDepositsRequestOrder];
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
/** Asset id-string (see GET /v1/assets), e.g. USDT_ETHEREUM. */
|
|
2
|
+
export declare const CryptopayAssetId: {
|
|
3
|
+
readonly UsdtEthereum: "USDT_ETHEREUM";
|
|
4
|
+
readonly UsdtArbitrum: "USDT_ARBITRUM";
|
|
5
|
+
readonly UsdtOptimism: "USDT_OPTIMISM";
|
|
6
|
+
readonly UsdtBase: "USDT_BASE";
|
|
7
|
+
readonly UsdtBsc: "USDT_BSC";
|
|
8
|
+
readonly UsdtPlasma: "USDT_PLASMA";
|
|
9
|
+
readonly UsdtPolygon: "USDT_POLYGON";
|
|
10
|
+
readonly UsdcEthereum: "USDC_ETHEREUM";
|
|
11
|
+
readonly UsdcArbitrum: "USDC_ARBITRUM";
|
|
12
|
+
readonly UsdCeArbitrum: "USDCE_ARBITRUM";
|
|
13
|
+
readonly UsdcOptimism: "USDC_OPTIMISM";
|
|
14
|
+
readonly UsdcBase: "USDC_BASE";
|
|
15
|
+
readonly UsdcBsc: "USDC_BSC";
|
|
16
|
+
readonly UsdcPlasma: "USDC_PLASMA";
|
|
17
|
+
readonly UsdcPolygon: "USDC_POLYGON";
|
|
18
|
+
readonly EthEthereum: "ETH_ETHEREUM";
|
|
19
|
+
readonly EthArbitrum: "ETH_ARBITRUM";
|
|
20
|
+
readonly EthOptimism: "ETH_OPTIMISM";
|
|
21
|
+
readonly EthBase: "ETH_BASE";
|
|
22
|
+
readonly XplPlasma: "XPL_PLASMA";
|
|
23
|
+
readonly BnbBsc: "BNB_BSC";
|
|
24
|
+
readonly PolPolygon: "POL_POLYGON";
|
|
25
|
+
readonly TestcoinEthereum: "TESTCOIN_ETHEREUM";
|
|
26
|
+
readonly TestcoinOptimism: "TESTCOIN_OPTIMISM";
|
|
27
|
+
readonly TestcoinPlasma: "TESTCOIN_PLASMA";
|
|
28
|
+
readonly TeststablecoinEthereum: "TESTSTABLECOIN_ETHEREUM";
|
|
29
|
+
readonly TeststablecoinOptimism: "TESTSTABLECOIN_OPTIMISM";
|
|
30
|
+
readonly TeststablecoinPlasma: "TESTSTABLECOIN_PLASMA";
|
|
31
|
+
};
|
|
32
|
+
export type CryptopayAssetId = (typeof CryptopayAssetId)[keyof typeof CryptopayAssetId];
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
// This file was auto-generated by Fern from our API Definition.
|
|
2
|
+
/** Asset id-string (see GET /v1/assets), e.g. USDT_ETHEREUM. */
|
|
3
|
+
export const CryptopayAssetId = {
|
|
4
|
+
UsdtEthereum: "USDT_ETHEREUM",
|
|
5
|
+
UsdtArbitrum: "USDT_ARBITRUM",
|
|
6
|
+
UsdtOptimism: "USDT_OPTIMISM",
|
|
7
|
+
UsdtBase: "USDT_BASE",
|
|
8
|
+
UsdtBsc: "USDT_BSC",
|
|
9
|
+
UsdtPlasma: "USDT_PLASMA",
|
|
10
|
+
UsdtPolygon: "USDT_POLYGON",
|
|
11
|
+
UsdcEthereum: "USDC_ETHEREUM",
|
|
12
|
+
UsdcArbitrum: "USDC_ARBITRUM",
|
|
13
|
+
UsdCeArbitrum: "USDCE_ARBITRUM",
|
|
14
|
+
UsdcOptimism: "USDC_OPTIMISM",
|
|
15
|
+
UsdcBase: "USDC_BASE",
|
|
16
|
+
UsdcBsc: "USDC_BSC",
|
|
17
|
+
UsdcPlasma: "USDC_PLASMA",
|
|
18
|
+
UsdcPolygon: "USDC_POLYGON",
|
|
19
|
+
EthEthereum: "ETH_ETHEREUM",
|
|
20
|
+
EthArbitrum: "ETH_ARBITRUM",
|
|
21
|
+
EthOptimism: "ETH_OPTIMISM",
|
|
22
|
+
EthBase: "ETH_BASE",
|
|
23
|
+
XplPlasma: "XPL_PLASMA",
|
|
24
|
+
BnbBsc: "BNB_BSC",
|
|
25
|
+
PolPolygon: "POL_POLYGON",
|
|
26
|
+
TestcoinEthereum: "TESTCOIN_ETHEREUM",
|
|
27
|
+
TestcoinOptimism: "TESTCOIN_OPTIMISM",
|
|
28
|
+
TestcoinPlasma: "TESTCOIN_PLASMA",
|
|
29
|
+
TeststablecoinEthereum: "TESTSTABLECOIN_ETHEREUM",
|
|
30
|
+
TeststablecoinOptimism: "TESTSTABLECOIN_OPTIMISM",
|
|
31
|
+
TeststablecoinPlasma: "TESTSTABLECOIN_PLASMA",
|
|
32
|
+
};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import type * as
|
|
1
|
+
import type * as SuwardSDK from "../index.mjs";
|
|
2
2
|
export interface CryptopayListPaymentsResponse {
|
|
3
3
|
hasMore?: boolean | undefined;
|
|
4
|
-
items?:
|
|
4
|
+
items?: SuwardSDK.CryptopayPaymentResponse[] | undefined;
|
|
5
5
|
lastId?: string | undefined;
|
|
6
6
|
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import type * as
|
|
1
|
+
import type * as SuwardSDK from "../index.mjs";
|
|
2
2
|
export interface CryptopayListStaticDepositsResponse {
|
|
3
3
|
hasMore?: boolean | undefined;
|
|
4
|
-
items?:
|
|
4
|
+
items?: SuwardSDK.CryptopayStaticDepositResponse[] | undefined;
|
|
5
5
|
lastId?: string | undefined;
|
|
6
6
|
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import type * as
|
|
1
|
+
import type * as SuwardSDK from "../index.mjs";
|
|
2
2
|
export interface CryptopayListStaticWalletsResponse {
|
|
3
3
|
hasMore?: boolean | undefined;
|
|
4
|
-
items?:
|
|
4
|
+
items?: SuwardSDK.CryptopayStaticWalletResponse[] | undefined;
|
|
5
5
|
lastId?: string | undefined;
|
|
6
6
|
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type * as
|
|
1
|
+
import type * as SuwardSDK from "../index.mjs";
|
|
2
2
|
export interface CryptopayPaymentResponse {
|
|
3
3
|
acceptedAt?: number | undefined;
|
|
4
4
|
activatedAt?: number | undefined;
|
|
@@ -7,7 +7,7 @@ export interface CryptopayPaymentResponse {
|
|
|
7
7
|
amount?: string | undefined;
|
|
8
8
|
amountConfirmed?: string | undefined;
|
|
9
9
|
amountReceived?: string | undefined;
|
|
10
|
-
asset?:
|
|
10
|
+
asset?: SuwardSDK.CryptopayAssetId | undefined;
|
|
11
11
|
createdAt?: number | undefined;
|
|
12
12
|
expiresAt?: number | undefined;
|
|
13
13
|
externalId?: string | undefined;
|
|
@@ -18,10 +18,10 @@ export interface CryptopayPaymentResponse {
|
|
|
18
18
|
networkFee?: string | undefined;
|
|
19
19
|
paymentWindowSeconds?: number | undefined;
|
|
20
20
|
projectId?: string | undefined;
|
|
21
|
-
redirect?:
|
|
22
|
-
status?:
|
|
23
|
-
subStatus?:
|
|
24
|
-
transactions?:
|
|
21
|
+
redirect?: SuwardSDK.CryptopayRedirectConfigDto | undefined;
|
|
22
|
+
status?: SuwardSDK.CryptopayPaymentStatusEnum | undefined;
|
|
23
|
+
subStatus?: SuwardSDK.CryptopayPaymentSubStatusEnum | undefined;
|
|
24
|
+
transactions?: SuwardSDK.CryptopayTransactionResponse[] | undefined;
|
|
25
25
|
underpaymentTolerance?: string | undefined;
|
|
26
26
|
updatedAt?: number | undefined;
|
|
27
27
|
webhookUrl?: string | undefined;
|
|
@@ -1,18 +1,18 @@
|
|
|
1
|
-
import type * as
|
|
1
|
+
import type * as SuwardSDK from "../index.mjs";
|
|
2
2
|
export interface CryptopayPublicPaymentResponse {
|
|
3
3
|
activatedAt?: number | undefined;
|
|
4
4
|
activationFlowSeconds?: number | undefined;
|
|
5
5
|
address?: string | undefined;
|
|
6
6
|
amount?: string | undefined;
|
|
7
7
|
amountReceived?: string | undefined;
|
|
8
|
-
asset?:
|
|
8
|
+
asset?: SuwardSDK.CryptopayAssetId | undefined;
|
|
9
9
|
createdAt?: number | undefined;
|
|
10
10
|
expiresAt?: number | undefined;
|
|
11
11
|
id?: string | undefined;
|
|
12
12
|
paymentWindowSeconds?: number | undefined;
|
|
13
|
-
redirect?:
|
|
14
|
-
status?:
|
|
15
|
-
subStatus?:
|
|
13
|
+
redirect?: SuwardSDK.CryptopayPublicRedirect | undefined;
|
|
14
|
+
status?: SuwardSDK.CryptopayPaymentStatusEnum | undefined;
|
|
15
|
+
subStatus?: SuwardSDK.CryptopayPaymentSubStatusEnum | undefined;
|
|
16
16
|
underpaymentTolerance?: string | undefined;
|
|
17
17
|
updatedAt?: number | undefined;
|
|
18
18
|
}
|
|
@@ -1,5 +1,15 @@
|
|
|
1
1
|
export interface CryptopayRedirectConfigDto {
|
|
2
2
|
data?: string | undefined;
|
|
3
|
-
params?:
|
|
3
|
+
params?: CryptopayRedirectConfigDto.Params.Item[] | undefined;
|
|
4
4
|
url?: string | undefined;
|
|
5
5
|
}
|
|
6
|
+
export declare namespace CryptopayRedirectConfigDto {
|
|
7
|
+
type Params = Params.Item[];
|
|
8
|
+
namespace Params {
|
|
9
|
+
const Item: {
|
|
10
|
+
readonly Id: "id";
|
|
11
|
+
readonly ExternalId: "externalId";
|
|
12
|
+
};
|
|
13
|
+
type Item = (typeof Item)[keyof typeof Item];
|
|
14
|
+
}
|
|
15
|
+
}
|
|
@@ -1,2 +1,11 @@
|
|
|
1
1
|
// This file was auto-generated by Fern from our API Definition.
|
|
2
|
-
export
|
|
2
|
+
export var CryptopayRedirectConfigDto;
|
|
3
|
+
(function (CryptopayRedirectConfigDto) {
|
|
4
|
+
let Params;
|
|
5
|
+
(function (Params) {
|
|
6
|
+
Params.Item = {
|
|
7
|
+
Id: "id",
|
|
8
|
+
ExternalId: "externalId",
|
|
9
|
+
};
|
|
10
|
+
})(Params = CryptopayRedirectConfigDto.Params || (CryptopayRedirectConfigDto.Params = {}));
|
|
11
|
+
})(CryptopayRedirectConfigDto || (CryptopayRedirectConfigDto = {}));
|
|
@@ -1,8 +1,9 @@
|
|
|
1
|
+
import type * as SuwardSDK from "../index.mjs";
|
|
1
2
|
export interface CryptopayStaticDepositResponse {
|
|
2
3
|
acceptedAt?: number | undefined;
|
|
3
4
|
address?: string | undefined;
|
|
4
5
|
amount?: string | undefined;
|
|
5
|
-
asset?:
|
|
6
|
+
asset?: SuwardSDK.CryptopayAssetId | undefined;
|
|
6
7
|
confirmedAt?: number | undefined;
|
|
7
8
|
createdAt?: number | undefined;
|
|
8
9
|
detectedAt?: number | undefined;
|
|
@@ -13,8 +14,18 @@ export interface CryptopayStaticDepositResponse {
|
|
|
13
14
|
networkFee?: string | undefined;
|
|
14
15
|
projectId?: string | undefined;
|
|
15
16
|
staticWalletId?: string | undefined;
|
|
16
|
-
status?:
|
|
17
|
+
status?: CryptopayStaticDepositResponse.Status | undefined;
|
|
17
18
|
transferIndex?: string | undefined;
|
|
18
19
|
txHash?: string | undefined;
|
|
19
20
|
updatedAt?: number | undefined;
|
|
20
21
|
}
|
|
22
|
+
export declare namespace CryptopayStaticDepositResponse {
|
|
23
|
+
const Status: {
|
|
24
|
+
readonly Detected: "detected";
|
|
25
|
+
readonly Accepted: "accepted";
|
|
26
|
+
readonly Confirmed: "confirmed";
|
|
27
|
+
readonly Ignored: "ignored";
|
|
28
|
+
readonly Invalidated: "invalidated";
|
|
29
|
+
};
|
|
30
|
+
type Status = (typeof Status)[keyof typeof Status];
|
|
31
|
+
}
|
|
@@ -1,2 +1,11 @@
|
|
|
1
1
|
// This file was auto-generated by Fern from our API Definition.
|
|
2
|
-
export
|
|
2
|
+
export var CryptopayStaticDepositResponse;
|
|
3
|
+
(function (CryptopayStaticDepositResponse) {
|
|
4
|
+
CryptopayStaticDepositResponse.Status = {
|
|
5
|
+
Detected: "detected",
|
|
6
|
+
Accepted: "accepted",
|
|
7
|
+
Confirmed: "confirmed",
|
|
8
|
+
Ignored: "ignored",
|
|
9
|
+
Invalidated: "invalidated",
|
|
10
|
+
};
|
|
11
|
+
})(CryptopayStaticDepositResponse || (CryptopayStaticDepositResponse = {}));
|