XHR XMLHttpRequest works! but with app.request api gives me internal server error! why?

I have a request with the new updated framework and several requests stopped working correctly and I do not know why!

Using XHR works perfectly but using app.request the post method is undefined and server response is “internal server error!”

works perfect!

    registerUser: function () {

      var self = this;
      console.log('registering user...');

      if (self.data.authProvider == "facebook") {
        var user_id = self.data.user.id;
      }

      if (self.data.authProvider == "google") {
        var user_id = self.data.user.userId;
      }
      var data = JSON.stringify({
        "id": user_id,
        "provider_name": self.data.authProvider,
        "name": self.data.user.name,
        "email": self.data.user.email,
      });

      var xhr = new XMLHttpRequest();
      xhr.withCredentials = true;

      xhr.addEventListener("readystatechange", function () {
        if (this.readyState === 4) {
          console.log(JSON.parse(this.responseText));
        }
      });

      xhr.open("POST", "https://_url_/user/v1/");
      xhr.setRequestHeader("Content-Type", "application/json");

      xhr.send(data);
    },

with app.request API I get “internal server error” post method data undefined

      registerUser: function () {

      var self = this;
      console.log('registering user...');

      if (self.data.authProvider == "facebook") {
        var user_id = self.data.user.id;
      }

      if (self.data.authProvider == "google") {
        var user_id = self.data.user.userId;
      }

      var data = JSON.stringify({
        "id": user_id,
        "provider_name": self.data.authProvider,
        "name": self.data.user.name,
        "email": self.data.user.email,
      });
      app.request({
        "headers": {
          "Content-Type": "application/json"
        },
        "url": 'https://_url_/user/v1/',
        "method": 'POST',
        "data": data,
        "statusCode": {
          404: function (xhr) {
            alert('page not found');
          }
        },
        beforeSend: function () {
          console.log('beforeSend');
        },
        complete: function () {
          console.log('complete');
          app.preloader.hide();
        },
        success: function (data) {

          console.log('success');
          console.log(data);

          app.preloader.hide();

        },
      })

    },

am I missing something with app.request API? I do not see what is the problem here! I only can say with app.request API the API calls does not work properly!

any ideas what is the error about? how to fix it?
appreciate any tips to find the problem and to solve it!

thanks!