Skip to main content

Endpoint

Authentication

This endpoint requires an OAuth access token. Send it as a bearer token:
Required scope: tasks:write
The version is uploaded as the access token’s user. The user_email field on the request body is ignored.

Path Parameters

Request Body

The request body must be a JSON object with the following fields:

Required Fields

Optional Fields

File Object Fields

Provide exactly one upload mode:
  • New version of an existing document - provide file_uuid and leave new_document_to_negotiate as false.
  • New negotiation document - set new_document_to_negotiate to true and omit file_uuid.
Providing both, or neither, returns a 422 Validation Error.

Request Example

Response

Success Response

Status Code: 200 OK

Response Fields

Error Responses

400 Bad Request

Returned when the access token has no user behind it. client_credentials tokens act as the admin who created the application, so this applies only to tokens issued before application creators were recorded.

401 Unauthorized

Returned when the access token is missing, unknown, revoked, or expired, or when an X-API-Key was sent instead of a bearer token. See OAuth error responses.

403 Forbidden

Returned when the token lacks the required scope:
Or when the user may not act on this task:

404 Not Found

Returned when the task does not exist.

409 Conflict

Returned when the task is not at a negotiation step or the upload conflicts with the current step state.

422 Validation Error

Returned when the request body is invalid, including when neither file_uuid nor new_document_to_negotiate is provided, or when both are provided.

429 Too Many Requests

Returned when your organization exceeds its per-minute request limit.

500 Internal Server Error

Returned when the upload fails due to a server error.

Notes

To find the file_uuid of an existing negotiation document, call Get Latest Negotiation Versions and reuse the returned file_uuid.
Set uploading_party to reflect who produced this version. It feeds the our_party_changes flag and helps track negotiation turn order.
The presigned download URL expires after a certain time (indicated by expires_at). Download the file before the URL expires or request it again.

Use Cases

This endpoint is useful for:
  • Round-trip negotiation - Upload counterparty redlines or your own revisions as new versions
  • External drafting tools - Push documents edited outside Chamelio back into the negotiation thread
  • New document negotiation - Start a fresh negotiation document on a step with new_document_to_negotiate
  • Attributed revisions - Record which user contributed each version