Jump to content
McKay Development

Recommended Posts

Posted

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.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...