Description
Sends a file, folder, or collection of files and folders.
URL
All responses are in JSON format by default, to specify an XML response add ".xml" to the end of the method name (in this case "file_send")
https://<yoursubdomain>.filetransfers.net/api/file_send
Restrictions
The calling user must have:
- Access to the file's location.
- Send permissions in the file's location.
Parameters
Bold indicates required
Parameter | Description |
---|---|
file_id | The ID of the file or folder being sent. Send multiple files/folders by using a comma-separated list. File IDs can be retrieved from file_list. |
user_ids | The ID of the user being sent the files. Send to multiple users by using a comma-separated list. User IDs can be retrieved from user_location_access. Invalid user IDs (IDs that do not exist on the site or do not have permissions to all of the files will be ignored. |
user_group_ids | The ID of the user group being sent the files. Send to multiple user groups by using a comma-separated list. User group IDs can be retrieved from user_location_access. Invalid user group IDs (IDs that do not have permissions to all of the files will be ignored. |
non_users | Comma-separated list of non-user email addresses. If the sender does not have permissions to send files to non-users in the location of the file they are sending this field will be nullified. |
download_receipt | Default is 0, 1 means the sender will receive an email notification the first time each recipient downloads the file. |
require_login | Default is 0, 1 means recipients will be forced to log in in order to download the file. Any values set in non_users will be nullified if this value is set to 1. |
link_expiration | Default (and maximum allowed valued) is 15 days for links in the notification to expire. Please note that link expiration does not mean the file will expire, only that the link in the notification will no longer work after the entered number of days. Use 0 for the notification link never to expire. |
bcc | Default is 0, if 1 all recipients will be BCC'd |
subject | An optional subject for the notification email |
message | An optional message to be included in the notification email |
api_key | Your API Key. |
timestamp | The current time in Unix timestamp format. |
signature | Please see "User Authentication" for more information. |
Sample Response
Successful response In JSON:
{"fileInfo":{"fileId":1071266,"path":"\/","fileName":"recording.aiff"}}
Successful response in XML:
<fileInfo> <fileId>1071267</fileId> <path>/</path> <fileName>image.png</fileName> </fileInfo>
Error response In JSON:
{"error":{"title":"You do not have access privileges for this location","message":"Please try a different location or speak to an administrator."}}
Error response In XML:
<error> <title>You do not have access privileges for this location</title> <message>Please try a different location or speak to an administrator.</message> </error>