5. Complete Group Transfer
Description |
This API completes a file upload session where the file can be uploaded in chunks. |
URL Path |
/transfer |
Method |
POST |
Permissions Restrictions
The API is limited to the user roles listed above (i.e. CO, Administrator, User), but assuming that a valid set of parameters is provided, including a group_id, only the transfer owner will be able alter the transfer.
Example:
The user test1 initiates a group transfer (i.e. calls /transfer successfully) and it receives a transfer group ID - group_id.
The user test2 tries to append a file to transfer with ID group_id. A 403 - Forbidden error will be returned stating that the user that has made the request is not authorized to alter the transfer.
The user test1 tries to append a file to the transfer - operation successful.
The user test1 completes the transfer by calling POST /transfer - operation successful.
Transfer with ID group_id will be accessible to the user until its expiration date.
HTTP header parameters
Authorization |
The API key of the caller |
REQUIRED |
This header should have the following format: |
group_id |
Transfer group ID |
REQUIRED |
A transfer group id obtained from the Initialize Group Transfer call. |
expires_after |
Expiration for each file in this transfer |
OPTIONAL |
Specify in DD:HH:MM:SS. Cannot be combined with 'expires' property. The value ranges are the following: -
Days, ranging from 0 to 10675199; |
Request Codes
200 |
OK |
Successful request |
400 |
Bad Request |
Invalid HTTP request |
401 |
Invalid parameter |
An invalid header parameter was specified |
403 |
Forbidden |
Authentication credentials incorrect |
500 |
Internal Server Error |
Server is temporarily unavailable |
Response
Example of a successful request:
{
"files"
: [
{
"file_id"
:
"e351401338b1420a9b56f32714b8804f"
,
"file_url"
:
"http:\/\/server:8000\/vault_rest\/file\/e351401338b1420a9b56f32714b8804f"
,
"folder_url"
:
"http:\/\/server:8010\/files\/personal\/folder\/845fc3013bf049308148028bb606c4d9"
,
"group_id"
:
"89e9b717ebc34c27b39b543aa96270c3"
,
"status_url"
:
"http:\/\/server:8000\/vault_rest\/file\/status\/e351401338b1420a9b56f32714b8804f"
,
"web_url"
:
"http:\/\/server:8010\/file\/e351401338b1420a9b56f32714b8804f"
}
]
}
Descriptions of response:
files.file_Id |
The ID of the file |
Use this ID when calling other REST APIs |
files.group_id |
The ID of the group |
Use this ID when calling other REST APIs |
files.file_url |
URL of the file |
Use this link to download the file (via REST) |
files.web_url |
URL of the file (Web) |
Use this link to download the file via a web browser |
files.status_url |
URL for file status |
Use this link to get the file status in (via REST) |
files.folder_url |
URL of the file's folder |
Use this link to navigate to the file's folder in the browser |