@siafoundation/explored-js
v0.3.1
Published
SDK for interacting with `explored`.
Downloads
89
Readme
explored-js
A Typescript SDK for interacting with the explored
API.
installation
npm install @siafoundation/explored-js
usage
import { Explored } from '@siafoundation/explored-js'
export async function exampleExploredDataFetch() {
const explored = Explored({
api: 'http://localhost:9980/api',
password: 'password1337',
})
try {
const transactionFeeResponse = await explored.txpoolFee()
if (transactionFeeResponse.status !== 200)
throw new Error(transactionFeeResponse.statusText)
const transactionFee = transactionFeeResponse.data
// Do Transaction Fee things.
console.log(transactionFee)
} catch (e) {
// Handle the error
console.log(e)
}
}
explored libraries
- types
- sdk (this repo)
- react hooks
API documentation
https://api.sia.tech/explored
The Sia Foundation
This library is brought to you by The Sia Foundation, Inc.--a registered 501(c)(3) non-profit dedicated to revolutionizing data storage through decentralization.