Reputation: 33
I am trying to hit an endpoint in postman. I am using a particular API which is given by Spoonacular. When I hit the HTTP GET request i get a 401 unauthorized response. I am not sure why I get this response. The response message is ->
{
"message": "Invalid API key. Go to https://docs.rapidapi.com/docs/keys for more info."
}
I know that my API is not invalid as I am able to get a status 200ok for other requests This is my request. I believe that I have formatted it correclty -> https://spoonacular-recipe-food-nutrition-v1.p.rapidapi.com/recipes/mealplans/generate?timeFrame=day&apiKey=MYAPIKEY
Does anyone know how to solve this. Thanks in advance
Upvotes: 0
Views: 1503
Reputation: 33
I figured it out myself in the end -> https://api.spoonacular.com/recipes/mealplans/generate?timeFrame=day&targetCalories=2000&diet=vegetarian&exclude=shellfish%2C%20olives&apiKey=myapi , I was using the wrong http address
Upvotes: 1