POST | /pdf/model |
---|
import 'package:servicestack/servicestack.dart';
import 'dart:typed_data';
class SetPdfModelResponse implements IConvertible
{
String? id;
bool? success;
SetPdfModelResponse({this.id,this.success});
SetPdfModelResponse.fromJson(Map<String, dynamic> json) { fromMap(json); }
fromMap(Map<String, dynamic> json) {
id = json['id'];
success = json['success'];
return this;
}
Map<String, dynamic> toJson() => {
'id': id,
'success': success
};
getTypeName() => "SetPdfModelResponse";
TypeContext? context = _ctx;
}
class PdfModel implements IConvertible
{
String? model;
PdfModel({this.model});
PdfModel.fromJson(Map<String, dynamic> json) { fromMap(json); }
fromMap(Map<String, dynamic> json) {
model = json['model'];
return this;
}
Map<String, dynamic> toJson() => {
'model': model
};
getTypeName() => "PdfModel";
TypeContext? context = _ctx;
}
class SetPdfModelRequest implements IConvertible
{
PdfModel? pdfModel;
SetPdfModelRequest({this.pdfModel});
SetPdfModelRequest.fromJson(Map<String, dynamic> json) { fromMap(json); }
fromMap(Map<String, dynamic> json) {
pdfModel = JsonConverters.fromJson(json['pdfModel'],'PdfModel',context!);
return this;
}
Map<String, dynamic> toJson() => {
'pdfModel': JsonConverters.toJson(pdfModel,'PdfModel',context!)
};
getTypeName() => "SetPdfModelRequest";
TypeContext? context = _ctx;
}
TypeContext _ctx = TypeContext(library: 'hcbtas_q_albamfs_api.azurewebsites.net', types: <String, TypeInfo> {
'SetPdfModelResponse': TypeInfo(TypeOf.Class, create:() => SetPdfModelResponse()),
'PdfModel': TypeInfo(TypeOf.Class, create:() => PdfModel()),
'SetPdfModelRequest': TypeInfo(TypeOf.Class, create:() => SetPdfModelRequest()),
});
To override the Content-type in your clients, use the HTTP Accept Header, append the .jsv suffix or ?format=jsv
The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.
POST /pdf/model HTTP/1.1
Host: hcbtas-q-albamfs-api.azurewebsites.net
Accept: text/jsv
Content-Type: text/jsv
Content-Length: length
{
pdfModel:
{
model: String
}
}
HTTP/1.1 200 OK Content-Type: text/jsv Content-Length: length { id: 00000000000000000000000000000000, success: False }