Trendsic Platform Service

<back to all web services

ErrorLogRequest

The following routes are available for this service:
GET,POST,OPTIONS/v1/ErrorLog
import 'package:servicestack/servicestack.dart';
import 'dart:typed_data';

class ErrorLog implements IConvertible
{
    int? ErrorLogId;
    String? Message;
    String? Page;
    int? LineNumber;
    int? ColNumber;
    String? UserAgent;
    DateTime? LogDate;

    ErrorLog({this.ErrorLogId,this.Message,this.Page,this.LineNumber,this.ColNumber,this.UserAgent,this.LogDate});
    ErrorLog.fromJson(Map<String, dynamic> json) { fromMap(json); }

    fromMap(Map<String, dynamic> json) {
        ErrorLogId = json['ErrorLogId'];
        Message = json['Message'];
        Page = json['Page'];
        LineNumber = json['LineNumber'];
        ColNumber = json['ColNumber'];
        UserAgent = json['UserAgent'];
        LogDate = JsonConverters.fromJson(json['LogDate'],'DateTime',context!);
        return this;
    }

    Map<String, dynamic> toJson() => {
        'ErrorLogId': ErrorLogId,
        'Message': Message,
        'Page': Page,
        'LineNumber': LineNumber,
        'ColNumber': ColNumber,
        'UserAgent': UserAgent,
        'LogDate': JsonConverters.toJson(LogDate,'DateTime',context!)
    };

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

class ErrorLogResponse implements IConvertible
{
    ResponseStatus? ResponseStatus;
    List<ErrorLog>? ErrorLog = [];

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

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

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

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

class ErrorLogRequest implements IConvertible
{
    List<ErrorLog>? ErrorLog = [];

    ErrorLogRequest({this.ErrorLog});
    ErrorLogRequest.fromJson(Map<String, dynamic> json) { fromMap(json); }

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

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

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

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

Dart ErrorLogRequest DTOs

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

HTTP + CSV

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

POST /v1/ErrorLog HTTP/1.1 
Host: api.dev.dynamics.trendsic.com 
Accept: text/csv
Content-Type: text/csv
Content-Length: length

{"ErrorLog":[{"ErrorLogId":0,"Message":"String","Page":"String","LineNumber":0,"ColNumber":0,"UserAgent":"String","LogDate":"0001-01-01T00:00:00.0000000"}]}
HTTP/1.1 200 OK
Content-Type: text/csv
Content-Length: length

{"ResponseStatus":{"ErrorCode":"String","Message":"String","StackTrace":"String","Errors":[{"ErrorCode":"String","FieldName":"String","Message":"String","Meta":{"String":"String"}}],"Meta":{"String":"String"}},"ErrorLog":[{"ErrorLogId":0,"Message":"String","Page":"String","LineNumber":0,"ColNumber":0,"UserAgent":"String","LogDate":"0001-01-01T00:00:00.0000000"}]}