0

I'm using RestAPI to delete item from list. But I dont want to permanently delete it. I want to send it to Recycle Bin. Is there possible with using RestAPI?

2 Answers2

1

instead of delete command, use recycle:

http://sitecollectionURL/_api/web/lists(listname)/items(itemid)/recycle()

Deepmala
  • 1,857
  • 1
  • 10
  • 15
1

If you use HTTP command DELETE, it will delete permanently and below is URI struture:

http://<sitecollection>/<site>/_api/web/lists(listid)/items(itemid) 

If you want to delete item and move it to recycle bin, use HTTP command POST and below is URI structure:

http://<sitecollection>/<site>/_api/web/lists(listid)/items(itemid)/recycle()
Anil Pal
  • 1,079
  • 8
  • 17