You can use ERB to format each test case. GET api/aaa {:id=>12} {"id": 12, "name": "rick"} Endpoint note