UNPKG

equation-sdk

Version:

🛠 An SDK for building applications on top of Equation.

39 lines (38 loc) • 1.27 kB
import PositionRouter from "./modules/PositionRouter"; import Approval from "./modules/Approval"; import { Markets } from "./modules/Markets"; declare class EquationSDK { providerName: string; privateKey: string | undefined; wallet: null; Web3Provider: any; /** * Represents the Equation SDK constructor. * @constructor * @param {string} providerName - The name of the Web3Provider. * @param {string} privateKey - The private key. */ constructor(providerName: string, privateKey?: string); /** * Get the Web3Provider instance. * @returns { Web3Provider } The Web3Provider instance. */ get provider(): any; get approval(): Approval; /** * Get the PositionRouter instance. * @returns {PositionRouter} The PositionRouter instance. */ get positionRouter(): PositionRouter; /** * Get the Markets instance. * @returns {Markets} The Market instance. */ get markets(): typeof Markets; /** * Connect to the Web3Provider. * @returns { Promise<boolean> } A promise that resolves to true if the connection is successful, false otherwise. */ connect(): Promise<void>; } export default EquationSDK;