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
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 PurchaseOrder
            Public Overridable Property PurchaseOrderID As Integer
            Public Overridable Property PurchaseOrderUID As Guid
            Public Overridable Property ProjectID As Integer
            Public Overridable Property PONumber As String
            Public Overridable Property Vendor As String
            Public Overridable Property Status As String
            Public Overridable Property AmountUSD As Decimal
            Public Overridable Property CostCode As String
            Public Overridable Property NeedByDate As Date?
            Public Overridable Property Notes As String
            Public Overridable Property IssuedAt As Date?
            Public Overridable Property ReceivedAt As Date?
            Public Overridable Property CreatedBy As String
            Public Overridable Property CreatedAt As Date?
            Public Overridable Property UpdatedAt As Date?
            Public Overridable Property LineCount As Integer
            Public Overridable Property FirstItem As String
            Public Overridable Property DaysToNeed As Integer
            Public Overridable Property Lines As List(Of PurchaseOrderLine) = New List(Of PurchaseOrderLine)
        End Class

        Public Partial Class PurchaseOrderBuyoutSummary
            Public Overridable Property ProjectID As Integer
            Public Overridable Property MaterialBudget As Decimal
            Public Overridable Property Committed As Decimal
            Public Overridable Property Received As Decimal
            Public Overridable Property OpenPOs As Integer
            Public Overridable Property LatePOs As Integer
            Public Overridable Property POCount As Integer
            Public Overridable Property RemainingBuyout As Decimal
        End Class

        Public Partial Class PurchaseOrderLine
            Public Overridable Property PurchaseOrderLineID As Integer
            Public Overridable Property PurchaseOrderID As Integer
            Public Overridable Property MaterialID As Integer?
            Public Overridable Property Description As String
            Public Overridable Property Unit As String
            Public Overridable Property Qty As Decimal
            Public Overridable Property UnitPrice As Decimal
            Public Overridable Property QtyReceived As Decimal
            Public Overridable Property CostCode As String
            Public Overridable Property SortOrder As Integer
        End Class

        Public Partial Class PurchaseOrderListRequest
            Public Overridable Property ProjectID As Integer
        End Class

        Public Partial Class PurchaseOrderListResponse
            Public Overridable Property ResponseStatus As ResponseStatus
            Public Overridable Property ProjectID As Integer
            Public Overridable Property Orders As List(Of PurchaseOrder) = New List(Of PurchaseOrder)
            Public Overridable Property Summary As PurchaseOrderBuyoutSummary
        End Class
    End Namespace
End Namespace

VB.NET PurchaseOrderListRequest DTOs

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

HTTP + OTHER

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/jsonl
HTTP/1.1 200 OK
Content-Type: text/jsonl
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-01T00:00:00.0000000","Notes":"String","IssuedAt":"0001-01-01T00:00:00.0000000","ReceivedAt":"0001-01-01T00:00:00.0000000","CreatedBy":"String","CreatedAt":"0001-01-01T00:00:00.0000000","UpdatedAt":"0001-01-01T00:00:00.0000000","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}}