Trendsic Platform Service

<back to all web services

MaterialShortfallsRequest

Requires Authentication
The following routes are available for this service:
GET,OPTIONS/v1/projects/{ProjectID}/material-shortfalls
import java.math.*
import java.util.*
import java.io.InputStream
import net.servicestack.client.*


open class MaterialShortfallsRequest
{
    open var ProjectID:Int? = null
}

open class MaterialShortfallsResponse
{
    open var ResponseStatus:ResponseStatus? = null
    open var ProjectID:Int? = null
    open var Shortfalls:ArrayList<MaterialShortfall> = ArrayList<MaterialShortfall>()
}

open class MaterialShortfall
{
    open var MaterialID:Int? = null
    open var Name:String? = null
    open var MaterialType:String? = null
    open var OnHand:BigDecimal? = null
    open var QtyNeeded:BigDecimal? = null
    open var ShortQty:BigDecimal? = null
    open var Unit:String? = null
    open var UnitPrice:BigDecimal? = null
    open var EstUSD:BigDecimal? = null
    open var Vendor:String? = null
    open var JobStartDate:Date? = null
}

Kotlin MaterialShortfallsRequest 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/projects/{ProjectID}/material-shortfalls HTTP/1.1 
Host: api.dev.dynamics.trendsic.com 
Accept: text/jsv
HTTP/1.1 200 OK
Content-Type: text/jsv
Content-Length: length

{
	ResponseStatus: 
	{
		ErrorCode: String,
		Message: String,
		StackTrace: String,
		Errors: 
		[
			{
				ErrorCode: String,
				FieldName: String,
				Message: String,
				Meta: 
				{
					String: String
				}
			}
		],
		Meta: 
		{
			String: String
		}
	},
	ProjectID: 0,
	Shortfalls: 
	[
		{
			MaterialID: 0,
			Name: String,
			MaterialType: String,
			OnHand: 0,
			QtyNeeded: 0,
			ShortQty: 0,
			Unit: String,
			UnitPrice: 0,
			EstUSD: 0,
			Vendor: String,
			JobStartDate: 0001-01-01
		}
	]
}