Skip to contents

Retrieves the list of all available trading markets from the KuCoin API asynchronously.

Usage

get_market_list_impl(
  base_url = get_base_url(),
  .__coro_env_parent__ = <environment>
)

Arguments

base_url

Character string; base URL for the KuCoin API. Defaults to get_base_url().

Value

Promise resolving to a character vector of trading market identifiers (e.g., "USDS", "TON").

Details

Workflow Overview

  1. URL Assembly: Combines base_url with /api/v1/markets.

  2. HTTP Request: Sends a GET request with a 10-second timeout via httr::GET().

  3. Response Processing: Validates the response with process_kucoin_response() and extracts the "data" field as a character vector.

API Endpoint

GET https://api.kucoin.com/api/v1/markets

Usage

Utilised to identify available trading markets on KuCoin for filtering or querying market-specific data.

Official Documentation

KuCoin Get Market List

Examples

if (FALSE) { # \dontrun{
main_async <- coro::async(function() {
  markets <- await(get_market_list_impl())
  print(markets)
})
main_async()
while (!later::loop_empty()) later::run_now()
} # }