Add Record to creator report from JS widget

Add Record to creator report from JS widget

I have created an HTML page to get the location. I need to get this location and insert it to report name called "Location" in Zoho creator.  this is the error that I'm facing,

 POST https://creatorapp.zoho.com/widgetapi/companyname/developer/form/Locations 404
"{"code":2930,"message":"Error Occurred. We are sorry for the inconvenience."}"}

This is my code
 ZOHO.CREATOR.init()
        .then(function(data) {
            var queryParams = ZOHO.CREATOR.UTIL.getQueryParams();

            $('#btnSave').click(function() {
                console.log("Record Adding...");
                
                  var formData = {
                    "autocomplete":document.getElementById("autocomplete").value
                    
  
                }
        
              config = {
                      formName : "Locations",
                      data : formData
              }
            
             ZOHO.CREATOR.API.addRecord(config).then(function(response){
                if(response.code == 3000){
                    console.log("Record added successfully");
                }   
             });
           });            
        });