Rename¶
Change the name of a file or a folder.
Request¶
POST https://api.cloudplan.biz/api/folder/rename
{
"node_id":"..." // (string, semi-optional) the node where the file
or folder is stored and the rename should be executed.
When not node id is passed a suitable node will be
determined automatically if possible.
"ff_name":"..." // (string, required) the new name
"ff_id":"..." // (string, required) the id of the item to be renamed
"parent_id": "..." // (string, required for renaming files) parent folder id
of the item to be renamed
"is_file": true/false // (bool, required for renaming files) set true when
renaming files
}
Note: either node_id or parent_id have to be submitted.
Reply¶
{
"result": true/false
"reason": any of the error codes below
}
Error Codes¶
ff_id_empty
ff_name_empty
no_parent_id_and_no_node_id
no_node_syncing_folder
user_not_found
ff_name_already_exists
timeout_db
file_not_found
file_is_broken
error codes from :doc:`api/user/login`