GET api/ProductPhotos

Gets the list of products with their photos available

Request Information

URI Parameters

NameDescriptionTypeAdditional information
HasPhotos

If the products returned should have photos or not (default true)

boolean

Required

WholesalerArticleNumber

Article code for the product defined by the wholesaler (optional)

string

Primary key field

URI Example

api/ProductPhotos?HasPhotos={HasPhotos}&WholesalerArticleNumber={WholesalerArticleNumber}

Body Parameters

None.

Response Information

Resource Description

A wrapper class containing the photos

Oresto.API.Models.GET.ProductPhotos.ProductPhotoData
NameDescriptionTypeAdditional information
Errors

Possible errors that were experienced when processing the request

Collection of string

None.

Products

The list of products with their photos

Collection of Oresto.API.Models.GET.ProductPhotos.Product

None.

RequestInformation

Additional information about the request

Oresto.API.Models.Shared.RequestInformation

None.

Response Formats

application/json, text/json

Sample:
{
  "Products": [
    {
      "WholesalerArticleNumber": "sample string 1",
      "Photos": [
        {
          "PhotoId": 1,
          "LanguageCode": "sample string 2",
          "FileName": "sample string 3"
        },
        {
          "PhotoId": 1,
          "LanguageCode": "sample string 2",
          "FileName": "sample string 3"
        }
      ]
    },
    {
      "WholesalerArticleNumber": "sample string 1",
      "Photos": [
        {
          "PhotoId": 1,
          "LanguageCode": "sample string 2",
          "FileName": "sample string 3"
        },
        {
          "PhotoId": 1,
          "LanguageCode": "sample string 2",
          "FileName": "sample string 3"
        }
      ]
    }
  ],
  "RequestInformation": {
    "RequestDuration": 1,
    "WholesalerId": 2,
    "UserId": 3
  },
  "Errors": [
    "sample string 1",
    "sample string 2"
  ]
}

application/xml, text/xml

Sample:
<ProductPhotoData xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/Oresto.API.Models.GET.ProductPhotos">
  <Errors xmlns:d2p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays" xmlns="http://schemas.datacontract.org/2004/07/Oresto.API.Models.Shared">
    <d2p1:string>sample string 1</d2p1:string>
    <d2p1:string>sample string 2</d2p1:string>
  </Errors>
  <RequestInformation xmlns="http://schemas.datacontract.org/2004/07/Oresto.API.Models.Shared">
    <RequestDuration>1</RequestDuration>
    <UserId>3</UserId>
    <WholesalerId>2</WholesalerId>
  </RequestInformation>
  <Products>
    <Product>
      <Photos>
        <Product.Photo>
          <FileName>sample string 3</FileName>
          <LanguageCode>sample string 2</LanguageCode>
          <PhotoId>1</PhotoId>
        </Product.Photo>
        <Product.Photo>
          <FileName>sample string 3</FileName>
          <LanguageCode>sample string 2</LanguageCode>
          <PhotoId>1</PhotoId>
        </Product.Photo>
      </Photos>
      <WholesalerArticleNumber>sample string 1</WholesalerArticleNumber>
    </Product>
    <Product>
      <Photos>
        <Product.Photo>
          <FileName>sample string 3</FileName>
          <LanguageCode>sample string 2</LanguageCode>
          <PhotoId>1</PhotoId>
        </Product.Photo>
        <Product.Photo>
          <FileName>sample string 3</FileName>
          <LanguageCode>sample string 2</LanguageCode>
          <PhotoId>1</PhotoId>
        </Product.Photo>
      </Photos>
      <WholesalerArticleNumber>sample string 1</WholesalerArticleNumber>
    </Product>
  </Products>
</ProductPhotoData>