Ferriar_幽助 Posted September 22, 2017 Report Share Posted September 22, 2017 Hi all, i need your help. i can't get the token when i want to send others a offer. which method i need to use. thanks a lot. var offer = manager.createOffer(offSteamID);var accountid = offer.partner.accountid;console.log(accountid); Quote Link to comment Share on other sites More sharing options...
Dr. McKay Posted September 22, 2017 Report Share Posted September 22, 2017 You should collect the token by asking the user for their trade URL. Quote Link to comment Share on other sites More sharing options...
Ferriar_幽助 Posted September 25, 2017 Author Report Share Posted September 25, 2017 You should collect the token by asking the user for their trade URL.i realized the most web if we want send the offer, the user's offerurl is provided by themself, i just want get the token parameter. Is there any way to get it? Quote Link to comment Share on other sites More sharing options...
Dr. McKay Posted September 25, 2017 Report Share Posted September 25, 2017 You want to parse the URL? https://nodejs.org/api/url.html Quote Link to comment Share on other sites More sharing options...
Andrei Elvis Posted September 27, 2017 Report Share Posted September 27, 2017 To get just the token from a tradeurl you can use this example: var tradelink = 'https://steamcommunity.com/tradeoffer/new/?partner=6969696969&token=testtest123'; var token = tradelink.split('token=')[1]; console.log(token); //OUTPUT: testtest123 Vanilla 1 Quote Link to comment Share on other sites More sharing options...
BlackieWitch Posted March 28 Report Share Posted March 28 Hey, i know that this a really old post, but i was wondering if there a way to find the token without knowing the other person nor it being public, so not just asking them for it. If yes, i'd be very thankful to know it! Quote Link to comment Share on other sites More sharing options...
Dr. McKay Posted March 29 Report Share Posted March 29 No. That would defeat the purpose of the token. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
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.