mirror of
https://github.com/orionprotocol/sdk.git
synced 2026-03-14 06:02:36 +03:00
Compatibility
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@orionprotocol/sdk",
|
||||
"version": "0.19.42-rc4",
|
||||
"version": "0.19.42-rc5",
|
||||
"description": "Orion Protocol SDK",
|
||||
"main": "./lib/index.cjs",
|
||||
"module": "./lib/index.js",
|
||||
|
||||
@@ -84,6 +84,7 @@ class BlockchainService {
|
||||
this.getUserEarned = this.getUserEarned.bind(this);
|
||||
this.getPoolsV3Info = this.getPoolsV3Info.bind(this);
|
||||
this.getHistory = this.getHistory.bind(this);
|
||||
this.getPrices = this.getPrices.bind(this);
|
||||
this.getPricesWithQuoteAsset = this.getPricesWithQuoteAsset.bind(this);
|
||||
this.getTokensFee = this.getTokensFee.bind(this);
|
||||
this.getGasPriceWei = this.getGasPriceWei.bind(this);
|
||||
@@ -215,8 +216,14 @@ class BlockchainService {
|
||||
{ headers: this.basicAuthHeaders }
|
||||
);
|
||||
|
||||
getPricesWithQuoteAsset = () => fetchWithValidation(
|
||||
getPrices = () => fetchWithValidation(
|
||||
`${this.apiUrl}/api/prices`,
|
||||
z.record(z.string()).transform(makePartial),
|
||||
{ headers: this.basicAuthHeaders }
|
||||
);
|
||||
|
||||
getPricesWithQuoteAsset = () => fetchWithValidation(
|
||||
`${this.apiUrl}/api/quotedPrices`,
|
||||
pricesWithQuoteAssetSchema,
|
||||
{ headers: this.basicAuthHeaders }
|
||||
);
|
||||
|
||||
@@ -3,5 +3,6 @@ import { makePartial } from '../../../utils/index.js';
|
||||
|
||||
export const pricesWithQuoteAssetSchema = z.object({
|
||||
quoteAsset: z.string(),
|
||||
quoteAssetAddress: z.string(),
|
||||
prices: z.record(z.string()).transform(makePartial)
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user