移远官网

EC600N HTTP POST JSON数据如何发送???

AT+QHTTPCFG=“contextid”,1

AT+QHTTPCFG=“contenttype”,0

AT+QHTTPCFG=“requestheader”,1

AT+QIACT=1

AT+QHTTPURL=74,3

http://link.my.qxwz.com/api/devices/register?registerCod

AT+QHTTPPOST=399,3,3

POST /mcu HTTP1.1
Host:http://link.my.qxwz.com/api/devices/register?registerCod
User-Agent:QUECTEL_MODULE
Content-Type:application/json
Content-Length:195
Connection: Keep-Alive

{“sn”:“9622110001”,“deviceName”:“裂缝计”,“deviceType”: “1”,“network”: “0”,“protocol”: “0”,“monitorTypes”: [{“type”: “L1_LF”,“sid”: “1”},{“type”: “L1_QJ”,“sid”: “1”},{“type”: “L1_JS”,“sid”: “1”}]}
set http body sucess

有人碰到过这个问题吗?

没有问题的, 可以再看一下文档,类型支持json的, 流程可以参考如下验证:用你的地址验证是OK的

AT+QIACT=1
AT+QHTTPCFG=“contextid”,1
AT+QHTTPCFG=“requestheader”,0
AT+QHTTPCFG=“contenttype”,4

AT+QHTTPURL=56,3
http://link.my.qxwz.com/api/devices/register?registerCod

AT+QHTTPPOST=189,30,30
{“sn”:“9622110001”,“deviceName”:“裂缝计”,“deviceType”:“1”,“network”:“0”,“protocol”:“0”,“monitorTypes”: [{“type”: “L1_LF”,“sid”: “1”},{“type”: “L1_QJ”,“sid”: “1”},{"type”: "L1_JS”,“sid”: “1”}]}

image