| POST | /{Workspace}/ScheduleRequestList |
|---|
Imports System
Imports System.Collections
Imports System.Collections.Generic
Imports System.Runtime.Serialization
Imports ServiceStack
Imports ServiceStack.DataAnnotations
Imports Field2Office.API.Model.Schedules
Namespace Global
Namespace Field2Office.API.Model.Schedules
Public Partial Class Schedule
Public Sub New()
Users = New List(Of String)
Teams = New List(Of String)
Data = New Dictionary(Of String, Object)
End Sub
Public Overridable Property Workspace As String
Public Overridable Property ObjectId As String
Public Overridable Property VersionId As String
Public Overridable Property BasedOn As String
Public Overridable Property Start As String
Public Overridable Property [End] As String
Public Overridable Property TimeZone As String
Public Overridable Property Users As List(Of String)
Public Overridable Property Teams As List(Of String)
Public Overridable Property Data As Dictionary(Of String, Object)
End Class
Public Partial Class ScheduleRequest
Public Sub New()
Users = New List(Of String)
Teams = New List(Of String)
Schedules = New List(Of Schedule)
End Sub
Public Overridable Property Workspace As String
Public Overridable Property ObjectId As String
Public Overridable Property VersionId As String
Public Overridable Property Users As List(Of String)
Public Overridable Property Teams As List(Of String)
Public Overridable Property UnassignUsers As Boolean
Public Overridable Property UnassignTeams As Boolean
Public Overridable Property Unschedule As Boolean
Public Overridable Property DeleteTask As Boolean
Public Overridable Property Status As String
Public Overridable Property Type As String
Public Overridable Property TaskType As String
Public Overridable Property DueDate As String
Public Overridable Property SetPriority As Boolean
Public Overridable Property Priority As Integer
Public Overridable Property Schedules As List(Of Schedule)
End Class
'''<Summary>
'''Set schedules for multiple tasks in a single operation.
'''</Summary>
Public Partial Class ScheduleRequestList
Public Sub New()
ScheduleRequests = New List(Of ScheduleRequest)
End Sub
Public Overridable Property Workspace As String
Public Overridable Property ScheduleRequests As List(Of ScheduleRequest)
End Class
End Namespace
End Namespace
VB.NET ScheduleRequestList 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 /{Workspace}/ScheduleRequestList HTTP/1.1
Host: dev.fieldsquared.com
Accept: application/json
Content-Type: application/json
Content-Length: length
{"Workspace":"String","ScheduleRequests":[{"Workspace":"String","ObjectId":"String","VersionId":"String","Users":["String"],"Teams":["String"],"UnassignUsers":false,"UnassignTeams":false,"Unschedule":false,"DeleteTask":false,"Status":"String","Type":"String","TaskType":"String","DueDate":"String","SetPriority":false,"Priority":0,"Schedules":[{"Workspace":"String","ObjectId":"String","VersionId":"String","BasedOn":"String","Start":"String","End":"String","TimeZone":"String","Users":["String"],"Teams":["String"],"Data":{"String":{}}}]}]}