Trendsic Platform Service

<back to all web services

ContainersRequest

Requires Authentication
The following routes are available for this service:
GET,OPTIONS/v1/records/warehouse/containers
import 'package:servicestack/servicestack.dart';

class ContainerItemDto implements IConvertible
{
    String? Id;
    String? Name;
    String? Flag;
    bool? Warn;

    ContainerItemDto({this.Id,this.Name,this.Flag,this.Warn});
    ContainerItemDto.fromJson(Map<String, dynamic> json) { fromMap(json); }

    fromMap(Map<String, dynamic> json) {
        Id = json['Id'];
        Name = json['Name'];
        Flag = json['Flag'];
        Warn = json['Warn'];
        return this;
    }

    Map<String, dynamic> toJson() => {
        'Id': Id,
        'Name': Name,
        'Flag': Flag,
        'Warn': Warn
    };

    getTypeName() => "ContainerItemDto";
    TypeContext? context = _ctx;
}

class RecordContainerDto implements IConvertible
{
    int? ContainerId;
    String? Barcode;
    String? Kind;
    String? Icon;
    String? Name;
    String? ZoneKey;
    String? Slot;
    String? Status;
    String? CheckoutJson;
    List<ContainerItemDto>? Items = [];

    RecordContainerDto({this.ContainerId,this.Barcode,this.Kind,this.Icon,this.Name,this.ZoneKey,this.Slot,this.Status,this.CheckoutJson,this.Items});
    RecordContainerDto.fromJson(Map<String, dynamic> json) { fromMap(json); }

    fromMap(Map<String, dynamic> json) {
        ContainerId = json['ContainerId'];
        Barcode = json['Barcode'];
        Kind = json['Kind'];
        Icon = json['Icon'];
        Name = json['Name'];
        ZoneKey = json['ZoneKey'];
        Slot = json['Slot'];
        Status = json['Status'];
        CheckoutJson = json['CheckoutJson'];
        Items = JsonConverters.fromJson(json['Items'],'List<ContainerItemDto>',context!);
        return this;
    }

    Map<String, dynamic> toJson() => {
        'ContainerId': ContainerId,
        'Barcode': Barcode,
        'Kind': Kind,
        'Icon': Icon,
        'Name': Name,
        'ZoneKey': ZoneKey,
        'Slot': Slot,
        'Status': Status,
        'CheckoutJson': CheckoutJson,
        'Items': JsonConverters.toJson(Items,'List<ContainerItemDto>',context!)
    };

    getTypeName() => "RecordContainerDto";
    TypeContext? context = _ctx;
}

class ContainersResponse implements IConvertible
{
    ResponseStatus? ResponseStatus;
    List<RecordContainerDto>? Containers = [];

    ContainersResponse({this.ResponseStatus,this.Containers});
    ContainersResponse.fromJson(Map<String, dynamic> json) { fromMap(json); }

    fromMap(Map<String, dynamic> json) {
        ResponseStatus = JsonConverters.fromJson(json['ResponseStatus'],'ResponseStatus',context!);
        Containers = JsonConverters.fromJson(json['Containers'],'List<RecordContainerDto>',context!);
        return this;
    }

    Map<String, dynamic> toJson() => {
        'ResponseStatus': JsonConverters.toJson(ResponseStatus,'ResponseStatus',context!),
        'Containers': JsonConverters.toJson(Containers,'List<RecordContainerDto>',context!)
    };

    getTypeName() => "ContainersResponse";
    TypeContext? context = _ctx;
}

class ContainersRequest implements IConvertible
{
    ContainersRequest();
    ContainersRequest.fromJson(Map<String, dynamic> json) : super();
    fromMap(Map<String, dynamic> json) {
        return this;
    }

    Map<String, dynamic> toJson() => {};
    getTypeName() => "ContainersRequest";
    TypeContext? context = _ctx;
}

TypeContext _ctx = TypeContext(library: 'api.dev.dynamics.trendsic.com', types: <String, TypeInfo> {
    'ContainerItemDto': TypeInfo(TypeOf.Class, create:() => ContainerItemDto()),
    'RecordContainerDto': TypeInfo(TypeOf.Class, create:() => RecordContainerDto()),
    'List<ContainerItemDto>': TypeInfo(TypeOf.Class, create:() => <ContainerItemDto>[]),
    'ContainersResponse': TypeInfo(TypeOf.Class, create:() => ContainersResponse()),
    'List<RecordContainerDto>': TypeInfo(TypeOf.Class, create:() => <RecordContainerDto>[]),
    'ContainersRequest': TypeInfo(TypeOf.Class, create:() => ContainersRequest()),
});

Dart ContainersRequest DTOs

To override the Content-type in your clients, use the HTTP Accept Header, append the .other suffix or ?format=other

HTTP + OTHER

The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.

GET /v1/records/warehouse/containers HTTP/1.1 
Host: api.dev.dynamics.trendsic.com 
Accept: text/jsonl
HTTP/1.1 200 OK
Content-Type: text/jsonl
Content-Length: length

{"ResponseStatus":{"ErrorCode":"String","Message":"String","StackTrace":"String","Errors":[{"ErrorCode":"String","FieldName":"String","Message":"String","Meta":{"String":"String"}}],"Meta":{"String":"String"}},"Containers":[{"ContainerId":0,"Barcode":"String","Kind":"String","Icon":"String","Name":"String","ZoneKey":"String","Slot":"String","Status":"String","CheckoutJson":"String","Items":[{"Id":"String","Name":"String","Flag":"String","Warn":false}]}]}