@riocrypto/common 1.0.1898 → 1.0.1900

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/build/index.d.ts CHANGED
@@ -328,6 +328,9 @@ export * from "./types/pre-settlement-transaction-type";
328
328
  export * from "./types/currency-with-country";
329
329
  export * from "./types/CEP";
330
330
  export * from "./types/CEP-status";
331
+ export * from "./types/fx-sub-trade";
332
+ export * from "./types/fx-sub-trade-status";
333
+ export * from "./types/fx-sub-trade-type";
331
334
  export * from "./classes/KYCFieldClass";
332
335
  export * from "./classes/KYCFileClass";
333
336
  export * from "./classes/CountryAsset";
package/build/index.js CHANGED
@@ -344,6 +344,9 @@ __exportStar(require("./types/pre-settlement-transaction-type"), exports);
344
344
  __exportStar(require("./types/currency-with-country"), exports);
345
345
  __exportStar(require("./types/CEP"), exports);
346
346
  __exportStar(require("./types/CEP-status"), exports);
347
+ __exportStar(require("./types/fx-sub-trade"), exports);
348
+ __exportStar(require("./types/fx-sub-trade-status"), exports);
349
+ __exportStar(require("./types/fx-sub-trade-type"), exports);
347
350
  __exportStar(require("./classes/KYCFieldClass"), exports);
348
351
  __exportStar(require("./classes/KYCFileClass"), exports);
349
352
  __exportStar(require("./classes/CountryAsset"), exports);
@@ -0,0 +1,8 @@
1
+ export declare enum FXSubTradeStatus {
2
+ Created = "created",
3
+ Complete = "complete",
4
+ PartiallyFilled = "partiallyFilled",
5
+ Failed = "failed",
6
+ Filling = "filling",
7
+ Cancelled = "cancelled"
8
+ }
@@ -0,0 +1,12 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.FXSubTradeStatus = void 0;
4
+ var FXSubTradeStatus;
5
+ (function (FXSubTradeStatus) {
6
+ FXSubTradeStatus["Created"] = "created";
7
+ FXSubTradeStatus["Complete"] = "complete";
8
+ FXSubTradeStatus["PartiallyFilled"] = "partiallyFilled";
9
+ FXSubTradeStatus["Failed"] = "failed";
10
+ FXSubTradeStatus["Filling"] = "filling";
11
+ FXSubTradeStatus["Cancelled"] = "cancelled";
12
+ })(FXSubTradeStatus = exports.FXSubTradeStatus || (exports.FXSubTradeStatus = {}));
@@ -0,0 +1,4 @@
1
+ export declare enum FXSubTradeType {
2
+ Market = "market",
3
+ Limit = "limit"
4
+ }
@@ -0,0 +1,8 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.FXSubTradeType = void 0;
4
+ var FXSubTradeType;
5
+ (function (FXSubTradeType) {
6
+ FXSubTradeType["Market"] = "market";
7
+ FXSubTradeType["Limit"] = "limit";
8
+ })(FXSubTradeType = exports.FXSubTradeType || (exports.FXSubTradeType = {}));
@@ -0,0 +1,26 @@
1
+ import { Fiat } from "./fiat";
2
+ import { Crypto } from "./crypto";
3
+ import { FXProvider } from "./fx-provider";
4
+ import { FXSubTradeStatus } from "./fx-sub-trade-status";
5
+ import { FXSubTradeType } from "./fx-sub-trade-type";
6
+ export interface FXSubTrade {
7
+ id: string;
8
+ createdAt: Date;
9
+ fxTradeId: string;
10
+ provider: FXProvider;
11
+ originAmount: number;
12
+ originCurrency: Fiat | Crypto;
13
+ destinationAmount: number;
14
+ destinationCurrency: Fiat | Crypto;
15
+ status: FXSubTradeStatus;
16
+ type: FXSubTradeType;
17
+ providerOrderId?: string;
18
+ amountFilled?: number;
19
+ limitPrice?: number;
20
+ price?: number;
21
+ providerOptions?: {
22
+ emarkets?: {
23
+ orderType?: "TOD" | "SPT" | "TOM";
24
+ };
25
+ };
26
+ }
@@ -0,0 +1,2 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -4,5 +4,6 @@ export declare enum FXTradeStatus {
4
4
  Completed = "completed",
5
5
  Cancelled = "cancelled",
6
6
  Failed = "failed",
7
- PendingExecutionThreshold = "pendingExecutionThreshold"
7
+ PendingExecutionThreshold = "pendingExecutionThreshold",
8
+ WaitingForFunds = "waitingForFunds"
8
9
  }
@@ -9,4 +9,5 @@ var FXTradeStatus;
9
9
  FXTradeStatus["Cancelled"] = "cancelled";
10
10
  FXTradeStatus["Failed"] = "failed";
11
11
  FXTradeStatus["PendingExecutionThreshold"] = "pendingExecutionThreshold";
12
+ FXTradeStatus["WaitingForFunds"] = "waitingForFunds";
12
13
  })(FXTradeStatus = exports.FXTradeStatus || (exports.FXTradeStatus = {}));
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@riocrypto/common",
3
- "version": "1.0.1898",
3
+ "version": "1.0.1900",
4
4
  "description": "",
5
5
  "main": "./build/index.js",
6
6
  "types": "./build/index.d.ts",