Sale documents
Add document
Adds a document to a sale. fileName and base64Content are required. Returns 422 for invalid file names, file names longer than 150 characters, or invalid base64 content.
Validation & Requirements
Required Parameters
- saleGuid (path, string, format=guid)
- form (body, object)
Required JSON Body Fields
- base64Content (minLength=1)
- fileName (minLength=1)
Validations
- Invalid GUID values in *Guid/*Guids fields return 422 Unprocessable Entity.
- Invalid date values in *date* fields return 422 Unprocessable Entity.
- Missing required request body returns 422 Unprocessable Entity with Missing request body..
- Additional business-rule validation may return 422 with details in the errors array.
- File name is required and cannot exceed 150 characters.
- base64Content must be valid base64.
Integration Requirement
- Retrieve the corresponding ...Form endpoint immediately before write operations to get current dynamic required fields and allowed values.
post/api/files/sales/{saleGuid}/documents
Path parameters
saleGuidstring guid required
GUID of the sale you want to add the document to.