SecretNET.Token Namespace

Snip20Querier..::..GetExchangeRate Method

Gets information about the token exchange rate functionality that the contract provides (This query need not be authenticated). This query MUST return. - exchange rate, as an integer string. The amount of native coins that equal one token. - Denomination of native tokens which are acceptable, as a string OR a comma separated value.

Namespace:  SecretNET.Token
Assembly:  SecretNET.Token (in SecretNET.Token.dll)

Syntax


public Task<SecretQueryContractResult<GetExchangeRateResponse>> GetExchangeRate(
	string contractAddress,
	Nullable<string> codeHash
)
Public Function GetExchangeRate ( _
	contractAddress As String, _
	codeHash As Nullable(Of String) _
) As Task(Of SecretQueryContractResult(Of GetExchangeRateResponse))
public:
Task<SecretQueryContractResult<GetExchangeRateResponse^>^>^ GetExchangeRate(
	String^ contractAddress, 
	Nullable<String^> codeHash
)

Parameters

contractAddress
Type: String
The contract address.
codeHash
Type: Nullable<(Of <(<'String>)>)>
CodeHash is (not really) optional and makes a call way faster.

Return Value

SecretQueryContractResult<GetExchangeRateResponse>.