Wikimedia_query: Wikimedia_query Use httr package to retrieve responses in...

View source: R/wiki_utils.R

Wikimedia_queryR Documentation

Wikimedia_query Use httr package to retrieve responses in JSON format about an article from Wikimedia API.

Description

Wikimedia_query Use httr package to retrieve responses in JSON format about an article from Wikimedia API.

Usage

Wikimedia_query(
  query,
  project = "en.wikipedia.org",
  headers = my_headers,
  attempts = 2
)

Arguments

query

A list with de (key, values) pairs with the search.

project

The Wikimedia project to search.

headers

A vector with aditional query headers for the request.

attempts

On errors, the maximun number of times the query is launched if repetition_on_error is not zero (default 2)

Value

The response in JSON format or NULL on errors.

Author(s)

Angel F. Zazo, Departament of Computer Science and Automatics, University of Salamanca


wikiTools documentation built on March 24, 2022, 9:05 a.m.