You can use the SharePoint Rest API option, below article for your reference.
function addListItem() {
var myListUrl= "mysite.sharepoint.com/_vti_bin/listdata.svc/myList";
var item= {};
item.Title = "Adding an item using 2010 REST API";
var itemEntry= JSON.stringify(item);
$.ajax({
type: "POST",
url: myListUrl,
data: itemEntry,
contentType: "application/json; charset=utf-8",
success: function () {
//do stuff here
},
error: function() {
//do some error handling here
}
});
}
Thanks & Regards,