|
1 | 1 | # -*- coding:utf-8 -*- |
2 | 2 |
|
3 | | -query = 'https://en.wikipedia.org/w/api.php?action=query&format=json&formatversion=2&iiprop=size|url|timestamp&prop=imageinfo&titles=File%3ADouglas%20adams%20portrait%20cropped.jpg' |
| 3 | +query = 'https://en.wikipedia.org/w/api.php?action=query&formatversion=2&iiprop=size|url|timestamp|extmetadata&prop=imageinfo&titles=File%3ADouglas%20adams%20portrait%20cropped.jpg' |
4 | 4 |
|
5 | 5 | response = r''' |
6 | 6 | { |
7 | | - "continue": { |
8 | | - "iistart": "2010-04-16T22:53:21Z", |
9 | | - "continue": "||" |
10 | | - }, |
11 | | - "query": { |
12 | | - "pages": [ |
13 | | - { |
14 | | - "ns": 6, |
15 | | - "title": "File:Douglas adams portrait cropped.jpg", |
16 | | - "missing": true, |
17 | | - "known": true, |
18 | | - "imagerepository": "shared", |
19 | | - "imageinfo": [ |
20 | | - { |
21 | | - "timestamp": "2010-04-16T22:54:28Z", |
22 | | - "size": 32915, |
23 | | - "width": 333, |
24 | | - "height": 386, |
25 | | - "url": "https://upload.wikimedia.org/wikipedia/commons/c/c0/Douglas_adams_portrait_cropped.jpg", |
26 | | - "descriptionurl": "https://commons.wikimedia.org/wiki/File:Douglas_adams_portrait_cropped.jpg", |
27 | | - "descriptionshorturl": "https://commons.wikimedia.org/w/index.php?curid=10031710" |
28 | | - } |
| 7 | + "continue": { |
| 8 | + "iistart": "2010-04-16T22:53:21Z", |
| 9 | + "continue": "||" |
| 10 | + }, |
| 11 | + "query": { |
| 12 | + "pages": [ |
| 13 | + { |
| 14 | + "ns": 6, |
| 15 | + "title": "File:Douglas adams portrait cropped.jpg", |
| 16 | + "missing": true, |
| 17 | + "known": true, |
| 18 | + "imagerepository": "shared", |
| 19 | + "imageinfo": [ |
| 20 | + { |
| 21 | + "timestamp": "2010-04-16T22:54:28Z", |
| 22 | + "size": 32915, |
| 23 | + "width": 333, |
| 24 | + "height": 386, |
| 25 | + "url": "https://upload.wikimedia.org/wikipedia/commons/c/c0/Douglas_adams_portrait_cropped.jpg", |
| 26 | + "descriptionurl": "https://commons.wikimedia.org/wiki/File:Douglas_adams_portrait_cropped.jpg", |
| 27 | + "descriptionshorturl": "https://commons.wikimedia.org/w/index.php?curid=10031710", |
| 28 | + "extmetadata": { |
| 29 | + "DateTime": { |
| 30 | + "value": "2010-04-16 22:54:28", |
| 31 | + "source": "mediawiki-metadata", |
| 32 | + "hidden": "" |
| 33 | + }, |
| 34 | + "ObjectName": { |
| 35 | + "value": "Douglas adams portrait cropped", |
| 36 | + "source": "mediawiki-metadata", |
| 37 | + "hidden": "" |
| 38 | + }, |
| 39 | + "CommonsMetadataExtension": { |
| 40 | + "value": 1.2, |
| 41 | + "source": "extension", |
| 42 | + "hidden": "" |
| 43 | + }, |
| 44 | + "Categories": { |
| 45 | + "value": "Douglas Adams|Portrait photographs of men|Self-published work|Uploaded with derivativeFX", |
| 46 | + "source": "commons-categories", |
| 47 | + "hidden": "" |
| 48 | + }, |
| 49 | + "Assessments": { |
| 50 | + "value": "", |
| 51 | + "source": "commons-categories", |
| 52 | + "hidden": "" |
| 53 | + }, |
| 54 | + "ImageDescription": { |
| 55 | + "value": "douglas adams inspired \"Hitch hikers guide to the galaxy\" H2G2 <a rel=\"nofollow\" class=\"external text\" href=\"http://www.hughes-photography.eu\">www.hughes-photography.eu</a>", |
| 56 | + "source": "commons-desc-page" |
| 57 | + }, |
| 58 | + "DateTimeOriginal": { |
| 59 | + "value": "", |
| 60 | + "source": "commons-desc-page" |
| 61 | + }, |
| 62 | + "Credit": { |
| 63 | + "value": "<ul>\n<li><a href=\"//commons.wikimedia.org/wiki/File:Douglas_adams_portrait.jpg\" title=\"File:Douglas adams portrait.jpg\">Douglas_adams_portrait.jpg</a></li>\n</ul>", |
| 64 | + "source": "commons-desc-page", |
| 65 | + "hidden": "" |
| 66 | + }, |
| 67 | + "Artist": { |
| 68 | + "value": "<ul>\n<li>\n<a href=\"//commons.wikimedia.org/wiki/File:Douglas_adams_portrait.jpg\" title=\"File:Douglas adams portrait.jpg\">Douglas_adams_portrait.jpg</a>: <a rel=\"nofollow\" class=\"external text\" href=\"https://www.flickr.com/people/79664273@N00\">michael hughes</a> from berlin, germany</li>\n<li>derivative work: <a href=\"//commons.wikimedia.org/wiki/User:Beao\" title=\"User:Beao\">Bea</a><b><a href=\"//commons.wikimedia.org/wiki/User_talk:Beao\" title=\"User talk:Beao\">o</a></b>\n</li>\n</ul>", |
| 69 | + "source": "commons-desc-page" |
| 70 | + }, |
| 71 | + "LicenseShortName": { |
| 72 | + "value": "CC BY-SA 2.0", |
| 73 | + "source": "commons-desc-page", |
| 74 | + "hidden": "" |
| 75 | + }, |
| 76 | + "UsageTerms": { |
| 77 | + "value": "Creative Commons Attribution-Share Alike 2.0", |
| 78 | + "source": "commons-desc-page", |
| 79 | + "hidden": "" |
| 80 | + }, |
| 81 | + "AttributionRequired": { |
| 82 | + "value": "true", |
| 83 | + "source": "commons-desc-page", |
| 84 | + "hidden": "" |
| 85 | + }, |
| 86 | + "LicenseUrl": { |
| 87 | + "value": "https://creativecommons.org/licenses/by-sa/2.0", |
| 88 | + "source": "commons-desc-page", |
| 89 | + "hidden": "" |
| 90 | + }, |
| 91 | + "Copyrighted": { |
| 92 | + "value": "True", |
| 93 | + "source": "commons-desc-page", |
| 94 | + "hidden": "" |
| 95 | + }, |
| 96 | + "Restrictions": { |
| 97 | + "value": "", |
| 98 | + "source": "commons-desc-page", |
| 99 | + "hidden": "" |
| 100 | + }, |
| 101 | + "License": { |
| 102 | + "value": "cc-by-sa-2.0", |
| 103 | + "source": "commons-templates", |
| 104 | + "hidden": "" |
| 105 | + } |
| 106 | + } |
| 107 | + } |
| 108 | + ] |
| 109 | + } |
29 | 110 | ] |
30 | | - } |
31 | | - ] |
32 | | - } |
| 111 | + } |
33 | 112 | } |
34 | 113 | ''' |
35 | 114 |
|
|
0 commit comments