Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up

👥 Custom node-steam handler which provides group functions

License

NotificationsYou must be signed in to change notification settings

scholtzm/node-steam-groups

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

20 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

NPM versionDependency Status

This is a tiny node.js module which provides customnode-steam handler for group functions.

Installation

npm install steam-groups

Usage

Firstly, requiresteam as well assteam-groups module ...

varSteam=require('steam');varSteamGroups=require('steam-groups');

After that, instantiate SteamGroups by providing the Steam client instance as a constructor parameter...

varclient=newSteam.SteamClient();varsteamGroups=newSteamGroups(client);

That's it. You can now use additional group functions.

Methods

inviteUserToGroup(steamIdGroup, steamIdInvited)

Invite usersteamIdInvited to groupsteamIdGroup.steamIdGroup has to be ingroupID64 format.

Example ofgroupID64 can be foundhere.

acknowledgeGroupInvite(steamIdGroup, response)

Accept or decline an invite to join groupsteamIdGroup.response is aboolean value.

This can be used in conjunction withnode-steam'sgroup event.

Example

// Require steam and steam-groups firstvarSteam=require('steam');varSteamGroups=require('steam-groups');// Create new SteamClient object and pass it as a constructor paramvarclient=newSteam.SteamClient();varsteamFriends=newSteam.SteamFriends(client);varsteamGroups=newSteamGroups(client);// Connect to Steam network and add additional code here ...// Decline any incoming group invitesteamFriends.on('group',function(group,relationship){if(relationship===Steam.EClanRelationship.Invited){steamGroups.acknowledgeGroupInvite(group,false);}});// Invite anyone who messages us to a groupsteamFriends.on('friendMsg',function(user,message,type){if(type===Steam.EChatEntryType.ChatMsg){steamGroups.inviteUserToGroup('1234567890',user);}});

Disclaimer

node-steam is port ofSteamKit2, which does not support group functions. Automating group functionalities might be against Steam's EULA. There are many people who run trading bots and automate this process, but remember that you are using this at your own risk.

License

MIT. SeeLICENSE.

About

👥 Custom node-steam handler which provides group functions

Topics

Resources

License

Stars

Watchers

Forks

Packages

No packages published

[8]ページ先頭

©2009-2025 Movatter.jp