Server

<back to all web services

Eras2FileDownload

Requires Authentication
The following routes are available for this service:
POST/files/{UserId}/
import 'package:servicestack/servicestack.dart';
import 'dart:typed_data';

class Eras2FileDownloadResponse implements IConvertible
{
    Map<String,String?>? options;
    ResponseStatus? responseStatus;

    Eras2FileDownloadResponse({this.options,this.responseStatus});
    Eras2FileDownloadResponse.fromJson(Map<String, dynamic> json) { fromMap(json); }

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

    Map<String, dynamic> toJson() => {
        'options': JsonConverters.toJson(options,'Map<String,String?>',context!),
        'responseStatus': JsonConverters.toJson(responseStatus,'ResponseStatus',context!)
    };

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

// @DataContract
class Eras2FileDownload implements IConvertible
{
    // @DataMember(Name="UserId")
    String? UserId;

    // @DataMember(Name="FileGuids")
    List<String>? FileGuids;

    Eras2FileDownload({this.UserId,this.FileGuids});
    Eras2FileDownload.fromJson(Map<String, dynamic> json) { fromMap(json); }

    fromMap(Map<String, dynamic> json) {
        UserId = json['userId'];
        FileGuids = JsonConverters.fromJson(json['fileGuids'],'List<String>',context!);
        return this;
    }

    Map<String, dynamic> toJson() => {
        'userId': UserId,
        'fileGuids': JsonConverters.toJson(FileGuids,'List<String>',context!)
    };

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

TypeContext _ctx = TypeContext(library: 'inea_servdesk.eras_online.de', types: <String, TypeInfo> {
    'Eras2FileDownloadResponse': TypeInfo(TypeOf.Class, create:() => Eras2FileDownloadResponse()),
    'Map<String,String?>': TypeInfo(TypeOf.Class, create:() => Map<String,String?>()),
    'Eras2FileDownload': TypeInfo(TypeOf.Class, create:() => Eras2FileDownload()),
});

Dart Eras2FileDownload 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.

POST /files/{UserId}/ HTTP/1.1 
Host: inea-servdesk.eras-online.de 
Accept: text/jsonl
Content-Type: text/jsonl
Content-Length: length

{"UserId":"00000000000000000000000000000000","FileGuids":["00000000000000000000000000000000"]}
HTTP/1.1 200 OK
Content-Type: text/jsonl
Content-Length: length

{Unable to show example output for type 'Eras2FileDownloadResponse' using the custom 'other' filter}Cannot dynamically create an instance of type 'Eras2Web.Service.Desktop.Server.ServiceModel.Eras2Client.Files.Download.Eras2FileDownloadResponse'. Reason: No parameterless constructor defined.