I am making a steam trade bot and I need to know what items get traded to me so I can store them into a database. The bot is using node-steam and node-steam-tradeoffers. The bot is currently operational and successfully makes trades.
on a succeful trade this is the code that runs:
var items = offer.items_to_receive;
offers.acceptOffer({tradeOfferId: offer.tradeofferid});
logger.info("A Trade has been accepted: " + offer.steamid_other);
// prints out all the items received
for (i = 0; i < items.length; i++){
logger.info("Items recieved: " + items[i]);
}
The problem is the output: http://prntscr.com/6jksqw
I have been looking at the steam dev site: https://developer.valvesoftware.com/wiki/Steam_Web_API/IEconService
I am using the property items_to_receive which is an array of CEcon_Asset. The problem is I don't know how to access the items in the array.
Thanks in advance for your time and help!