SolarEnergyPrediction

FREEMIUM
By STROMDAO | Updated hace 19 días | Energy
Popularity

9 / 10

Latency

22,845ms

Service Level

41%

Health Check

N/A

Back to All Discussions

Get no response

Rapid account: Abeggled
abeggled
hace un año

const axios = require(“axios”);

const options = {
method: ‘GET’,
url: ‘https://solarenergyprediction.p.rapidapi.com/v2.0/solar/prediction’,
params: {
lat: ‘46.77’,
lon: ‘7.65’,
deg: ‘33’,
az: ‘3’,
wp: ‘9300’,
decoration: ‘forecast.solar’
},
headers: {
‘X-RapidAPI-Key’: ‘6cc4c00b14msh2fd52ad1b22763bp1b2a4djsn26xxxxxxxxxx’,
‘X-RapidAPI-Host’: ‘solarenergyprediction.p.rapidapi.com
}
};

axios.request(options).then(function (response) {
console.log(response.data);
}).catch(function (error) {
console.error(error);
});

and the result looks like:

{
“result”: {
“watts”: {},
“watt_hours”: {},
“watt_hours_day”: {}
},
“message”: {
“code”: 0,
“type”: “success”,
“text”: “compatibility mode from SolarPredictionAPI”,
“info”: {
“place”: “not resolved”,
“timezone”: “Europe/Berlin”
},
“ratelimit”: {
“period”: 3600,
“limit”: 0,
“remaining”: -1
}
}
}

Join in the discussion - add comment below:

Login / Signup to post new comments