| GET | /stock/{brand}/{posCode}/{articleCode} | Get stock details |
|---|
import java.math.*
import java.util.*
import net.servicestack.client.*
import com.google.gson.annotations.*
import com.google.gson.reflect.*
open class GetStockDetail
{
/**
* Brand
*/
@ApiMember(Description="Brand", IsRequired=true)
var brand:String? = null
/**
* POS Legacy
*/
@ApiMember(Description="POS Legacy", IsRequired=true)
var posCode:String? = null
/**
* Article Code
*/
@ApiMember(Description="Article Code", IsRequired=true)
var articleCode:String? = null
}
open class GetStockDetailResponse
{
/**
* Article code
*/
@ApiMember(Description="Article code", IsRequired=true)
var articleCode:String? = null
/**
* Brand
*/
@ApiMember(Description="Brand", IsRequired=true)
var brand:String? = null
/**
* Pos Code
*/
@ApiMember(Description="Pos Code", IsRequired=true)
var posCode:String? = null
/**
* Current Stock Quantity
*/
@ApiMember(Description="Current Stock Quantity", IsRequired=true)
var currentStockQuantity:Int? = null
/**
* Shared Stock Location
*/
@ApiMember(Description="Shared Stock Location", IsRequired=true)
var sharedStockLocation:Pos? = null
/**
* Stock Positions
*/
@ApiMember(Description="Stock Positions", IsRequired=true)
var stockPositions:ArrayList<StockPositionItem> = ArrayList<StockPositionItem>()
}
open class Pos
{
/**
* Name of the POS
*/
@ApiMember(Description="Name of the POS", IsRequired=true)
var name:String? = null
/**
* POS Code
*/
@ApiMember(Description="POS Code", IsRequired=true)
var posCode:String? = null
/**
* Pos Code To Be Displayed
*/
@ApiMember(Description="Pos Code To Be Displayed", IsRequired=true)
var posCodeToBeDisplayed:String? = null
/**
* Country of the POS
*/
@ApiMember(Description="Country of the POS", IsRequired=true)
var country:String? = null
/**
* City of the POS
*/
@ApiMember(Description="City of the POS", IsRequired=true)
var city:String? = null
/**
* Postal Code
*/
@ApiMember(Description="Postal Code", IsRequired=true)
var postalCode:String? = null
/**
* State
*/
@ApiMember(Description="State", IsRequired=true)
var state:String? = null
/**
* Street
*/
@ApiMember(Description="Street", IsRequired=true)
var street:String? = null
}
open class StockPositionItem
{
/**
* Quantity
*/
@ApiMember(Description="Quantity", IsRequired=true)
var quantity:Int? = null
/**
* Serial Number
*/
@ApiMember(Description="Serial Number")
var serialNumber:String? = null
/**
* Stock Date
*/
@ApiMember(Description="Stock Date", IsRequired=true)
var stockDate:String? = null
/**
* Loaded On Date
*/
@ApiMember(Description="Loaded On Date", IsRequired=true)
var loadedOnDate:String? = null
/**
* Type e.g. consignment or standard
*/
@ApiMember(Description="Type e.g. consignment or standard", IsRequired=true)
@SerializedName("type") var Type:String? = null
/**
* Is Consignment Sellable
*/
@ApiMember(Description="Is Consignment Sellable ", IsRequired=true)
var isConsignmentSellable:Boolean? = null
/**
* Sell-In Price. Disclaimer: this data will be arriving empty/null due to DealerCost project still being in test phase.
*/
@ApiMember(Description="Sell-In Price. Disclaimer: this data will be arriving empty/null due to DealerCost project still being in test phase.")
var unitNetAmount:UnitNetAmount? = null
/**
* Retail Sales Price
*/
@ApiMember(Description="Retail Sales Price")
var retailSalesPrice:UnitNetAmount? = null
}
open class UnitNetAmount
{
/**
* Currency Iso Code
*/
@ApiMember(Description="Currency Iso Code", IsRequired=true)
var currencyIsoCode:String? = null
/**
* Value
*/
@ApiMember(Description="Value", IsRequired=true)
var value:BigDecimal? = null
}
To override the Content-type in your clients, use the HTTP Accept Header, append the .xml suffix or ?format=xml
The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.
GET /stock/{brand}/{posCode}/{articleCode} HTTP/1.1
Host: dev-api-booster.richemont.com
Accept: application/xml
HTTP/1.1 200 OK
Content-Type: application/xml
Content-Length: length
<GetStockDetailResponse xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/Richemont.Booster2.PublicApi.Stock.ServiceModel">
<articleCode>String</articleCode>
<brand>String</brand>
<currentStockQuantity>0</currentStockQuantity>
<posCode>String</posCode>
<sharedStockLocation>
<city>String</city>
<country>String</country>
<name>String</name>
<posCode>String</posCode>
<posCodeToBeDisplayed>String</posCodeToBeDisplayed>
<postalCode>String</postalCode>
<state>String</state>
<street>String</street>
</sharedStockLocation>
<stockPositions>
<StockPositionItem>
<isConsignmentSellable>false</isConsignmentSellable>
<loadedOnDate>String</loadedOnDate>
<quantity>0</quantity>
<retailSalesPrice>
<currencyIsoCode>String</currencyIsoCode>
<value>0</value>
</retailSalesPrice>
<serialNumber>String</serialNumber>
<stockDate>String</stockDate>
<type>String</type>
<unitNetAmount>
<currencyIsoCode>String</currencyIsoCode>
<value>0</value>
</unitNetAmount>
</StockPositionItem>
</stockPositions>
</GetStockDetailResponse>