Upload a document for a load

Upload a document associated with a specific load. The file content must be base64-encoded and accompanied by an MD5 checksum for integrity verification.

Supported file types: .pdf, .jpg/.jpeg, .png, .heic, .webp, .tiff/.tif.

When uploading an invoice (fileType: INVOICE), the referenceNumbers.invoiceNumber field is required.

Body
required
application/json
  • checksum
    Type: string
    required

    MD5 hex digest of the raw (pre-encoding) file bytes, used for integrity verification

  • content
    Type: string
    required

    Base64-encoded file bytes

  • contentType
    Type: string
    required

    MIME type of the file. Supported values: application/pdf, image/jpeg, image/png, image/heic, image/webp, image/tiff

  • filename
    Type: string
    required

    Original filename including extension. Supported extensions: .pdf, .jpg, .jpeg, .png, .heic, .webp, .tiff, .tif

  • fileType
    enum
    const:  
    INVOICE
    required

    The category of the document being uploaded

    values
    • INVOICE
  • loadNum
    Type: string
    required

    The load's external number in the TMS (brokerageLoadId)

  • sizeBytes
    Type: integer
    required

    File size in bytes

  • referenceNumbers
    Type: object · LoadFileUploadReferenceNumbers
Responses
  • application/json
  • application/json
Request Example for post/callback/upload-document
curl https://api.prod.goaugment.com/callback/upload-document \
  --request POST \
  --header 'Content-Type: application/json' \
  --header 'Authorization: Basic username:password' \
  --data '{
  "loadNum": "",
  "filename": "invoice-1234.pdf",
  "fileType": "INVOICE",
  "contentType": "application/pdf",
  "content": "",
  "sizeBytes": 1,
  "checksum": "",
  "referenceNumbers": {
    "invoiceNumber": ""
  }
}'
{
  "summary": {
    "total": 1,
    "succeeded": 1,
    "failed": 1
  },
  "results": [
    {
      "filename": "string",
      "success": true,
      "data": {
        "size": 1,
        "contentType": "string",
        "id": "string"
      }
    }
  ]
}