Delete File or Folder
Delete an individual file or folder from the file staging server.
DELETE
/api/{version}/services/file_staging/items/{item}Headers
Section link for Headers| Name | Description |
|---|---|
Accept | application/json (default) or application/xml |
URI Path Parameters
Section link for URI Path Parameters| Name | Description |
|---|---|
item | The absolute path to the file or folder to delete. This path is specific to the authenticated user. Admin users can access the root directory. All other users can only access their own user directory. |
Query Parameters
Section link for Query Parameters| Name | Description |
|---|---|
recursive | Applicable to deleting folders only. If true, the request will delete the contents of a folder and all subfolders. The default is false. |
Request
Section link for Requestcurl -L -X DELETE -H "Authorization:{SESSION_ID}"" \
-H "Accept: application/json" \
https://myvault.veevavault.com/api/v23.1/services/file_staging/items/u10001400/promotional2021?recursive=trueResponse
Section link for Response{
"responseStatus": "SUCCESS",
"data": {
"job_id": 100953,
"url": "/api/v23.1/services/jobs/100953"
}
}Response Details
Section link for Response DetailsOn SUCCESS, the response contains the following information:
| Name | Description |
|---|---|
job_id | The Job ID value to retrieve the status and results of the request. |
url | URL to retrieve the current job status of this request. |
Deleting Files in the Inbox Directory
Section link for Deleting Files in the Inbox DirectoryDeleting files from your Vault's Inbox directory does not delete corresponding Staged documents Vault created when the files were uploaded. Learn more in Vault Help