| GET | /stock/{brand}/slim | Get slim Stock |
|---|
import 'package:servicestack/servicestack.dart';
class GetStockSlimResponse implements IConvertible
{
/**
* Total Product Count
*/
// @ApiMember(Description="Total Product Count", IsRequired=true)
int? totalProductCount;
/**
* Total Consignment Count
*/
// @ApiMember(Description="Total Consignment Count", IsRequired=true)
int? totalConsignmentCount;
/**
* Articles
*/
// @ApiMember(Description="Articles", IsRequired=true)
List<String>? elements;
GetStockSlimResponse({this.totalProductCount,this.totalConsignmentCount,this.elements});
GetStockSlimResponse.fromJson(Map<String, dynamic> json) { fromMap(json); }
fromMap(Map<String, dynamic> json) {
totalProductCount = json['totalProductCount'];
totalConsignmentCount = json['totalConsignmentCount'];
elements = JsonConverters.fromJson(json['elements'],'List<String>',context!);
return this;
}
Map<String, dynamic> toJson() => {
'totalProductCount': totalProductCount,
'totalConsignmentCount': totalConsignmentCount,
'elements': JsonConverters.toJson(elements,'List<String>',context!)
};
getTypeName() => "GetStockSlimResponse";
TypeContext? context = _ctx;
}
class GetStockSlim implements IConvertible
{
/**
* Brand
*/
// @ApiMember(Description="Brand", IsRequired=true)
String? brand;
/**
* POS Legacy
*/
// @ApiMember(Description="POS Legacy")
List<String>? posCodes;
/**
* Article Codes
*/
// @ApiMember(Description="Article Codes")
List<String>? articleCodes;
/**
* Cluster Id
*/
// @ApiMember(Description="Cluster Id")
List<String>? clusterIds;
/**
* Include Extra Info
*/
// @ApiMember(Description="Include Extra Info")
bool? includeExtraInfo;
/**
* Include Consignment NotAuthorized POS
*/
// @ApiMember(Description="Include Consignment NotAuthorized POS")
bool? includeConsignmentNotAuthorizedPOS;
/**
* Item type, 'standard' OR 'consigned'. By default, all are coming
*/
// @ApiMember(Description="Item type, 'standard' OR 'consigned'. By default, all are coming")
String? type;
GetStockSlim({this.brand,this.posCodes,this.articleCodes,this.clusterIds,this.includeExtraInfo,this.includeConsignmentNotAuthorizedPOS,this.type});
GetStockSlim.fromJson(Map<String, dynamic> json) { fromMap(json); }
fromMap(Map<String, dynamic> json) {
brand = json['brand'];
posCodes = JsonConverters.fromJson(json['posCodes'],'List<String>',context!);
articleCodes = JsonConverters.fromJson(json['articleCodes'],'List<String>',context!);
clusterIds = JsonConverters.fromJson(json['clusterIds'],'List<String>',context!);
includeExtraInfo = json['includeExtraInfo'];
includeConsignmentNotAuthorizedPOS = json['includeConsignmentNotAuthorizedPOS'];
type = json['type'];
return this;
}
Map<String, dynamic> toJson() => {
'brand': brand,
'posCodes': JsonConverters.toJson(posCodes,'List<String>',context!),
'articleCodes': JsonConverters.toJson(articleCodes,'List<String>',context!),
'clusterIds': JsonConverters.toJson(clusterIds,'List<String>',context!),
'includeExtraInfo': includeExtraInfo,
'includeConsignmentNotAuthorizedPOS': includeConsignmentNotAuthorizedPOS,
'type': type
};
getTypeName() => "GetStockSlim";
TypeContext? context = _ctx;
}
TypeContext _ctx = TypeContext(library: 'dev_api_booster.richemont.com', types: <String, TypeInfo> {
'GetStockSlimResponse': TypeInfo(TypeOf.Class, create:() => GetStockSlimResponse()),
'GetStockSlim': TypeInfo(TypeOf.Class, create:() => GetStockSlim()),
});
To override the Content-type in your clients, use the HTTP Accept Header, append the .other suffix or ?format=other
The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.
GET /stock/{brand}/slim HTTP/1.1
Host: dev-api-booster.richemont.com
Accept: text/jsonl
HTTP/1.1 200 OK
Content-Type: text/jsonl
Content-Length: length
{"totalProductCount":0,"totalConsignmentCount":0,"elements":["String"]}