SupportDeveloper ForumLogin
  • Overview
    • Introduction
    • Getting Started
    • Authentication
    • Error Handling
    • Pagination
    • Filtering
    • Ordering
    • Rate Limits
    • Permissions
    • Webhooks
    • MCP Server
    • Versioning
    • Changelog
    • Support
  • API v1 Reference
    • Projects Overview
    • Tasks Overview
    • Time Tracking Overview
    • Documents Overview
    • Search Overview
    • Companies Overview
    • Users Overview
    • Files & Images Overview
    • Custom Fields Overview
    • Workload & Planning Overview
    • Project Templates Overview
    • Login & Access Overview
    • API Management Overview
LogoLogo
SupportDeveloper ForumLogin
API v1 ReferenceDocument Files

POST
https://api.awork.com/api/v1/documents/:documentId/files/byurl
POST
/api/v1/documents/:documentId/files/byurl
1curl -X POST https://api.awork.com/api/v1/documents/documentId/files/byurl \
2 -H "Authorization: Bearer <token>" \
3 -H "Content-Type: application/json" \
4 -d '{}'
Try it
200Successful
1{
2 "name": "Final project report",
3 "description": "The client requested a cost overview and timeline",
4 "id": "123e4567-e89b-12d3-a456-426614174000",
5 "entityId": "123e4567-e89b-12d3-a456-426614174000",
6 "fileName": "Final project report.xlsx",
7 "entityType": "project",
8 "mimeType": "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet",
9 "createdOn": "2024-01-15T09:30:00Z",
10 "createdBy": "123e4567-e89b-12d3-a456-426614174000",
11 "updatedOn": "2024-01-15T09:30:00Z",
12 "updatedBy": "123e4567-e89b-12d3-a456-426614174000",
13 "fileVersions": [
14 {
15 "id": "123e4567-e89b-12d3-a456-426614174000",
16 "fileInfoId": "123e4567-e89b-12d3-a456-426614174000",
17 "version": 13,
18 "size": 13590,
19 "width": 1920,
20 "height": 1200,
21 "createdOn": "2024-01-15T09:30:00Z",
22 "createdBy": "123e4567-e89b-12d3-a456-426614174000",
23 "updatedOn": "2024-01-15T09:30:00Z",
24 "updatedBy": "123e4567-e89b-12d3-a456-426614174000"
25 }
26 ],
27 "isCommentFile": false,
28 "externalProvider": "string",
29 "externalFileUrl": "string",
30 "isHiddenForConnectUsers": true
31}
Was this page helpful?
Previous

Returns the file with the specified id of the document with the specified id.

Next
Built with
The file needs to be a public available url. The file size must not exceed 100MB.
Uploads a new file by providing an url.

Authentication

AuthorizationBearer

Bearer authentication of the form Bearer <token>, where token is your auth token.

OR
AuthorizationBearer

Bearer authentication of the form Bearer <token>, where token is your auth token.

Path Parameters

documentIdstringRequiredformat: "uuid"
The id of the document the file is linked to.

Request

The url, name and description of the file.
urlstring or nullOptional
The public url to the file.
namestring or nullOptional
The name of the file.
descriptionstring or nullOptional
The description of the file.

Response

OK
namestring or null

The user-specified name of the file.

descriptionstring or null
The description of the file.
idstring or nullformat: "uuid"
The id of the file info.
entityIdstring or nullformat: "uuid"
The id of the linked entity.
fileNamestring or null
The name of the file.
entityTypestring or null
The name of the linked entity type.
mimeTypestring or null
The MIME type of the file.
createdOnstring or nullformat: "date-time"
The date this file was created.
createdBystring or nullformat: "uuid"
The id of the user who created this file.
updatedOnstring or nullformat: "date-time"
The date this file was last modified.
updatedBystring or nullformat: "uuid"
The id of the user who last modified this file.
fileVersionslist of objects or null
List of all versions.
isCommentFileboolean or null
Whether the file is related to a comment.
externalProviderstring or null
The external provider for the file. Like 'google' or 'onedrive'.
externalFileUrlstring or null
The file url of the external provider.
isHiddenForConnectUsersboolean or null
Whether the file is hidden for connect users.
OK