-->
Page 1 of 1

Cant send HTTP POST via AT commands!

PostPosted: Fri Oct 30, 2015 4:45 pm
by PerryMZ
Hi! I am trying to send some data to PUSH-totification server, which require POST request. Here is curl example:

curl -X POST \
-H "x-instapush-appid: 52d477b2a4c48a" \
-H "x-instapush-appsecret: 2364eb29c3774016fd8" \
-H "Content-Type: application/json" \
-d '{"event":"signups","trackers":{"email":"myemail "}}' \
https://api.instapush.im/v1/post

Here my AT commands:
AT+CIPSTART="TCP","instapush.im",80
CONNECT
OK

AT+CIPSEND=271
OK
>

POST /v1/post HTTP/1.1\r\
Host: api.instapush.im\r\n
x-instapush-appid: XXXXXXXX\r\n
x-instapush-appsecret: YYYYYYYYYYYYY\r\n
Content-Type: application/json\r\n\
Content - Length: 51\r\n\r\n

{"event":"gradus","trackers":{"temperature":"777"}}

And nothing happend! WHat am doing wrong??

Re: Cant send HTTP POST via AT commands!

PostPosted: Sat Oct 31, 2015 12:21 pm
by PerryMZ
Problem was in a "space".