From now on we're going towards trading features for our application.
Step 1, is that each user have a wallet for all the coins (e.g. BTC, ETH, SHIB) and fiat (e.g. USDT).
Wallets are basically models that have following fields:
user
coin
unit
As you can see user and coin field have relationships with our two other models User and Coin.
Let's do step 1 and we'll continue with others steps.
We also need these two endpoint
api/wallets/ [GET] return a list of all assets owned by user including the USDT wallet. Bonus: Also return their approximated value in USDT.
api/wallets/<symbol>/ [GET] Same as above only for requested coin.
From now on we're going towards trading features for our application. Step 1, is that each user have a wallet for all the coins (e.g. BTC, ETH, SHIB) and fiat (e.g. USDT). Wallets are basically models that have following fields:
As you can see user and coin field have relationships with our two other models User and Coin. Let's do step 1 and we'll continue with others steps.
We also need these two endpoint
api/wallets/ [GET]
return a list of all assets owned by user including the USDT wallet. Bonus: Also return their approximated value in USDT.api/wallets/<symbol>/ [GET]
Same as above only for requested coin.