POST api/GetShipments_V1
Get shipments ussing different filters GetShipmentType have the following types ByIds, ByDate, ByCarrierId, ByTrackingNumber, ByReference, ByOrderNumber
Request Information
URI Parameters
None.
Body Parameters
The request is presented below!
WS_Repository.Models.Requests.Ship.GetShipmentsRequest| Name | Description | Type | Additional information |
|---|---|---|---|
| WS_Key |
(Mandatory) Webservice Key provided by 2ship support |
string |
None. |
| ShipmentIds |
get by ShipmentId - Array of Shipment Id |
Collection of integer |
None. |
| DateStart |
get by date - DateStart |
date |
None. |
| DateEnd |
get by date - DateEnd |
date |
None. |
| Type |
(Mandatory) Type of the GetShipmentsRequest |
WS_Repository.Models.Requests.Ship.GetShipmentType |
None. |
| CarrierId |
get by Carrier Id |
integer |
None. |
| TrackingNumber |
TrackingNumber |
string |
None. |
| Reference |
get by Reference |
string |
None. |
| PONumber |
get by PO Number |
string |
None. |
| OrderNumber |
get by OrderNumber |
string |
None. |
| RetrieveBase64StringDocuments |
Use to get in the response also the documents in Base64String format |
boolean |
None. |
Request Formats
application/json, text/json
{
"WS_Key": "sample string 1",
"ShipmentIds": [
1,
2
],
"DateStart": "2025-12-14T10:51:11.8288305Z",
"DateEnd": "2025-12-14T10:51:11.8288305Z",
"Type": 0,
"CarrierId": 4,
"TrackingNumber": "sample string 5",
"Reference": "sample string 6",
"PONumber": "sample string 7",
"OrderNumber": "sample string 8",
"RetrieveBase64StringDocuments": true
}
application/xml, text/xml
<GetShipmentsRequest xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/WS_Repository.Models.Requests.Ship">
<CarrierId>4</CarrierId>
<DateEnd>2025-12-14T10:51:11.8288305Z</DateEnd>
<DateStart>2025-12-14T10:51:11.8288305Z</DateStart>
<OrderNumber>sample string 8</OrderNumber>
<PONumber>sample string 7</PONumber>
<Reference>sample string 6</Reference>
<RetrieveBase64StringDocuments>true</RetrieveBase64StringDocuments>
<ShipmentIds xmlns:d2p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
<d2p1:int>1</d2p1:int>
<d2p1:int>2</d2p1:int>
</ShipmentIds>
<TrackingNumber>sample string 5</TrackingNumber>
<Type>ByIds</Type>
<WS_Key>sample string 1</WS_Key>
</GetShipmentsRequest>
application/x-www-form-urlencoded
Response Information
Resource Description
Collection of WS_Repository.Models.Responses.Ship.CarrierShipResponse| Name | Description | Type | Additional information |
|---|---|---|---|
| ShipDocuments |
Array of Ship Documents |
Collection of WS_Repository.Models.Responses.Ship.ShipDocument |
None. |
| ShipId |
Internal 2ship Shipment Id |
integer |
None. |
| OrderNumber |
Order number, optional, assigned by callers on the request |
string |
None. |
| CloseAggregationId |
Specify if the shipment is aggregated with other shipments at close transaction - the close aggregation id represent the firstshipment id from the group of aggregated shipments - Used on GetShipments transaction |
integer |
None. |
| Service |
Rate Service |
WS_Repository.Models.Responses.Rate.RateService |
None. |
| Carrier |
Rate Service |
WS_Repository.Models.Responses.Rate.Carrier |
None. |
| LocationId |
2Ship Location Id |
integer |
None. |
| LocationName |
2Ship Location Name |
string |
None. |
| ProNumber |
Pro Number - will be populated when the carrier is LTL and was shipped with a Pro Number |
string |
None. |
| TrackingNumber |
Carrier Master TrackingNumber of the shipment |
string |
None. |
| TrackingUrl |
2Ship Tracking Url |
string |
None. |
| AirwayBillNumber |
Carrier Airway Bill Number of the shipment (not used by all carriers) |
string |
None. |
| PackageTrackingNumbers |
Carrier Package TrackingNumbers of the shipment |
Collection of string |
None. |
| ShipmentDetails |
Details of the shipment |
WS_Repository.Models.Responses.Ship.ShipmentDetails |
None. |
| ExchangeRate |
Exchange Rate object available if the RateCurrencySelect is specify on the ship request |
WS_Repository.Models.Responses.Ship.ExchangeRate |
None. |
| MycarrierDetails |
when the carrier is My Carrier(999) here are populated your carrier info |
WS_Repository.Models.Responses.Ship.MyCarrierDetails |
None. |
| Status |
The current status of the shipment (returned only from GetChanges ws call): Shipped, Deleted, Closed, DeletedOnHold, Imported |
string |
None. |
| StatusTimestamp |
The timestamp when the shipment changed to the given status (returned only from GetChanges ws call) |
string |
None. |
| QRCodeValue |
QR Code Value |
string |
None. |
| QRCodeImageURL |
QR Code Image URL |
string |
None. |
| ClientId |
ClientId of Client created the shipment |
integer |
None. |
| ExternalClientID |
External client ID |
string |
None. |
| UserId |
UserId of user created the shipment |
integer |
None. |
| UserName |
User name of user created the shipment |
string |
None. |
| WebsiteUrl |
(Only available on ShipmentStatusChange webhooks at ship/delete) WebsiteUrl |
string |
None. |
| OriginHubCode |
Origin Hub/Airport Code |
string |
None. |
| DestinationHubCode |
Origin Hub/Airport Code |
string |
None. |
| InternalNotes |
Internal notes |
string |
None. |
| ShipWithoutPrinterMessage |
(Optional) Use this filter to find the Carrier services that allow you to ship without the need for a printed label |
string |
None. |
| WebhookType |
Webhook Type |
string |
None. |