/files
Heads Up!
This page documents the Advance Access version (think "beta" but with fewer bugs) of the folders functionality.
This call moves a file from one folder to another. Moving of files is only allowed within the same project.
https://api.sb.biodatacatalyst.nhlbi.nih.gov/v2/files/{file_id}/actions/move
Request
Example request
POST /v2/files/{file_id}/actions/move HTTP/1.1
Host: api.sb.biodatacatalyst.nhlbi.nih.gov
X-SBG-Auth-Token: 3259c50e1ac5426ea8f1273259740f74
Content-Type: application/json
X-SBG-advance-access: advance
curl --data '@move.json' -X POST -H "X-SBG-Auth-Token: 6282d5e2121d43e7900e9d52b15845e7" -H "Content-Type: application/json" 'https://api.sb.biodatacatalyst.nhlbi.nih.gov/files'
Header Fields
Name | Description |
---|---|
X-SBG-Auth-Token required | Your authentication token. |
Content-Type required | application/json |
X-SBG-Advance-Access required | advance |
Request body
In the request body, you should enter the following list of key-value pairs:
Name | Data type | Description |
---|---|---|
parent required | String | Specifies the target folder by using its ID. To find out the folder ID, use the List folder contents call for its parent folder. |
name | String | Specifies a new name for a file in case you want to rename it. If you want to use the same name, omit this key. |
Example request body
{
"parent": "57ff702e1c94d72f08ba34e8",
"name": "1000G_omni2.5.hg38.vcf"
}
Response
See a list of response codes that may be contained in the body of the response..