Adding games from the list to the Steam account
aVitaliy opened this issue · 11 comments
Hello!
Is there a script with which you can add games from the list to the Steam account in the wish list. Or how to create such a script?
you what to add games to a steam wish list?
Yes, I need to add games to my wish list on my account. Not to do it manually, but through a script.
For example, here with this script you can add games to your wishlist via the console. But for this you need to go to your Steam account in the browser and only then run this script.
javascript:AddToWishlist( 498700, 'add_to_wishlist_area', 'add_to_wishlist_area_success', 'add_to_wishlist_area_fail', '1_5_9__407' ); javascript:AddToWishlist( 530860, 'add_to_wishlist_area', 'add_to_wishlist_area_success', 'add_to_wishlist_area_fail', '1_5_9__407' ); javascript:AddToWishlist( 552350, 'add_to_wishlist_area', 'add_to_wishlist_area_success', 'add_to_wishlist_area_fail', '1_5_9__407' ); javascript:AddToWishlist( 312900, 'add_to_wishlist_area', 'add_to_wishlist_area_success', 'add_to_wishlist_area_fail', '1_5_9__407' );
im not at home, but one way you can do it, with my script. Is to create a new file add the
module.exports = function(steamClient, RequestCommunity, RequestStore, SessionID, options, callback){}
to the file. and use RequestCommunity
and post to 'https://store.steampowered.com/api/addtowishlist' whit the sessionid and appid.
Eks.
var list = [730, 570, ...]; module.exports = function(steamClient, RequestCommunity, RequestStore, SessionID, options, callback){ var loop = function (index, end_callback) { if(list.length > index){ RequestCommunity.post({ url: "https://store.steampowered.com/api/addtowishlist", form:{ appid: list[index], sessionid: SessionID } }, function (postErr, postHttpResponse, postBody) { loop(++index, end_callback); }); } } loop(0, callback); }
dont know the the code work like it is, just did it on the fly.
C:\Soft\Awards.BotS.Steam\modules\wishlist.js:1
var list = [239140, 1195460, 649950, 493520, 1174180]; module.exports = function
(steamClient, RequestCommunity, RequestStore, SessionID, options, callback){ var
loop = function (index, end_callback) { if(list.length > index){ RequestCommuni
ty.post({ url: "https://store.steampowered.com/api/addtowishlist", form:{ appid:
list[index], sessionid: SessionID } }, function (postErr, postHttpResponse, pos
tBody) { loop(++index, end_callback); }); } } loop(0, callback); }
^^^^
SyntaxError: Unexpected identifier
←[90m at Module._compile (internal/modules/cjs/loader.js:892:18)←[39m
←[90m at Object.Module._extensions..js (internal/modules/cjs/loader.js:973:10
)←[39m
←[90m at Module.load (internal/modules/cjs/loader.js:812:32)←[39m
←[90m at Function.Module._load (internal/modules/cjs/loader.js:724:14)←[39m
←[90m at Module.require (internal/modules/cjs/loader.js:849:19)←[39m
←[90m at require (internal/modules/cjs/helpers.js:74:18)←[39m
at Object. (C:\Soft\Awards.BotS.Steam\main-herhung.js:17:14)
←[90m at Module._compile (internal/modules/cjs/loader.js:956:30)←[39m
←[90m at Object.Module._extensions..js (internal/modules/cjs/loader.js:973:10
)←[39m
←[90m at Module.load (internal/modules/cjs/loader.js:812:32)←[39m
module.exports = function(steamClient, RequestCommunity, RequestStore, SessionID, options, callback){
var loop = function (index, end_callback) {
if(list.length > index){
RequestCommunity.post({
url: "https://store.steampowered.com/api/addtowishlist",
form:{
appid: list[index],
sessionid: SessionID
}
}, function (postErr, postHttpResponse, postBody) {
console.log("added: " + list[index]);
loop(++index, end_callback);
});
}else{
console.log("done whit a steam user");
end_callback();
}
}
loop(0, callback);
}
Might be the
else{
end_callback();
}
the first code doent have that part.
Now the script is working. But, games are not added to the wish list on the Steam account.
var list = [239140, 1195460, 649950, 493520, 1174180];
Okay, i thing i know why, but i have to look into it later. i thing is the part where it add some cookie in the store code
I have added AddGameToWishlist.js, that shoud work. Let me know it, still doent work
Hello.
C:\Soft\Awards.BotS.Steam\modules\AddGameToWishlist.js:9
url: url,
^
ReferenceError: url is not defined
at loop (C:\Soft\Awards.BotS.Steam\modules\AddGameToWishlist.js:9:16)
at Array.module.exports (C:\Soft\Awards.BotS.Steam\modules\AddGameToWishlist
.js:25:5)
at runModules (C:\Soft\Awards.BotS.Steam\main-herhung.js:122:23)
at C:\Soft\Awards.BotS.Steam\main-herhung.js:67:17
at C:\Soft\Awards.BotS.Steam\main-herhung.js:117:3
at SteamWebLogOn. (C:\Soft\Awards.BotS.Steam\node_modules\←[4mste
am-weblogon←[24m\index.js:48:5)
at IncomingMessage. (C:\Soft\Awards.BotS.Steam\node_modules\←[4ms
team-web-api←[24m\index.js:42:9)
←[90m at IncomingMessage.emit (events.js:215:7)←[39m
←[90m at endReadableNT (_stream_readable.js:1183:12)←[39m
←[90m at processTicksAndRejections (internal/process/task_queues.js:80:21)←[39m
Does not work.
If you add url then the script works but the games are not added to the wish list.
url: "https://store.steampowered.com/api/addtowishlist",
i have made a update the worked for me, for the list you sended. I have added a wants_mature_content cookie, doent know if that was why it did not work before. OBS. the date is hardcode for the cookie, so it may be ended when you test.
Can i get you to confirm that it also work for you now?
Hello!
The new version is working. Checked on multiple accounts. The games I need are correctly added to Steam’s wish list.
Thanks!