Wikipedia Parser

No algorithm description given

0. TL;DR This algorithm provides basic API access to Wikipedia. 1. Introduction Search Wikipedia, get article summaries, get data like links and images from a page, and more. This algorithm wraps the MediaWiki API so you can focus on accessing relevant Wikipedia data, instead of downloading the latest Wikipedia dump. Input: (Required): Only one of them A Wikipedia article name* Search for a Wikipedia article** Number of random articles*** (Optional) : Set Wikipedia Language*** Output: JSON formatted page data (only for article name) List of article names (for searching a term & random articles) 2. Retrieving a Wikipedia Article *A wikipedia Article:  Retrieve a Wikipedia Articles by it's title name (key = "articleName") Example of retrieving a Wikipedia Article: "AI Winter" or {
 "articleName": "AI Winter"
} 3. Searching for a Wikipedia Article **Search for a Wikipedia Article:  Search for Wikipedia articles that match the search term (key = search) Example of searching for Wikipedia articles: {
 "search": "Great Filter"
} 4. Getting Random Wikipedia Article(s) ***Number of Random Articles: Get up to 500 random Wikipedia articles (key = random) Example of getting random Wikipedia articles: {
 "random": 10
} 5. Outputs JSON formatted page data: Output is returned after for requesting a valid Wikipedia article. Example for JSON formatted page data (for articleName = "AI Winter"): {
 "pageid": "3548574",
 "links": ["1997 Asian financial crisis", "AAAI", "AI effect", "AI winter", ...],
 "title": "AI winter",
 "url": "",
 "summary": "In the history of artificial intelligence, an AI winter is a period of ...",
 "content": "In the history of artificial intelligence, an AI winter is a period of ...",
 "references": ["", "http:", ...],
 "images": ["", "", ...]
} A List of article names: Output is returned after searching for a term or requesting a number of random articles. Example for a list of article name (for search = "Fermi Paradox"):  [
 "Fermi paradox",
 "Fermi Paradox (album)",
 "Planetarium hypothesis",
 "Manifold Trilogy",
 "Great Filter",
 "Zoo hypothesis",
 "The Fermi Paradox Is Our Business Model",
 "Fermi and Frost"
 Example for a list of article names (for random = 10): [
 "2005 CIS football season",
 "Stephen Kelman",
 "Samuel Owens",
 "Stockport Central Library",
 "Liam Fox",
 "Smales Farm Busway Station",
 "U.S. Route 62 in Arkansas"
] 6. Credits For more information please visit:

(no tags)

Cost Breakdown

0 cr
royalty per call
1 cr
usage per second
avg duration

Cost Calculator

API call duration (sec)
API calls
Estimated cost
per calls
for large volume discounts
For additional details on how pricing works, see Algorithmia pricing.

Internet access

This algorithm has Internet access. This is necessary for algorithms that rely on external services, however it also implies that this algorithm is able to send your input data outside of the Algorithmia platform.

To understand more about how algorithm permissions work, see the permissions documentation.

1. Type your input

2. See the result

Running algorithm...

3. Use this algorithm

curl -X POST -d '{{input | formatInput:"curl"}}' -H 'Content-Type: application/json' -H 'Authorization: Simple YOUR_API_KEY'
View cURL Docs
algo auth
algo run algo://web/WikipediaParser/0.1.0 -d '{{input | formatInput:"cli"}}'
View CLI Docs
import com.algorithmia.*;
import com.algorithmia.algo.*;

String input = "{{input | formatInput:"java"}}";
AlgorithmiaClient client = Algorithmia.client("YOUR_API_KEY");
Algorithm algo = client.algo("algo://web/WikipediaParser/0.1.0");
AlgoResponse result = algo.pipeJson(input);
View Java Docs
import com.algorithmia._
import com.algorithmia.algo._

val input = {{input | formatInput:"scala"}}
val client = Algorithmia.client("YOUR_API_KEY")
val algo = client.algo("algo://web/WikipediaParser/0.1.0")
val result = algo.pipeJson(input)
View Scala Docs
var input = {{input | formatInput:"javascript"}};
           .then(function(output) {
View Javascript Docs
var input = {{input | formatInput:"javascript"}};
           .then(function(response) {
View NodeJS Docs
import Algorithmia

input = {{input | formatInput:"python"}}
client = Algorithmia.client('YOUR_API_KEY')
algo = client.algo('web/WikipediaParser/0.1.0')
print algo.pipe(input)
View Python Docs

input <- {{input | formatInput:"r"}}
client <- getAlgorithmiaClient("YOUR_API_KEY")
algo <- client$algo("web/WikipediaParser/0.1.0")
result <- algo$pipe(input)$result
View R Docs
require 'algorithmia'

input = {{input | formatInput:"ruby"}}
client = Algorithmia.client('YOUR_API_KEY')
algo = client.algo('web/WikipediaParser/0.1.0')
puts algo.pipe(input).result
View Ruby Docs
use algorithmia::*;

let input = {{input | formatInput:"rust"}};
let client = Algorithmia::client("YOUR_API_KEY");
let algo = client.algo("web/WikipediaParser/0.1.0");
let response = algo.pipe(input);
View Rust Docs
import Algorithmia

let input = "{{input | formatInput:"swift"}}";
let client = Algorithmia.client(simpleKey: "YOUR_API_KEY")
let algo = client.algo(algoUri: "web/WikipediaParser/0.1.0") { resp, error in
View Swift Docs
  • {{comment.username}}