I am developping a web application that uses a feature service, what i want to do is save the data in the feature server, and then delete all the features at the start of the application. I am able to save data in the feature service, my problem is how to delete the features in the start of the application. I found a solution to that suggesting that I use the operation: "Delete Features" of the REST API, but I think I am making a mistake in the syntax, here is my code sample:
var theurl= "***/arcgis/rest/services/edt/FeatureServer/0/deleteFeatures"
var request = esri.request({
url: theurl,
// Service parameters if required, sent with URL as key/value pairs
content: {
f: "json",
where: "1=1"}
});
I don't know what I am missing can you please help