Topic on Talk:Citoid/API

Diegodlh (talkcontribs)

Hi all! The API documentation currently says that "At present, there is guaranteed to be only one citation Object in the [response] Array". It also says that the query parameter "currently takes URLs, DOIs, PMCIDs, and PMIDs" (although I see the automatic citation wizard in the English Wikipedia's Visual Editor says "title" and "citation" too).

However, if I enter one or more words, such as "wikipedia", as query parameter, the API returns two citation objects in the response array: https://en.wikipedia.org/api/rest_v1/data/citation/mediawiki/wikipedia. They seem to be the result of some free search, as both have the word "wikipedia" somewhere in the object. Is this the expected behavior? Is this documented somewhere?

Similarly, if one of the words is a URL (for example "wikipedia http://nla.gov.au/nla.news-article19573778"), two citation objects are returned again: https://en.wikipedia.org/api/rest_v1/data/citation/mediawiki/wikipedia%20http%3A%2F%2Fnla.gov.au%2Fnla.news-article19573778. The first one seems to be the result of a free search (notice it has the word "nla"), whereas the second one is the translation result for the URL.

Thank you!

PerfektesChaos (talkcontribs)

I got the impression that you misunderstood something.

  • You cannot enter a “word” or even worse “words”.
  • You need to provide a URL of the precise resource you want to refer to.
  • Or you may use things like “PMID 1234” or “DOI 10.1000/182”.
Mvolz (WMF) (talkcontribs)
This post was hidden by Strainu (history)