mirror of
https://github.com/orionprotocol/sdk.git
synced 2026-04-05 04:28:16 +03:00
Add governanceChainsInfoSchema
This commit is contained in:
@@ -14,6 +14,7 @@ import {
|
||||
governanceContractsSchema,
|
||||
governancePoolsSchema,
|
||||
governancePoolSchema,
|
||||
governanceChainsInfoSchema,
|
||||
} from './schemas/index.js';
|
||||
import type redeemOrderSchema from '../Aggregator/schemas/redeemOrderSchema.js';
|
||||
import { sourceAtomicHistorySchema, targetAtomicHistorySchema } from './schemas/atomicHistorySchema.js';
|
||||
@@ -110,6 +111,7 @@ class BlockchainService {
|
||||
this.getGovernanceContracts = this.getGovernanceContracts.bind(this);
|
||||
this.getGovernancePools = this.getGovernancePools.bind(this);
|
||||
this.getGovernancePool = this.getGovernancePool.bind(this);
|
||||
this.getGovernanceChainsInfo = this.getGovernanceChainsInfo.bind(this);
|
||||
}
|
||||
|
||||
get blockchainServiceWsUrl() {
|
||||
@@ -443,6 +445,11 @@ class BlockchainService {
|
||||
`${this.apiUrl}/api/governance/pools/${address}`,
|
||||
governancePoolSchema,
|
||||
);
|
||||
|
||||
getGovernanceChainsInfo = () => fetchWithValidation(
|
||||
`${this.apiUrl}/api/governance/chains-info`,
|
||||
governanceChainsInfoSchema,
|
||||
);
|
||||
}
|
||||
|
||||
export * as schemas from './schemas/index.js';
|
||||
|
||||
Reference in New Issue
Block a user