POST | /RestApi/recycle-bin/batch/restore |
---|
import 'package:servicestack/servicestack.dart';
class RestoreRecycleBinItems implements IConvertible
{
List<String>? Ids;
RestoreRecycleBinItems({this.Ids});
RestoreRecycleBinItems.fromJson(Map<String, dynamic> json) { fromMap(json); }
fromMap(Map<String, dynamic> json) {
Ids = JsonConverters.fromJson(json['Ids'],'List<String>',context!);
return this;
}
Map<String, dynamic> toJson() => {
'Ids': JsonConverters.toJson(Ids,'List<String>',context!)
};
getTypeName() => "RestoreRecycleBinItems";
TypeContext? context = _ctx;
}
class ModalMessageProxy implements IConvertible
{
bool? IsRecoverable;
String? HeaderText;
String? BodyText;
String? ActionButtonText;
bool? HasCancelButton;
ModalMessageProxy({this.IsRecoverable,this.HeaderText,this.BodyText,this.ActionButtonText,this.HasCancelButton});
ModalMessageProxy.fromJson(Map<String, dynamic> json) { fromMap(json); }
fromMap(Map<String, dynamic> json) {
IsRecoverable = json['IsRecoverable'];
HeaderText = json['HeaderText'];
BodyText = json['BodyText'];
ActionButtonText = json['ActionButtonText'];
HasCancelButton = json['HasCancelButton'];
return this;
}
Map<String, dynamic> toJson() => {
'IsRecoverable': IsRecoverable,
'HeaderText': HeaderText,
'BodyText': BodyText,
'ActionButtonText': ActionButtonText,
'HasCancelButton': HasCancelButton
};
getTypeName() => "ModalMessageProxy";
TypeContext? context = _ctx;
}
class BatchRestoreModalMessageProxy extends ModalMessageProxy implements IConvertible
{
List<String>? InvalidItems;
BatchRestoreModalMessageProxy({this.InvalidItems});
BatchRestoreModalMessageProxy.fromJson(Map<String, dynamic> json) { fromMap(json); }
fromMap(Map<String, dynamic> json) {
super.fromMap(json);
InvalidItems = JsonConverters.fromJson(json['InvalidItems'],'List<String>',context!);
return this;
}
Map<String, dynamic> toJson() => super.toJson()..addAll({
'InvalidItems': JsonConverters.toJson(InvalidItems,'List<String>',context!)
});
getTypeName() => "BatchRestoreModalMessageProxy";
TypeContext? context = _ctx;
}
TypeContext _ctx = TypeContext(library: 'www.asg.com.au', types: <String, TypeInfo> {
'RestoreRecycleBinItems': TypeInfo(TypeOf.Class, create:() => RestoreRecycleBinItems()),
'ModalMessageProxy': TypeInfo(TypeOf.Class, create:() => ModalMessageProxy()),
'BatchRestoreModalMessageProxy': TypeInfo(TypeOf.Class, create:() => BatchRestoreModalMessageProxy()),
});
Dart RestoreRecycleBinItems DTOs
To override the Content-type in your clients, use the HTTP Accept Header, append the .csv suffix or ?format=csv
The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.
POST /RestApi/recycle-bin/batch/restore HTTP/1.1
Host: www.asg.com.au
Accept: text/csv
Content-Type: text/csv
Content-Length: length
{"Ids":["00000000-0000-0000-0000-000000000000"]}
HTTP/1.1 200 OK Content-Type: text/csv Content-Length: length {Unable to show example output for type 'BatchRestoreModalMessageProxy' using the custom 'csv' filter}No parameterless constructor defined for this object.