Quick buy at max price not working
I was wondering whether the bid() function is still fully functional when trying to bid the buy now price.
To illustrate: items = session.search(ctype = 'training', category = 'position', defId = resourceId, max_buy = 2000, page_size = 50, fast = True) len(items) # Returns 50
Let's extract the last item from the list, just to decrease the odds that it has already been bought session.bid(trade_id=items[-1]['id'], bid=2000, fast = True)
The session.bid() call returns False. It's highly unlikely that the item has already been bought, as the current minimum buy now price that items are listed for even falls below 1800 coins. (len(session.search(ctype = 'training', category = 'position', defId = resourceId, max_buy = 1800, page_size = 50, fast = True)) # Returns 50)
Am I overlooking something? Thanks for thinking along :)
@RoelvanDooren I think the problem is that you are trying to buy a player by his id attribute instead of tradeId.
So, you should try to change this call:
session.bid(trade_id=items[-1]['id'], bid=2000, fast = True)
to this one:
session.bid(trade_id=items[-1]['tradeId'], bid=2000, fast = True)
@SilverCorvin Oh my, how on earth could I not have noticed this.. Thanks!