Skip to content

Commit 7b87a79

Browse files
authored
Merge pull request #8 from tbass134/ml_predictions
added predictions endpoint
2 parents d091f6f + 925ee57 commit 7b87a79

1 file changed

Lines changed: 15 additions & 1 deletion

File tree

shrimpy/shrimpy_api_client.py

Lines changed: 15 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -354,7 +354,21 @@ def run_backtest(self, exchange, rebalance_period, fee, start_time, end_time,
354354
}
355355
return self._call_endpoint('POST', endpoint, data=data)
356356

357-
357+
## Predictions
358+
359+
def get_predictions(self, exchange, base_trading_symbol, quote_trading_symbol):
360+
endpoint = 'analytics/predict'
361+
params = {
362+
'exchange':exchange,
363+
'baseTradingSymbol': base_trading_symbol,
364+
'quoteTradingSymbol': quote_trading_symbol
365+
}
366+
query_string = self._create_query_string(
367+
endpoint,
368+
params
369+
)
370+
return self._call_endpoint('GET', query_string)
371+
358372
## Insights
359373

360374
def get_asset_dominance(self):

0 commit comments

Comments
 (0)