Files
nym/clients/validator
benedetta davico 17c2aecd99 starting to add vesting tests (#3134)
* starting to add vesting tests

* adding more vesting client tests

* starting to add vesting tests & merging develop

* adding more vesting client tests

* fix linting

* Revert "Merge conflicts"

This reverts commit 0beb025a62.

* fix linting errors

* fix linting errors

* removing only adding skip

---------

Co-authored-by: fmtabbara <fmtabbara@hotmail.co.uk>
2023-03-22 18:30:07 +01:00
..
2023-03-22 18:30:07 +01:00
2023-03-01 10:22:35 +01:00
2023-03-01 10:22:35 +01:00
2021-12-16 15:35:30 +00:00
2021-03-24 11:49:58 +00:00
2023-03-01 10:22:35 +01:00

Nym Validator Client (Typescript)

A TypeScript client for interacting with CosmWasm smart contracts in Nym validators.

Include the Nym Validator in your project:

yarn add @nymproject/nym-validator-client

Connect to validator and make queries

import Validator from '@nymproject/nym-validator-client'

const main = async () => {

 const client = await Validator.connectForQuery(rpcAddress, validatorAddress, prefix, mixnetContractAddress, vestingContractAddress, denom)

 client.getBalance(address)

}

Connect to validator for performing actions

import Validator from '@nymproject/nym-validator-client'

const main = async () => {

 const client = await Validator.connect(mnemonic, rpcAddress, validatorAddress, prefix, mixnetContractAddress, vestingContractAddress, denom)

 const res = await client.send(address, [{ amount: '10000000', denom: 'unym' }]);

}