I received the servertime from the Binance-API,I try to work with and it looks like this:
{ "serverTime": 1518440400000 } The question is, how can I compute the date out of this stamp?
I tried
import datetime print(datetime.datetime.fromtimestamp( int("1518308894652")).strftime('%Y-%m-%d %H:%M:%S')) But the date wasn´t valid.
Do you have ideas, or is it to specific? Thank you!
1518440400000is the actual timestamp you got back? If so, that would mean the server is running in the year 50087... But assuming that's just an example, most languages should have some function for this. What language are you using?