mirror of
https://github.com/orionprotocol/sdk.git
synced 2026-03-14 14:12:35 +03:00
feat: added endpoint for receiving gas limits from OB
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@orionprotocol/sdk",
|
||||
"version": "0.20.60",
|
||||
"version": "0.20.61-rc100",
|
||||
"description": "Orion Protocol SDK",
|
||||
"main": "./lib/index.cjs",
|
||||
"module": "./lib/index.js",
|
||||
|
||||
@@ -111,6 +111,7 @@ class BlockchainService {
|
||||
this.getBlockNumber = this.getBlockNumber.bind(this);
|
||||
this.getRedeemOrderBySecretHash = this.getRedeemOrderBySecretHash.bind(this);
|
||||
this.claimOrder = this.claimOrder.bind(this);
|
||||
this.getGasLimits = this.getGasLimits.bind(this);
|
||||
}
|
||||
|
||||
get basicAuthHeaders() {
|
||||
@@ -484,6 +485,12 @@ class BlockchainService {
|
||||
body: JSON.stringify(secretHashes),
|
||||
},
|
||||
);
|
||||
|
||||
getGasLimits = () => fetchWithValidation(
|
||||
`${this.apiUrl}api/baseLimits`,
|
||||
z.record(z.number()),
|
||||
{ headers: this.basicAuthHeaders }
|
||||
);
|
||||
}
|
||||
|
||||
export * as schemas from './schemas/index.js';
|
||||
|
||||
Reference in New Issue
Block a user