Сформируйте и отправьте по указанному выше url:
ncat -C httpbin.org 80
GET /anything HTTP/1.0
Host: httpbin.org
HTTP/1.1 200 OK
Connection: close
Server: meinheld/0.6.1
Date: Sat, 21 Apr 2018 17:15:37 GMT
Content-Type: application/json
Access-Control-Allow-Origin: *
Access-Control-Allow-Credentials: true
X-Powered-By: Flask
X-Processed-Time: 0
Content-Length: 246
Via: 1.1 vegur
{
"args": {},
"data": "",
"files": {},
"form": {},
"headers": {
"Connection": "close",
"Host": "httpbin.org"
},
"json": null,
"method": "GET",
"origin": "128.204.3.127",
"url": "http://httpbin.org/anything"
}
GET /anything?name=maksim HTTP/1.0
Host: httpbin.org
HTTP/1.1 200 OK
Connection: close
Server: meinheld/0.6.1
Date: Sat, 21 Apr 2018 17:16:33 GMT
Content-Type: application/json
Access-Control-Allow-Origin: *
Access-Control-Allow-Credentials: true
X-Powered-By: Flask
X-Processed-Time: 0
Content-Length: 282
Via: 1.1 vegur
{
"args": {
"name": "maksim"
},
"data": "",
"files": {},
"form": {},
"headers": {
"Connection": "close",
"Host": "httpbin.org"
},
"json": null,
"method": "GET",
"origin": "128.204.3.127",
"url": "http://httpbin.org/anything?name=maksim"
}
POST /anything HTTP/1.0
Host: httpbin.org
Content-Length: 10
text=5
HTTP/1.1 200 OK
Connection: close
Server: meinheld/0.6.1
Date: Sat, 21 Apr 2018 17:18:14 GMT
Content-Type: application/json
Access-Control-Allow-Origin: *
Access-Control-Allow-Credentials: true
X-Powered-By: Flask
X-Processed-Time: 0
Content-Length: 290
Via: 1.1 vegur
{
"args": {},
"data": "text=5\r\n\r\n",
"files": {},
"form": {},
"headers": {
"Connection": "close",
"Content-Length": "10",
"Host": "httpbin.org"
},
"json": null,
"method": "POST",
"origin": "128.204.3.127",
"url": "http://httpbin.org/anything"
}
Обрати внимание на лишние символы возврата каретки и новой строки в теле запроса. Должно быть два отступа новой строки между последним заголовком и телом, но после тела - это не обязательно. Вероятнее всего, это лишнее.