Hi,
I am playing with https://github.com/djones/grape-goliath-example . My current API class looks like:
class Posts < Grape::API
version 'v1'
format :json
default_format :json
resource 'user' do
post "/create" do
params.except('route_info')
end
end
end
The original version of example is using grape 0.2.2, where both call shown below work as expected. When updated the 0.4.1 (bundle update grape) the following call works:
curl -X POST -d '{"post":{"title":"David Jones","body":"this is my message"}}' http://localhost:9000/posts/create -H Content-Type:application/json
returning
{"post":{"title":"David Jones","body":"this is my message"}}
but when application/json is ommited
curl -X POST -d '{"post":{"title":"David Jones","body":"this is my message"}}' http://localhost:9000/posts/create
the call returns
{"{\"post\":{\"title\":\"David Jones\",\"body\":\"this is my message\"}}":null}
Hi,
I am playing with https://github.com/djones/grape-goliath-example . My current API class looks like:
The original version of example is using grape 0.2.2, where both call shown below work as expected. When updated the 0.4.1 (bundle update grape) the following call works:
returning
but when application/json is ommited
the call returns