Trendsic Platform Service

<back to all web services

ImportCommitRequest

Requires Authentication
The following routes are available for this service:
POST,OPTIONS/v1/import/{Type}/commit
import java.math.*
import java.util.*
import java.io.InputStream
import net.servicestack.client.*


open class ImportCommitRequest
{
    open var Type:String? = null
}

open class ImportResult
{
    open var ImportType:String? = null
    open var FileName:String? = null
    open var DryRun:Boolean? = null
    open var ImportBatchId:Int? = null
    open var TotalRows:Int? = null
    open var NewRows:Int? = null
    open var UpdatedRows:Int? = null
    open var SkippedRows:Int? = null
    open var ErrorRows:Int? = null
    open var Rows:ArrayList<ImportRowResult> = ArrayList<ImportRowResult>()
    open var ResponseStatus:ResponseStatus? = null
}

open class ImportRowResult
{
    open var Line:Int? = null
    open var Action:String? = null
    open var Field:String? = null
    open var Message:String? = null
    open var Summary:String? = null
}

Kotlin ImportCommitRequest DTOs

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

To embed the response in a jsonp callback, append ?callback=myCallback

HTTP + JSON

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

POST /v1/import/{Type}/commit HTTP/1.1 
Host: api.dev.dynamics.trendsic.com 
Accept: application/json
Content-Type: application/json
Content-Length: length

{"Type":"String"}
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: length

{"ImportType":"String","FileName":"String","DryRun":false,"ImportBatchId":0,"TotalRows":0,"NewRows":0,"UpdatedRows":0,"SkippedRows":0,"ErrorRows":0,"Rows":[{"Line":0,"Action":"String","Field":"String","Message":"String","Summary":"String"}],"ResponseStatus":{"ErrorCode":"String","Message":"String","StackTrace":"String","Errors":[{"ErrorCode":"String","FieldName":"String","Message":"String","Meta":{"String":"String"}}],"Meta":{"String":"String"}}}