UNPKG

nmkr-studio-api

Version:

Typesafe API Client to work with the NMKR Studio V2 API

153 lines 5.48 kB
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.ManagedWalletsService = void 0; class ManagedWalletsService { constructor(httpRequest) { this.httpRequest = httpRequest; } /** * Creates an Managed Wallet * @returns CreateWalletResultClass Returns the CreateWalletResultClass Class * @throws ApiError */ postV2CreateWallet({ customerid, requestBody, }) { return this.httpRequest.request({ method: 'POST', url: '/v2/CreateWallet/{customerid}', path: { 'customerid': customerid, }, body: requestBody, mediaType: 'application/json', errors: { 401: `The access was denied. (Wrong or expired APIKEY, wrong projectid etc.)`, 429: `Too Many Requests`, 500: `Internal server error - see the errormessage in the result`, }, }); } /** * Returns the key hash of a Managed Wallet * @returns string Returns the CreateWalletResultClass Class * @throws ApiError */ postV2GetKeyHash({ customerid, requestBody, }) { return this.httpRequest.request({ method: 'POST', url: '/v2/GetKeyHash/{customerid}', path: { 'customerid': customerid, }, body: requestBody, mediaType: 'application/json', errors: { 401: `The access was denied. (Wrong or expired APIKEY, wrong projectid etc.)`, 429: `Too Many Requests`, 500: `Internal server error - see the errormessage in the result`, }, }); } /** * Returns the utxo of a managed Wallet * @returns TxInAddressesClass Returns the TxInAddressesClass Class * @throws ApiError */ getV2GetWalletUtxo({ address, }) { return this.httpRequest.request({ method: 'GET', url: '/v2/GetWalletUtxo/{address}', path: { 'address': address, }, errors: { 401: `The access was denied. (Wrong or expired APIKEY, wrong projectid etc.)`, 429: `Too Many Requests`, 500: `Internal server error - see the errormessage in the result`, }, }); } /** * Imports an Wallet * @returns ImportWalletResultClass Returns the CreateWalletResultClass Class * @throws ApiError */ postV2ImportWallet({ customerid, requestBody, }) { return this.httpRequest.request({ method: 'POST', url: '/v2/ImportWallet/{customerid}', path: { 'customerid': customerid, }, body: requestBody, mediaType: 'application/json', errors: { 401: `The access was denied. (Wrong or expired APIKEY, wrong projectid etc.)`, 429: `Too Many Requests`, 500: `Internal server error - see the errormessage in the result`, }, }); } /** * Lists all managed Wallets * @returns Wallets Returns the CreateWalletResultClass Class * @throws ApiError */ getV2ListAllWallets({ customerid, }) { return this.httpRequest.request({ method: 'GET', url: '/v2/ListAllWallets/{customerid}', path: { 'customerid': customerid, }, errors: { 401: `The access was denied. (Wrong or expired APIKEY, wrong projectid etc.)`, 429: `Too Many Requests`, 500: `Internal server error - see the errormessage in the result`, }, }); } /** * Makes a transaction on a managed Wallet * @returns MakeTransactionResultClass Returns the MakeTransactionResult Class * @throws ApiError */ postV2MakeTransaction({ customerid, requestBody, }) { return this.httpRequest.request({ method: 'POST', url: '/v2/MakeTransaction/{customerid}', path: { 'customerid': customerid, }, body: requestBody, mediaType: 'application/json', errors: { 401: `The access was denied. (Wrong or expired APIKEY, wrong projectid etc.)`, 429: `Too Many Requests`, 500: `Internal server error - see the errormessage in the result`, }, }); } /** * Send all ADA and all Tokens from a managed wallet to a receiver address * @returns MakeTransactionResultClass Returns the MakeTransactionResult Class * @throws ApiError */ postV2SendAllAssets({ customerid, requestBody, }) { return this.httpRequest.request({ method: 'POST', url: '/v2/SendAllAssets/{customerid}', path: { 'customerid': customerid, }, body: requestBody, mediaType: 'application/json', errors: { 401: `The access was denied. (Wrong or expired APIKEY, wrong projectid etc.)`, 429: `Too Many Requests`, 500: `Internal server error - see the errormessage in the result`, }, }); } } exports.ManagedWalletsService = ManagedWalletsService; //# sourceMappingURL=ManagedWalletsService.js.map