Trendsic Platform Service

<back to all web services

DispatchSettlementRequest

Requires Authentication
The following routes are available for this service:
GET,OPTIONS/v1/dispatch/settlements/{SettlementId}
Imports System
Imports System.IO
Imports System.Collections
Imports System.Collections.Generic
Imports System.Runtime.Serialization
Imports ServiceStack
Imports ServiceStack.DataAnnotations
Imports CRM.AgencyPlatform.API.Internal

Namespace Global

    Namespace CRM.AgencyPlatform.API.Internal

        Public Partial Class DispatchLoadStageView
            Public Overridable Property Stage As String
            Public Overridable Property AtUtc As Date
            Public Overridable Property Note As String
        End Class

        Public Partial Class DispatchLoadView
            Public Overridable Property LoadId As Integer
            Public Overridable Property Code As String
            Public Overridable Property [Module] As String
            Public Overridable Property TruckLabel As String
            Public Overridable Property DriverLabel As String
            Public Overridable Property CarrierLabel As String
            Public Overridable Property SourceLabel As String
            Public Overridable Property DestinationLabel As String
            Public Overridable Property Qty As Decimal?
            Public Overridable Property Unit As String
            Public Overridable Property QtyText As String
            Public Overridable Property TicketCode As String
            Public Overridable Property RateApplied As Decimal?
            Public Overridable Property RateBasis As String
            Public Overridable Property Revenue As Decimal?
            Public Overridable Property PayPlanLabel As String
            Public Overridable Property Pay As Decimal?
            Public Overridable Property Status As String
            Public Overridable Property OpenedUtc As Date
            Public Overridable Property ClosedUtc As Date?
            Public Overridable Property Photos As Integer
            Public Overridable Property Stages As List(Of DispatchLoadStageView) = New List(Of DispatchLoadStageView)
        End Class

        Public Partial Class DispatchSettlementDeductionView
            Public Overridable Property DeductionId As Integer
            Public Overridable Property Kind As String
            Public Overridable Property Label As String
            Public Overridable Property Amount As Decimal
            Public Overridable Property Note As String
        End Class

        Public Partial Class DispatchSettlementRequest
            Public Overridable Property SettlementId As Integer
        End Class

        Public Partial Class DispatchSettlementsResponse
            Public Overridable Property Settlements As List(Of DispatchSettlementView) = New List(Of DispatchSettlementView)
            Public Overridable Property Settlement As DispatchSettlementView
            Public Overridable Property Suggestions As List(Of DispatchSettlementSuggestView) = New List(Of DispatchSettlementSuggestView)
            Public Overridable Property ResponseStatus As ResponseStatus
        End Class

        Public Partial Class DispatchSettlementSuggestView
            Public Overridable Property VendorID As Integer
            Public Overridable Property VendorName As String
            Public Overridable Property SplitPct As Decimal
            Public Overridable Property Terms As String
            Public Overridable Property W9OnFile As Boolean
            Public Overridable Property CoiExpires As Date?
            Public Overridable Property PeriodStart As Date
            Public Overridable Property PeriodEnd As Date
            Public Overridable Property UnsettledLoads As Integer
            Public Overridable Property UnpricedLoads As Integer
            Public Overridable Property UnsettledPay As Decimal
        End Class

        Public Partial Class DispatchSettlementView
            Public Overridable Property SettlementId As Integer
            Public Overridable Property Code As String
            Public Overridable Property VendorID As Integer
            Public Overridable Property VendorName As String
            Public Overridable Property PeriodStart As Date
            Public Overridable Property PeriodEnd As Date
            Public Overridable Property LoadCount As Integer
            Public Overridable Property GrossRevenue As Decimal
            Public Overridable Property SplitPct As Decimal
            Public Overridable Property CarrierShare As Decimal
            Public Overridable Property DeductionsTotal As Decimal
            Public Overridable Property Net As Decimal
            Public Overridable Property Status As String
            Public Overridable Property Notes As String
            Public Overridable Property GeneratedUtc As Date
            Public Overridable Property SentUtc As Date?
            Public Overridable Property ApprovedUtc As Date?
            Public Overridable Property ApprovedBy As String
            Public Overridable Property PaidUtc As Date?
            Public Overridable Property PaidRef As String
            Public Overridable Property ContactCount As Integer
            Public Overridable Property Deductions As List(Of DispatchSettlementDeductionView) = New List(Of DispatchSettlementDeductionView)
            Public Overridable Property Loads As List(Of DispatchLoadView) = New List(Of DispatchLoadView)
        End Class
    End Namespace
