Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var (
SteamCommunityUnvavailable = errors.New("Steam community is unavailable")
)
Functions ¶
This section is empty.
Types ¶
type Credentials ¶
type Credentials struct { Password string `url:"password"` Username string `url:"username"` TwoFactorCode string `url:"twofactorcode"` EmailAuth string `url:"emailauth"` LoginFriendlyName string `url:"loginfriendlyname"` CaptchaGID int `url:"captchagid"` CaptchaText string `url:"captcha_text"` Token string `url:"-"` SteamID string `url:"-"` EmailSteamID string `url:"emailsteamid"` RSATimeStamp string `url:"rsatimestamp"` RememberLogin bool `url:"remember_login"` DoNotCache string `url:"donotcache"` }
Credentials represents a request parameters for logging in proccess
func NewCredentials ¶
func NewCredentials(username, password, steamid string) Credentials
NewCredentials creates minimum required parameters for logging in proccess
type LoginResponse ¶
type LoginResponse struct { Success bool `json:"success"` Message string `json:"message,omitempty"` RequiresTwoFactor bool `json:"requires_twofactor"` //If requires steamguard EmailAuthNeeded bool `json:"emailauth_needed,omitempty"` EmailDomain string `json:"emaildomain"` EmailSteamID string `json:"emailsteamid"` //When logged in LoginComplete bool `json:"login_complete,omitempty"` TransferURL string `json:"transfer_url,omitempty"` TransferParameters TransferParameters `json:"transfer_parameters,omitempty"` }
LoginResponse represents response after trying to log in
type Session ¶
Session holding cookies and other needed data for connecting to steam servers
func NewSession ¶
NewSession creates new Session The call itself is blocking due to cookies being set up.
func (*Session) GetSessionID ¶
GetSessionID gets session id - useful for tradeoffers and other actions
func (*Session) IsLoggedIn ¶
func (*Session) Login ¶
func (sess *Session) Login(credentials Credentials) (*LoginResponse, error)
Login logs into steam service with given credentials
Click to show internal directories.
Click to hide internal directories.