@riocrypto/common-server 1.0.2431 → 1.0.2432

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.
@@ -10,7 +10,7 @@ declare class ClusterClient {
10
10
  newAmountCrypto?: number;
11
11
  useSamePrice?: boolean;
12
12
  }): Promise<Quote>;
13
- createQuote({ userId, side, country, fiat, crypto, amountFiat, amountCrypto, USBankTransferMethod, deferredPaymentType, twoWaySettlementType, twoWaySettlementDateOffset, netPrice, marketPrice, ignoreLiquidityError, priceType, limitNetPrice, cancelAt, }: {
13
+ createQuote({ userId, side, country, fiat, crypto, amountFiat, amountCrypto, USBankTransferMethod, deferredPaymentType, twoWaySettlementType, twoWaySettlementDateOffset, netPrice, marketPrice, ignoreLiquidityError, priceType, limitNetPrice, validFromDate, validUntilDate, }: {
14
14
  userId: string;
15
15
  side: Side;
16
16
  country: Country;
@@ -27,7 +27,8 @@ declare class ClusterClient {
27
27
  ignoreLiquidityError?: boolean;
28
28
  priceType?: PriceType;
29
29
  limitNetPrice?: number;
30
- cancelAt?: Date;
30
+ validFromDate?: Date;
31
+ validUntilDate?: Date;
31
32
  }): Promise<Quote>;
32
33
  getNewChainedQuote(chainedOrderId: string, chainedQuote: ChainedQuote, newOriginAmount?: number): Promise<ChainedQuote>;
33
34
  getBidQuote(userId: string, side: Side, country: Country, fiat: Fiat, crypto: Crypto, amountFiat?: number, amountCrypto?: number, USBankTransferMethod?: "ach_push" | "wire", netPrice?: string): Promise<Quote>;
@@ -74,7 +74,7 @@ class ClusterClient {
74
74
  return response.data.quote;
75
75
  });
76
76
  }
77
- createQuote({ userId, side, country, fiat, crypto, amountFiat, amountCrypto, USBankTransferMethod, deferredPaymentType, twoWaySettlementType, twoWaySettlementDateOffset, netPrice, marketPrice, ignoreLiquidityError, priceType, limitNetPrice, cancelAt, }) {
77
+ createQuote({ userId, side, country, fiat, crypto, amountFiat, amountCrypto, USBankTransferMethod, deferredPaymentType, twoWaySettlementType, twoWaySettlementDateOffset, netPrice, marketPrice, ignoreLiquidityError, priceType, limitNetPrice, validFromDate, validUntilDate, }) {
78
78
  return __awaiter(this, void 0, void 0, function* () {
79
79
  const response = yield this.axios.post(`${this.baseUrl}/api/quotes`, {
80
80
  userId,
@@ -93,7 +93,8 @@ class ClusterClient {
93
93
  ignoreLiquidityError,
94
94
  priceType,
95
95
  limitNetPrice,
96
- cancelAt,
96
+ validFromDate,
97
+ validUntilDate,
97
98
  }, {
98
99
  headers: {
99
100
  "x-cluster-api-key": this.clusterApiKey,
@@ -32,7 +32,8 @@ interface OrderAttrs {
32
32
  withdrawalTxIds?: string[];
33
33
  brokerId?: string;
34
34
  limitNetPrice?: number;
35
- cancelAt?: Date;
35
+ validFromDate?: Date;
36
+ validUntilDate?: Date;
36
37
  conversionRateUSD: number;
37
38
  conversionRateUSDWithMarkups: number;
38
39
  actualConversionRateUSD?: number;
@@ -145,7 +146,8 @@ interface OrderDoc extends Document {
145
146
  twoWaySettlementDate: Date;
146
147
  country: Country;
147
148
  limitNetPrice?: number;
148
- cancelAt?: Date;
149
+ validFromDate?: Date;
150
+ validUntilDate?: Date;
149
151
  cryptoAddress?: string;
150
152
  amountFiat: number;
151
153
  amountCrypto: number;
@@ -38,7 +38,10 @@ const buildOrder = (mongoose) => {
38
38
  bulkBankPaymentId: {
39
39
  type: String,
40
40
  },
41
- cancelAt: {
41
+ validFromDate: {
42
+ type: mongoose.Schema.Types.Date,
43
+ },
44
+ validUntilDate: {
42
45
  type: mongoose.Schema.Types.Date,
43
46
  },
44
47
  crypto: {
@@ -20,7 +20,8 @@ interface QuoteAttrs {
20
20
  price?: number;
21
21
  marketPrice: number;
22
22
  createdAt: Date;
23
- cancelAt?: Date;
23
+ validFromDate?: Date;
24
+ validUntilDate?: Date;
24
25
  noMarkups: boolean;
25
26
  quoteInCrypto: boolean;
26
27
  reissueAfterExpiration: boolean;
@@ -58,7 +59,8 @@ interface QuoteDoc extends Document {
58
59
  liquidityProvider: LiquidityProvider;
59
60
  processor: Processor;
60
61
  createdAt: Date;
61
- cancelAt?: Date;
62
+ validFromDate?: Date;
63
+ validUntilDate?: Date;
62
64
  fees: Fees;
63
65
  price?: number;
64
66
  marketPrice: number;
@@ -107,7 +107,10 @@ const buildQuote = (mongoose) => {
107
107
  type: mongoose.Schema.Types.Date,
108
108
  required: true,
109
109
  },
110
- cancelAt: {
110
+ validFromDate: {
111
+ type: mongoose.Schema.Types.Date,
112
+ },
113
+ validUntilDate: {
111
114
  type: mongoose.Schema.Types.Date,
112
115
  },
113
116
  conversionRateUSD: {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@riocrypto/common-server",
3
- "version": "1.0.2431",
3
+ "version": "1.0.2432",
4
4
  "description": "",
5
5
  "main": "./build/index.js",
6
6
  "types": "./build/index.d.ts",
@@ -28,7 +28,7 @@
28
28
  "@google-cloud/secret-manager": "^5.3.0",
29
29
  "@google-cloud/storage": "^6.9.5",
30
30
  "@hyperdx/node-opentelemetry": "^0.7.0",
31
- "@riocrypto/common": "^1.0.2189",
31
+ "@riocrypto/common": "^1.0.2190",
32
32
  "@types/express": "^4.17.13",
33
33
  "axios": "^1.7.4",
34
34
  "crypto-js": "^4.2.0",