API | SPOT | AGIX to FET

Hello,

After AGIX migrate to FET, how can I get the transaction that result on this change?

Using API i have the AGIX transactions (trades) but I don’t have my FET tokens, but if I check directly on binance application I don’t have the AGIX anymore (because it migrate to FET). How can I handle this via API?

Anyone in the same situation?

Thanks!

Query AGIX trading pairs for old orders and FET pairs for new orders.

There is no special support for token splits and merges in the API. New tokens get new trading pairs, while the old trading pairs remain denominated in the old tokens.

Back when the merge happened, if you had any open orders with AGIX base asset, those should have been canceled. Your remaining AGIX balance should have been swapped for FET.

You should be able to get the details of the swap via transaction history.

Hii, thanks for the reply!

I have my trades AGIX and my trades FET (that it’s ok).

The problem is: if I sum the quantities from my AGIX I still holding a quantity from this token (via API) but in reality I don’t have any quantity of AGIX (and it’s okay), where can I get the difference via API?

I trying to avoid the Binance transaction history, because I’m building a binance connector (only using API).

In this screenshot you can see the calculated balance (is the sum of que quantities from all the trades that I receive from binance endpoint /api/v3/myTrades) and the reported balance (it’s the balance from endpoint /api/v3/account).

You can see that it’s ok from token FET but it’s wrong for the token AGIX, that indicates that maybe I missing some transaction but I can’t find it (it only happens to this token that has been merged).

That’s my main problem :frowning: .

Thanks!

Basically how can I find the “Your remaining AGIX balance should have been swapped for FET”? Do you know the endpoint that handle this?

Thanks!

I get this information from the endpoint /sapi/v1/asset/assetDividend:

But it only indicates the token that I receive, it does not indicate the token that I “swap” to receive the FET, in this case the AGIX.

Wallet API support for token redenominations/splits/merges is rather poor :sob:

/sapi/v1/asset/assetDividend happens to report the credited new asset, but there is sadly no API endpoint that would report the old asset debit that happens as a part of token migration. At least, as far as I know.

Transaction history requested on the website does report a negative “distribution” of the old token and positive “distribution” of the new one. However, its not easily programmable (i.e., you need to automate clicking buttons on a webpage).

The exchange rate was 1 AGIX ⇒ 0.43335 FET (Fetch.ai (FET), Ocean Protocol (OCEAN) and SingularityNET (AGIX) Token Merge) which matches your values:

  • 877.122 AGIX × 0.43335 = 380.1008187 FET

But sadly, no API :frowning:

Until API support for this use case improves, I’m afraid you’d need to track token migrations manually.

Thanks for the feedback!

It’s a really handle this manually **** :slight_smile: