diff --git a/mediawiki-api.ipynb b/mediawiki-api.ipynb index 9fd6711..e78f42e 100644 --- a/mediawiki-api.ipynb +++ b/mediawiki-api.ipynb @@ -49,37 +49,42 @@ ] }, { - "cell_type": "markdown", + "cell_type": "code", + "execution_count": 65, "metadata": {}, + "outputs": [], "source": [ - "https://pzwiki.wdka.nl/mw-mediadesign/api.php?action=query&titles=Main%20page&format=json" + "# When you visit .... https://pzwiki.wdka.nl/mw-mediadesign/ ........ the URL magically turns into ........ https://pzwiki.wdka.nl/mediadesign/Main_Page\n", + "# This is probably something configured on the server (which is the XPUB XVM server, the wiki is installed there)." ] }, { "cell_type": "code", - "execution_count": null, + "execution_count": 67, "metadata": {}, "outputs": [], "source": [ - "# what's in this URL?" + "# How to access the API?\n", + "\n", + "# Visit in the browser: " ] }, { - "cell_type": "code", - "execution_count": null, + "cell_type": "markdown", "metadata": {}, - "outputs": [], "source": [ - "# https://pzwiki.wdka.nl/mw-mediadesign/ ........ magically turns into ........ https://pzwiki.wdka.nl/mediadesign/Main_Page" + "https://pzwiki.wdka.nl/mw-mediadesign/api.php (This is the main access point of the API of the PZI wiki.)\n", + "\n", + "https://pzwiki.wdka.nl/mw-mediadesign/api.php?action=query&titles=Main%20page&format=json (This is an example of an API request.)" ] }, { "cell_type": "code", - "execution_count": null, + "execution_count": 64, "metadata": {}, "outputs": [], "source": [ - "# https://pzwiki.wdka.nl/mw-mediadesign/api.php" + "# What's in this URL?" ] }, { @@ -166,6 +171,16 @@ "# Wander around in the documentation page, edit the URL, make a couple requests!" ] }, + { + "cell_type": "code", + "execution_count": 68, + "metadata": {}, + "outputs": [], + "source": [ + "# Try to use the actions: \"query\" and \"parse\". \n", + "# We will focus on these two today." + ] + }, { "cell_type": "code", "execution_count": null,