POST api/ListOnHoldOrders_V1

Get the list of onhold orders in 2ship

Request Information

URI Parameters

None.

Body Parameters

The request is presented below!

WS_Repository.Models.Requests.Hold.ListOnHoldRequest
NameDescriptionTypeAdditional information
WS_Key

(Mandatory) Webservice Key provided by 2ship support

string

None.

FilterByCarriersID

(Optional) if specified it returns only orders with that particular carriers id

Collection of integer

None.

FromTransactionDate

(Optional) if specified it returns only orders starting from that particular date and time

date

None.

ToTransactionDate

(Optional) if specified it returns only orders to that particular date and time

date

None.

FilterByOnHoldStatuses

(Optional) if specified it returns only orders with that particular OnHold statuses

Collection of integer

None.

IncludeOrderDetails

(Optional) if specified it returns the order details in response

boolean

None.

Page

integer

None.

PageSize

integer

None.

Request Formats

application/json, text/json

Sample:
{
  "WS_Key": "sample string 1",
  "FilterByCarriersID": [
    1,
    2
  ],
  "FromTransactionDate": "2025-12-14T10:52:02.8801057-05:00",
  "ToTransactionDate": "2025-12-14T10:52:02.8801057-05:00",
  "FilterByOnHoldStatuses": [
    1,
    2
  ],
  "IncludeOrderDetails": true,
  "Page": 2,
  "PageSize": 3
}

application/xml, text/xml

Sample:
<ListOnHoldRequest xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/WS_Repository.Models.Requests.Hold">
  <FilterByCarriersID xmlns:d2p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
    <d2p1:int>1</d2p1:int>
    <d2p1:int>2</d2p1:int>
  </FilterByCarriersID>
  <FilterByOnHoldStatuses xmlns:d2p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
    <d2p1:int>1</d2p1:int>
    <d2p1:int>2</d2p1:int>
  </FilterByOnHoldStatuses>
  <FromTransactionDate>2025-12-14T10:52:02.8801057-05:00</FromTransactionDate>
  <IncludeOrderDetails>true</IncludeOrderDetails>
  <Page>2</Page>
  <PageSize>3</PageSize>
  <ToTransactionDate>2025-12-14T10:52:02.8801057-05:00</ToTransactionDate>
  <WS_Key>sample string 1</WS_Key>
</ListOnHoldRequest>

application/x-www-form-urlencoded

Sample:

Failed to generate the sample for media type 'application/x-www-form-urlencoded'. Cannot use formatter 'System.Web.Http.ModelBinding.JQueryMvcFormUrlEncodedFormatter' to write type 'WS_Repository.Models.Requests.Hold.ListOnHoldRequest'.

Response Information

Resource Description

WS_Repository.Models.Responses.Hold.ListOnHoldResponse
NameDescriptionTypeAdditional information
HasMore

boolean

None.

Page

integer

None.

PageSize

integer

None.

Count

integer

None.

OnHoldOrders

List of all onhold orders returned

Collection of WS_Repository.Models.Responses.Hold.OnHoldOrder

None.

Response Formats

application/json

Sample:

An exception has occurred while using the formatter 'System.Net.Http.Formatting.JsonMediaTypeFormatter' to generate sample for media type 'application/json'. Exception message: Self referencing loop detected with type 'WS_Repository.Models.Responses.Ship.Commodity'. Path 'OnHoldOrders[0].OrderDetails.Contents.Commodities[0].BundleComponents'.

text/json

Sample:

An exception has occurred while using the formatter 'System.Net.Http.Formatting.JsonMediaTypeFormatter' to generate sample for media type 'text/json'. Exception message: Self referencing loop detected with type 'WS_Repository.Models.Responses.Ship.Commodity'. Path 'OnHoldOrders[0].OrderDetails.Contents.Commodities[0].BundleComponents'.

application/xml

Sample:

An exception has occurred while using the formatter 'System.Net.Http.Formatting.XmlMediaTypeFormatter' to generate sample for media type 'application/xml'. Exception message: Object graph for type 'System.Collections.Generic.List`1[[WS_Repository.Models.Responses.Ship.Commodity, WS_Repository.Models, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null]]' contains cycles and cannot be serialized if reference tracking is disabled.

text/xml

Sample:

An exception has occurred while using the formatter 'System.Net.Http.Formatting.XmlMediaTypeFormatter' to generate sample for media type 'text/xml'. Exception message: Object graph for type 'System.Collections.Generic.List`1[[WS_Repository.Models.Responses.Ship.Commodity, WS_Repository.Models, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null]]' contains cycles and cannot be serialized if reference tracking is disabled.