2021-07-25 09:19:56 +03:00
|
|
|
curl 'http://localhost:8000/post-json' -H 'Content-Type: application/json' --data $'{\n "name": "Bob",\n "password": "secret",\n "age": 30,\n "strict": true,\n "spacing": "\\n",\n "g_clef": "\\uD834\\uDD1E"\n}'
|
2021-05-14 20:31:18 +03:00
|
|
|
curl 'http://localhost:8000/post-json-array' -H 'Content-Type: application/json' --data '[1,2,3]'
|
|
|
|
curl 'http://localhost:8000/post-json-string' -H 'Content-Type: application/json' --data '"Hello"'
|
|
|
|
curl 'http://localhost:8000/post-json-number' -H 'Content-Type: application/json' --data '100'
|
|
|
|
curl 'http://localhost:8000/post-json-numbers' -H 'Content-Type: application/json' --data $'{\n "natural": 100,\n "negative": -1,\n "float": "3.333333333333333",\n "exponent": 100e100\n}'
|
|
|
|
curl 'http://localhost:8000/post-json-boolean' -H 'Content-Type: application/json' --data 'true'
|
|
|
|
curl 'http://localhost:8000/get-name'
|
2021-07-25 09:19:56 +03:00
|
|
|
curl 'http://localhost:8000/check_name' -H 'Content-Type: application/json' --data $'{\n "name": "Bob"\n}'
|