Skip to content

New Module Info

Lasse Støjier Pedersen edited this page Feb 3, 2020 · 2 revisions

module

when creating a new module, all you have to add to a file is:

module.exports = function(steamClient, RequestCommunity, RequestStore, SessionID, options, callback){
// add your code here
});

now you can do the requist you what.

Parameters

here you can see what each do.

steamClient

this is SteamClient of the npm module 'steam' npm steam can be used to start a game, get steamid, and more

RequestCommunity

this is a Request obj, of the npm module npm request, but it have all the cookies add for the steam store url, for the active account. if you need to make a request for the steam store domain use this. that way you will get the html dome as if you was login and did see the pake for you self.

RequestStore

this is the same as the RequestCommunity. but the cookies for the community domaine insted

SessionID

this is a string of the web session. this is almost allway need when senden form to steam.

options

is a object that have :

  • Index: the active index of the account in config.js
  • UserName: the sign in user name
  • steamUser: is a instance of npm steam user for the active account
  • steamFriends: is a instance of npm steam friends for the active account
  • accountPretty: is a string that prints '{steamid} - {loginUserName}:'

callback

when the module is all done, just call this, and it will go to the next module, or account

Clone this wiki locally