Trendsic Platform Service

<back to all web services

PurchaseOrderListRequest

Requires Authentication
The following routes are available for this service:
GET,OPTIONS/v1/projects/{ProjectID}/purchase-orders
PurchaseOrderListRequest Parameters:
NameParameterData TypeRequiredDescription
ProjectIDpathintNo
PurchaseOrderListResponse Parameters:
NameParameterData TypeRequiredDescription
ResponseStatusformResponseStatusNo
ProjectIDformintNo
OrdersformList<PurchaseOrder>No
SummaryformPurchaseOrderBuyoutSummaryNo
PurchaseOrder Parameters:
NameParameterData TypeRequiredDescription
PurchaseOrderIDformintNo
PurchaseOrderUIDformGuidNo
ProjectIDformintNo
PONumberformstringNo
VendorformstringNo
StatusformstringNo
AmountUSDformdecimalNo
CostCodeformstringNo
NeedByDateformDateTime?No
NotesformstringNo
IssuedAtformDateTime?No
ReceivedAtformDateTime?No
CreatedByformstringNo
CreatedAtformDateTime?No
UpdatedAtformDateTime?No
LineCountformintNo
FirstItemformstringNo
DaysToNeedformintNo
LinesformList<PurchaseOrderLine>No
PurchaseOrderLine Parameters:
NameParameterData TypeRequiredDescription
PurchaseOrderLineIDformintNo
PurchaseOrderIDformintNo
MaterialIDformint?No
DescriptionformstringNo
UnitformstringNo
QtyformdecimalNo
UnitPriceformdecimalNo
QtyReceivedformdecimalNo
CostCodeformstringNo
SortOrderformintNo
PurchaseOrderBuyoutSummary Parameters:
NameParameterData TypeRequiredDescription
ProjectIDformintNo
MaterialBudgetformdecimalNo
CommittedformdecimalNo
ReceivedformdecimalNo
OpenPOsformintNo
LatePOsformintNo
POCountformintNo
RemainingBuyoutformdecimalNo

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}/purchase-orders 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,
	Orders: 
	[
		{
			PurchaseOrderID: 0,
			PurchaseOrderUID: 00000000000000000000000000000000,
			ProjectID: 0,
			PONumber: String,
			Vendor: String,
			Status: String,
			AmountUSD: 0,
			CostCode: String,
			NeedByDate: 0001-01-01,
			Notes: String,
			IssuedAt: 0001-01-01,
			ReceivedAt: 0001-01-01,
			CreatedBy: String,
			CreatedAt: 0001-01-01,
			UpdatedAt: 0001-01-01,
			LineCount: 0,
			FirstItem: String,
			DaysToNeed: 0,
			Lines: 
			[
				{
					PurchaseOrderLineID: 0,
					PurchaseOrderID: 0,
					MaterialID: 0,
					Description: String,
					Unit: String,
					Qty: 0,
					UnitPrice: 0,
					QtyReceived: 0,
					CostCode: String,
					SortOrder: 0
				}
			]
		}
	],
	Summary: 
	{
		ProjectID: 0,
		MaterialBudget: 0,
		Committed: 0,
		Received: 0,
		OpenPOs: 0,
		LatePOs: 0,
		POCount: 0,
		RemainingBuyout: 0
	}
}