...
Authentication session for API use
task | curl | inputs | instructions |
---|---|---|---|
get all sensors | curl -X GET -H 'Accept: */*' -H 'Accept-Encoding: gzip, deflate' -H 'Connection: keep-alive' -H 'User-Agent: python-requests/2.19.1' --compressed https://greatlakestogulf.org/geostreams/api/sensors | ||
authenticate | curl -X POST -H 'Accept: */*' -H 'Accept-Encoding: gzip, deflate' -H 'Connection: keep-alive' -H 'Content-Length: 63' -H 'Content-Type: application/json' -H 'User-Agent: python-requests/2.19.1' -d '{"password": " |
*****", "identifier": "email"}' --compressed - |
| In the response will be X-Auth-Token: followed by the alphanumeric security token | ||
get token | headers = {"x-auth-token": r.headers["x-auth-token"], "Content-Encoding": "application/json"} | ||
Authentication session for API use
...