[DOCU-2383] Example to call markAsDeleted command using commands REST api Created: 27/Jan/22  Updated: 28/Jan/22  Resolved: 28/Jan/22

Status: Closed
Project: Documentation
Component/s: None
Affects Version/s: None
Fix Version/s: None

Type: Task Priority: Neutral
Reporter: Richard Gange Assignee: Martin DrĂ¡pela
Resolution: Done Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
relation
Template:
Acceptance criteria:
Empty
Task DoR:
Empty

 Description   

On the page for REST commands it would be helpful to add an example of how to call the markAsDeleted command.
Using cURL:

curl http://localhost:8080/magnoliaAuthor/.rest/commands/v2/markAsDeleted \
  -H "Content-Type: application/json" \
  -X POST --user superuser:superuser \
  --data \
'{
  "repository": "dam",
  "deleteNode": "google-plus.png",
  "uuid": "0234aab2-9a0a-456a-8f0b-fe0a6d4d83ec"
}'

For it to work properly you need three parameters for the call context:

  1. repository
  2. the name of the node to be marked
  3. the uuid of the parent node

Generated at Mon Feb 12 01:26:38 CET 2024 using Jira 9.4.2#940002-sha1:46d1a51de284217efdcb32434eab47a99af2938b.