Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Token management #10

Open
zverok opened this issue Dec 1, 2015 · 0 comments
Open

Token management #10

zverok opened this issue Dec 1, 2015 · 0 comments
Labels

Comments

@zverok
Copy link
Contributor

zverok commented Dec 1, 2015

All data-modifying actions require some dance with "tokens". It should be done transparently for user.
See https://www.mediawiki.org/wiki/API:Tokens

Note, that token management have different behavior in:

  • versions < 1.20
  • version 1.20-1.23
  • version 1.24+

See also #9 about version compatibility

NB: Current version of "manual" token management is:

token = api.query.meta(:tokens).response.dig('tokens', 'csrftoken')
response = api.edit.title('Wikipedia:Sandbox').text("Test '''me''', MediaWiktory!").token(token).response

It is, in fact, not that bad, and probably not worth over-automatization at all.

@zverok zverok modified the milestone: 0.0.2 aka MVP Dec 2, 2015
@zverok zverok added the idea label Jun 21, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant