@riocrypto/common 1.0.1464 → 1.0.1466

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.
@@ -49,6 +49,7 @@ import { SwapProvider } from "../types/swap-provider";
49
49
  import { SwapOrigin } from "../types/swap-origin";
50
50
  import { AddressVerification } from "../types/address-verification";
51
51
  import { BankAccountVerification } from "../types/bank-account-verification";
52
+ import { MultipartLiquidityOrder } from "../types/multipart-liquidity-order";
52
53
  export declare class RioAdminClient {
53
54
  private axios;
54
55
  constructor(axios: AxiosStatic | AxiosInstance);
@@ -171,6 +172,8 @@ export declare class RioAdminClient {
171
172
  createInternalSwap(originCrypto: Crypto, destinationCrypto: Crypto, amount: number, origin: SwapOrigin, destination: SwapOrigin, provider: SwapProvider): Promise<void>;
172
173
  expediteInternalSwap(id: string): Promise<void>;
173
174
  getInternalSwaps(page: number, limit?: number): Promise<InternalSwap[]>;
175
+ createMultipartOrder(amount: number): Promise<MultipartLiquidityOrder>;
176
+ getMultipartOrders(page: number, limit?: number): Promise<MultipartLiquidityOrder[]>;
174
177
  getAddressVerification(cryptoAddressId: string): Promise<AddressVerification>;
175
178
  getBankAccountVerification(bankAccountId: string): Promise<BankAccountVerification>;
176
179
  getBankPayout(orderId: string): Promise<BankPayout>;
@@ -10,6 +10,8 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
10
10
  };
11
11
  Object.defineProperty(exports, "__esModule", { value: true });
12
12
  exports.RioAdminClient = void 0;
13
+ const fiat_1 = require("../types/fiat");
14
+ const crypto_1 = require("../types/crypto");
13
15
  const IdentityVerificationType_1 = require("../types/IdentityVerificationType");
14
16
  class RioAdminClient {
15
17
  constructor(axios) {
@@ -596,6 +598,27 @@ class RioAdminClient {
596
598
  return data;
597
599
  });
598
600
  }
601
+ createMultipartOrder(amount) {
602
+ return __awaiter(this, void 0, void 0, function* () {
603
+ const { data } = yield this.axios.post(`/api/liquidity/multipart-orders`, {
604
+ amount,
605
+ originFiat: fiat_1.Fiat.USD,
606
+ destinationCrypto: crypto_1.Crypto.USDTEthereum,
607
+ });
608
+ return data;
609
+ });
610
+ }
611
+ getMultipartOrders(page, limit) {
612
+ return __awaiter(this, void 0, void 0, function* () {
613
+ const { data } = yield this.axios.get(`/api/liquidity/multipart-orders`, {
614
+ params: {
615
+ page,
616
+ limit,
617
+ },
618
+ });
619
+ return data;
620
+ });
621
+ }
599
622
  getAddressVerification(cryptoAddressId) {
600
623
  return __awaiter(this, void 0, void 0, function* () {
601
624
  const { data } = yield this.axios.get(`/api/addresses/verification?`, {
@@ -1,5 +1,6 @@
1
1
  import { Fiat } from "./fiat";
2
- export interface MultipartLiquidityOrderAttrs {
2
+ import { Crypto } from "./crypto";
3
+ export interface MultipartLiquidityOrder {
3
4
  createdAt: Date;
4
5
  destinationCrypto: Crypto;
5
6
  originFiat: Fiat;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@riocrypto/common",
3
- "version": "1.0.1464",
3
+ "version": "1.0.1466",
4
4
  "description": "",
5
5
  "main": "./build/index.js",
6
6
  "types": "./build/index.d.ts",