| POST | /v1/coverage/pto/{WorkerTimeOffID}/decide |
|---|
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 CoveragePlannedItem
Public Overridable Property WorkerTimeOffID As Integer
Public Overridable Property ContactId As Integer
Public Overridable Property WorkerName As String
Public Overridable Property Initials As String
Public Overridable Property Dates As String
Public Overridable Property Reason As String
Public Overridable Property Stage As String
Public Overridable Property StageLabel As String
Public Overridable Property NeedBook As Boolean
Public Overridable Property CoverageGapId As Integer?
Public Overridable Property Checks As List(Of CoveragePtoCheck) = New List(Of CoveragePtoCheck)
Public Overridable Property DenyReason As String
End Class
Public Partial Class CoveragePlannedResponse
Public Overridable Property Items As List(Of CoveragePlannedItem) = New List(Of CoveragePlannedItem)
Public Overridable Property ResponseStatus As ResponseStatus
End Class
Public Partial Class CoveragePtoCheck
Public Overridable Property Ok As Boolean
Public Overridable Property Text As String
End Class
Public Partial Class CoveragePtoDecideRequest
Public Overridable Property WorkerTimeOffID As Integer
Public Overridable Property Approve As Boolean
Public Overridable Property DenyReason As String
End Class
End Namespace
End Namespace
VB.NET CoveragePtoDecideRequest DTOs
To override the Content-type in your clients, use the HTTP Accept Header, append the .json suffix or ?format=json
To embed the response in a jsonp callback, append ?callback=myCallback
The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.
POST /v1/coverage/pto/{WorkerTimeOffID}/decide HTTP/1.1
Host: api.dev.dynamics.trendsic.com
Accept: application/json
Content-Type: application/json
Content-Length: length
{"WorkerTimeOffID":0,"Approve":false,"DenyReason":"String"}
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: length
{"Items":[{"WorkerTimeOffID":0,"ContactId":0,"WorkerName":"String","Initials":"String","Dates":"String","Reason":"String","Stage":"String","StageLabel":"String","NeedBook":false,"CoverageGapId":0,"Checks":[{"Ok":false,"Text":"String"}],"DenyReason":"String"}],"ResponseStatus":{"ErrorCode":"String","Message":"String","StackTrace":"String","Errors":[{"ErrorCode":"String","FieldName":"String","Message":"String","Meta":{"String":"String"}}],"Meta":{"String":"String"}}}