Ongoing WMS logo

Ongoing WMS Developer

UploadShipmentFile

This function allows you to attach files to shipments.

A possible use-case for this is if there are documents which you want the warehouse to print and send along with an consolidated shipment. You can use this function to attach the documents to the shipment. The warehouse can then print the documents when required.

Tags: UploadShipmentFile, ShipmentFile, File, UploadShipmentFileResult

Request XML

POST /xxx/Automation.asmx HTTP/1.1
Host: api.ongoingsystems.se
Content-Type: text/xml; charset=utf-8
Content-Length: length
SOAPAction: "http://ongoingsystems.se/Automation/UploadShipmentFile"

<?xml version="1.0" encoding="utf-8" ?>
<soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
   <soap:Body>
      <UploadShipmentFile xmlns="http://ongoingsystems.se/Automation">
         <UserName>string</UserName>
         <Password>string</Password>
         <ShipmentFile>
            <File>
               <FileName>string</FileName>
               <FileBytes>base64Binary</FileBytes>
               <MimeType>string</MimeType>
               <FileId>int</FileId>
            </File>
            <ShipmentId>int</ShipmentId>
         </ShipmentFile>
      </UploadShipmentFile>
   </soap:Body>
</soap:Envelope>
+

Request specification

UploadShipmentFile
UserName str(50) Req. Your username
Password str(50) Req. Your password
ShipmentFile object Req. An element of type ShipmentFile.
ShipmentFile
File object Req. An element of type File.
ShipmentId int Req. Ongoing WMS internal shipment id.
File
FileName str(300) Req. Filename. Note that if you try to attach two files to the same shipment, then the two files must have different filenames. When comparing filenames, the system does a case-insensitive comparison.
FileBytes base64Binary Req. The contents of the file, encoded using Base64.
MimeType str(50) Req. The MIME type of the file, specifying what kind of file it is.
FileId int Req. Should always be the fixed value -1.

Response XML

HTTP/1.1 200 OK
Content-Type: text/xml; charset=utf-8
Content-Length: length

<?xml version="1.0" encoding="utf-8" ?>
<soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
   <soap:Body>
      <UploadShipmentFileResponse xmlns="http://ongoingsystems.se/Automation">
         <UploadShipmentFileResult>
            <Success>bool</Success>
            <Message>string</Message>
            <ShipmentId>int</ShipmentId>
            <FileId>int</FileId>
         </UploadShipmentFileResult>
      </UploadShipmentFileResponse>
   </soap:Body>
</soap:Envelope>
+

Response specification

UploadShipmentFileResult
Success bool true if successful, false otherwise.
Message str(*) Error message, if the call was unsuccessful.
ShipmentId int Ongoing WMS internal id of the shipment.
FileId int Ongoing WMS internal id of the file.