aoinan
v2.1.0
Published
<> Simplified crawling of wikis
Downloads
12
Readme
aoinan
aoinan
can fetch remote pages from a MediaWiki server, extract structured data
and return it to you. It is heavily based on the WTF Wikipedia
module for its parsing of
wiki text.
Installation
yarn add aoinan
Initialization
Before using aoinan
, you need to tell it more about the server it needs to
connect to.
const aoinan = require('aoinan');
aoinan.init({
server: 'pathfinderwiki.com',
path: '/mediawiki',
});
See the Initialization section for more details.
Querying one page
You can then query any page by passing its title to aoinan.page
.
const scenario = await aoinan.page('The Burden of Envy');
See the Page section for more details.
Category
You can get all pages of a given category by calling aoinan.category
.
const scenarios = await aoinan.category('Season_1_(2E)_scenarios');
Documentation
The complete documentation can be found on https://projects.pixelastic.com/aoinan/