| POST | /stock/{brand}/export | Export Stock Data |
|---|
import java.math.*;
import java.util.*;
import net.servicestack.client.*;
public class dtos
{
public static class ExportStock extends StockRequest
{
/**
* Product Categories
*/
@ApiMember(Description="Product Categories")
public ArrayList<ProductCategory> productCategories = null;
/**
* Export Request ID of the API Consumers
*/
@ApiMember(Description="Export Request ID of the API Consumers", IsRequired=true)
public String downloadRequestId = null;
public ArrayList<ProductCategory> getProductCategories() { return productCategories; }
public ExportStock setProductCategories(ArrayList<ProductCategory> value) { this.productCategories = value; return this; }
public String getDownloadRequestId() { return downloadRequestId; }
public ExportStock setDownloadRequestId(String value) { this.downloadRequestId = value; return this; }
}
public static class StockRequest
{
/**
* Brand
*/
@ApiMember(Description="Brand", IsRequired=true)
public String brand = null;
/**
* POS Legacy
*/
@ApiMember(Description="POS Legacy")
public ArrayList<String> posCodes = null;
/**
* Article Codes
*/
@ApiMember(Description="Article Codes")
public ArrayList<String> articleCodes = null;
/**
* Include Extra Info
*/
@ApiMember(Description="Include Extra Info")
public Boolean includeExtraInfo = null;
/**
* Cluster Id
*/
@ApiMember(Description="Cluster Id")
public ArrayList<String> clusterIds = null;
/**
* Include Consignment NotAuthorized POS
*/
@ApiMember(Description="Include Consignment NotAuthorized POS")
public Boolean includeConsignmentNotAuthorizedPOS = null;
/**
* Include Retail Sales Price in the Output, by default: false
*/
@ApiMember(Description="Include Retail Sales Price in the Output, by default: false")
public Boolean includeRSP = null;
/**
* In Stock Since date from
*/
@ApiMember(Description="In Stock Since date from ")
public Date dateFrom = null;
/**
* In Stock Since date to
*/
@ApiMember(Description="In Stock Since date to")
public Date dateTo = null;
/**
* Item type, 'standard' OR 'consigned'. By default, all are coming
*/
@ApiMember(Description="Item type, 'standard' OR 'consigned'. By default, all are coming")
public String type = null;
public String getBrand() { return brand; }
public StockRequest setBrand(String value) { this.brand = value; return this; }
public ArrayList<String> getPosCodes() { return posCodes; }
public StockRequest setPosCodes(ArrayList<String> value) { this.posCodes = value; return this; }
public ArrayList<String> getArticleCodes() { return articleCodes; }
public StockRequest setArticleCodes(ArrayList<String> value) { this.articleCodes = value; return this; }
public Boolean isIncludeExtraInfo() { return includeExtraInfo; }
public StockRequest setIncludeExtraInfo(Boolean value) { this.includeExtraInfo = value; return this; }
public ArrayList<String> getClusterIds() { return clusterIds; }
public StockRequest setClusterIds(ArrayList<String> value) { this.clusterIds = value; return this; }
public Boolean isIncludeConsignmentNotAuthorizedPOS() { return includeConsignmentNotAuthorizedPOS; }
public StockRequest setIncludeConsignmentNotAuthorizedPOS(Boolean value) { this.includeConsignmentNotAuthorizedPOS = value; return this; }
public Boolean isIncludeRSP() { return includeRSP; }
public StockRequest setIncludeRSP(Boolean value) { this.includeRSP = value; return this; }
public Date getDateFrom() { return dateFrom; }
public StockRequest setDateFrom(Date value) { this.dateFrom = value; return this; }
public Date getDateTo() { return dateTo; }
public StockRequest setDateTo(Date value) { this.dateTo = value; return this; }
public String getType() { return type; }
public StockRequest setType(String value) { this.type = value; return this; }
}
public static class ProductCategory
{
/**
* Brand Category ID
*/
@ApiMember(Description="Brand Category ID")
public String brandCategoryId = null;
/**
* Grand Category ID
*/
@ApiMember(Description="Grand Category ID", IsRequired=true)
public String grandCategoryId = null;
/**
* Master Category ID
*/
@ApiMember(Description="Master Category ID")
public String masterCategoryId = null;
/**
* Category ID
*/
@ApiMember(Description="Category ID")
public String categoryId = null;
/**
* Sub Category ID
*/
@ApiMember(Description="Sub Category ID")
public String subCategoryId = null;
public String getBrandCategoryId() { return brandCategoryId; }
public ProductCategory setBrandCategoryId(String value) { this.brandCategoryId = value; return this; }
public String getGrandCategoryId() { return grandCategoryId; }
public ProductCategory setGrandCategoryId(String value) { this.grandCategoryId = value; return this; }
public String getMasterCategoryId() { return masterCategoryId; }
public ProductCategory setMasterCategoryId(String value) { this.masterCategoryId = value; return this; }
public String getCategoryId() { return categoryId; }
public ProductCategory setCategoryId(String value) { this.categoryId = value; return this; }
public String getSubCategoryId() { return subCategoryId; }
public ProductCategory setSubCategoryId(String value) { this.subCategoryId = value; return this; }
}
public static class ExportStockResponse
{
/**
* Unique Identifier of the Export Request created
*/
@ApiMember(Description="Unique Identifier of the Export Request created", IsRequired=true)
public UUID asyncTaskId = null;
public UUID getAsyncTaskId() { return asyncTaskId; }
public ExportStockResponse setAsyncTaskId(UUID value) { this.asyncTaskId = value; return this; }
}
}
To override the Content-type in your clients, use the HTTP Accept Header, append the .json suffix or ?format=json
To embed the response in a jsonp callback, append ?callback=myCallback
The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.
POST /stock/{brand}/export HTTP/1.1
Host: dev-api-booster.richemont.com
Accept: application/json
Content-Type: application/json
Content-Length: length
{"productCategories":[{"brandCategoryId":"String","grandCategoryId":"String","masterCategoryId":"String","categoryId":"String","subCategoryId":"String"}],"downloadRequestId":"String","brand":"String","posCodes":["String"],"articleCodes":["String"],"includeExtraInfo":false,"clusterIds":["String"],"includeConsignmentNotAuthorizedPOS":false,"includeRSP":false,"dateFrom":"\/Date(-62135596800000-0000)\/","dateTo":"\/Date(-62135596800000-0000)\/","type":"String"}
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: length
{"asyncTaskId":"00000000000000000000000000000000"}