| POST | /stock/{brand}/export | Export Stock Data |
|---|
export class StockRequest
{
/** @description Brand */
// @ApiMember(Description="Brand", IsRequired=true)
public brand: string;
/** @description POS Legacy */
// @ApiMember(Description="POS Legacy")
public posCodes: string[];
/** @description Article Codes */
// @ApiMember(Description="Article Codes")
public articleCodes: string[];
/** @description Include Extra Info */
// @ApiMember(Description="Include Extra Info")
public includeExtraInfo: boolean;
/** @description Cluster Id */
// @ApiMember(Description="Cluster Id")
public clusterIds: string[];
/** @description Include Consignment NotAuthorized POS */
// @ApiMember(Description="Include Consignment NotAuthorized POS")
public includeConsignmentNotAuthorizedPOS: boolean;
/** @description Include Retail Sales Price in the Output, by default: false */
// @ApiMember(Description="Include Retail Sales Price in the Output, by default: false")
public includeRSP: boolean;
/** @description In Stock Since date from */
// @ApiMember(Description="In Stock Since date from ")
public dateFrom?: string;
/** @description In Stock Since date to */
// @ApiMember(Description="In Stock Since date to")
public dateTo?: string;
/** @description Item type, 'standard' OR 'consigned'. By default, all are coming */
// @ApiMember(Description="Item type, 'standard' OR 'consigned'. By default, all are coming")
public type: string;
public constructor(init?: Partial<StockRequest>) { (Object as any).assign(this, init); }
}
export class ExportStockResponse
{
/** @description Unique Identifier of the Export Request created */
// @ApiMember(Description="Unique Identifier of the Export Request created", IsRequired=true)
public asyncTaskId: string;
public constructor(init?: Partial<ExportStockResponse>) { (Object as any).assign(this, init); }
}
export class ProductCategory
{
/** @description Brand Category ID */
// @ApiMember(Description="Brand Category ID")
public brandCategoryId: string;
/** @description Grand Category ID */
// @ApiMember(Description="Grand Category ID", IsRequired=true)
public grandCategoryId: string;
/** @description Master Category ID */
// @ApiMember(Description="Master Category ID")
public masterCategoryId: string;
/** @description Category ID */
// @ApiMember(Description="Category ID")
public categoryId: string;
/** @description Sub Category ID */
// @ApiMember(Description="Sub Category ID")
public subCategoryId: string;
public constructor(init?: Partial<ProductCategory>) { (Object as any).assign(this, init); }
}
export class ExportStock extends StockRequest
{
/** @description Product Categories */
// @ApiMember(Description="Product Categories")
public productCategories: ProductCategory[];
/** @description Export Request ID of the API Consumers */
// @ApiMember(Description="Export Request ID of the API Consumers", IsRequired=true)
public downloadRequestId: string;
public constructor(init?: Partial<ExportStock>) { super(init); (Object as any).assign(this, init); }
}
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.
POST /stock/{brand}/export HTTP/1.1
Host: dev-api-booster.richemont.com
Accept: application/xml
Content-Type: application/xml
Content-Length: length
<ExportStock xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/Richemont.Booster2.PublicApi.Stock.ServiceModel">
<articleCodes xmlns:d2p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
<d2p1:string>String</d2p1:string>
</articleCodes>
<brand>String</brand>
<clusterIds xmlns:d2p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
<d2p1:string>String</d2p1:string>
</clusterIds>
<dateFrom>0001-01-01T00:00:00</dateFrom>
<dateTo>0001-01-01T00:00:00</dateTo>
<includeConsignmentNotAuthorizedPOS>false</includeConsignmentNotAuthorizedPOS>
<includeExtraInfo>false</includeExtraInfo>
<includeRSP>false</includeRSP>
<posCodes xmlns:d2p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
<d2p1:string>String</d2p1:string>
</posCodes>
<type>String</type>
<downloadRequestId>String</downloadRequestId>
<productCategories>
<ProductCategory>
<brandCategoryId>String</brandCategoryId>
<categoryId>String</categoryId>
<grandCategoryId>String</grandCategoryId>
<masterCategoryId>String</masterCategoryId>
<subCategoryId>String</subCategoryId>
</ProductCategory>
</productCategories>
</ExportStock>
HTTP/1.1 200 OK Content-Type: application/xml Content-Length: length <ExportStockResponse xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/Richemont.Booster2.PublicApi.Stock.ServiceModel"> <asyncTaskId>00000000-0000-0000-0000-000000000000</asyncTaskId> </ExportStockResponse>