In [1]:
import pywikibot
In [ ]:
 
In [3]:
site = pywikibot.Site('test','wikipedia')
In [4]:
site
Out[4]:
APISite("test", "wikipedia")
In [5]:
page = pywikibot.Page(site, 'test')
In [6]:
page.exists()
VERBOSE:pywiki:Found 1 wikipedia:test processes running, including this one.
Out[6]:
True
In [7]:
page.text = "Hello World"
In [8]:
page.save()
Page [[Test]] saved
INFO:pywiki:Page [[Test]] saved
In [ ]: