Jump to content
McKay Development

.Coder

Member
  • Posts

    1
  • Joined

  • Last visited

Posts posted by .Coder

  1. Hi, so I want to make a bot that will send trade offers with specific items already selected on my website to a user. So the bot will ask for that user items bot will not give any from own inventory.

     

    I guess I have to do something with this code but I have not idea what.

    var offer = manager.createOffer("https://steamcommunity.com/tradeoffer/new/?partner=157268861&token=N_0bQbD4");
    offer.addMyItems(inventory);
    offer.setMessage("Here, have some items!");
    offer.send(function(err, status) {
    	if (err) {
    		console.log(err);
    		return;
    	}
    
    	if (status == 'pending') {
    		// We need to confirm it
    		console.log(`Offer #${offer.id} sent, but requires confirmation`);
    		community.acceptConfirmationForObject("identitySecret", offer.id, function(err) {
    		if (err) {
    			console.log(err);
    		} else {
    			console.log("Offer confirmed");
    		}
    	});
    	} else {
    		console.log(`Offer #${offer.id} sent successfully`);
    	}
    });
    

    So this code, send items from "our" / bot inventory, but I need to send a trade offer with items from a specific user from steam and then he has to accept it.

×
×
  • Create New...