CurrencyRateController Actions
5 actions registered.
| Name | Deprecated |
|---|---|
getState | |
setCurrentCurrency | |
startPolling | |
stopPollingByPollingToken | |
updateExchangeRate |
CurrencyRateController:getState
Package: @metamask/assets-controllers
Handler signature:
() => CurrencyRateState
CurrencyRateController:setCurrentCurrency
Package: @metamask/assets-controllers
Sets a currency to track.
Parameters:
| Name | Description |
|---|---|
currentCurrency | ISO 4217 currency code. |
Handler signature:
(currentCurrency: string) => Promise<void>
CurrencyRateController:startPolling
Package: @metamask/assets-controllers
Handler signature:
CurrencyRateController['startPolling']
CurrencyRateController:stopPollingByPollingToken
Package: @metamask/assets-controllers
Handler signature:
CurrencyRateController['stopPollingByPollingToken']
CurrencyRateController:updateExchangeRate
Package: @metamask/assets-controllers
Updates the exchange rate for the current currency and native currency pairs.
Parameters:
| Name | Description |
|---|---|
nativeCurrencies | The native currency symbols to fetch exchange rates for. |
Handler signature:
(nativeCurrencies: (string | undefined)[]) => Promise<void>