Skip to content

Instantly share code, notes, and snippets.

@cornfeedhobo
Last active August 29, 2015 14:18
Show Gist options
  • Save cornfeedhobo/1cf0f915a996c91ea00d to your computer and use it in GitHub Desktop.
Save cornfeedhobo/1cf0f915a996c91ea00d to your computer and use it in GitHub Desktop.
Polo XMR 24hr summary
#!/usr/bin/env python
import requests
from datetime import timedelta
from datetime import datetime
payload = {
'command': 'returnChartData',
'currencyPair': 'BTC_XMR',
'start': ((datetime.now() - timedelta(days=1)) - datetime(1970,1,1)).total_seconds(),
'end': 9999999999,
'period': 86400
}
r = requests.get('https://poloniex.com/public', params=payload)
print(r.text)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment