Post JSON

var params = {

"param1" : "value1"

};

$.ajax({

type : "post",

url : "https://www.xxx.com/url",

data : JSON.stringify(params),

contentType : 'application/json; charset=utf-8',

dataType : "json",

success : function(result, dataType) {xxx(result,dataType);},

complete : function(json_data) {},

error : function(result, dataType){alert("Error");}

});