Class: DesmosClient
Client to interact with the Desmos chain.
Hierarchy
SigningCosmWasmClient
↳
DesmosClient
Constructors
constructor
• new DesmosClient(client
, options
, signer?
): DesmosClient
Parameters
Name | Type |
---|---|
client | undefined | Tendermint37Client |
options | Options |
signer | Signer |
Returns
Overrides
SigningCosmWasmClient.constructor
Defined in
packages/core/src/desmosclient.ts:203
Properties
broadcastPollIntervalMs
• Readonly
broadcastPollIntervalMs: undefined
| number
Inherited from
SigningCosmWasmClient.broadcastPollIntervalMs
Defined in
node_modules/@cosmjs/cosmwasm-stargate/build/signingcosmwasmclient.d.ts:106
broadcastTimeoutMs
• Readonly
broadcastTimeoutMs: undefined
| number
Inherited from
SigningCosmWasmClient.broadcastTimeoutMs
Defined in
node_modules/@cosmjs/cosmwasm-stargate/build/signingcosmwasmclient.d.ts:105
options
• Private
Readonly
options: Options
Defined in
packages/core/src/desmosclient.ts:140
registry
• Readonly
registry: Registry
Inherited from
SigningCosmWasmClient.registry
Defined in
node_modules/@cosmjs/cosmwasm-stargate/build/signingcosmwasmclient.d.ts:104
txSigner
• Private
txSigner: Signer
Defined in
packages/core/src/desmosclient.ts:134
types
• Private
types: AminoTypes
Defined in
packages/core/src/desmosclient.ts:138
typesRegistry
• Private
typesRegistry: Registry
Defined in
packages/core/src/desmosclient.ts:136
Accessors
querier
• get
querier(): DesmosQueryClient
Gets a DesmosQueryClient that can be used to query the data from the chain. NOTE: This method will throw an Error if the Client is not connected.
Returns
Defined in
packages/core/src/desmosclient.ts:658
Methods
broadcastTransaction
▸ broadcastTransaction(tx
, mode
): Promise
<BroadcastResponse
>
Broadcast a transaction on chain.
Parameters
Name | Type | Description |
---|---|---|
tx | TxRaw | The transaction to broadcast. |
mode | BroadcastMode | The broadcast mode. |
Returns
Promise
<BroadcastResponse
>
Defined in
packages/core/src/desmosclient.ts:715
broadcastTx
▸ broadcastTx(tx
, timeoutMs?
, pollIntervalMs?
): Promise
<DeliverTxResponse
>
Broadcasts a signed transaction to the network and monitors its inclusion in a block.
If broadcasting is rejected by the node for some reason (e.g. because of a CheckTx failure), an error is thrown.
If the transaction is not included in a block before the provided timeout, this errors with a TimeoutError
.
If the transaction is included in a block, a DeliverTxResponse
is returned. The caller then
usually needs to check for execution success or failure.
Parameters
Name | Type |
---|---|
tx | Uint8Array |
timeoutMs? | number |
pollIntervalMs? | number |
Returns
Promise
<DeliverTxResponse
>
Inherited from
SigningCosmWasmClient.broadcastTx
Defined in
node_modules/@cosmjs/cosmwasm-stargate/build/cosmwasmclient.d.ts:83
broadcastTxAsync
▸ broadcastTxAsync(tx
): Promise
<AsyncBroadcastResponse
>
Broadcast transaction to mempool and do not wait for response.
Parameters
Name | Type | Description |
---|---|---|
tx | TxRaw | The transaction to broadcast. |
Returns
Promise
<AsyncBroadcastResponse
>
Defined in
packages/core/src/desmosclient.ts:666
broadcastTxBlock
▸ broadcastTxBlock(tx
): Promise
<BlockBroadcastResponse
>
Broadcast transaction to mempool and wait that is included in a block.
Parameters
Name | Type | Description |
---|---|---|
tx | TxRaw | The transaction to broadcast. |
Returns
Promise
<BlockBroadcastResponse
>
Defined in
packages/core/src/desmosclient.ts:696
broadcastTxRawSync
▸ broadcastTxRawSync(tx
): Promise
<SyncBroadcastResponse
>
Broadcast transaction to mempool and wait for response.
Parameters
Name | Type | Description |
---|---|---|
tx | TxRaw | The transaction to broadcast. |
Returns
Promise
<SyncBroadcastResponse
>
Defined in
packages/core/src/desmosclient.ts:681
broadcastTxSync
▸ broadcastTxSync(tx
): Promise
<string
>
Broadcasts a signed transaction to the network without monitoring it.
If broadcasting is rejected by the node for some reason (e.g. because of a CheckTx failure), an error is thrown.
If the transaction is broadcasted, a string
containing the hash of the transaction is returned. The caller then
usually needs to check if the transaction was included in a block and was successful.
Parameters
Name | Type |
---|---|
tx | Uint8Array |
Returns
Promise
<string
>
Returns the hash of the transaction
Inherited from
SigningCosmWasmClient.broadcastTxSync
Defined in
node_modules/@cosmjs/cosmwasm-stargate/build/cosmwasmclient.d.ts:95
clearAdmin
▸ clearAdmin(senderAddress
, contractAddress
, fee
, memo?
): Promise
<ChangeAdminResult
>
Parameters
Name | Type |
---|---|
senderAddress | string |
contractAddress | string |
fee | number | StdFee | "auto" |
memo? | string |
Returns
Promise
<ChangeAdminResult
>
Inherited from
SigningCosmWasmClient.clearAdmin
Defined in
node_modules/@cosmjs/cosmwasm-stargate/build/signingcosmwasmclient.d.ts:139
delegateTokens
▸ delegateTokens(delegatorAddress
, validatorAddress
, amount
, fee
, memo?
): Promise
<DeliverTxResponse
>
Parameters
Name | Type |
---|---|
delegatorAddress | string |
validatorAddress | string |
amount | Coin |
fee | number | StdFee | "auto" |
memo? | string |
Returns
Promise
<DeliverTxResponse
>
Inherited from
SigningCosmWasmClient.delegateTokens
Defined in
node_modules/@cosmjs/cosmwasm-stargate/build/signingcosmwasmclient.d.ts:147
disconnect
▸ disconnect(): void
Returns
void
Inherited from
SigningCosmWasmClient.disconnect
Defined in
node_modules/@cosmjs/cosmwasm-stargate/build/cosmwasmclient.d.ts:71
encodeToAmino
▸ encodeToAmino(msgs
): AminoMsg
[]
Encode the given message objects into Amino messages.
Parameters
Name | Type | Description |
---|---|---|
msgs | readonly EncodeObject [] | Messages to be encoded. |
Returns
AminoMsg
[]
Defined in
packages/core/src/desmosclient.ts:483
estimateTxFee
▸ estimateTxFee(signerAddress
, messages
, options?
): Promise
<StdFee
>
Function to estimate the fees required to perform a transaction.
Parameters
Name | Type | Description |
---|---|---|
signerAddress | string | Address of who is performing the transaction. |
messages | readonly EncodeObject [] | Messages of the transaction to simulate. |
options? | SimulateOptions | Extra transaction simulation options. |
Returns
Promise
<StdFee
>
Defined in
packages/core/src/desmosclient.ts:446
estimateTxGas
▸ estimateTxGas(signerAddress
, messages
, options?
): Promise
<number
>
Function to estimate the required gas to perform a transaction.
Parameters
Name | Type | Description |
---|---|---|
signerAddress | string | Address of who is performing the transaction. |
messages | readonly EncodeObject [] | Messages of the transaction to simulate. |
options? | SimulateOptions | Extra transaction simulation options. |
Returns
Promise
<number
>
Defined in
packages/core/src/desmosclient.ts:408
execute
▸ execute(senderAddress
, contractAddress
, msg
, fee
, memo?
, funds?
): Promise
<ExecuteResult
>
Parameters
Name | Type |
---|---|
senderAddress | string |
contractAddress | string |
msg | any |
fee | number | StdFee | "auto" |
memo? | string |
funds? | readonly Coin [] |
Returns
Promise
<ExecuteResult
>
Inherited from
SigningCosmWasmClient.execute
Defined in
node_modules/@cosmjs/cosmwasm-stargate/build/signingcosmwasmclient.d.ts:141
executeMultiple
▸ executeMultiple(senderAddress
, instructions
, fee
, memo?
): Promise
<ExecuteResult
>
Like execute
but allows executing multiple messages in one transaction.
Parameters
Name | Type |
---|---|
senderAddress | string |
instructions | readonly ExecuteInstruction [] |
fee | number | StdFee | "auto" |
memo? | string |
Returns
Promise
<ExecuteResult
>
Inherited from
SigningCosmWasmClient.executeMultiple
Defined in
node_modules/@cosmjs/cosmwasm-stargate/build/signingcosmwasmclient.d.ts:145
forceGetQueryClient
▸ forceGetQueryClient(): DesmosQueryClient
Implements SigningStargateClient.
Returns
Overrides
SigningCosmWasmClient.forceGetQueryClient
Defined in
packages/core/src/desmosclient.ts:272
forceGetTmClient
▸ forceGetTmClient(): TendermintClient
Returns
TendermintClient
Inherited from
SigningCosmWasmClient.forceGetTmClient
Defined in
node_modules/@cosmjs/cosmwasm-stargate/build/cosmwasmclient.d.ts:60
getAccount
▸ getAccount(searchAddress
): Promise
<null
| Account
>
Gets the account associated to the provided address, or null
if no account is found.
This function has been overridden to correctly parse a Desmos profile.
Parameters
Name | Type |
---|---|
searchAddress | string |
Returns
Promise
<null
| Account
>
Overrides
SigningCosmWasmClient.getAccount
Defined in
packages/core/src/desmosclient.ts:241
getAccountFromSigner
▸ getAccountFromSigner(address
): Promise
<AccountData
>
Returns the account having the given address reading them from the signer.
Parameters
Name | Type | Description |
---|---|---|
address | string | Address of the account to be searched for. |
Returns
Promise
<AccountData
>
Defined in
packages/core/src/desmosclient.ts:329
getBalance
▸ getBalance(address
, searchDenom
): Promise
<Coin
>
Parameters
Name | Type |
---|---|
address | string |
searchDenom | string |
Returns
Promise
<Coin
>
Inherited from
SigningCosmWasmClient.getBalance
Defined in
node_modules/@cosmjs/cosmwasm-stargate/build/cosmwasmclient.d.ts:68
getBlock
▸ getBlock(height?
): Promise
<Block
>
Parameters
Name | Type |
---|---|
height? | number |
Returns
Promise
<Block
>
Inherited from
SigningCosmWasmClient.getBlock
Defined in
node_modules/@cosmjs/cosmwasm-stargate/build/cosmwasmclient.d.ts:67
getChainId
▸ getChainId(): Promise
<string
>
Returns
Promise
<string
>
Inherited from
SigningCosmWasmClient.getChainId
Defined in
node_modules/@cosmjs/cosmwasm-stargate/build/cosmwasmclient.d.ts:63
getCodeDetails
▸ getCodeDetails(codeId
): Promise
<CodeDetails
>
Parameters
Name | Type |
---|---|
codeId | number |
Returns
Promise
<CodeDetails
>
Inherited from
SigningCosmWasmClient.getCodeDetails
Defined in
node_modules/@cosmjs/cosmwasm-stargate/build/cosmwasmclient.d.ts:103
getCodes
▸ getCodes(): Promise
<readonly Code
[]>
getCodes() returns all codes and is just looping through all pagination pages.
This is potentially inefficient and advanced apps should consider creating their own query client to handle pagination together with the app's screens.
Returns
Promise
<readonly Code
[]>
Inherited from
SigningCosmWasmClient.getCodes
Defined in
node_modules/@cosmjs/cosmwasm-stargate/build/cosmwasmclient.d.ts:102
getContract
▸ getContract(address
): Promise
<Contract
>
Throws an error if no contract was found at the address
Parameters
Name | Type |
---|---|
address | string |
Returns
Promise
<Contract
>
Inherited from
SigningCosmWasmClient.getContract
Defined in
node_modules/@cosmjs/cosmwasm-stargate/build/cosmwasmclient.d.ts:119
getContractCodeHistory
▸ getContractCodeHistory(address
): Promise
<readonly ContractCodeHistoryEntry
[]>
Throws an error if no contract was found at the address
Parameters
Name | Type |
---|---|
address | string |
Returns
Promise
<readonly ContractCodeHistoryEntry
[]>
Inherited from
SigningCosmWasmClient.getContractCodeHistory
Defined in
node_modules/@cosmjs/cosmwasm-stargate/build/cosmwasmclient.d.ts:123
getContracts
▸ getContracts(codeId
): Promise
<readonly string
[]>
getContracts() returns all contract instances for one code and is just looping through all pagination pages.
This is potentially inefficient and advanced apps should consider creating their own query client to handle pagination together with the app's screens.
Parameters
Name | Type |
---|---|
codeId | number |
Returns
Promise
<readonly string
[]>
Inherited from
SigningCosmWasmClient.getContracts
Defined in
node_modules/@cosmjs/cosmwasm-stargate/build/cosmwasmclient.d.ts:110
getContractsByCreator
▸ getContractsByCreator(creator
): Promise
<string
[]>
Returns a list of contract addresses created by the given creator. This just loops through all pagination pages.
Parameters
Name | Type |
---|---|
creator | string |
Returns
Promise
<string
[]>
Inherited from
SigningCosmWasmClient.getContractsByCreator
Defined in
node_modules/@cosmjs/cosmwasm-stargate/build/cosmwasmclient.d.ts:115
getHeight
▸ getHeight(): Promise
<number
>
Returns
Promise
<number
>
Inherited from
SigningCosmWasmClient.getHeight
Defined in
node_modules/@cosmjs/cosmwasm-stargate/build/cosmwasmclient.d.ts:64
getProfile
▸ getProfile(searchAddress
): Promise
<null
| Profile
>
Gets the profile associated to the provided address, or null
if no profile is found.
Parameters
Name | Type |
---|---|
searchAddress | string |
Returns
Promise
<null
| Profile
>
Defined in
packages/core/src/desmosclient.ts:254
getQueryClient
▸ getQueryClient(): undefined
| DesmosQueryClient
Implements SigningStargateClient.
Returns
undefined
| DesmosQueryClient
Overrides
SigningCosmWasmClient.getQueryClient
Defined in
packages/core/src/desmosclient.ts:263
getSequence
▸ getSequence(address
): Promise
<SequenceResponse
>
Parameters
Name | Type |
---|---|
address | string |
Returns
Promise
<SequenceResponse
>
Inherited from
SigningCosmWasmClient.getSequence
Defined in
node_modules/@cosmjs/cosmwasm-stargate/build/cosmwasmclient.d.ts:66
getSignerData
▸ getSignerData(signerAddress
): Promise
<SignerData
>
Returns the SignerData for the user having the given address, querying them from the chain.
Parameters
Name | Type |
---|---|
signerAddress | string |
Returns
Promise
<SignerData
>
Defined in
packages/core/src/desmosclient.ts:286
getTmClient
▸ getTmClient(): undefined
| TendermintClient
Returns
undefined
| TendermintClient
Inherited from
SigningCosmWasmClient.getTmClient
Defined in
node_modules/@cosmjs/cosmwasm-stargate/build/cosmwasmclient.d.ts:59
getTx
▸ getTx(id
): Promise
<null
| IndexedTx
>
Parameters
Name | Type |
---|---|
id | string |
Returns
Promise
<null
| IndexedTx
>
Inherited from
SigningCosmWasmClient.getTx
Defined in
node_modules/@cosmjs/cosmwasm-stargate/build/cosmwasmclient.d.ts:69
instantiate
▸ instantiate(senderAddress
, codeId
, msg
, label
, fee
, options?
): Promise
<InstantiateResult
>
Parameters
Name | Type |
---|---|
senderAddress | string |
codeId | number |
msg | any |
label | string |
fee | number | StdFee | "auto" |
options? | InstantiateOptions |
Returns
Promise
<InstantiateResult
>
Inherited from
SigningCosmWasmClient.instantiate
Defined in
node_modules/@cosmjs/cosmwasm-stargate/build/signingcosmwasmclient.d.ts:136
instantiate2
▸ instantiate2(senderAddress
, codeId
, salt
, msg
, label
, fee
, options?
): Promise
<InstantiateResult
>
Parameters
Name | Type |
---|---|
senderAddress | string |
codeId | number |
salt | Uint8Array |
msg | any |
label | string |
fee | number | StdFee | "auto" |
options? | InstantiateOptions |
Returns
Promise
<InstantiateResult
>
Inherited from
SigningCosmWasmClient.instantiate2
Defined in
node_modules/@cosmjs/cosmwasm-stargate/build/signingcosmwasmclient.d.ts:137
migrate
▸ migrate(senderAddress
, contractAddress
, codeId
, migrateMsg
, fee
, memo?
): Promise
<MigrateResult
>
Parameters
Name | Type |
---|---|
senderAddress | string |
contractAddress | string |
codeId | number |
migrateMsg | any |
fee | number | StdFee | "auto" |
memo? | string |
Returns
Promise
<MigrateResult
>
Inherited from
SigningCosmWasmClient.migrate
Defined in
node_modules/@cosmjs/cosmwasm-stargate/build/signingcosmwasmclient.d.ts:140
queryContractRaw
▸ queryContractRaw(address
, key
): Promise
<null
| Uint8Array
>
Returns the data at the key if present (raw contract dependent storage data) or null if no data at this key.
Promise is rejected when contract does not exist.
Parameters
Name | Type |
---|---|
address | string |
key | Uint8Array |
Returns
Promise
<null
| Uint8Array
>
Inherited from
SigningCosmWasmClient.queryContractRaw
Defined in
node_modules/@cosmjs/cosmwasm-stargate/build/cosmwasmclient.d.ts:130
queryContractSmart
▸ queryContractSmart(address
, queryMsg
): Promise
<any
>
Makes a smart query on the contract, returns the parsed JSON document.
Promise is rejected when contract does not exist. Promise is rejected for invalid query format. Promise is rejected for invalid response format.
Parameters
Name | Type |
---|---|
address | string |
queryMsg | any |
Returns
Promise
<any
>
Inherited from
SigningCosmWasmClient.queryContractSmart
Defined in
node_modules/@cosmjs/cosmwasm-stargate/build/cosmwasmclient.d.ts:138
searchTx
▸ searchTx(query
): Promise
<IndexedTx
[]>
Parameters
Name | Type |
---|---|
query | SearchTxQuery |
Returns
Promise
<IndexedTx
[]>
Inherited from
SigningCosmWasmClient.searchTx
Defined in
node_modules/@cosmjs/cosmwasm-stargate/build/cosmwasmclient.d.ts:70
sendIbcTokens
▸ sendIbcTokens(senderAddress
, recipientAddress
, transferAmount
, sourcePort
, sourceChannel
, timeoutHeight
, timeoutTimestamp
, fee
, memo?
): Promise
<DeliverTxResponse
>
This has been re-implemented to support backward compatibility with the SigningStargateClient type.
Parameters
Name | Type | Default value | Description |
---|---|---|---|
senderAddress | string | undefined | - |
recipientAddress | string | undefined | - |
transferAmount | Coin | undefined | - |
sourcePort | string | undefined | - |
sourceChannel | string | undefined | - |
timeoutHeight | undefined | Height | undefined | - |
timeoutTimestamp | undefined | number | undefined | timeout in seconds |
fee | number | StdFee | "auto" | undefined | - |
memo | string | "" | - |
Returns
Promise
<DeliverTxResponse
>
Defined in
packages/core/src/desmosclient.ts:624
sendTokens
▸ sendTokens(senderAddress
, recipientAddress
, amount
, fee
, memo?
): Promise
<DeliverTxResponse
>
Parameters
Name | Type |
---|---|
senderAddress | string |
recipientAddress | string |
amount | readonly Coin [] |
fee | number | StdFee | "auto" |
memo? | string |
Returns
Promise
<DeliverTxResponse
>
Inherited from
SigningCosmWasmClient.sendTokens
Defined in
node_modules/@cosmjs/cosmwasm-stargate/build/signingcosmwasmclient.d.ts:146
setSigner
▸ setSigner(signer
): void
Updates the signer used to sign the transaction.
Parameters
Name | Type | Description |
---|---|---|
signer | Signer | The new signer that will be used. |
Returns
void
Defined in
packages/core/src/desmosclient.ts:233
sign
▸ sign(signerAddress
, messages
, fee
, memo?
, explicitSignerData?
): Promise
<TxRaw
>
Signs a transaction using the provided data.
Note that an error will be thrown if the signer is not set (i.e. the client has been built
without using the withSigner
builder).
The sign mode (SIGN_MODE_DIRECT or SIGN_MODE_LEGACY_AMINO_JSON) is determined by this client's signer.
You can pass signer data (account number, sequence and chain id) explicitly instead of querying them from the chain. This is needed when signing for a multisig account, but it also allows for offline signing (See the SigningStargateClient.offline constructor).
NOTE: It's recommend to use the signTx method instead of this.Parameters
Name | Type |
---|---|
signerAddress | string |
messages | readonly EncodeObject [] |
fee | StdFee | "auto" |
memo? | string |
explicitSignerData? | SignerData |
Returns
Promise
<TxRaw
>
Overrides
SigningCosmWasmClient.sign
Defined in
packages/core/src/desmosclient.ts:309
signAndBroadcast
▸ signAndBroadcast(signerAddress
, messages
, fee
, memo?
): Promise
<DeliverTxResponse
>
Parameters
Name | Type |
---|---|
signerAddress | string |
messages | readonly EncodeObject [] |
fee | number | StdFee | "auto" |
memo? | string |
Returns
Promise
<DeliverTxResponse
>
Overrides
SigningCosmWasmClient.signAndBroadcast
Defined in
packages/core/src/desmosclient.ts:159
signAndBroadcastSync
▸ signAndBroadcastSync(signerAddress
, messages
, fee
, memo?
): Promise
<string
>
Creates a transaction with the given messages, fee and memo. Then signs and broadcasts the transaction.
This method is useful if you want to send a transaction in broadcast, without waiting for it to be placed inside a block, because for example I would like to receive the hash to later track the transaction with another tool.
Parameters
Name | Type | Description |
---|---|---|
signerAddress | string | The address that will sign transactions using this instance. The signer must be able to sign with this address. |
messages | readonly EncodeObject [] | |
fee | number | StdFee | "auto" | |
memo? | string |
Returns
Promise
<string
>
Returns the hash of the transaction
Inherited from
SigningCosmWasmClient.signAndBroadcastSync
Defined in
node_modules/@cosmjs/cosmwasm-stargate/build/signingcosmwasmclient.d.ts:173
signTx
▸ signTx(signerAddress
, messages
, options?
): Promise
<SignatureResult
>
Signs a transaction using the provided data.
Note that an error will be thrown if the signer is not set (i.e. the client has been built
without using the withSigner
builder).
The sign mode (SIGN_MODE_DIRECT or SIGN_MODE_LEGACY_AMINO_JSON) is determined by this client's signer.
You can pass signer data (account number, sequence and chain id) explicitly instead of querying them from the chain. This is needed when signing for a multisig account, but it also allows for offline signing (See the SigningStargateClient.offline constructor).
Parameters
Name | Type |
---|---|
signerAddress | string |
messages | readonly EncodeObject [] |
options? | SignTxOptions |
Returns
Promise
<SignatureResult
>
Defined in
packages/core/src/desmosclient.ts:351
signTxAmino
▸ signTxAmino(signerAddress
, messages
, fee
, memo
, «destructured»
, feeGranter?
): Promise
<SignatureResult
>
Parameters
Name | Type |
---|---|
signerAddress | string |
messages | readonly EncodeObject [] |
fee | StdFee |
memo | undefined | string |
«destructured» | SignerData |
feeGranter? | string |
Returns
Promise
<SignatureResult
>
Defined in
packages/core/src/desmosclient.ts:487
signTxDirect
▸ signTxDirect(signerAddress
, messages
, fee
, memo
, «destructured»
, feeGranter?
): Promise
<SignatureResult
>
Parameters
Name | Type |
---|---|
signerAddress | string |
messages | readonly EncodeObject [] |
fee | StdFee |
memo | undefined | string |
«destructured» | SignerData |
feeGranter? | string |
Returns
Promise
<SignatureResult
>
Defined in
packages/core/src/desmosclient.ts:559
simulate
▸ simulate(signerAddress
, messages
, memo
): Promise
<number
>
Parameters
Name | Type |
---|---|
signerAddress | string |
messages | readonly EncodeObject [] |
memo | undefined | string |
Returns
Promise
<number
>
Inherited from
SigningCosmWasmClient.simulate
Defined in
node_modules/@cosmjs/cosmwasm-stargate/build/signingcosmwasmclient.d.ts:133
undelegateTokens
▸ undelegateTokens(delegatorAddress
, validatorAddress
, amount
, fee
, memo?
): Promise
<DeliverTxResponse
>
Parameters
Name | Type |
---|---|
delegatorAddress | string |
validatorAddress | string |
amount | Coin |
fee | number | StdFee | "auto" |
memo? | string |
Returns
Promise
<DeliverTxResponse
>
Inherited from
SigningCosmWasmClient.undelegateTokens
Defined in
node_modules/@cosmjs/cosmwasm-stargate/build/signingcosmwasmclient.d.ts:148
updateAdmin
▸ updateAdmin(senderAddress
, contractAddress
, newAdmin
, fee
, memo?
): Promise
<ChangeAdminResult
>
Parameters
Name | Type |
---|---|
senderAddress | string |
contractAddress | string |
newAdmin | string |
fee | number | StdFee | "auto" |
memo? | string |
Returns
Promise
<ChangeAdminResult
>
Inherited from
SigningCosmWasmClient.updateAdmin
Defined in
node_modules/@cosmjs/cosmwasm-stargate/build/signingcosmwasmclient.d.ts:138
upload
▸ upload(senderAddress
, wasmCode
, fee
, memo?
, instantiatePermission?
): Promise
<UploadResult
>
Uploads code and returns a receipt, including the code ID
Parameters
Name | Type |
---|---|
senderAddress | string |
wasmCode | Uint8Array |
fee | number | StdFee | "auto" |
memo? | string |
instantiatePermission? | AccessConfig |
Returns
Promise
<UploadResult
>
Inherited from
SigningCosmWasmClient.upload
Defined in
node_modules/@cosmjs/cosmwasm-stargate/build/signingcosmwasmclient.d.ts:135
withdrawRewards
▸ withdrawRewards(delegatorAddress
, validatorAddress
, fee
, memo?
): Promise
<DeliverTxResponse
>
Parameters
Name | Type |
---|---|
delegatorAddress | string |
validatorAddress | string |
fee | number | StdFee | "auto" |
memo? | string |
Returns
Promise
<DeliverTxResponse
>
Inherited from
SigningCosmWasmClient.withdrawRewards
Defined in
node_modules/@cosmjs/cosmwasm-stargate/build/signingcosmwasmclient.d.ts:149
connect
▸ connect(endpoint
, options?
): Promise
<DesmosClient
>
Parameters
Name | Type |
---|---|
endpoint | string |
options | Options |
Returns
Promise
<DesmosClient
>
Overrides
SigningCosmWasmClient.connect
Defined in
packages/core/src/desmosclient.ts:142
connectWithSigner
▸ connectWithSigner(endpoint
, signer
, options?
): Promise
<DesmosClient
>
Parameters
Name | Type |
---|---|
endpoint | string |
signer | Signer |
options | Options |
Returns
Promise
<DesmosClient
>
Overrides
SigningCosmWasmClient.connectWithSigner
Defined in
packages/core/src/desmosclient.ts:150
create
▸ create(tmClient
): Promise
<CosmWasmClient
>
Creates an instance from a manually created Tendermint client.
Use this to use Tendermint37Client
instead of Tendermint34Client
.
Parameters
Name | Type |
---|---|
tmClient | TendermintClient |
Returns
Promise
<CosmWasmClient
>
Inherited from
SigningCosmWasmClient.create
Defined in
node_modules/@cosmjs/cosmwasm-stargate/build/cosmwasmclient.d.ts:57
createWithSigner
▸ createWithSigner(tmClient
, signer
, options?
): Promise
<SigningCosmWasmClient
>
Creates an instance from a manually created Tendermint client.
Use this to use Tendermint37Client
instead of Tendermint34Client
.
Parameters
Name | Type |
---|---|
tmClient | TendermintClient |
signer | OfflineSigner |
options? | SigningCosmWasmClientOptions |
Returns
Promise
<SigningCosmWasmClient
>
Inherited from
SigningCosmWasmClient.createWithSigner
Defined in
node_modules/@cosmjs/cosmwasm-stargate/build/signingcosmwasmclient.d.ts:121
offline
▸ offline(signer
, options?
): Promise
<DesmosClient
>
Creates a client in offline mode.
When you try to use online functionality with such client, an exception will be raised.
Parameters
Name | Type |
---|---|
signer | Signer |
options | Options |
Returns
Promise
<DesmosClient
>
Overrides
SigningCosmWasmClient.offline