Search API Connector Documentation

Print

Import KuCoin Data to Google Sheets

In this guide, we’ll walk through how to pull data from the KuCoin API directly into Google Sheets, using the API Connector add-on for Sheets.

For this guide, we’ll be using their open market endpoints so we don’t need any API keys or other authorization. Let’s jump right in!

Contents

Before You Begin

Click here to install the API Connector add-on from the Google Marketplace.

Part 1: Create Your API Request URL

For our first request, we’ll get current data for all the trading pairs in the market .

  • API Base URL: https://api.kucoin.com
  • Endpoint: /api/v1/market/allTickers

Putting it together, we get the full API Request URL:

https://api.kucoin.com/api/v1/market/allTickers

Part 2: Pull KuCoin Data into Google Sheets

We can now enter that URL into API Connector.

  1. Open up Google Sheets and click Extensions > API Connector > Open.
  2. In the Create screen, enter the Request URL we just created
    kucoin-url
  3. We don’t need OAuth authentication so just leave that set to None. We don’t need to enter any headers either so just skip that section.
  4. Create a new tab and click Set current to use that tab as your data destination.
  5. Name your request and click Run. A minute or two later you’ll see a list of trading pairs and related stats populate your sheet:
    kucoin-results


Part 3: More Example API Requests

You can check the documentation for the full set of endpoints and parameters, but if you just want to check it out, try the following examples:

  • Get a list of symbols
    https://api.kucoin.com/api/v1/symbols
  • Get a specific trading pair
    https://api.kucoin.com/api/v1/market/orderbook/level1?symbol=BTC-USDT
  • Get 24 hr stats
    https://api.kucoin.com/api/v1/market/stats?symbol=BTC-USDT

Part 4: Handle Pagination

Note that the Kucoin API limits the number of records returned in each request. By default, only 100 records will be returned unless you use the currentPage parameter as shown in their documentation.

With API Connector, you can set up pagination handling to cycle through pages automatically, like this:

  • API URL: enter your request URL
  • Pagination: page parameter
  • Page parameter: currentPage
  • Run until: choose when to stop fetching data
    kucoin-pagination-currentpage

Part 5: API Documentation

Official API documentation: https://docs.kucoin.com/#market-data

Previous Import Kraken Data to Google Sheets
Next Import LinkedIn Ads Data to Google Sheets

Leave a Comment

Table of Contents