Torna ai Tool

Generatore URL MediaWiki

Genera URL di esportazione API MediaWiki in blocco da un elenco di titoli di pagina o link wiki.

Generatore URL API

Elaborazione in Blocco

Elabora più titoli di pagina o URL contemporaneamente

Formati Multipli

Esporta in formati JSON, XML o PHP

Auto-Chunking

Divide automaticamente le richieste grandi in blocchi da 50 titoli

Configurazione

Inserisci il dominio wiki. Verrà compilato automaticamente se incolli un URL completo sotto.

Inserisci un titolo pagina o URL per riga. Gli URL verranno analizzati automaticamente per estrarre i nomi pagina.

Titoli per richiesta API (max 50 raccomandato)

URL API Generati 0

Titoli Unici: 0
Richieste API: 0
Formato: -

Complete Guide to MediaWiki API & Bulk Exports

What is the MediaWiki API?

The MediaWiki API is a web service that provides programmatic access to wiki data and functionality. It is available on any MediaWiki installation (including Wikipedia, Fandom wikis, Wikidata, and self-hosted company wikis) at the api.php endpoint. Using the API, you can retrieve page content, metadata, revision histories, images, and structured data without scraping HTML — which is both faster and less brittle than web scraping.

Understanding the API URL Structure

A typical MediaWiki content export API request looks like this:

https://en.wikipedia.org/w/api.php?action=query&titles=MediaWiki|PHP&prop=revisions&rvprop=content&format=json

The key parameters are: action (query, parse, etc.), titles (pipe-separated page names), prop (what properties to return), and format (json, xml, etc.). The titles parameter allows up to 50 pages per request — our tool automatically splits larger lists into batches and generates one API URL per chunk.

Common Use Cases for Bulk Wiki Exports

  • Content Auditing: Export entire categories of wiki pages to a JSON file, then analyze word counts, last-modified dates, and authors to identify stale content that needs updating.
  • AI Training Data: Researchers extract Wikipedia articles at scale to build datasets for NLP models. The raw wikitext (markup) format is often preferred over HTML for this purpose.
  • Internal Wiki Migration: When migrating a company wiki (e.g., from Confluence to a MediaWiki-based system or vice versa), the API enables scripted extraction of all articles into structured JSON for transformation.
  • Link Graph Analysis: Security researchers and SEO analysts extract all pages from a wiki domain to build a link graph, identifying hubs, orphaned pages, and internal linking patterns.

Output Formats Explained

Our tool generates API URLs in multiple formats: JSON is recommended for programmatic processing (most languages have native JSON parsers). XML is useful for legacy systems or when using XSLT for transformation. PHP Serialized format is useful when consuming the API directly within a PHP application. The "formatted" variants (jsonfm, xmlfm) return human-readable pretty-printed output suitable for manual inspection in a browser.

Frequently Asked Questions

Can I export protected pages?

You can only export pages you have permission to view. Protected pages and pages requiring an account will return an API error unless you provide a valid session cookie or OAuth token. For public wikis like Wikipedia, all articles are publicly readable without authentication. For private wikis, you need to pass credentials via the API's login endpoint first.

Why are pages split into chunks of 50?

The MediaWiki API enforces a limit of 50 titles per query request for logged-out users (500 for logged-in API users). This is a server-side to prevent abuse and excessive load. Our tool respects this limit by splitting larger title lists into multiple batches and generating a separate API URL for each, so you can fetch them sequentially or in parallel.

Can I use this with any MediaWiki installation?

Yes! Any site running MediaWiki 1.17+ supports the modern API endpoint at /w/api.php. This includes Wikipedia, all Fandom (Wikia) wikis, Wikidata, Wikimedia Commons, self-hosted company wikis, and open-source community wikis. Simply enter the domain (e.g., terraria.wiki.gg) and the tool constructs the API URL automatically.

About the Author: Nicola Selenu

Nicola is a Lead Developer and Digital Marketing Technologist with years of hands-on experience in technical SEO, web analytics, and deliverability. He builds tools to bridge the gap between complex marketing technicalities and easy-to-use solutions.