GeezerVisonThe World Wide Web, restored to 800 pixels of glory. |
| Home|About|Gaming cabinet|Archives|How it works|Starter sites |
GeezerVison is showing www.mediawiki.org — API:REST API/Get started - MediaWiki This page helps you get started using the MediaWiki REST API to perform common types of operations. Before you beginYour use of the MediaWiki REST API must follow the access and usage policies. Sample call# Search English Wikipedia for an article about Earth $ curl "https://en.wikipedia.org/w/rest.php/v1/search/page?q=earth&limit=1" Data formatsREST API endpoints return data in JSON or HTML format. See the API reference for the content type supported by each endpoint. URL structureAPI endpoints share a consistent URL structure that includes the wiki's base URL, the wiki's script path, and the API version: # URL structure> [project url]/[script path]/rest.php/v[version number]/ # Example URL: Get the history of the Main Page of English Wikipedia https://en.wikipedia.org/w/rest.php/v1/page/Main_Page/history
Use conditional requests to optimize API callsSee Wikimedia APIs/Conditional requests. Make cross-origin requestsFor instructions on how to use cross-origin resource sharing (CORS) requests in your JavaScript code to communicate between wikis on different domains, see Special:MyLanguage/Manual:CORS. Next steps |
| You are visitor 01402503 — GeezerVison does not store the pages you look up. Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required. |