project.addFile
Copies a file uploaded with file.upload into persistent project storage and attaches it to the project so it is available to all tasks in that project. Each project holds at most 199 resources (files and web links combined). The source file_id is not consumed.
Upload flow
- Call file.upload with the file’s name, then
PUTthe file bytes to the returnedupload_url. - After the
PUTcompletes, callproject.addFilewithproject_idand the returnedfile.id. Passfilenameonly if you want to override the display name stored in the project.
file.upload expiration window. The source file_id is not consumed: it expires on its normal schedule, and deleting it with file.delete does not affect the project file.
Limits and rules
- File size and type: Inherits file.upload limits (up to 512 MB; executable and script extensions are prohibited). Any overridden
filenamemust be 1–255 characters, include an allowed file extension, and must not contain path separators (/,\),?,#, or control characters. - Project resource limit: Each project holds at most 199 resources in total (files and web links combined). Exceeding the cap returns
429 resource_exhausted. - Web links: This endpoint attaches files only; managing project web links is not supported via OpenAPI.
Errors
Headers
API key for direct authentication. Provide either this or Authorization, not both. See Authentication.
OAuth2 access token in Bearer {token} format. An OAuth client requires the manage_all_tasks scope unless it is a Trusted team client or Trusted public client; create_project alone is not sufficient. Provide either this or x-manus-api-key, not both. See the Open App guide.
"Bearer {access_token}"
Body
The unique identifier of the target project. Use project.list to get project IDs.
1 - 65ID of a file uploaded with file.upload. The file must belong to the authenticated user and have status uploaded.
1 - 64