Answer the question
In order to leave comments, you need to log in
How to get the desired element with json after sending a get request?
import json
import requests
pair = 'BTC/UAH'
side = 'baying'
response = requests.get('https://richamster.com/public/v1/exchange/order-book',
params= { 'pair' : pair,
'side' : side,
}
)
data = response.json()
print (data)
Answer the question
In order to leave comments, you need to log in
The server response contains purchase requests with keys - the price "unit_price" and the purchase amount "sum", you need to find out what the price "unit_price" will be if the sum "sum" becomes more equal to, for example, 1000, while you need to filter by additional parameters - by one of the pairs ,'BTC/UAH','ETH/UAH'..... and by type 'baying' or 'selling'.
Of course I would like the code in python.
Thank you FRIENDS)))
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question