title: Problem in adding Customer in shopify using api
body: <p>I have a shopify store and I have created a custom form in footer of my store and want to use details added from that form to create a new customer. I have tried to send a post request to endpoint "/admin/customers.json" using code given below </p>
  
  <pre><code>$(document).ready(function(){
    $('.klaviyo_submit_button').on('click', function(){
  
      $.ajax({
              url: '/admin/customers.json',
              dataType: 'json',
              type: 'POST',
              data:{
                     "customer": {
                        "first_name": "Steve",
                        "last_name": "Lastnameson",
                        "email": "steve.lastnameson@example.com",
                        "phone": "+15142546011",
                        "verified_email": true    
                   }
              },
              success: function() {
                alert('Customer is added');
              }
            });
      })
  
  }) 
  </code></pre>
  
  <p>But it is not sending post request and shows status code "303 see other". Can someone please let me know what mistake I made here and how can I add customer from this form. I am using this code in shopify's theme.js.liquid file.</p>
  
  <p>Thanks </p>