Content Type Headers
-
Assert that a POST request to "/api/level18" returns a 200 status code.
-
Assert that a POST request to "/api/level18" with a header of "Content-Type" with a value of "text/plain", and
body of "Just plain ol talkin" returns the
response:
Understood.
-
Assert that a POST request to "/api/level18" with header of "Content-Type" with a value of "application/json",
and body of:
{
"how": "about this?"
}
returns
the response:
{
"Yup": "got it"
}