How to leverage both exchange files and API to load trade history

If you already have trade history on your ledger which you uploaded using the exchange files, there is a way to retain this trade history and switch to using the API for any NEW trades that take place after the last upload time. This feature was released on Nov. 29, 2021.

In this article, we will explain how to use this new feature in different scenarios.


Scenario 1

For Binance SPOT trades, you already have trade history on your ledger which you uploaded using the exchange files. For any NEW trades going forward, you want to use the API instead.


* Even if you change your mind and decide that you want to fetch ALL trade history using the API, if trade history from the exchange files existed on your ledger when you established the API connection, the API sync would only fetch trades that happened AFTER the displayed timestamp. You need to first delete the API connection and re-establish it. You can use the same API key and secret for this.


How to handle this scenario

When establishing the Binance API connection, please take note of the timestamp displayed. This is the timestamp of the last SPOT trade that was uploaded using the exchange files. In the below example, you have transactions up to 15:55:01 on April 27, 2021 on your ledger via the file upload.

The new API will fetch any transactions that happened after the displayed timestamp. If you are okay with this, tick the "Binance/現物注文トレード履歴(Binance/SPOT trade history)" checkbox.


Scenario 2

You've been uploading Binance trade history via the exchange files, but you are worried that you may be missing some trades. For the current fiscal year, you don't want to use the trade history from the exchange files and use the API instead to fetch all trades.


How to handle this scenario

Assuming that the current fiscal year is 2021, you need to delete the Binance trade history for 2021.


* How to delete Binance trade history

  1. Click the Trash icon to the left of "Add Transactions".
  2. From the source list select all Binance trade types, select 2021 as the fiscal year, and click "Delete Selected".



After deleting the trade history for 2021, establish the API connection. Please check that the timestamp displayed is before 2021.


Scenario 3

For the trade history that you have previously uploaded using custom files, you want to get them from the exchange using the API instead. For example, you previously uploaded convert history using custom files but want to get them via the API instead.


How to handle this scenario

Cryptact cannot link the trades uploaded using custom files to the trades fetched via the API. When you establish the API connection, you will end up with duplicate trades.

After establishing the API connection, if you end up having duplicate trades on your ledger, please delete the necessary trade history.

For details on how to delete trade history, please refer to here.