POST api/UploadOrderDocuments_V1
Add Order Documents
Request Information
URI Parameters
None.
Body Parameters
The request is presented below!
WS_Repository.Models.Requests.Hold.UploadOrderDocumentsRequestName | Description | Type | Additional information |
---|---|---|---|
WS_Key |
(Mandatory) Webservice Key provided by 2ship support |
string |
None. |
OrderNumber |
(Optional) Mandatory if FindBy = ByOrderNumber |
string |
None. |
ShipmentId |
(Optional) Mandatory if FindBy = ByShipmentId |
integer |
None. |
FindBy |
(Mandatory) this element is desired to know how to lookup the onhold order that you wish to update |
WS_Repository.Models.Requests.Hold.FindOrderType |
None. |
UploadDocumentsInfo |
(Optional) if missing it will remove all Documents Attached to the order |
WS_Repository.Models.Requests.Hold.UploadDocumentsInfo |
None. |
Request Formats
application/json, text/json
Sample:
{ "WS_Key": "sample string 1", "OrderNumber": "sample string 2", "ShipmentId": 3, "FindBy": 0, "UploadDocumentsInfo": { "ListOfDocuments": [ { "DocumentName": "sample string 1", "DocumentBytes": "QEA=", "DocumentType": 0 }, { "DocumentName": "sample string 1", "DocumentBytes": "QEA=", "DocumentType": 0 } ] } }
application/xml, text/xml
Sample:
<UploadOrderDocumentsRequest xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/WS_Repository.Models.Requests.Hold"> <FindBy>ByShipmentId</FindBy> <OrderNumber>sample string 2</OrderNumber> <ShipmentId>3</ShipmentId> <UploadDocumentsInfo> <ListOfDocuments> <DocumentToUpload> <DocumentBytes>QEA=</DocumentBytes> <DocumentName>sample string 1</DocumentName> <DocumentType>OtherDocument</DocumentType> </DocumentToUpload> <DocumentToUpload> <DocumentBytes>QEA=</DocumentBytes> <DocumentName>sample string 1</DocumentName> <DocumentType>OtherDocument</DocumentType> </DocumentToUpload> </ListOfDocuments> </UploadDocumentsInfo> <WS_Key>sample string 1</WS_Key> </UploadOrderDocumentsRequest>
application/x-www-form-urlencoded
Sample:
Response Information
Resource Description
WS_Repository.Models.Responses.Hold.UploadOrderDocumentsResponseName | Description | Type | Additional information |
---|---|---|---|
Success |
specify if the order documents were uploaded or not |
boolean |
None. |
Error |
Error message |
string |
None. |
Response Formats
application/json, text/json
Sample:
{ "Success": true, "Error": "sample string 2" }
application/xml, text/xml
Sample:
<UploadOrderDocumentsResponse xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/WS_Repository.Models.Responses.Hold"> <Error>sample string 2</Error> <Success>true</Success> </UploadOrderDocumentsResponse>