CryptoExcel

Crypto Excel » Docs_functions Fetch Convert Trh

Function Convert TRH

Convert any coins to fiat currency at specific intervals using a chosen exchange’s latest prices (with throttling)

function convert trh
Function Convert Trh
func convert trh
Function Convert TRH

1. Syntax

=ST_convert_trh ( from_coin, to_coin, [exchange], [trh_sec])

2. Parameters

 

ParameterRequiredDescriptionExample
from_coinYCoin you want to convert. Can be a range ( multiple coins)“ATOM”,”BTC”
to_coinYfiat currency“USD”
Exchange*N Default BinanceExchange you want to use for the conversion“Bitmex”
trh_sec
N Default 300. min 120Seconds interval between consecutive calls120

*you can choose any exchange amongst the supported one which has the from_coin and to_coin listed

from_coin

Required: Y

Description: Coin you want to convert. Can be a range ( multiple coins)

Example: “ATOM”, “BTC”

to_coin

Required: Y

Description: fiat currency

Example: “USD”

exchange

Required: N. def “Binance”

Description: Exchange you want to use for the conversion

Example: “bitmex”

You can choose any exchange amongst the supported one which has the from_coin and to_coin listed

trh_sec

Required: N. def 500. Min 120

Description: seconds interval between consecutive calls

Example: 120

3. Return Value

ValueDescription
Timetime of the conversion
RateConversion rate

Time

time of the conversion

Rate

conversion rate

4. Rate limits

This function send 1 request to the exchange even if you want to convert multiple coins at once

Tip. Use st_watch_requests() to monitor your requests.

5. Usage

The Convert trh function returns the Time and the conversion rate for one or multiple coins to the desired fiat. You can specify the Exchange that will be used for the conversion. Prices are refreshed automatically at defined intervals. (trh_sec). Both from and to coins must be listed on the specified exchange This function does not require Authentication

6. Convert related functions