Sha256: 67bcb4ce9007bbb708da14f55b77157f85d90d78dcb10e1dafa959eebff9a3a4
Contents?: true
Size: 786 Bytes
Versions: 1
Compression:
Stored size: 786 Bytes
Contents
module OnlinegamesInfoConnect module OauthGuild def create_guild(guild, user) return user.token.post("/api/guilds", {body: {name: guild.name, tag: guild.tag, user_id: user.ogi_uid, char_id: user.char_id}}).parsed end def remove_guild(guild, user) return user.token.post("/api/guilds/remove", {body: {guild_id: guild.ogi_alliance_id}}).parsed end def add_user(guild, user, new_member) return user.token.post("/api/guilds/add_user", {body: {guild_id: guild.ogi_alliance_id, user_id: new_member.ogi_uid, char_id: new_member.char_id}}).parsed end def remove_user_from_guild(guild, user, member) return user.token.post("/api/guilds/remove_user", {body: {guild_id: guild.ogi_alliance_id, user_id: member.ogi_uid, char_id: member.char_id}}).parsed end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
onlinegames_info_connect-0.0.1 | lib/onlinegames_info_connect/oauth_guild.rb |