Trendsic Platform Service

<back to all web services

ImportHistoryRequest

Requires Authentication
The following routes are available for this service:
GET/v1/import/history
import Foundation
import ServiceStack

public class ImportHistoryRequest : Codable
{
    required public init(){}
}

public class ImportHistoryResponse : Codable
{
    public var batches:[ImportBatchLog] = []
    public var responseStatus:ResponseStatus

    required public init(){}
}

public class ImportBatchLog : Codable
{
    public var importBatchId:Int
    public var batchUID:String
    public var importType:String
    public var fileName:String
    public var status:String
    public var totalRows:Int
    public var insertedRows:Int
    public var updatedRows:Int
    public var skippedRows:Int
    public var errorRows:Int
    public var createdBy:String
    public var createdAt:Date

    required public init(){}
}


Swift ImportHistoryRequest 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.

GET /v1/import/history HTTP/1.1 
Host: api.dev.dynamics.trendsic.com 
Accept: text/csv
HTTP/1.1 200 OK
Content-Type: text/csv
Content-Length: length

{"Batches":[{"ImportBatchId":0,"BatchUID":"00000000000000000000000000000000","ImportType":"String","FileName":"String","Status":"String","TotalRows":0,"InsertedRows":0,"UpdatedRows":0,"SkippedRows":0,"ErrorRows":0,"CreatedBy":"String","CreatedAt":"0001-01-01T00:00:00.0000000"}],"ResponseStatus":{"ErrorCode":"String","Message":"String","StackTrace":"String","Errors":[{"ErrorCode":"String","FieldName":"String","Message":"String","Meta":{"String":"String"}}],"Meta":{"String":"String"}}}