0.0
No commit activity in last 3 years
No release in over 3 years
A client for the MediaWiki API
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
 Dependencies

Runtime

>= 0.13.3, ~> 0.13
>= 0.14.24, ~> 0.14
>= 1.6.5, ~> 1.6
>= 0.10.1, ~> 0.10
>= 10.4.2, ~> 10.4
>= 0.9.7, ~> 0.9
>= 2.9.3, ~> 2.9
>= 1.20.4, ~> 1.20
>= 0.8.1, ~> 0.8
 Project Readme

MediaWiki-Keiki

A Ruby API client for the MediaWiki API

Features

Query the WikiMedia API, returning JSON documents

  • Multiple pages per query supported

Retrieve data from WikiMedia pages, including

  • Title
  • Full text
  • Full text as HTML
  • Short text summary

Installation

Install as a ruby gem

$ gem install mediawiki-keiki

Or add it to your application's Gemfile:

gem 'mediawiki-gateway'

Usage

Create a simple query with a single page

query = WikiMedia::Query.new('foo')

Create a query with multiple pages

query = WikiMedia::Query.new('foo|bar')

Retrieve a page from a query

foo_page = query.pages['foo']

Get the summary of a page

puts foo_page.summary

Get the title of a page

puts foo_page.title