Getting 404 Not Found when using Meraki Developer Hub

bbyw
Conversationalist

Getting 404 Not Found when using Meraki Developer Hub

Hello!

I'm trying to write a script in Python for my organization that will use Meraki API.

 

However, since yesterday, I've been running into one issue. Namely when I try to use the Meraki Developer Hub site I'm getting all the time the 404 Not Found response.

bbyw_0-1707297551835.png


I'm using correct organization ID as when I run some simple script locally from my computer I'm getting some results.

What could be the issue? I've been researching this topic and saw similar but could not find any answer that would enable me to use the Developer Hub.

 

9 Replies 9
Ralph-AprolisUK
Just browsing

I am also having the same issue whether http requesting or browsing to the endppoint

GreenMan
Meraki Employee
Meraki Employee

Is this a particular problem with a specific endpoint - or all endpoints?

I've just been running a few basic test calls via the developer Hub and they appear to work fine

If you're using a Python script, I'm not sure how the Develop Hub page is involved..?   Unless maybe you're separately testing calls which you later use in your script, perhaps

Ralph-AprolisUK
Just browsing

We are able to get the API-Key fine, but when querying devices the request is

 

Method: GET, RequestUri: 'https://api.meraki.com/api/v1/organizations/xxxxx/devices', Version: 1.1, Content: <null>, Headers:
{
X-Cisco-Meraki-API-Key: xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
Accept: application/json
}

 

we are using C#.net and passing the API-key and organisationId

 

The response is Response status code does not indicate success: 404 (Not Found).<br>Response status code does not indicate success: 404 (Not Found). https://api.meraki.com/api/v1/organizations/xxxxxx/devices

Ralph-AprolisUK
Just browsing

I am using the Live one https://api.meraki.com/api/v1/

GreenMan
Meraki Employee
Meraki Employee

404 is a pretty general error - you may need to post your whole call for people to advise.  The original question here was specific to the Developer Hub page, where there used to be a more obvious option for including your own API key in the call (which is essential, in any call, of course).   Remember to hide the API key itself, if you do post.

bbyw
Conversationalist

I was missing X-Cisco-Meraki-API-Key as header when using the Developer Site that's why I was getting the 404 error.

 

bbyw_0-1707308500583.jpeg

 

 

When added, now everything works fine.


GreenMan
Meraki Employee
Meraki Employee

Yeah - you definitely need that...   (glad to see you obfuscated your actual key!)

Ryan_Miles
Meraki Employee
Meraki Employee

This is a frequent issue lately ever since we made this change back in Nov 2023. 

 

"API interactive Documentation update


Improved security by providing test keys to run request against the API and restricting user sensitive API keys to be pasted in the documentation."

 

The default API key is for a sandbox environment Org

 

For example this call works https://developer.cisco.com/meraki/api-v1/get-organizations/ because it simply returns the Org the API key has access to.

 

"id": "1215707",
"name": "API Demo Organization"

 

But when you run other endpoints that specify an Org, networks, etc that API key of course wouldn't work in your own Org. So, as @bbyw mentioned you need to add your API key if you want to use the dev site against your own Org. 

 

One more example using the get Org networks call. If you put your Org ID in it will produce a 404 error because the default API doesn't have access to your Org. If you instead used the demo Org ID mentioned above 1215707 the call works as expected.

Ryan

If you found this post helpful, please give it Kudos. If my answer solves your problem please click Accept as Solution so others can benefit from it.
tchan
Conversationalist

I’m reaching out to get some additional insights into an issue I’m encountering with the Meraki API. I’m facing consistent 404 errors when trying to retrieve the Network ID for my organization, and I’d like to clarify a few points to see if you might have any clues that could help.

  1. Full Administrator Access: I’ve verified that I have full administrator rights on my sandbox environment, so permissions should not be the issue.

  2. API Key Testing: I have tried using two different API keys with the same result. Both keys work fine for retrieving the organization ID, which confirms they have some access. However, I receive a 404 error specifically when trying to access the /networks endpoint for both my Production organization ID and the sandbox organization ID.

  3. Could you provide any guidance on whether there are additional settings or steps I might be overlooking? Additionally, with the recent API changes in November, is there anything specific I need to configure to ensure these calls work with my actual organization data, rather than the sandbox environment?  
  4. I am using Postman curl for my testing dev_lab 
Get notified when there are additional replies to this discussion.