/documents

Create a document and one or more links with deferred uploading. The document is created immediately with uploadStatus='inUpload' and a presigned uploadUrl is returned. After S3 ObjectCreated, uploadStatus becomes 'completed' and fileType/fileSize are automatically detected from the uploaded file. A cleanup job deletes 'inUpload' documents after ~12 hours (TTL). Links are automatically propagated along the OST chain (order-shipment-tour); do not manually duplicate links across the chain.

Access Rules:

  • If no accessRules are provided, all visibility fields default to 'visible' (shipperVisibility, operatorVisibility, carrierVisibility).

Slot context rules:

  • For shipment + ('proof'|'stop_document'): provide slotContext.stopType = 'pickup' | 'dropoff'.
  • For tour + ('proof'|'stop_document'): provide slotContext.stopIndex (0-based).
  • For slotType 'property': provide slotContext.propertyId (required). The system will automatically set the target entity's property value to the created DocumentLink ID (only for supported entity types).
  • For slotType 'general': no slotContext allowed

Restrictions:

  • Property links via External API are only allowed for entity types that actually support properties per schema (e.g., shipment, tour, order, carrier, carrier-user, carrier-team, vehicle, shipper, shipper-team, shipper-user, shipper-address, contact, loading-point, operator-team, operator-user).
  • Deprecated or internal types (e.g., driver, api-key, automation, transport-draft, decode-job, orbit-shop, mailbox, magic-inbox) are blocked for documents with slotType='property'.
Language
Credentials
Header
URL
Click Try It! to start a request and see the response here!