Skip to content

ODIN-PROTOCOL/odinprotocoljs

Repository files navigation

Logo

Odinprotocoljs

OdinprotocolJS is a library for interacting easily with Odin network based on Stargate.

Report Bug · Request Feature


Install

npm install odinprotocoljs

Usage

First you need to import the odin client and connect it to your RPC. Then you can call the methods of the client.

All methods for Odin Client are defined in the interface extension types/generated/odin/odinExtension.ts

Run the following file with:

node --es-module-specifier-resolution=node .\dataSourceTest.js

RPC Clients

import { odinQueryClient } from "odinprotocoljs";

const config_rpc = "https://node.odin-freya-website.odinprotocol.io/mainnet/a/"

const myOdinClient = new odinQueryClient()
await myOdinClient.connect(config_rpc);

const dataSource = await myOdinClient.queryClient.oracle.getDataSourceById(14)
console.log(dataSource)

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published