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: Pull Data from KuCoin to Sheets

The easiest way to get started with the Kucoin API is through API Connector’s built-in integration.

  1. In Sheets, open API Connector and create a new request (Extensions > API Connector > Open > Create request)
  2. Select Kucoin from the drop-down list of applications
    kucoin-application
  3. Select an endpoint.  These endpoints are all open so you don’t need an API key. For this example we’ll choose the /market/allTickers endpoint.
    kucoin-endpoints
  4. Choose a destination sheet, name your request, and hit Run.
    kucoin-response

Part 2: Create a Custom Request

Alternatively, you can run a custom request instead of using API Connector’s built-in integration, using any of the endpoints and parameters shown in the API documentation. Here is an example setup:

  • Application: Custom
  • Request methodGET
  • Request URLhttps://api.kucoin.com/api/v1/market/allTickers
kucoin-results

To easily convert your preset request to a custom request, click Output Options > More Options > Add Request URL before you run your request. This will print your request URL into your sheet so you can copy and paste it.

Part 3: Get Private KuCoin Account Data

The above endpoints deal with public market data from the KuCoin API.

If you are instead a KuCoin customer looking to get API data from your own account, they require a more complex authentication process that includes generating a “signature”.

To access your private account data, please copy this sheet and follow the instructions within.

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:

  • 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

10 thoughts on “Import KuCoin Data to Google Sheets”

    • Kucoin requires that you apply a "signature" as shown here. It looks pretty similar to what Binance requires, so the Binance sheet probably just requires some minor modification to work with KuCoin, but I haven't tried it myself so can't say for sure.

      Reply
      • I am trying, but can't get it to work..
        Would you be able to help me out?
        I can share what I have currently.

      • I already fixed it and it seems to work. Let me know if you would like to have it as well, so you could add it to your website.

      • Hey Sander, thanks, I'd love to see your sheet or learn more about how you modified the Binance sheet. (I don't have my own Kucoin account, so I couldn't modify and test it myself). If it works, I'll update the article to include instructions.

      • Hey Synt, Sander kindly shared his modified sheet with us, I've added it to the article here. Please check if that works for you.

  1. how to import all historical trades from Kucoin to Google Sheets?
    I was able to get only last trades using your template from Part 3

    Reply

Leave a Reply to Synt Cancel reply

Jump To