Manual:Pywikibot/PAWS

This document provides a quick interactive overview of Pywikibot using a 'notebook' hosted on the Wikimedia Foundation labs environment using 'PAWS' (Pywikibot: A Web Shell).

Create a Wikimedia account
To follow this walk-through, you only need an account on a Wikimedia project.

To create a Wikimedia account, see Help:Logging in. (Avoid special characters until T120066 is fixed.)

Sign into a notebook
To start a hosted notebook, go to https://tools.wmflabs.org/paws

Click "Sign in with MediaWiki", and then click "Allow" when asked to approve "Use OAuth for Authentication".

The first time you access PAWS, you need to create a server.

Once that is completed, you will be redirected to a URL like https://tools.wmflabs.org/paws/user/ /tree

To start a new interactive terminal, click 'New' on the right hand side, and then 'Terminal'.

You should now have a unix '$' prompt.

Test Pywikibot
Pywikibot needs a configuration file 'user-config.py' which should have been automatically created for you, set to use as default https://test.wikipedia.org/. T120265

The following command should confirm that you can log into https://test.wikipedia.org/. It will prompt for your password. After typing your password, press Enter. The login script should then attempt to login and confirm it was successful.

Create a page
To create a page, run the following: