We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
In short, you need to set the header and set raw_post to json.
resource "Order" do header "Content-Type", "application/json" post "/orders" do parameter :name, "Order name" let(:name) { "New order" } let(:raw_post) { params.to_json } example "Sending JSON" do do_request response_body.should be_json_eql({ :name => name }.to_json) status.should == 201 end end end