Я просто отправлял некоторые данные на свое устройство на доске вещей, написав эту команду в командной строке
curl -v -X POST -d "{\"temperature\": 25}" http://demo.thingsboard.io/devices/api/v1/IG4XXXXXXXXXCQM/telemetry
--header "Content-Type:application/json"
, но я получаю это сообщение об ошибке в последний раз
{"timestamp":"2020-01-16T13:09:05.031+0000","status":405,"error":"Method Not Allowed","message":"Request method 'POST' not supported","path":"/devices/api/v1/IG4Dxxxxxxxxxxxxxxxxs6CCQM/telemetry"}* Connection #0 to host demo.thingsboard.io left intact
что это Я не правильно делаю? Все усилия приветствуются. Ниже приведены документация и полное сообщение об ошибке
Thingsboard
Note: Unnecessary use of -X or --request, POST is already inferred.
* Trying 104.196.24.70:80...
* TCP_NODELAY set
* Connected to demo.thingsboard.io (104.196.24.70) port 80 (#0)
> POST /devices/api/v1/IGxxxxxxxs6CCQM/telemetry HTTP/1.1
> Host: demo.thingsboard.io
> User-Agent: curl/7.65.1
> Accept: */*
> Content-Type:application/json
> Content-Length: 19
>
* upload completely sent off: 19 out of 19 bytes
* Mark bundle as not supporting multiuse
< HTTP/1.1 405
< Allow: GET, HEAD
< X-Content-Type-Options: nosniff
< X-XSS-Protection: 1; mode=block
< Cache-Control: no-cache, no-store, max-age=0, must-revalidate
< Pragma: no-cache
< Expires: 0
< Content-Type: application/json;charset=UTF-8
< Content-Language: en
< Transfer-Encoding: chunked
< Date: Thu, 16 Jan 2020 13:09:04 GMT
<
{"timestamp":"2020-01-16T13:09:05.031+0000","status":405,"error":"Method Not Allowed","message":"Request method 'POST' not supported","path":"/devices/api/v1/IGxxxxxxxxxxxs6CCQM/telemetry"}* Connection #0 to host demo.thingsboard.io left intact