End Namespace

VB.NET DispatchSettlementRequest DTOs

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

HTTP + JSV

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

GET /v1/dispatch/settlements/{SettlementId} HTTP/1.1 
Host: api.dev.dynamics.trendsic.com 
Accept: text/jsv
HTTP/1.1 200 OK
Content-Type: text/jsv
Content-Length: length

{
	Settlements: 
	[
		{
			SettlementId: 0,
			Code: String,
			VendorID: 0,
			VendorName: String,
			PeriodStart: 0001-01-01,
			PeriodEnd: 0001-01-01,
			LoadCount: 0,
			GrossRevenue: 0,
			SplitPct: 0,
			CarrierShare: 0,
			DeductionsTotal: 0,
			Net: 0,
			Status: String,
			Notes: String,
			GeneratedUtc: 0001-01-01,
			SentUtc: 0001-01-01,
			ApprovedUtc: 0001-01-01,
			ApprovedBy: String,
			PaidUtc: 0001-01-01,
			PaidRef: String,
			ContactCount: 0,
			Deductions: 
			[
				{
					DeductionId: 0,
					Kind: String,
					Label: String,
					Amount: 0,
					Note: String
				}
			],
			Loads: 
			[
				{
					LoadId: 0,
					Code: String,
					Module: String,
					TruckLabel: String,
					DriverLabel: String,
					CarrierLabel: String,
					SourceLabel: String,
					DestinationLabel: String,
					Qty: 0,
					Unit: String,
					QtyText: String,
					TicketCode: String,
					RateApplied: 0,
					RateBasis: String,
					Revenue: 0,
					PayPlanLabel: String,
					Pay: 0,
					Status: String,
					OpenedUtc: 0001-01-01,
					ClosedUtc: 0001-01-01,
					Photos: 0,
					Stages: 
					[
						{
							Stage: String,
							AtUtc: 0001-01-01,
							Note: String
						}
					]
				}
			]
		}
	],
	Settlement: 
	{
		SettlementId: 0,
		Code: String,
		VendorID: 0,
		VendorName: String,
		PeriodStart: 0001-01-01,
		PeriodEnd: 0001-01-01,
		LoadCount: 0,
		GrossRevenue: 0,
		SplitPct: 0,
		CarrierShare: 0,
		DeductionsTotal: 0,
		Net: 0,
		Status: String,
		Notes: String,
		GeneratedUtc: 0001-01-01,
		SentUtc: 0001-01-01,
		ApprovedUtc: 0001-01-01,
		ApprovedBy: String,
		PaidUtc: 0001-01-01,
		PaidRef: String,
		ContactCount: 0,
		Deductions: 
		[
			{
				DeductionId: 0,
				Kind: String,
				Label: String,
				Amount: 0,
				Note: String
			}
		],
		Loads: 
		[
			{
				LoadId: 0,
				Code: String,
				Module: String,
				TruckLabel: String,
				DriverLabel: String,
				CarrierLabel: String,
				SourceLabel: String,
				DestinationLabel: String,
				Qty: 0,
				Unit: String,
				QtyText: String,
				TicketCode: String,
				RateApplied: 0,
				RateBasis: String,
				Revenue: 0,
				PayPlanLabel: String,
				Pay: 0,
				Status: String,
				OpenedUtc: 0001-01-01,
				ClosedUtc: 0001-01-01,
				Photos: 0,
				Stages: 
				[
					{
						Stage: String,
						AtUtc: 0001-01-01,
						Note: String
					}
				]
			}
		]
	},
	Suggestions: 
	[
		{
			VendorID: 0,
			VendorName: String,
			SplitPct: 0,
			Terms: String,
			W9OnFile: False,
			CoiExpires: 0001-01-01,
			PeriodStart: 0001-01-01,
			PeriodEnd: 0001-01-01,
			UnsettledLoads: 0,
			UnpricedLoads: 0,
			UnsettledPay: 0
		}
	],
	ResponseStatus: 
	{
		ErrorCode: String,
		Message: String,
		StackTrace: String,
		Errors: 
		[
			{
				ErrorCode: String,
				FieldName: String,
				Message: String,
				Meta: 
				{
					String: String
				}
			}
		],
		Meta: 
		{
			String: String
		}
	}
}