Is it possible to connect API from RapidApi?

Hey,
I’m trying to connect this API from RapidApi, but it doesn’t seems there’s a plugin for RapidApi.
Is it possible to connect this API:
https://rapidapi.com/api-sports/api/api-football/
Help much appreciated :slight_smile:

3 Likes

If the programming language you’re using isn’t available — or you prefer to use another request library — have no fear! All of the APIs available on RapidAPI are exposed through a REST API endpoint. All you’ll need to do is take the information provided on the documentation. Here’s an example of what that would look like

var options = {
  method: 'POST',
  url: API_URL,
  headers: { 
    'cache-control': 'no-cache',
    'Content-Type': 'application/json',
    'X-RapidAPI-Key': API_KEY,
    'header1': 'header-value-1'
  },
  qs: { 
    parameter1: 'parameter-value-1' 
  }
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);
  console.log(body);
});
2 Likes