Dupdroid
Posts: 0
Joined: Sat Mar 30, 2013 9:07 pm

servercode test using x-www-form-urlencoded = status":"400 Bad Request / code:BCXX002

I'm getting an error trying to test a basic server code script using x-www-form-urlencoded:

{
"status":"400 Bad Request",
"url":"https://api.appery.io/rest/1/code/593...",
"response":{
"code":"BCXX002",
"description":"Cannot consume content type"
}
}

server code script =

var body = request.body(); //Saving the request body
var name = request.get("name"); //Saving the request parameter "name"
response.success(name + ":" + "\n" + body); //Output them both

What am I doing wrong?

Image

Image

Image

Image

Maryna Brodina
Posts: 0
Joined: Thu Apr 05, 2012 7:27 am

servercode test using x-www-form-urlencoded = status":"400 Bad Request / code:BCXX002

Hello!

Unfortunately you can't send request to appery.io server code with content type application/x-www-form-urlencoded

Return to “Issues”