POST v1/Orders/{orderId}/Rows
Adds the specified order row.
Request Information
URI Parameters
| Name | Description | Type | Additional information |
|---|---|---|---|
| orderId |
The order identifier. |
integer |
Required. |
Body Parameters
The order Row.
OrderRow| Name | Description | Type | Additional information |
|---|---|---|---|
| Id |
Gets or sets the identifier. |
integer |
Must be 0 (for insert operations) |
| ProductSelectionProductId |
Gets or sets the product selection product identifier. |
integer |
None. |
| ProductId |
Gets the product ID of the selected Product. |
integer |
None. |
| OrderRowKey |
Gets or sets the order row key. |
string |
Max length: 50 |
| ItemQuantity |
Gets or sets the item quantity. When a credit is made, the value must be smaller than 0. |
decimal number |
Required |
| ProductName |
Gets or sets the name of the product. |
string |
Max length: 500 |
| ProductCode |
Gets or sets the product code. |
string |
Required Max length: 100 |
| ProductDescription |
Gets or sets the product description. |
string |
Max length: 2147483647 |
| ItemPriceExVat |
Gets or sets the item price (exclude VAT). |
decimal number |
Required |
| ItemPriceIncVat |
Gets or sets the item price (include VAT). |
decimal number |
Required |
| ItemDiscountExVat |
Gets or sets the item discount (exclude VAT). ItemDiscount takes precedence on RowDiscount. |
decimal number |
Required |
| ItemDiscountIncVat |
Gets or sets the item discount (include VAT). ItemDiscount takes precedence on RowDiscount. |
decimal number |
Required |
| RowDiscountExVat |
Gets or sets the row discount (exclude VAT). ItemDiscount takes precedence on RowDiscount. |
decimal number |
Required |
| RowDiscountIncVat |
Gets or sets the row discount (include VAT). ItemDiscount takes precedence on RowDiscount. |
decimal number |
Required |
| Vatperc |
Gets or sets the VAT percent. |
decimal number |
Required |
| VATTariffId |
Gets or sets the vat tariff identifier. |
integer |
None. |
| VATTariffCode |
Gets or sets the vat tariff code. |
string |
None. |
| RowTotalExVat |
Gets or sets the row total (exclude VAT). |
decimal number |
Required |
| RowTotalIncVat |
Gets or sets the row total (include VAT). |
decimal number |
Required |
| Comment |
Gets or sets the comment. |
string |
Max length: 2147483647 |
| SupplierId |
Gets or sets the supplier identifier. |
integer |
None. |
| ItemPurchasePrice |
Gets or sets the item purchase price. |
decimal number |
None. |
| CreditForOrderRowId |
When adding a credit row, optionally reference to an existing OrderRow. |
integer |
None. |
| Sequence |
The display sequence. If not specified ShopCtrl will determine the sequence. |
integer |
Required |
| ShopProductUrl |
Optionally specify the url to the product page on the Shop. |
string |
Max length: 200 |
| ShopProductImageUrl |
Optionally specify the url to the product image. When not provided, ShopCtrl will use the image as defined with the ShopCtrl Product. |
string |
Max length: 200 |
| ShipmentId |
Gets the Shipment identifier by which the row is fulfilled. |
integer |
None. |
| StockStatus |
Gets the stock status. |
StockStatusEnum |
None. |
| IsAllocated |
Indicates if the orderrow is allocated |
boolean |
None. |
| WarehouseId |
Gets the WarehouseId |
integer |
None. |
| WarehouseSelectionMethod |
Gets the method on which warehouse is assigned. 'Automatic' means ShopCtrl decides which warehouse is used. When 'Manual' is set, a warehouse is pre-selected. |
WarehouseSelectionMethodEnum |
None. |
| Params |
Gets or sets the parameters. |
Collection of OrderRowParameter |
None. |
| DisableRecalculate |
Gets or sets the DisableRecalculate option on OrderRows. |
boolean |
Required |
Request Formats
application/json, text/json
{
"Id": 1,
"ProductSelectionProductId": 1,
"ProductId": null,
"OrderRowKey": "sample string 2",
"ItemQuantity": 3.0,
"ProductName": "sample string 4",
"ProductCode": "sample string 5",
"ProductDescription": "sample string 6",
"ItemPriceExVat": 7.0,
"ItemPriceIncVat": 8.0,
"ItemDiscountExVat": 9.0,
"ItemDiscountIncVat": 10.0,
"RowDiscountExVat": 11.0,
"RowDiscountIncVat": 12.0,
"Vatperc": 1.0,
"VATTariffId": 1,
"VATTariffCode": "sample string 13",
"RowTotalExVat": 14.0,
"RowTotalIncVat": 15.0,
"Comment": "sample string 16",
"SupplierId": 1,
"ItemPurchasePrice": 1.0,
"CreditForOrderRowId": 1,
"Sequence": 1,
"ShopProductUrl": "sample string 17",
"ShopProductImageUrl": "sample string 18",
"ShipmentId": 1,
"StockStatus": 0,
"IsAllocated": true,
"WarehouseId": 1,
"WarehouseSelectionMethod": 0,
"Params": [
{
"Key": "sample string 1",
"Value": "sample string 2",
"DataType": 0,
"DataTypeName": "String"
},
{
"Key": "sample string 1",
"Value": "sample string 2",
"DataType": 0,
"DataTypeName": "String"
}
],
"DisableRecalculate": true
}
application/xml, text/xml
<OrderRow xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<Id>1</Id>
<ProductSelectionProductId>1</ProductSelectionProductId>
<OrderRowKey>sample string 2</OrderRowKey>
<ItemQuantity>3</ItemQuantity>
<ProductName>sample string 4</ProductName>
<ProductCode>sample string 5</ProductCode>
<ProductDescription>sample string 6</ProductDescription>
<ItemPriceExVat>7</ItemPriceExVat>
<ItemPriceIncVat>8</ItemPriceIncVat>
<ItemDiscountExVat>9</ItemDiscountExVat>
<ItemDiscountIncVat>10</ItemDiscountIncVat>
<RowDiscountExVat>11</RowDiscountExVat>
<RowDiscountIncVat>12</RowDiscountIncVat>
<Vatperc>1</Vatperc>
<VATTariffId>1</VATTariffId>
<VATTariffCode>sample string 13</VATTariffCode>
<RowTotalExVat>14</RowTotalExVat>
<RowTotalIncVat>15</RowTotalIncVat>
<Comment>sample string 16</Comment>
<SupplierId>1</SupplierId>
<ItemPurchasePrice>1</ItemPurchasePrice>
<CreditForOrderRowId>1</CreditForOrderRowId>
<Sequence>1</Sequence>
<ShopProductUrl>sample string 17</ShopProductUrl>
<ShopProductImageUrl>sample string 18</ShopProductImageUrl>
<ShipmentId>1</ShipmentId>
<StockStatus>NotActive</StockStatus>
<IsAllocated>true</IsAllocated>
<WarehouseId>1</WarehouseId>
<WarehouseSelectionMethod>Automatic</WarehouseSelectionMethod>
<Params>
<Param>
<Key>sample string 1</Key>
<Value>sample string 2</Value>
<DataType>String</DataType>
</Param>
<Param>
<Key>sample string 1</Key>
<Value>sample string 2</Value>
<DataType>String</DataType>
</Param>
</Params>
<DisableRecalculate>true</DisableRecalculate>
</OrderRow>
Response Information
Resource Description
The HttpResponseMessage object.
HttpResponseMessage| Name | Description | Type | Additional information |
|---|---|---|---|
| Version | Version |
None. |
|
| Content | HttpContent |
None. |
|
| StatusCode | HttpStatusCode |
None. |
|
| ReasonPhrase | string |
None. |
|
| Headers | Collection of Object |
None. |
|
| RequestMessage | HttpRequestMessage |
None. |
|
| IsSuccessStatusCode | boolean |
None. |