0

When querying wikidata, I get a Access-Control-Allow-Origin error.

My request is sent using Axios from a Reactjs web app:

let query = "https://www.wikidata.org/w/api.php?action=wbgetentities&format=json&titles=La_Cha%C3%AEne_Info&sites=enwiki|frwiki";
axios.get(query, (response) => {
    ...
});

Adding origin=* as for the wikipedia api does not work and replacing www by en returns an insecure response.

Is there a way around this?

ted
  • 13,596
  • 9
  • 65
  • 107

0 Answers0