Move A Folder

Title

Move a folder to a different place

URL Path

vault_rest/move_folders

Method

PUT

Summary

This API allows moving one or multiple folders in MetaDefender Vault.

HTTP header parameters

Authorization

The API key of the caller

REQUIRED

This header should have the following format:
Bearer [

Example: Bearer Cp01BwnXAIOLZXxn7yogjKqIZnZpQD

Method: PUT

HTTP body

json formatted request

REQUIRED

HTTP body sample
{
"folders": [
{
"folder_id": "c5133a2deb5a4f4798b45731cc1bcda9",
"name": "folder3",
"path": "test\\folder3"
},
{
"folder_id": "433beb56d2c94effb24bccdce6823a7b",
"name": "folder2",
"path": "test\\folder2"
},
{
"folder_id": "4db39640b3ef4f068b66ead001f5bbd2",
"name": "folder1",
"path": "test\\folder1"
}
],
"new_path": ""
}

Description of request body

Name

Description

folder_id

The GUID of the folder

name

The name of the folder

path

Current folder path

new_path

Path where to move the folder

Request Error

400

Bad Request

Invalid HTTP request

401

Unauthorized

Authentication unauthorized

403

Forbidden

Permission denied

500

Internal Server Error

Server is temporarily unavailable

Response

In case of a successful request status code 200 will be returned and the body of the response can be ignored. This means that the folders have been moved successfully.

Example of a failed request:

{
"message": "The destination folder already contains a folder with the same name",
"ui_message_key": "API_FOLDER_MOVE_DESTINATION_HAS_FOLDER_WITH_SAME_NAME",
"status_code": "BadRequest"
}

Descriptions of response:

status_code

HTTP status code

message

A message describing the error

ui_message_key

A message key that is useful for localization