POST api/products/categoryProducts
Request Information
URI Parameters
None.
Body Parameters
SearchOptions| Name | Description | Type | Additional information |
|---|---|---|---|
| CategoryName | string |
None. |
|
| SearchTerm | string |
None. |
|
| IsHomeProducts | boolean |
None. |
|
| IsSale | boolean |
None. |
|
| ClassId | integer |
None. |
|
| pageNum | integer |
None. |
Request Formats
application/json, text/json
Sample:
{
"CategoryName": "sample string 1",
"SearchTerm": "sample string 2",
"IsHomeProducts": true,
"IsSale": true,
"ClassId": 1,
"pageNum": 3
}
application/xml, text/xml
Sample:
<SearchOptions xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/IRAQI_API.ViewModels"> <CategoryName>sample string 1</CategoryName> <ClassId>1</ClassId> <IsHomeProducts>true</IsHomeProducts> <IsSale>true</IsSale> <SearchTerm>sample string 2</SearchTerm> <pageNum>3</pageNum> </SearchOptions>
multipart/form-data
Sample:
<SearchOptions xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/IRAQI_API.ViewModels"><CategoryName>sample string 1</CategoryName><ClassId>1</ClassId><IsHomeProducts>true</IsHomeProducts><IsSale>true</IsSale><SearchTerm>sample string 2</SearchTerm><pageNum>3</pageNum></SearchOptions>
application/x-www-form-urlencoded
Sample:
Sample not available.
Response Information
Resource Description
Collection of CategoryProductsData| Name | Description | Type | Additional information |
|---|---|---|---|
| ID | integer |
None. |
|
| Name | string |
None. |
|
| PackQuantity | decimal number |
None. |
|
| PackPrice | decimal number |
None. |
|
| PrimaryImage | string |
None. |
|
| SecondaryImages | Collection of string |
None. |
|
| Tag1 | string |
None. |
|
| Tag2 | string |
None. |
|
| SalePrice | string |
None. |
|
| Price | string |
None. |
|
| IsNew | boolean |
None. |
|
| IsSaleDisplayed | boolean |
None. |
|
| IsPropertiesPrice | boolean |
None. |
|
| ShortDescription | string |
None. |
|
| IsWeeklyProduct | boolean |
None. |
|
| PropertyPrices | Collection of PropertyPriceData |
None. |
Response Formats
application/json, text/json
Sample:
[
{
"ID": 1,
"Name": "sample string 2",
"PackQuantity": 1.1,
"PackPrice": 1.1,
"PrimaryImage": "sample string 3",
"SecondaryImages": [
"sample string 1",
"sample string 2"
],
"Tag1": "sample string 4",
"Tag2": "sample string 5",
"SalePrice": "sample string 6",
"Price": "sample string 7",
"IsNew": true,
"IsSaleDisplayed": true,
"IsPropertiesPrice": true,
"ShortDescription": "sample string 11",
"IsWeeklyProduct": true,
"PropertyPrices": [
{
"Price": 1.1,
"DiscountPercent": 1.1,
"DiscountPrice": 1.1,
"PackQuantity": 1,
"PackPrice": 1.1,
"PropertyValuesIds": [
1,
2
]
},
{
"Price": 1.1,
"DiscountPercent": 1.1,
"DiscountPrice": 1.1,
"PackQuantity": 1,
"PackPrice": 1.1,
"PropertyValuesIds": [
1,
2
]
}
]
},
{
"ID": 1,
"Name": "sample string 2",
"PackQuantity": 1.1,
"PackPrice": 1.1,
"PrimaryImage": "sample string 3",
"SecondaryImages": [
"sample string 1",
"sample string 2"
],
"Tag1": "sample string 4",
"Tag2": "sample string 5",
"SalePrice": "sample string 6",
"Price": "sample string 7",
"IsNew": true,
"IsSaleDisplayed": true,
"IsPropertiesPrice": true,
"ShortDescription": "sample string 11",
"IsWeeklyProduct": true,
"PropertyPrices": [
{
"Price": 1.1,
"DiscountPercent": 1.1,
"DiscountPrice": 1.1,
"PackQuantity": 1,
"PackPrice": 1.1,
"PropertyValuesIds": [
1,
2
]
},
{
"Price": 1.1,
"DiscountPercent": 1.1,
"DiscountPrice": 1.1,
"PackQuantity": 1,
"PackPrice": 1.1,
"PropertyValuesIds": [
1,
2
]
}
]
}
]
application/xml, text/xml
Sample:
<ArrayOfCategoryProductsData xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/IRAQI_API.Models.Data">
<CategoryProductsData>
<ID>1</ID>
<IsNew>true</IsNew>
<IsPropertiesPrice>true</IsPropertiesPrice>
<IsSaleDisplayed>true</IsSaleDisplayed>
<IsWeeklyProduct>true</IsWeeklyProduct>
<Name>sample string 2</Name>
<PackPrice>1.1</PackPrice>
<PackQuantity>1.1</PackQuantity>
<Price>sample string 7</Price>
<PrimaryImage>sample string 3</PrimaryImage>
<PropertyPrices>
<PropertyPriceData>
<DiscountPercent>1.1</DiscountPercent>
<DiscountPrice>1.1</DiscountPrice>
<PackPrice>1.1</PackPrice>
<PackQuantity>1</PackQuantity>
<Price>1.1</Price>
<PropertyValuesIds xmlns:d5p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
<d5p1:int>1</d5p1:int>
<d5p1:int>2</d5p1:int>
</PropertyValuesIds>
</PropertyPriceData>
<PropertyPriceData>
<DiscountPercent>1.1</DiscountPercent>
<DiscountPrice>1.1</DiscountPrice>
<PackPrice>1.1</PackPrice>
<PackQuantity>1</PackQuantity>
<Price>1.1</Price>
<PropertyValuesIds xmlns:d5p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
<d5p1:int>1</d5p1:int>
<d5p1:int>2</d5p1:int>
</PropertyValuesIds>
</PropertyPriceData>
</PropertyPrices>
<SalePrice>sample string 6</SalePrice>
<SecondaryImages xmlns:d3p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
<d3p1:string>sample string 1</d3p1:string>
<d3p1:string>sample string 2</d3p1:string>
</SecondaryImages>
<ShortDescription>sample string 11</ShortDescription>
<Tag1>sample string 4</Tag1>
<Tag2>sample string 5</Tag2>
</CategoryProductsData>
<CategoryProductsData>
<ID>1</ID>
<IsNew>true</IsNew>
<IsPropertiesPrice>true</IsPropertiesPrice>
<IsSaleDisplayed>true</IsSaleDisplayed>
<IsWeeklyProduct>true</IsWeeklyProduct>
<Name>sample string 2</Name>
<PackPrice>1.1</PackPrice>
<PackQuantity>1.1</PackQuantity>
<Price>sample string 7</Price>
<PrimaryImage>sample string 3</PrimaryImage>
<PropertyPrices>
<PropertyPriceData>
<DiscountPercent>1.1</DiscountPercent>
<DiscountPrice>1.1</DiscountPrice>
<PackPrice>1.1</PackPrice>
<PackQuantity>1</PackQuantity>
<Price>1.1</Price>
<PropertyValuesIds xmlns:d5p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
<d5p1:int>1</d5p1:int>
<d5p1:int>2</d5p1:int>
</PropertyValuesIds>
</PropertyPriceData>
<PropertyPriceData>
<DiscountPercent>1.1</DiscountPercent>
<DiscountPrice>1.1</DiscountPrice>
<PackPrice>1.1</PackPrice>
<PackQuantity>1</PackQuantity>
<Price>1.1</Price>
<PropertyValuesIds xmlns:d5p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
<d5p1:int>1</d5p1:int>
<d5p1:int>2</d5p1:int>
</PropertyValuesIds>
</PropertyPriceData>
</PropertyPrices>
<SalePrice>sample string 6</SalePrice>
<SecondaryImages xmlns:d3p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
<d3p1:string>sample string 1</d3p1:string>
<d3p1:string>sample string 2</d3p1:string>
</SecondaryImages>
<ShortDescription>sample string 11</ShortDescription>
<Tag1>sample string 4</Tag1>
<Tag2>sample string 5</Tag2>
</CategoryProductsData>
</ArrayOfCategoryProductsData>
multipart/form-data
Sample:
<ArrayOfCategoryProductsData xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/IRAQI_API.Models.Data"><CategoryProductsData><ID>1</ID><IsNew>true</IsNew><IsPropertiesPrice>true</IsPropertiesPrice><IsSaleDisplayed>true</IsSaleDisplayed><IsWeeklyProduct>true</IsWeeklyProduct><Name>sample string 2</Name><PackPrice>1.1</PackPrice><PackQuantity>1.1</PackQuantity><Price>sample string 7</Price><PrimaryImage>sample string 3</PrimaryImage><PropertyPrices><PropertyPriceData><DiscountPercent>1.1</DiscountPercent><DiscountPrice>1.1</DiscountPrice><PackPrice>1.1</PackPrice><PackQuantity>1</PackQuantity><Price>1.1</Price><PropertyValuesIds xmlns:d5p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays"><d5p1:int>1</d5p1:int><d5p1:int>2</d5p1:int></PropertyValuesIds></PropertyPriceData><PropertyPriceData><DiscountPercent>1.1</DiscountPercent><DiscountPrice>1.1</DiscountPrice><PackPrice>1.1</PackPrice><PackQuantity>1</PackQuantity><Price>1.1</Price><PropertyValuesIds xmlns:d5p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays"><d5p1:int>1</d5p1:int><d5p1:int>2</d5p1:int></PropertyValuesIds></PropertyPriceData></PropertyPrices><SalePrice>sample string 6</SalePrice><SecondaryImages xmlns:d3p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays"><d3p1:string>sample string 1</d3p1:string><d3p1:string>sample string 2</d3p1:string></SecondaryImages><ShortDescription>sample string 11</ShortDescription><Tag1>sample string 4</Tag1><Tag2>sample string 5</Tag2></CategoryProductsData><CategoryProductsData><ID>1</ID><IsNew>true</IsNew><IsPropertiesPrice>true</IsPropertiesPrice><IsSaleDisplayed>true</IsSaleDisplayed><IsWeeklyProduct>true</IsWeeklyProduct><Name>sample string 2</Name><PackPrice>1.1</PackPrice><PackQuantity>1.1</PackQuantity><Price>sample string 7</Price><PrimaryImage>sample string 3</PrimaryImage><PropertyPrices><PropertyPriceData><DiscountPercent>1.1</DiscountPercent><DiscountPrice>1.1</DiscountPrice><PackPrice>1.1</PackPrice><PackQuantity>1</PackQuantity><Price>1.1</Price><PropertyValuesIds xmlns:d5p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays"><d5p1:int>1</d5p1:int><d5p1:int>2</d5p1:int></PropertyValuesIds></PropertyPriceData><PropertyPriceData><DiscountPercent>1.1</DiscountPercent><DiscountPrice>1.1</DiscountPrice><PackPrice>1.1</PackPrice><PackQuantity>1</PackQuantity><Price>1.1</Price><PropertyValuesIds xmlns:d5p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays"><d5p1:int>1</d5p1:int><d5p1:int>2</d5p1:int></PropertyValuesIds></PropertyPriceData></PropertyPrices><SalePrice>sample string 6</SalePrice><SecondaryImages xmlns:d3p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays"><d3p1:string>sample string 1</d3p1:string><d3p1:string>sample string 2</d3p1:string></SecondaryImages><ShortDescription>sample string 11</ShortDescription><Tag1>sample string 4</Tag1><Tag2>sample string 5</Tag2></CategoryProductsData></ArrayOfCategoryProductsData>