I am trying to do API Access for Meraki switch+AP that I have.
I created an organization through the web-UI and I could see it there. When I try to do a get of that - its failing
with 404 - not found. Please let me know what I am missing.
Here is my curl command
curl -v -L -H 'X-Cisco-Meraki-API-Key: <mykeyhere>' -X GET -H 'Content-Type: application/json' 'https://api.meraki.com/api/v0/organizations'
curl -v -L -H 'X-Cisco-Meraki-API-Key: {61f0c114336be2a5828f9e95388dca8d0f91178b}' -X GET -H 'Content-Type: application/json' 'https://api.meraki.com/api/v0/organizations'
Note: Unnecessary use of -X or --request, GET is already inferred.
* Trying 209.206.53.98...
* TCP_NODELAY set
* Connected to api.meraki.com (209.206.53.98) port 443 (#0)
* ALPN, offering h2
* ALPN, offering http/1.1
* successfully set certificate verify locations:
* CAfile: /etc/ssl/cert.pem
CApath: none
* TLSv1.2 (OUT), TLS handshake, Client hello (1):
* TLSv1.2 (IN), TLS handshake, Server hello (2):
* TLSv1.2 (IN), TLS handshake, Certificate (11):
* TLSv1.2 (IN), TLS handshake, Server key exchange (12):
* TLSv1.2 (IN), TLS handshake, Server finished (14):
* TLSv1.2 (OUT), TLS handshake, Client key exchange (16):
* TLSv1.2 (OUT), TLS change cipher, Change cipher spec (1):
* TLSv1.2 (OUT), TLS handshake, Finished (20):
* TLSv1.2 (IN), TLS change cipher, Change cipher spec (1):
* TLSv1.2 (IN), TLS handshake, Finished (20):
* SSL connection using TLSv1.2 / ECDHE-RSA-AES256-GCM-SHA384
* ALPN, server did not agree to a protocol
* Server certificate:
* subject: OU=Domain Control Validated; OU=EssentialSSL Wildcard; CN=*.meraki.com
* start date: Sep 5 00:00:00 2019 GMT
* expire date: Sep 4 23:59:59 2021 GMT
* subjectAltName: host "api.meraki.com" matched cert's "*.meraki.com"
* issuer: C=GB; ST=Greater Manchester; L=Salford; O=Sectigo Limited; CN=Sectigo RSA Domain Validation Secure Server CA
* SSL certificate verify ok.
> GET /api/v0/organizations HTTP/1.1
> Host: api.meraki.com
> User-Agent: curl/7.64.1
> Accept: */*
> X-Cisco-Meraki-API-Key: {61f0c114336be2a5828f9e95388dca8d0f91178b}
> Content-Type: application/json
>
< HTTP/1.1 404 Not Found
< Server: nginx
< Date: Tue, 28 Jan 2020 02:19:44 GMT
< Content-Type: text/html; charset=utf-8
< Transfer-Encoding: chunked
< Connection: keep-alive
< Vary: Accept-Encoding
< X-UA-Compatible: IE=Edge,chrome=1
< Cache-Control: no-cache
< X-Request-Id: 98a9a7365f5d9b26b81900e6d46beb56
< X-Runtime: 0.025251
<
* Connection #0 to host api.meraki.com left intact
* Closing connection 0