title: cakephp validates() not working in REST api
body: <p>i am trying to validate data before insert,update and delete into database table using validates() in cakephp.
  one thing that has to be noticed that i am doing this with REST api.
  i want that, when i call an api for insert,update,delete before it perform the task it must be validate the data.
  like i want to insert an email address if input is not an email then it should give me an error message,but it always comes in if condition which is wrong.
  my code is given below -</p>
  
  <p>controller:-WebserviceController.php</p>
  
  <pre><code>App::uses('AppController', 'Controller');
   class WebserviceController extends AppController {
   public $components = array('RequestHandler','Api','Paginator','CurrencyConverter.CurrencyConverter');
   public function beforeFilter() {
      parent::beforeFilter();
   }
   public function add()
   {
      $this-&gt;loadModel('User');
      $this-&gt;User-&gt;set($this-&gt;request-&gt;data);
      if ($this-&gt;User-&gt;validates()) {
          $this-&gt;set(array(
          'result' =&gt; array(
              'status' =&gt; true,
              'msg' =&gt; __("validation are working")
          ),
          '_serialize' =&gt; array('result'),
      ));
      } else {
          $this-&gt;set(array(
          'result' =&gt; array(
              'status' =&gt; false,
              'msg' =&gt; __("invalid email input")
          ),
          '_serialize' =&gt; array('result'),
      ));
  
      }
   }
  </code></pre>
  
  <p>model:-UserModel.php</p>
  
  <pre><code>App::uses('AppModel', 'Model');
  
  class UserModel extends AppModel {
      public $validate = array(
      'email' =&gt; 'email'
      );
  }
  </code></pre>
  
  <p>I tried so hard but no luck. I am stuck, please help me out thanks in advance.</p>