POST api/Product/Add

Request Information

URI Parameters

None.

Body Parameters

ProductAddDto
NameDescriptionTypeAdditional information
Price

decimal number

None.

ViewCount

integer

None.

IsActive

boolean

None.

ProductCategoryID

globally unique identifier

Required

WebSiteID

globally unique identifier

None.

productItemAdds

Collection of ProductItemAddDto

None.

CurrencyID

globally unique identifier

None.

Request Formats

application/json, text/json

Sample:
{
  "price": 1.1,
  "viewCount": 2,
  "isActive": true,
  "productCategoryID": "7200d90f-03e0-48db-aef9-e8a2efc97902",
  "webSiteID": "bd1e607a-85a6-443e-b169-f692c3a45f2f",
  "productItemAdds": [
    {
      "title": "sample string 1",
      "previewText": "sample string 2",
      "detail": "sample string 3",
      "url": "sample string 4",
      "productID": "d06faef3-943d-4df0-a163-bee23209c762",
      "languageID": "df136b29-3340-449d-8612-e60989b23718"
    },
    {
      "title": "sample string 1",
      "previewText": "sample string 2",
      "detail": "sample string 3",
      "url": "sample string 4",
      "productID": "d06faef3-943d-4df0-a163-bee23209c762",
      "languageID": "df136b29-3340-449d-8612-e60989b23718"
    }
  ],
  "currencyID": "66ed9cb3-c187-4b7e-8d08-2b939b2ef483"
}

application/xml, text/xml

Sample:
<ProductAddDto xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/RS.Core.Service.DTOs">
  <CurrencyID>66ed9cb3-c187-4b7e-8d08-2b939b2ef483</CurrencyID>
  <IsActive>true</IsActive>
  <Price>1.1</Price>
  <ProductCategoryID>7200d90f-03e0-48db-aef9-e8a2efc97902</ProductCategoryID>
  <ViewCount>2</ViewCount>
  <WebSiteID>bd1e607a-85a6-443e-b169-f692c3a45f2f</WebSiteID>
  <productItemAdds>
    <ProductItemAddDto>
      <Detail>sample string 3</Detail>
      <LanguageID>df136b29-3340-449d-8612-e60989b23718</LanguageID>
      <PreviewText>sample string 2</PreviewText>
      <ProductID>d06faef3-943d-4df0-a163-bee23209c762</ProductID>
      <Title>sample string 1</Title>
      <Url>sample string 4</Url>
    </ProductItemAddDto>
    <ProductItemAddDto>
      <Detail>sample string 3</Detail>
      <LanguageID>df136b29-3340-449d-8612-e60989b23718</LanguageID>
      <PreviewText>sample string 2</PreviewText>
      <ProductID>d06faef3-943d-4df0-a163-bee23209c762</ProductID>
      <Title>sample string 1</Title>
      <Url>sample string 4</Url>
    </ProductItemAddDto>
  </productItemAdds>
</ProductAddDto>

application/x-www-form-urlencoded

Sample:

Sample not available.

text/html

Sample:
{"Price":1.1,"ViewCount":2,"IsActive":true,"ProductCategoryID":"7200d90f-03e0-48db-aef9-e8a2efc97902","WebSiteID":"bd1e607a-85a6-443e-b169-f692c3a45f2f","productItemAdds":[{"Title":"sample string 1","PreviewText":"sample string 2","Detail":"sample string 3","Url":"sample string 4","ProductID":"d06faef3-943d-4df0-a163-bee23209c762","LanguageID":"df136b29-3340-449d-8612-e60989b23718"},{"Title":"sample string 1","PreviewText":"sample string 2","Detail":"sample string 3","Url":"sample string 4","ProductID":"d06faef3-943d-4df0-a163-bee23209c762","LanguageID":"df136b29-3340-449d-8612-e60989b23718"}],"CurrencyID":"66ed9cb3-c187-4b7e-8d08-2b939b2ef483"}

Response Information

Resource Description

IHttpActionResult

None.

Response Formats

application/json, text/json, application/xml, text/xml, text/html

Sample:

Sample not available.