@openweb3-io/wallet 0.1.1 → 0.1.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.
- package/README.md +2 -2
- package/dist/index.d.ts +2 -20
- package/dist/index.js +88 -179
- package/dist/index.js.map +1 -1
- package/dist/openapi/apis/AddressesApi.js +170 -203
- package/dist/openapi/apis/AddressesApi.js.map +1 -1
- package/dist/openapi/apis/CurrenciesApi.js +94 -119
- package/dist/openapi/apis/CurrenciesApi.js.map +1 -1
- package/dist/openapi/apis/ExchangesApi.js +278 -311
- package/dist/openapi/apis/ExchangesApi.js.map +1 -1
- package/dist/openapi/apis/NetworksApi.js +48 -65
- package/dist/openapi/apis/NetworksApi.js.map +1 -1
- package/dist/openapi/apis/RatesApi.js +105 -130
- package/dist/openapi/apis/RatesApi.js.map +1 -1
- package/dist/openapi/apis/TransactionsApi.js +256 -297
- package/dist/openapi/apis/TransactionsApi.js.map +1 -1
- package/dist/openapi/apis/WalletsApi.js +243 -292
- package/dist/openapi/apis/WalletsApi.js.map +1 -1
- package/dist/openapi/apis/WebhookEndpointsApi.js +190 -239
- package/dist/openapi/apis/WebhookEndpointsApi.js.map +1 -1
- package/dist/openapi/apis/WebhookEventTypesApi.js +31 -48
- package/dist/openapi/apis/WebhookEventTypesApi.js.map +1 -1
- package/dist/openapi/apis/WebhookEventsApi.js +83 -108
- package/dist/openapi/apis/WebhookEventsApi.js.map +1 -1
- package/dist/openapi/auth/auth.d.ts +0 -8
- package/dist/openapi/auth/auth.js +1 -16
- package/dist/openapi/auth/auth.js.map +1 -1
- package/dist/openapi/dist/apis/AddressesApi.d.ts +12 -0
- package/dist/openapi/dist/apis/AddressesApi.js +222 -0
- package/dist/openapi/dist/apis/AddressesApi.js.map +1 -0
- package/dist/openapi/dist/apis/CurrenciesApi.d.ts +10 -0
- package/dist/openapi/dist/apis/CurrenciesApi.js +140 -0
- package/dist/openapi/dist/apis/CurrenciesApi.js.map +1 -0
- package/dist/openapi/dist/apis/ExchangesApi.d.ts +18 -0
- package/dist/openapi/dist/apis/ExchangesApi.js +348 -0
- package/dist/openapi/dist/apis/ExchangesApi.js.map +1 -0
- package/dist/openapi/dist/apis/NetworksApi.d.ts +8 -0
- package/dist/openapi/dist/apis/NetworksApi.js +88 -0
- package/dist/openapi/dist/apis/NetworksApi.js.map +1 -0
- package/dist/openapi/dist/apis/RatesApi.d.ts +10 -0
- package/dist/openapi/dist/apis/RatesApi.js +151 -0
- package/dist/openapi/dist/apis/RatesApi.js.map +1 -0
- package/dist/openapi/dist/apis/TransactionsApi.d.ts +16 -0
- package/dist/openapi/dist/apis/TransactionsApi.js +320 -0
- package/dist/openapi/dist/apis/TransactionsApi.js.map +1 -0
- package/dist/openapi/dist/apis/WalletsApi.d.ts +16 -0
- package/dist/openapi/dist/apis/WalletsApi.js +307 -0
- package/dist/openapi/dist/apis/WalletsApi.js.map +1 -0
- package/dist/openapi/dist/apis/WebhookEndpointsApi.d.ts +16 -0
- package/dist/openapi/dist/apis/WebhookEndpointsApi.js +254 -0
- package/dist/openapi/dist/apis/WebhookEndpointsApi.js.map +1 -0
- package/dist/openapi/dist/apis/WebhookEventTypesApi.d.ts +8 -0
- package/dist/openapi/dist/apis/WebhookEventTypesApi.js +71 -0
- package/dist/openapi/dist/apis/WebhookEventTypesApi.js.map +1 -0
- package/dist/openapi/dist/apis/WebhookEventsApi.d.ts +10 -0
- package/dist/openapi/dist/apis/WebhookEventsApi.js +129 -0
- package/dist/openapi/dist/apis/WebhookEventsApi.js.map +1 -0
- package/dist/openapi/dist/apis/baseapi.d.ts +14 -0
- package/dist/openapi/dist/apis/baseapi.js +25 -0
- package/dist/openapi/dist/apis/baseapi.js.map +1 -0
- package/dist/openapi/dist/apis/exception.d.ts +5 -0
- package/dist/openapi/dist/apis/exception.js +12 -0
- package/dist/openapi/dist/apis/exception.js.map +1 -0
- package/dist/openapi/dist/auth/auth.d.ts +9 -0
- package/dist/openapi/dist/auth/auth.js +27 -0
- package/dist/openapi/dist/auth/auth.js.map +1 -0
- package/dist/openapi/dist/configuration.d.ts +6 -0
- package/dist/openapi/dist/configuration.js +21 -0
- package/dist/openapi/dist/configuration.js.map +1 -0
- package/dist/openapi/dist/http/http.d.ts +40 -0
- package/dist/openapi/dist/http/http.js +171 -0
- package/dist/openapi/dist/http/http.js.map +1 -0
- package/dist/openapi/dist/http/isomorphic-fetch.d.ts +3 -0
- package/dist/openapi/dist/http/isomorphic-fetch.js +31 -0
- package/dist/openapi/dist/http/isomorphic-fetch.js.map +1 -0
- package/dist/openapi/dist/index.d.ts +7 -0
- package/dist/openapi/dist/index.js +31 -0
- package/dist/openapi/dist/index.js.map +1 -0
- package/dist/openapi/dist/middleware.d.ts +6 -0
- package/dist/openapi/dist/middleware.js +17 -0
- package/dist/openapi/dist/middleware.js.map +1 -0
- package/dist/openapi/dist/models/Account.d.ts +17 -0
- package/dist/openapi/dist/models/Account.js +51 -0
- package/dist/openapi/dist/models/Account.js.map +1 -0
- package/dist/openapi/dist/models/Address.d.ts +17 -0
- package/dist/openapi/dist/models/Address.js +33 -0
- package/dist/openapi/dist/models/Address.js.map +1 -0
- package/dist/openapi/dist/models/ChainNetwork.d.ts +17 -0
- package/dist/openapi/dist/models/ChainNetwork.js +63 -0
- package/dist/openapi/dist/models/ChainNetwork.js.map +1 -0
- package/dist/openapi/dist/models/CreateEndpoint.d.ts +17 -0
- package/dist/openapi/dist/models/CreateEndpoint.js +57 -0
- package/dist/openapi/dist/models/CreateEndpoint.js.map +1 -0
- package/dist/openapi/dist/models/CreateExchange.d.ts +17 -0
- package/dist/openapi/dist/models/CreateExchange.js +45 -0
- package/dist/openapi/dist/models/CreateExchange.js.map +1 -0
- package/dist/openapi/dist/models/CreateTransferRequest.d.ts +17 -0
- package/dist/openapi/dist/models/CreateTransferRequest.js +39 -0
- package/dist/openapi/dist/models/CreateTransferRequest.js.map +1 -0
- package/dist/openapi/dist/models/CreateTransferResponse.d.ts +17 -0
- package/dist/openapi/dist/models/CreateTransferResponse.js +21 -0
- package/dist/openapi/dist/models/CreateTransferResponse.js.map +1 -0
- package/dist/openapi/dist/models/CreateWalletRequest.d.ts +17 -0
- package/dist/openapi/dist/models/CreateWalletRequest.js +27 -0
- package/dist/openapi/dist/models/CreateWalletRequest.js.map +1 -0
- package/dist/openapi/dist/models/CreateWithdrawReply.d.ts +17 -0
- package/dist/openapi/dist/models/CreateWithdrawReply.js +21 -0
- package/dist/openapi/dist/models/CreateWithdrawReply.js.map +1 -0
- package/dist/openapi/dist/models/CreateWithdrawRequest.d.ts +17 -0
- package/dist/openapi/dist/models/CreateWithdrawRequest.js +57 -0
- package/dist/openapi/dist/models/CreateWithdrawRequest.js.map +1 -0
- package/dist/openapi/dist/models/Currency.d.ts +17 -0
- package/dist/openapi/dist/models/Currency.js +135 -0
- package/dist/openapi/dist/models/Currency.js.map +1 -0
- package/dist/openapi/dist/models/CurrencyNetwork.d.ts +17 -0
- package/dist/openapi/dist/models/CurrencyNetwork.js +135 -0
- package/dist/openapi/dist/models/CurrencyNetwork.js.map +1 -0
- package/dist/openapi/dist/models/CurrencyPair.d.ts +17 -0
- package/dist/openapi/dist/models/CurrencyPair.js +27 -0
- package/dist/openapi/dist/models/CurrencyPair.js.map +1 -0
- package/dist/openapi/dist/models/CursorPageAccount.d.ts +17 -0
- package/dist/openapi/dist/models/CursorPageAccount.js +39 -0
- package/dist/openapi/dist/models/CursorPageAccount.js.map +1 -0
- package/dist/openapi/dist/models/CursorPageAddress.d.ts +17 -0
- package/dist/openapi/dist/models/CursorPageAddress.js +39 -0
- package/dist/openapi/dist/models/CursorPageAddress.js.map +1 -0
- package/dist/openapi/dist/models/CursorPageChainNetwork.d.ts +17 -0
- package/dist/openapi/dist/models/CursorPageChainNetwork.js +39 -0
- package/dist/openapi/dist/models/CursorPageChainNetwork.js.map +1 -0
- package/dist/openapi/dist/models/CursorPageCurrency.d.ts +17 -0
- package/dist/openapi/dist/models/CursorPageCurrency.js +39 -0
- package/dist/openapi/dist/models/CursorPageCurrency.js.map +1 -0
- package/dist/openapi/dist/models/CursorPageEndpoint.d.ts +17 -0
- package/dist/openapi/dist/models/CursorPageEndpoint.js +39 -0
- package/dist/openapi/dist/models/CursorPageEndpoint.js.map +1 -0
- package/dist/openapi/dist/models/CursorPageExchange.d.ts +17 -0
- package/dist/openapi/dist/models/CursorPageExchange.js +39 -0
- package/dist/openapi/dist/models/CursorPageExchange.js.map +1 -0
- package/dist/openapi/dist/models/CursorPageTransaction.d.ts +17 -0
- package/dist/openapi/dist/models/CursorPageTransaction.js +39 -0
- package/dist/openapi/dist/models/CursorPageTransaction.js.map +1 -0
- package/dist/openapi/dist/models/CursorPageWallet.d.ts +17 -0
- package/dist/openapi/dist/models/CursorPageWallet.js +39 -0
- package/dist/openapi/dist/models/CursorPageWallet.js.map +1 -0
- package/dist/openapi/dist/models/CursorPageWebhookEvent.d.ts +17 -0
- package/dist/openapi/dist/models/CursorPageWebhookEvent.js +39 -0
- package/dist/openapi/dist/models/CursorPageWebhookEvent.js.map +1 -0
- package/dist/openapi/dist/models/DeleteWebhookEndpointResponse.d.ts +17 -0
- package/dist/openapi/dist/models/DeleteWebhookEndpointResponse.js +21 -0
- package/dist/openapi/dist/models/DeleteWebhookEndpointResponse.js.map +1 -0
- package/dist/openapi/dist/models/Endpoint.d.ts +17 -0
- package/dist/openapi/dist/models/Endpoint.js +69 -0
- package/dist/openapi/dist/models/Endpoint.js.map +1 -0
- package/dist/openapi/dist/models/EstimateFeeRequest.d.ts +17 -0
- package/dist/openapi/dist/models/EstimateFeeRequest.js +45 -0
- package/dist/openapi/dist/models/EstimateFeeRequest.js.map +1 -0
- package/dist/openapi/dist/models/EstimateFeeResponse.d.ts +17 -0
- package/dist/openapi/dist/models/EstimateFeeResponse.js +27 -0
- package/dist/openapi/dist/models/EstimateFeeResponse.js.map +1 -0
- package/dist/openapi/dist/models/EstimateResponse.d.ts +17 -0
- package/dist/openapi/dist/models/EstimateResponse.js +45 -0
- package/dist/openapi/dist/models/EstimateResponse.js.map +1 -0
- package/dist/openapi/dist/models/EventType.d.ts +17 -0
- package/dist/openapi/dist/models/EventType.js +27 -0
- package/dist/openapi/dist/models/EventType.js.map +1 -0
- package/dist/openapi/dist/models/Exchange.d.ts +17 -0
- package/dist/openapi/dist/models/Exchange.js +99 -0
- package/dist/openapi/dist/models/Exchange.js.map +1 -0
- package/dist/openapi/dist/models/ExchangeCurrencyPairs.d.ts +17 -0
- package/dist/openapi/dist/models/ExchangeCurrencyPairs.js +27 -0
- package/dist/openapi/dist/models/ExchangeCurrencyPairs.js.map +1 -0
- package/dist/openapi/dist/models/ExchangeSubmitResponse.d.ts +17 -0
- package/dist/openapi/dist/models/ExchangeSubmitResponse.js +21 -0
- package/dist/openapi/dist/models/ExchangeSubmitResponse.js.map +1 -0
- package/dist/openapi/dist/models/GetCurrencyPairQuotaResponse.d.ts +17 -0
- package/dist/openapi/dist/models/GetCurrencyPairQuotaResponse.js +51 -0
- package/dist/openapi/dist/models/GetCurrencyPairQuotaResponse.js.map +1 -0
- package/dist/openapi/dist/models/GetRatesRequest.d.ts +17 -0
- package/dist/openapi/dist/models/GetRatesRequest.js +21 -0
- package/dist/openapi/dist/models/GetRatesRequest.js.map +1 -0
- package/dist/openapi/dist/models/GetRatesResponse.d.ts +17 -0
- package/dist/openapi/dist/models/GetRatesResponse.js +21 -0
- package/dist/openapi/dist/models/GetRatesResponse.js.map +1 -0
- package/dist/openapi/dist/models/ListExchangeCurrencyPairsResponse.d.ts +17 -0
- package/dist/openapi/dist/models/ListExchangeCurrencyPairsResponse.js +21 -0
- package/dist/openapi/dist/models/ListExchangeCurrencyPairsResponse.js.map +1 -0
- package/dist/openapi/dist/models/ModelError.d.ts +17 -0
- package/dist/openapi/dist/models/ModelError.js +27 -0
- package/dist/openapi/dist/models/ModelError.js.map +1 -0
- package/dist/openapi/dist/models/ObjectSerializer.d.ts +55 -0
- package/dist/openapi/dist/models/ObjectSerializer.js +330 -0
- package/dist/openapi/dist/models/ObjectSerializer.js.map +1 -0
- package/dist/openapi/dist/models/Rate.d.ts +17 -0
- package/dist/openapi/dist/models/Rate.js +27 -0
- package/dist/openapi/dist/models/Rate.js.map +1 -0
- package/dist/openapi/dist/models/ResendWebhookEventRequest.d.ts +17 -0
- package/dist/openapi/dist/models/ResendWebhookEventRequest.js +27 -0
- package/dist/openapi/dist/models/ResendWebhookEventRequest.js.map +1 -0
- package/dist/openapi/dist/models/ResendWebhookEventResponse.d.ts +17 -0
- package/dist/openapi/dist/models/ResendWebhookEventResponse.js +21 -0
- package/dist/openapi/dist/models/ResendWebhookEventResponse.js.map +1 -0
- package/dist/openapi/dist/models/Transaction.d.ts +17 -0
- package/dist/openapi/dist/models/Transaction.js +99 -0
- package/dist/openapi/dist/models/Transaction.js.map +1 -0
- package/dist/openapi/dist/models/TransactionDirection.d.ts +0 -0
- package/dist/openapi/dist/models/TransactionDirection.js +2 -0
- package/dist/openapi/dist/models/TransactionDirection.js.map +1 -0
- package/dist/openapi/dist/models/TransactionStatus.d.ts +0 -0
- package/dist/openapi/dist/models/TransactionStatus.js +2 -0
- package/dist/openapi/dist/models/TransactionStatus.js.map +1 -0
- package/dist/openapi/dist/models/UpdateEndpoint.d.ts +17 -0
- package/dist/openapi/dist/models/UpdateEndpoint.js +57 -0
- package/dist/openapi/dist/models/UpdateEndpoint.js.map +1 -0
- package/dist/openapi/dist/models/UpdateWalletRequest.d.ts +17 -0
- package/dist/openapi/dist/models/UpdateWalletRequest.js +27 -0
- package/dist/openapi/dist/models/UpdateWalletRequest.js.map +1 -0
- package/dist/openapi/dist/models/Wallet.d.ts +17 -0
- package/dist/openapi/dist/models/Wallet.js +39 -0
- package/dist/openapi/dist/models/Wallet.js.map +1 -0
- package/dist/openapi/dist/models/WebhookEvent.d.ts +17 -0
- package/dist/openapi/dist/models/WebhookEvent.js +39 -0
- package/dist/openapi/dist/models/WebhookEvent.js.map +1 -0
- package/dist/openapi/dist/models/all.d.ts +46 -0
- package/dist/openapi/dist/models/all.js +59 -0
- package/dist/openapi/dist/models/all.js.map +1 -0
- package/dist/openapi/dist/rxjsStub.d.ts +10 -0
- package/dist/openapi/dist/rxjsStub.js +32 -0
- package/dist/openapi/dist/rxjsStub.js.map +1 -0
- package/dist/openapi/dist/servers.d.ts +12 -0
- package/dist/openapi/dist/servers.js +31 -0
- package/dist/openapi/dist/servers.js.map +1 -0
- package/dist/openapi/dist/types/ObjectParamAPI.d.ts +82 -0
- package/dist/openapi/dist/types/ObjectParamAPI.js +170 -0
- package/dist/openapi/dist/types/ObjectParamAPI.js.map +1 -0
- package/dist/openapi/dist/types/ObservableAPI.d.ts +92 -0
- package/dist/openapi/dist/types/ObservableAPI.js +576 -0
- package/dist/openapi/dist/types/ObservableAPI.js.map +1 -0
- package/dist/openapi/dist/types/PromiseAPI.d.ts +82 -0
- package/dist/openapi/dist/types/PromiseAPI.js +202 -0
- package/dist/openapi/dist/types/PromiseAPI.js.map +1 -0
- package/dist/openapi/dist/util.d.ts +1 -0
- package/dist/openapi/dist/util.js +25 -0
- package/dist/openapi/dist/util.js.map +1 -0
- package/dist/openapi/http/http.js +23 -36
- package/dist/openapi/http/http.js.map +1 -1
- package/dist/openapi/index.d.ts +1 -1
- package/dist/openapi/index.js +0 -2
- package/dist/openapi/index.js.map +1 -1
- package/dist/openapi/models/CreateTransferRequest.d.ts +3 -0
- package/dist/openapi/models/CreateTransferRequest.js +6 -0
- package/dist/openapi/models/CreateTransferRequest.js.map +1 -1
- package/dist/openapi/models/Currency.d.ts +2 -0
- package/dist/openapi/models/Currency.js +12 -0
- package/dist/openapi/models/Currency.js.map +1 -1
- package/dist/openapi/models/CurrencyNetwork.d.ts +1 -0
- package/dist/openapi/models/CurrencyNetwork.js +6 -0
- package/dist/openapi/models/CurrencyNetwork.js.map +1 -1
- package/dist/openapi/models/EstimateFeeResponse.js.map +1 -1
- package/dist/openapi/models/ObjectSerializer.d.ts +0 -9
- package/dist/openapi/models/ObjectSerializer.js +0 -27
- package/dist/openapi/models/ObjectSerializer.js.map +1 -1
- package/dist/openapi/models/all.d.ts +0 -9
- package/dist/openapi/models/all.js +0 -9
- package/dist/openapi/models/all.js.map +1 -1
- package/dist/openapi/types/ObjectParamAPI.d.ts +0 -49
- package/dist/openapi/types/ObjectParamAPI.js +14 -49
- package/dist/openapi/types/ObjectParamAPI.js.map +1 -1
- package/dist/openapi/types/ObservableAPI.d.ts +0 -29
- package/dist/openapi/types/ObservableAPI.js +1 -124
- package/dist/openapi/types/ObservableAPI.js.map +1 -1
- package/dist/openapi/types/PromiseAPI.d.ts +0 -25
- package/dist/openapi/types/PromiseAPI.js +14 -56
- package/dist/openapi/types/PromiseAPI.js.map +1 -1
- package/package.json +2 -1
|
@@ -0,0 +1,222 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.AddressesApiResponseProcessor = exports.AddressesApiRequestFactory = void 0;
|
|
4
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
5
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
6
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
7
|
+
function fulfilled(value) { try {
|
|
8
|
+
step(generator.next(value));
|
|
9
|
+
}
|
|
10
|
+
catch (e) {
|
|
11
|
+
reject(e);
|
|
12
|
+
} }
|
|
13
|
+
function rejected(value) { try {
|
|
14
|
+
step(generator["throw"](value));
|
|
15
|
+
}
|
|
16
|
+
catch (e) {
|
|
17
|
+
reject(e);
|
|
18
|
+
} }
|
|
19
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
20
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
21
|
+
});
|
|
22
|
+
};
|
|
23
|
+
const baseapi_1 = require("./baseapi");
|
|
24
|
+
const http_1 = require("../http/http");
|
|
25
|
+
const ObjectSerializer_1 = require("../models/ObjectSerializer");
|
|
26
|
+
const exception_1 = require("./exception");
|
|
27
|
+
const util_1 = require("../util");
|
|
28
|
+
class AddressesApiRequestFactory extends baseapi_1.BaseAPIRequestFactory {
|
|
29
|
+
v1AddressesList(limit, currency, cursor, type, walletId, _options) {
|
|
30
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
31
|
+
let _config = _options || this.configuration;
|
|
32
|
+
if (limit === null || limit === undefined) {
|
|
33
|
+
throw new baseapi_1.RequiredError('Required parameter limit was null or undefined when calling v1AddressesList.');
|
|
34
|
+
}
|
|
35
|
+
const localVarPath = '/api/v1/addresses';
|
|
36
|
+
const requestContext = _config.baseServer.makeRequestContext(localVarPath, http_1.HttpMethod.GET);
|
|
37
|
+
requestContext.setHeaderParam("Accept", "application/json, */*;q=0.8");
|
|
38
|
+
if (currency !== undefined) {
|
|
39
|
+
requestContext.setQueryParam("currency", ObjectSerializer_1.ObjectSerializer.serialize(currency, "string", ""));
|
|
40
|
+
}
|
|
41
|
+
if (cursor !== undefined) {
|
|
42
|
+
requestContext.setQueryParam("cursor", ObjectSerializer_1.ObjectSerializer.serialize(cursor, "string", ""));
|
|
43
|
+
}
|
|
44
|
+
if (limit !== undefined) {
|
|
45
|
+
requestContext.setQueryParam("limit", ObjectSerializer_1.ObjectSerializer.serialize(limit, "number", ""));
|
|
46
|
+
}
|
|
47
|
+
if (type !== undefined) {
|
|
48
|
+
requestContext.setQueryParam("type", ObjectSerializer_1.ObjectSerializer.serialize(type, "string", ""));
|
|
49
|
+
}
|
|
50
|
+
if (walletId !== undefined) {
|
|
51
|
+
requestContext.setQueryParam("walletId", ObjectSerializer_1.ObjectSerializer.serialize(walletId, "string", ""));
|
|
52
|
+
}
|
|
53
|
+
let authMethod = null;
|
|
54
|
+
authMethod = _config.authMethods["ApiKeyAuth"];
|
|
55
|
+
if (authMethod) {
|
|
56
|
+
yield authMethod.applySecurityAuthentication(requestContext);
|
|
57
|
+
}
|
|
58
|
+
return requestContext;
|
|
59
|
+
});
|
|
60
|
+
}
|
|
61
|
+
v1WalletsGetDepositAddress(walletId, currency, network, _options) {
|
|
62
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
63
|
+
let _config = _options || this.configuration;
|
|
64
|
+
if (walletId === null || walletId === undefined) {
|
|
65
|
+
throw new baseapi_1.RequiredError('Required parameter walletId was null or undefined when calling v1WalletsGetDepositAddress.');
|
|
66
|
+
}
|
|
67
|
+
if (currency === null || currency === undefined) {
|
|
68
|
+
throw new baseapi_1.RequiredError('Required parameter currency was null or undefined when calling v1WalletsGetDepositAddress.');
|
|
69
|
+
}
|
|
70
|
+
if (network === null || network === undefined) {
|
|
71
|
+
throw new baseapi_1.RequiredError('Required parameter network was null or undefined when calling v1WalletsGetDepositAddress.');
|
|
72
|
+
}
|
|
73
|
+
const localVarPath = '/api/v1/wallets/{walletId}/deposit_address'
|
|
74
|
+
.replace('{' + 'walletId' + '}', encodeURIComponent(String(walletId)));
|
|
75
|
+
const requestContext = _config.baseServer.makeRequestContext(localVarPath, http_1.HttpMethod.GET);
|
|
76
|
+
requestContext.setHeaderParam("Accept", "application/json, */*;q=0.8");
|
|
77
|
+
if (currency !== undefined) {
|
|
78
|
+
requestContext.setQueryParam("currency", ObjectSerializer_1.ObjectSerializer.serialize(currency, "string", ""));
|
|
79
|
+
}
|
|
80
|
+
if (network !== undefined) {
|
|
81
|
+
requestContext.setQueryParam("network", ObjectSerializer_1.ObjectSerializer.serialize(network, "string", ""));
|
|
82
|
+
}
|
|
83
|
+
let authMethod = null;
|
|
84
|
+
authMethod = _config.authMethods["ApiKeyAuth"];
|
|
85
|
+
if (authMethod) {
|
|
86
|
+
yield authMethod.applySecurityAuthentication(requestContext);
|
|
87
|
+
}
|
|
88
|
+
return requestContext;
|
|
89
|
+
});
|
|
90
|
+
}
|
|
91
|
+
v1WalletsListDepositAddresses(walletId, limit, currency, cursor, network, _options) {
|
|
92
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
93
|
+
let _config = _options || this.configuration;
|
|
94
|
+
if (walletId === null || walletId === undefined) {
|
|
95
|
+
throw new baseapi_1.RequiredError('Required parameter walletId was null or undefined when calling v1WalletsListDepositAddresses.');
|
|
96
|
+
}
|
|
97
|
+
if (limit === null || limit === undefined) {
|
|
98
|
+
throw new baseapi_1.RequiredError('Required parameter limit was null or undefined when calling v1WalletsListDepositAddresses.');
|
|
99
|
+
}
|
|
100
|
+
const localVarPath = '/api/v1/wallets/{walletId}/deposit_addresses'
|
|
101
|
+
.replace('{' + 'walletId' + '}', encodeURIComponent(String(walletId)));
|
|
102
|
+
const requestContext = _config.baseServer.makeRequestContext(localVarPath, http_1.HttpMethod.GET);
|
|
103
|
+
requestContext.setHeaderParam("Accept", "application/json, */*;q=0.8");
|
|
104
|
+
if (currency !== undefined) {
|
|
105
|
+
requestContext.setQueryParam("currency", ObjectSerializer_1.ObjectSerializer.serialize(currency, "string", ""));
|
|
106
|
+
}
|
|
107
|
+
if (cursor !== undefined) {
|
|
108
|
+
requestContext.setQueryParam("cursor", ObjectSerializer_1.ObjectSerializer.serialize(cursor, "string", ""));
|
|
109
|
+
}
|
|
110
|
+
if (limit !== undefined) {
|
|
111
|
+
requestContext.setQueryParam("limit", ObjectSerializer_1.ObjectSerializer.serialize(limit, "number", ""));
|
|
112
|
+
}
|
|
113
|
+
if (network !== undefined) {
|
|
114
|
+
requestContext.setQueryParam("network", ObjectSerializer_1.ObjectSerializer.serialize(network, "string", ""));
|
|
115
|
+
}
|
|
116
|
+
let authMethod = null;
|
|
117
|
+
authMethod = _config.authMethods["ApiKeyAuth"];
|
|
118
|
+
if (authMethod) {
|
|
119
|
+
yield authMethod.applySecurityAuthentication(requestContext);
|
|
120
|
+
}
|
|
121
|
+
return requestContext;
|
|
122
|
+
});
|
|
123
|
+
}
|
|
124
|
+
}
|
|
125
|
+
exports.AddressesApiRequestFactory = AddressesApiRequestFactory;
|
|
126
|
+
class AddressesApiResponseProcessor {
|
|
127
|
+
v1AddressesList(response) {
|
|
128
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
129
|
+
const contentType = ObjectSerializer_1.ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
|
|
130
|
+
if (util_1.isCodeInRange("200", response.httpStatusCode)) {
|
|
131
|
+
const body = ObjectSerializer_1.ObjectSerializer.deserialize(ObjectSerializer_1.ObjectSerializer.parse(yield response.body.text(), contentType), "CursorPageAddress", "");
|
|
132
|
+
return body;
|
|
133
|
+
}
|
|
134
|
+
if (util_1.isCodeInRange("400", response.httpStatusCode)) {
|
|
135
|
+
const body = ObjectSerializer_1.ObjectSerializer.deserialize(ObjectSerializer_1.ObjectSerializer.parse(yield response.body.text(), contentType), "Error", "");
|
|
136
|
+
throw new exception_1.ApiException(400, body);
|
|
137
|
+
}
|
|
138
|
+
if (util_1.isCodeInRange("401", response.httpStatusCode)) {
|
|
139
|
+
const body = ObjectSerializer_1.ObjectSerializer.deserialize(ObjectSerializer_1.ObjectSerializer.parse(yield response.body.text(), contentType), "Error", "");
|
|
140
|
+
throw new exception_1.ApiException(401, body);
|
|
141
|
+
}
|
|
142
|
+
if (util_1.isCodeInRange("404", response.httpStatusCode)) {
|
|
143
|
+
const body = ObjectSerializer_1.ObjectSerializer.deserialize(ObjectSerializer_1.ObjectSerializer.parse(yield response.body.text(), contentType), "Error", "");
|
|
144
|
+
throw new exception_1.ApiException(404, body);
|
|
145
|
+
}
|
|
146
|
+
if (util_1.isCodeInRange("500", response.httpStatusCode)) {
|
|
147
|
+
const body = ObjectSerializer_1.ObjectSerializer.deserialize(ObjectSerializer_1.ObjectSerializer.parse(yield response.body.text(), contentType), "Error", "");
|
|
148
|
+
throw new exception_1.ApiException(500, body);
|
|
149
|
+
}
|
|
150
|
+
if (response.httpStatusCode >= 200 && response.httpStatusCode <= 299) {
|
|
151
|
+
const body = ObjectSerializer_1.ObjectSerializer.deserialize(ObjectSerializer_1.ObjectSerializer.parse(yield response.body.text(), contentType), "CursorPageAddress", "");
|
|
152
|
+
return body;
|
|
153
|
+
}
|
|
154
|
+
let body = response.body || "";
|
|
155
|
+
throw new exception_1.ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\"");
|
|
156
|
+
});
|
|
157
|
+
}
|
|
158
|
+
v1WalletsGetDepositAddress(response) {
|
|
159
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
160
|
+
const contentType = ObjectSerializer_1.ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
|
|
161
|
+
if (util_1.isCodeInRange("200", response.httpStatusCode)) {
|
|
162
|
+
const body = ObjectSerializer_1.ObjectSerializer.deserialize(ObjectSerializer_1.ObjectSerializer.parse(yield response.body.text(), contentType), "Address", "");
|
|
163
|
+
return body;
|
|
164
|
+
}
|
|
165
|
+
if (util_1.isCodeInRange("400", response.httpStatusCode)) {
|
|
166
|
+
const body = ObjectSerializer_1.ObjectSerializer.deserialize(ObjectSerializer_1.ObjectSerializer.parse(yield response.body.text(), contentType), "Error", "");
|
|
167
|
+
throw new exception_1.ApiException(400, body);
|
|
168
|
+
}
|
|
169
|
+
if (util_1.isCodeInRange("401", response.httpStatusCode)) {
|
|
170
|
+
const body = ObjectSerializer_1.ObjectSerializer.deserialize(ObjectSerializer_1.ObjectSerializer.parse(yield response.body.text(), contentType), "Error", "");
|
|
171
|
+
throw new exception_1.ApiException(401, body);
|
|
172
|
+
}
|
|
173
|
+
if (util_1.isCodeInRange("404", response.httpStatusCode)) {
|
|
174
|
+
const body = ObjectSerializer_1.ObjectSerializer.deserialize(ObjectSerializer_1.ObjectSerializer.parse(yield response.body.text(), contentType), "Error", "");
|
|
175
|
+
throw new exception_1.ApiException(404, body);
|
|
176
|
+
}
|
|
177
|
+
if (util_1.isCodeInRange("500", response.httpStatusCode)) {
|
|
178
|
+
const body = ObjectSerializer_1.ObjectSerializer.deserialize(ObjectSerializer_1.ObjectSerializer.parse(yield response.body.text(), contentType), "Error", "");
|
|
179
|
+
throw new exception_1.ApiException(500, body);
|
|
180
|
+
}
|
|
181
|
+
if (response.httpStatusCode >= 200 && response.httpStatusCode <= 299) {
|
|
182
|
+
const body = ObjectSerializer_1.ObjectSerializer.deserialize(ObjectSerializer_1.ObjectSerializer.parse(yield response.body.text(), contentType), "Address", "");
|
|
183
|
+
return body;
|
|
184
|
+
}
|
|
185
|
+
let body = response.body || "";
|
|
186
|
+
throw new exception_1.ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\"");
|
|
187
|
+
});
|
|
188
|
+
}
|
|
189
|
+
v1WalletsListDepositAddresses(response) {
|
|
190
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
191
|
+
const contentType = ObjectSerializer_1.ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
|
|
192
|
+
if (util_1.isCodeInRange("200", response.httpStatusCode)) {
|
|
193
|
+
const body = ObjectSerializer_1.ObjectSerializer.deserialize(ObjectSerializer_1.ObjectSerializer.parse(yield response.body.text(), contentType), "CursorPageAddress", "");
|
|
194
|
+
return body;
|
|
195
|
+
}
|
|
196
|
+
if (util_1.isCodeInRange("400", response.httpStatusCode)) {
|
|
197
|
+
const body = ObjectSerializer_1.ObjectSerializer.deserialize(ObjectSerializer_1.ObjectSerializer.parse(yield response.body.text(), contentType), "Error", "");
|
|
198
|
+
throw new exception_1.ApiException(400, body);
|
|
199
|
+
}
|
|
200
|
+
if (util_1.isCodeInRange("401", response.httpStatusCode)) {
|
|
201
|
+
const body = ObjectSerializer_1.ObjectSerializer.deserialize(ObjectSerializer_1.ObjectSerializer.parse(yield response.body.text(), contentType), "Error", "");
|
|
202
|
+
throw new exception_1.ApiException(401, body);
|
|
203
|
+
}
|
|
204
|
+
if (util_1.isCodeInRange("404", response.httpStatusCode)) {
|
|
205
|
+
const body = ObjectSerializer_1.ObjectSerializer.deserialize(ObjectSerializer_1.ObjectSerializer.parse(yield response.body.text(), contentType), "Error", "");
|
|
206
|
+
throw new exception_1.ApiException(404, body);
|
|
207
|
+
}
|
|
208
|
+
if (util_1.isCodeInRange("500", response.httpStatusCode)) {
|
|
209
|
+
const body = ObjectSerializer_1.ObjectSerializer.deserialize(ObjectSerializer_1.ObjectSerializer.parse(yield response.body.text(), contentType), "Error", "");
|
|
210
|
+
throw new exception_1.ApiException(500, body);
|
|
211
|
+
}
|
|
212
|
+
if (response.httpStatusCode >= 200 && response.httpStatusCode <= 299) {
|
|
213
|
+
const body = ObjectSerializer_1.ObjectSerializer.deserialize(ObjectSerializer_1.ObjectSerializer.parse(yield response.body.text(), contentType), "CursorPageAddress", "");
|
|
214
|
+
return body;
|
|
215
|
+
}
|
|
216
|
+
let body = response.body || "";
|
|
217
|
+
throw new exception_1.ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\"");
|
|
218
|
+
});
|
|
219
|
+
}
|
|
220
|
+
}
|
|
221
|
+
exports.AddressesApiResponseProcessor = AddressesApiResponseProcessor;
|
|
222
|
+
//# sourceMappingURL=AddressesApi.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"AddressesApi.js","sourceRoot":"","sources":["../../../../src/openapi/dist/apis/AddressesApi.js"],"names":[],"mappings":";;;AAAA,IAAI,SAAS,GAAG,CAAC,IAAI,IAAI,IAAI,CAAC,SAAS,CAAC,IAAI,UAAU,OAAO,EAAE,UAAU,EAAE,CAAC,EAAE,SAAS;IACnF,SAAS,KAAK,CAAC,KAAK,IAAI,OAAO,KAAK,YAAY,CAAC,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,UAAU,OAAO,IAAI,OAAO,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;IAC5G,OAAO,IAAI,CAAC,CAAC,IAAI,CAAC,CAAC,GAAG,OAAO,CAAC,CAAC,CAAC,UAAU,OAAO,EAAE,MAAM;QACrD,SAAS,SAAS,CAAC,KAAK,IAAI,IAAI;YAAE,IAAI,CAAC,SAAS,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC,CAAC;SAAE;QAAC,OAAO,CAAC,EAAE;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 -0,0 +1,10 @@
|
|
|
1
|
+
export class CurrenciesApiRequestFactory extends BaseAPIRequestFactory {
|
|
2
|
+
constructor(configuration: import("..").Configuration);
|
|
3
|
+
v1CurrenciesList(limit: any, cursor: any, rated: any, _options: any): any;
|
|
4
|
+
v1CurrenciesRetrieve(code: any, _options: any): any;
|
|
5
|
+
}
|
|
6
|
+
export class CurrenciesApiResponseProcessor {
|
|
7
|
+
v1CurrenciesList(response: any): any;
|
|
8
|
+
v1CurrenciesRetrieve(response: any): any;
|
|
9
|
+
}
|
|
10
|
+
import { BaseAPIRequestFactory } from "./baseapi";
|
|
@@ -0,0 +1,140 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.CurrenciesApiResponseProcessor = exports.CurrenciesApiRequestFactory = void 0;
|
|
4
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
5
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
6
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
7
|
+
function fulfilled(value) { try {
|
|
8
|
+
step(generator.next(value));
|
|
9
|
+
}
|
|
10
|
+
catch (e) {
|
|
11
|
+
reject(e);
|
|
12
|
+
} }
|
|
13
|
+
function rejected(value) { try {
|
|
14
|
+
step(generator["throw"](value));
|
|
15
|
+
}
|
|
16
|
+
catch (e) {
|
|
17
|
+
reject(e);
|
|
18
|
+
} }
|
|
19
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
20
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
21
|
+
});
|
|
22
|
+
};
|
|
23
|
+
const baseapi_1 = require("./baseapi");
|
|
24
|
+
const http_1 = require("../http/http");
|
|
25
|
+
const ObjectSerializer_1 = require("../models/ObjectSerializer");
|
|
26
|
+
const exception_1 = require("./exception");
|
|
27
|
+
const util_1 = require("../util");
|
|
28
|
+
class CurrenciesApiRequestFactory extends baseapi_1.BaseAPIRequestFactory {
|
|
29
|
+
v1CurrenciesList(limit, cursor, rated, _options) {
|
|
30
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
31
|
+
let _config = _options || this.configuration;
|
|
32
|
+
if (limit === null || limit === undefined) {
|
|
33
|
+
throw new baseapi_1.RequiredError('Required parameter limit was null or undefined when calling v1CurrenciesList.');
|
|
34
|
+
}
|
|
35
|
+
const localVarPath = '/api/v1/currencies';
|
|
36
|
+
const requestContext = _config.baseServer.makeRequestContext(localVarPath, http_1.HttpMethod.GET);
|
|
37
|
+
requestContext.setHeaderParam("Accept", "application/json, */*;q=0.8");
|
|
38
|
+
if (cursor !== undefined) {
|
|
39
|
+
requestContext.setQueryParam("cursor", ObjectSerializer_1.ObjectSerializer.serialize(cursor, "string", ""));
|
|
40
|
+
}
|
|
41
|
+
if (limit !== undefined) {
|
|
42
|
+
requestContext.setQueryParam("limit", ObjectSerializer_1.ObjectSerializer.serialize(limit, "number", ""));
|
|
43
|
+
}
|
|
44
|
+
if (rated !== undefined) {
|
|
45
|
+
requestContext.setQueryParam("rated", ObjectSerializer_1.ObjectSerializer.serialize(rated, "boolean", ""));
|
|
46
|
+
}
|
|
47
|
+
let authMethod = null;
|
|
48
|
+
authMethod = _config.authMethods["ApiKeyAuth"];
|
|
49
|
+
if (authMethod) {
|
|
50
|
+
yield authMethod.applySecurityAuthentication(requestContext);
|
|
51
|
+
}
|
|
52
|
+
return requestContext;
|
|
53
|
+
});
|
|
54
|
+
}
|
|
55
|
+
v1CurrenciesRetrieve(code, _options) {
|
|
56
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
57
|
+
let _config = _options || this.configuration;
|
|
58
|
+
if (code === null || code === undefined) {
|
|
59
|
+
throw new baseapi_1.RequiredError('Required parameter code was null or undefined when calling v1CurrenciesRetrieve.');
|
|
60
|
+
}
|
|
61
|
+
const localVarPath = '/api/v1/currencies/{code}'
|
|
62
|
+
.replace('{' + 'code' + '}', encodeURIComponent(String(code)));
|
|
63
|
+
const requestContext = _config.baseServer.makeRequestContext(localVarPath, http_1.HttpMethod.GET);
|
|
64
|
+
requestContext.setHeaderParam("Accept", "application/json, */*;q=0.8");
|
|
65
|
+
let authMethod = null;
|
|
66
|
+
authMethod = _config.authMethods["ApiKeyAuth"];
|
|
67
|
+
if (authMethod) {
|
|
68
|
+
yield authMethod.applySecurityAuthentication(requestContext);
|
|
69
|
+
}
|
|
70
|
+
return requestContext;
|
|
71
|
+
});
|
|
72
|
+
}
|
|
73
|
+
}
|
|
74
|
+
exports.CurrenciesApiRequestFactory = CurrenciesApiRequestFactory;
|
|
75
|
+
class CurrenciesApiResponseProcessor {
|
|
76
|
+
v1CurrenciesList(response) {
|
|
77
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
78
|
+
const contentType = ObjectSerializer_1.ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
|
|
79
|
+
if (util_1.isCodeInRange("200", response.httpStatusCode)) {
|
|
80
|
+
const body = ObjectSerializer_1.ObjectSerializer.deserialize(ObjectSerializer_1.ObjectSerializer.parse(yield response.body.text(), contentType), "CursorPageCurrency", "");
|
|
81
|
+
return body;
|
|
82
|
+
}
|
|
83
|
+
if (util_1.isCodeInRange("400", response.httpStatusCode)) {
|
|
84
|
+
const body = ObjectSerializer_1.ObjectSerializer.deserialize(ObjectSerializer_1.ObjectSerializer.parse(yield response.body.text(), contentType), "Error", "");
|
|
85
|
+
throw new exception_1.ApiException(400, body);
|
|
86
|
+
}
|
|
87
|
+
if (util_1.isCodeInRange("401", response.httpStatusCode)) {
|
|
88
|
+
const body = ObjectSerializer_1.ObjectSerializer.deserialize(ObjectSerializer_1.ObjectSerializer.parse(yield response.body.text(), contentType), "Error", "");
|
|
89
|
+
throw new exception_1.ApiException(401, body);
|
|
90
|
+
}
|
|
91
|
+
if (util_1.isCodeInRange("404", response.httpStatusCode)) {
|
|
92
|
+
const body = ObjectSerializer_1.ObjectSerializer.deserialize(ObjectSerializer_1.ObjectSerializer.parse(yield response.body.text(), contentType), "Error", "");
|
|
93
|
+
throw new exception_1.ApiException(404, body);
|
|
94
|
+
}
|
|
95
|
+
if (util_1.isCodeInRange("500", response.httpStatusCode)) {
|
|
96
|
+
const body = ObjectSerializer_1.ObjectSerializer.deserialize(ObjectSerializer_1.ObjectSerializer.parse(yield response.body.text(), contentType), "Error", "");
|
|
97
|
+
throw new exception_1.ApiException(500, body);
|
|
98
|
+
}
|
|
99
|
+
if (response.httpStatusCode >= 200 && response.httpStatusCode <= 299) {
|
|
100
|
+
const body = ObjectSerializer_1.ObjectSerializer.deserialize(ObjectSerializer_1.ObjectSerializer.parse(yield response.body.text(), contentType), "CursorPageCurrency", "");
|
|
101
|
+
return body;
|
|
102
|
+
}
|
|
103
|
+
let body = response.body || "";
|
|
104
|
+
throw new exception_1.ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\"");
|
|
105
|
+
});
|
|
106
|
+
}
|
|
107
|
+
v1CurrenciesRetrieve(response) {
|
|
108
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
109
|
+
const contentType = ObjectSerializer_1.ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
|
|
110
|
+
if (util_1.isCodeInRange("200", response.httpStatusCode)) {
|
|
111
|
+
const body = ObjectSerializer_1.ObjectSerializer.deserialize(ObjectSerializer_1.ObjectSerializer.parse(yield response.body.text(), contentType), "Currency", "");
|
|
112
|
+
return body;
|
|
113
|
+
}
|
|
114
|
+
if (util_1.isCodeInRange("400", response.httpStatusCode)) {
|
|
115
|
+
const body = ObjectSerializer_1.ObjectSerializer.deserialize(ObjectSerializer_1.ObjectSerializer.parse(yield response.body.text(), contentType), "Error", "");
|
|
116
|
+
throw new exception_1.ApiException(400, body);
|
|
117
|
+
}
|
|
118
|
+
if (util_1.isCodeInRange("401", response.httpStatusCode)) {
|
|
119
|
+
const body = ObjectSerializer_1.ObjectSerializer.deserialize(ObjectSerializer_1.ObjectSerializer.parse(yield response.body.text(), contentType), "Error", "");
|
|
120
|
+
throw new exception_1.ApiException(401, body);
|
|
121
|
+
}
|
|
122
|
+
if (util_1.isCodeInRange("404", response.httpStatusCode)) {
|
|
123
|
+
const body = ObjectSerializer_1.ObjectSerializer.deserialize(ObjectSerializer_1.ObjectSerializer.parse(yield response.body.text(), contentType), "Error", "");
|
|
124
|
+
throw new exception_1.ApiException(404, body);
|
|
125
|
+
}
|
|
126
|
+
if (util_1.isCodeInRange("500", response.httpStatusCode)) {
|
|
127
|
+
const body = ObjectSerializer_1.ObjectSerializer.deserialize(ObjectSerializer_1.ObjectSerializer.parse(yield response.body.text(), contentType), "Error", "");
|
|
128
|
+
throw new exception_1.ApiException(500, body);
|
|
129
|
+
}
|
|
130
|
+
if (response.httpStatusCode >= 200 && response.httpStatusCode <= 299) {
|
|
131
|
+
const body = ObjectSerializer_1.ObjectSerializer.deserialize(ObjectSerializer_1.ObjectSerializer.parse(yield response.body.text(), contentType), "Currency", "");
|
|
132
|
+
return body;
|
|
133
|
+
}
|
|
134
|
+
let body = response.body || "";
|
|
135
|
+
throw new exception_1.ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\"");
|
|
136
|
+
});
|
|
137
|
+
}
|
|
138
|
+
}
|
|
139
|
+
exports.CurrenciesApiResponseProcessor = CurrenciesApiResponseProcessor;
|
|
140
|
+
//# sourceMappingURL=CurrenciesApi.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"CurrenciesApi.js","sourceRoot":"","sources":["../../../../src/openapi/dist/apis/CurrenciesApi.js"],"names":[],"mappings":";;;AAAA,IAAI,SAAS,GAAG,CAAC,IAAI,IAAI,IAAI,CAAC,SAAS,CAAC,IAAI,UAAU,OAAO,EAAE,UAAU,EAAE,CAAC,EAAE,SAAS;IACnF,SAAS,KAAK,CAAC,KAAK,IAAI,OAAO,KAAK,YAAY,CAAC,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,IAAI,C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WAAW,CAAC,mCAAgB,CAAC,KAAK,CAAC,MAAM,QAAQ,CAAC,IAAI,CAAC,IAAI,EAAE,EAAE,WAAW,CAAC,EAAE,UAAU,EAAE,EAAE,CAAC,CAAC;gBAC3H,OAAO,IAAI,CAAC;aACf;YACD,IAAI,IAAI,GAAG,QAAQ,CAAC,IAAI,IAAI,EAAE,CAAC;YAC/B,MAAM,IAAI,wBAAY,CAAC,QAAQ,CAAC,cAAc,EAAE,oCAAoC,GAAG,IAAI,GAAG,IAAI,CAAC,CAAC;QACxG,CAAC,CAAC,CAAC;IACP,CAAC;CACJ;AA/DD,wEA+DC"}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
export class ExchangesApiRequestFactory extends BaseAPIRequestFactory {
|
|
2
|
+
constructor(configuration: import("..").Configuration);
|
|
3
|
+
v1ExchangesCreate(request: any, _options: any): any;
|
|
4
|
+
v1ExchangesCurrencyPairs(_options: any): any;
|
|
5
|
+
v1ExchangesCurrencyQuota(fromCurrency: any, toCurrency: any, _options: any): any;
|
|
6
|
+
v1ExchangesList(limit: any, walletId: any, cursor: any, _options: any): any;
|
|
7
|
+
v1ExchangesRetrieve(exchangeId: any, _options: any): any;
|
|
8
|
+
v1ExchangesSubmit(exchangeId: any, _options: any): any;
|
|
9
|
+
}
|
|
10
|
+
export class ExchangesApiResponseProcessor {
|
|
11
|
+
v1ExchangesCreate(response: any): any;
|
|
12
|
+
v1ExchangesCurrencyPairs(response: any): any;
|
|
13
|
+
v1ExchangesCurrencyQuota(response: any): any;
|
|
14
|
+
v1ExchangesList(response: any): any;
|
|
15
|
+
v1ExchangesRetrieve(response: any): any;
|
|
16
|
+
v1ExchangesSubmit(response: any): any;
|
|
17
|
+
}
|
|
18
|
+
import { BaseAPIRequestFactory } from "./baseapi";
|