REST API errors and examples


#1

So basically tutorials for the REST API thru curl calls are little shallow.

  1. It appears, I can use some of the calls without API Key and API Secret.
    Obtaining and oAuth token seems enough. (with e-mail + password)
  2. The token is 423 symbols long. Did anybody encounter any issues with that. It appears very long, at least in my first glance.
  3. In the API Docs https://mydevices.com/cayenne/docs_stage/cayenne-api/ we have the GET single thing call description double. Please, delete one.
    Also there is NO ONE example of calling a curl after “Curl example using Resource Owner Grant”, which is right before the “Single Sign on” paragraph.
  4. Based on
    curl --request POST
    –url https://api.mydevices.com/things/THING_ID/data
    –header ‘authorization: Basic base64(MQTT_USERNAME:MQTT_PASSWORD)’
    –header ‘content-type: application/json’
    –data ‘[
    {
    “channel”: 100,
    “value”: 27,
    “type”: “temp”,
    “unit”: “c”
    }
    ]’(I DIDNT TRY THAT! Provided by @asanchezdelc )
    We have a curl call on URL: api.devices.com/things in the code above, which is to the contrary of URL: platform.mydevices.com, which is used in the online docs. Which one should we be using?
  5. Also at the GitHub repository and your own docs they are some discrepancies. At the Simple API app https://github.com/myDevicesIoT/Cayenne-API-Sample-App#getting-real-time-device-data, no examples of curl calls there after either. Images links appear to be broken.