Send file by email
A request to export file.
POST /api/v1/files/{fileId}/email HTTP/1.1
- Path parameters
| Parameter | Description |
|---|---|
fileId | The ID of the file. |
- Request parameters
| Parameter | Description |
|---|---|
recipient | Array with recipient emails |
userMessage | User message to add in email. |
attachFile | Attach file itself or send link to the file instead. |
mediaType | Attachment mediaType ( See exportFormats[].targets[] array at Authenticate user through FS service for mobile ) [Since 2018.01] |
- Example request
curl 'http://localhost:8080/api/v1/files/189409595/email' -i -X POST \
-H 'X-co-auth-token: 157eb0031e3b1954ea3d73dca0e96964' \
-d 'recipient=%5B%22testsrvdocs2%40tacos.devoffice.ru%22%5D&userMessage=Here%27s+the+file+you+asked+for&attachFile=true&mediaType=application%2Fvnd.oasis.opendocument.text'
- Example response
HTTP/1.1 204 No Content
X-co-request-id: 67664574556351394872585153513930