solrise-dawn-sdk
v0.1.1
Published
Solrise Dawn SDK
Downloads
1
Readme
Solrise Dawn SDK
Solrise Dawn SDK is a simple JavaScript SDK that supports querying oracle prices (getPrice
, getPrices
), fund data (getFundData
), investor data (getInvestorData
) and supports basic trading transactions (exchange
, invest
, withdraw
).
Usage
Install the package using npm:
npm i solrise-dawn-sdk
Initialize the Solrise client:
const { Solrise, SecretKeySigner, SolflareSigner, MnemonicSigner } = require('solrise-dawn-sdk')
let signer = new SecretKeySigner(/* key */)
// let signer = new SolflareSigner(/* keystore path */, /* password */)
// let signer = new MnemonicSigner(/* mnemonic */)
let client = new Solrise(signer)
If you only plan to query data and don't want to send transactions, you can initialized the client without a signer:
const { Solrise } = require('solrise-dawn-sdk')
let client = new Solrise()
See more usage examples in the examples
directory.