title: Parameterize Post Request payload using Rest Assured
body: <p>I have below post request in Rest Assured code :</p>
  
  <p>I want to parameterize it. Please suggest.</p>
  
  <pre><code>       given().contentType(JSON).with()
            .body("\"id\":"123",\"email\":\"abv@gmail.com\"}").expect().body("status",            
          notNullValue()).when().post("https://localhost:8080/product/create.json");
  </code></pre>
  
  <p>Parameters</p>
  
  <p>id, email.</p>
  
  <p>When I declared String variables id,email and try passing in body() its not working.</p>
  
  <p>Not working code:</p>
  
  <pre><code> String id="123";
   String email=abc@gmail.com;
  
   given().contentType(JSON).with()
    .body("\"id\":id,\"email\":email}").expect().body("status",              
     notNullValue()).when().post("https://localhost:8080/product/create.json");
  </code></pre>