title: Ajax pass object to dancer module
body: <p>I have an object called 'contacts' passed through ajax to perl dancer module like:</p>
  
  <pre><code>$.ajax({
                  type: "POST",
                  url: 'Contacts/savecontact',
                  dataType: "json",
                  data: {con: contacts},
                  success: function (msg) {
                      alert("success");
                  }
     });
  </code></pre>
  
  <p>in module</p>
  
  <pre><code>any [ 'ajax', 'post'] =&gt; '/savecontact' =&gt; sub {
      set serializer =&gt; 'JSON';
      my $body = request-&gt;body;
      ### I need to get each value in objects contact like name, id etc
  
  };
  </code></pre>
  
  <p>I tried to dump <code>$body</code>, it comes as <code>"'con%5Bid%5D=1&amp;con%5Bname%5D=Amy+John&amp;con%5Baddress%5D=test+here'"</code></p>
  
  <p>Anyone please help me to get the parameters? </p>