class MediaWiktory::Wikipedia::Actions::Login
Log in and get authentication cookies.
Usage:
“`ruby api.login.name(value).perform # returns string with raw output # or api.login.name(value).response # returns output parsed and wrapped into Response
object “`
See {Base} for generic explanation of working with MediaWiki actions and {MediaWiktory::Wikipedia::Response} for working with action responses.
All action's parameters are documented as its public methods, see below.
Public Instance Methods
domain(value)
click to toggle source
Domain (optional).
@param value [String] @return [self]
# File lib/mediawiktory/wikipedia/actions/login.rb, line 42 def domain(value) merge(lgdomain: value.to_s) end
name(value)
click to toggle source
User name.
@param value [String] @return [self]
# File lib/mediawiktory/wikipedia/actions/login.rb, line 26 def name(value) merge(lgname: value.to_s) end
password(value)
click to toggle source
Password.
@param value [String] @return [self]
# File lib/mediawiktory/wikipedia/actions/login.rb, line 34 def password(value) merge(lgpassword: value.to_s) end
token(value)
click to toggle source
A “login” token retrieved from action=query&meta=tokens
@param value [String] @return [self]
# File lib/mediawiktory/wikipedia/actions/login.rb, line 50 def token(value) merge(lgtoken: value.to_s) end