| GET,OPTIONS | /v1/pm/job/{JobID} |
|---|
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 PmJob
Public Overridable Property JobID As Integer
Public Overridable Property Name As String
Public Overridable Property Description As String
Public Overridable Property Status As String
Public Overridable Property StartDate As String
Public Overridable Property EndDate As String
Public Overridable Property CrewCount As Integer
Public Overridable Property BudgetedHours As Double
Public Overridable Property EquipmentCount As Integer
Public Overridable Property MaterialCount As Integer
Public Overridable Property CrewCost As Double
Public Overridable Property EquipCost As Double
Public Overridable Property MatCost As Double
Public Overridable Property Cost As Double
Public Overridable Property NoCrew As Boolean
Public Overridable Property EquipConflict As Boolean
Public Overridable Property MaterialGap As Boolean
Public Overridable Property ReadyPct As Integer
Public Overridable Property Priority As String
Public Overridable Property Tags As List(Of String) = New List(Of String)
Public Overridable Property Crew As List(Of PmJobCrew) = New List(Of PmJobCrew)
Public Overridable Property Equipment As List(Of PmJobResource) = New List(Of PmJobResource)
Public Overridable Property Materials As List(Of PmJobResource) = New List(Of PmJobResource)
End Class
Public Partial Class PmJobCrew
Public Overridable Property ContactID As Integer
Public Overridable Property Name As String
Public Overridable Property Rate As Double
Public Overridable Property BudgetedHours As Double
Public Overridable Property IsOpen As Boolean
End Class
Public Partial Class PmJobRequest
Public Overridable Property JobID As Integer
End Class
Public Partial Class PmJobResource
Public Overridable Property Id As Integer
Public Overridable Property Name As String
Public Overridable Property Amount As Double
Public Overridable Property Qty As Integer
Public Overridable Property Unit As String
End Class
Public Partial Class PmJobResponse
Public Overridable Property Job As PmJob
Public Overridable Property ResponseStatus As ResponseStatus
End Class
End Namespace
End Namespace
To override the Content-type in your clients, use the HTTP Accept Header, append the .jsv suffix or ?format=jsv
The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.
GET /v1/pm/job/{JobID} HTTP/1.1
Host: api.dev.dynamics.trendsic.com
Accept: text/jsv
HTTP/1.1 200 OK
Content-Type: text/jsv
Content-Length: length
{
Job:
{
JobID: 0,
Name: String,
Description: String,
Status: String,
StartDate: String,
EndDate: String,
CrewCount: 0,
BudgetedHours: 0,
EquipmentCount: 0,
MaterialCount: 0,
CrewCost: 0,
EquipCost: 0,
MatCost: 0,
Cost: 0,
NoCrew: False,
EquipConflict: False,
MaterialGap: False,
ReadyPct: 0,
Priority: String,
Tags:
[
String
],
Crew:
[
{
ContactID: 0,
Name: String,
Rate: 0,
BudgetedHours: 0,
IsOpen: False
}
],
Equipment:
[
{
Id: 0,
Name: String,
Amount: 0,
Qty: 0,
Unit: String
}
],
Materials:
[
{
Id: 0,
Name: String,
Amount: 0,
Qty: 0,
Unit: String
}
]
},
ResponseStatus:
{
ErrorCode: String,
Message: String,
StackTrace: String,
Errors:
[
{
ErrorCode: String,
FieldName: String,
Message: String,
Meta:
{
String: String
}
}
],
Meta:
{
String: String
}
}
}