Quick and dirty shell script. Keine Garantie auf Richtigkeit. Ich habe damit aus meinem Shop 10969 Artikel in 5 Minuten entfernt.
while true; do
wget -q -L --user= --password= 'http:////api/articles/' -O - | egrep -o '"id":[0-9]+' | cut -d: -f2 | while read id; do
if [["$id" == ""]]; then
break 2;
fi;
echo -n "Deleting ID $id ";
wget -q -L --user= --password= --method=DELETE "http:////api/articles/$id" -O /dev/null;
echo "OK";
done;
done
Vielleicht nützt es jemandem was.