How can I read a json post, I have a react native app that is posting to my perl api, I'm doing what is below, but the post is alway empty, then I realize that what is being posted is a json post but I dont' know how to read the values from the post.
my $query = new CGI;
my $email = $query->param("email");
my $password = $query->param('password');
This is my post from react
axios.post(url, {
email: 'myemail@email.com',
password: 'password'
})
.then(function (response) {
alert(response);
})
.catch(function (error) {
alert(error);
});