Field Squared API Services

<back to all web services

DiscreetDocumentSchema

The following routes are available for this service:
GET, PUT, POST, DELETE/{Workspace}/DiscreetDocumentSchema
GET, PUT POST, DELETE/{Workspace}/DiscreetDocumentSchema/{Type}
Imports System
Imports System.Collections
Imports System.Collections.Generic
Imports System.Runtime.Serialization
Imports ServiceStack
Imports ServiceStack.DataAnnotations
Imports Field2Office.API.Model.DiscreetDocument

Namespace Global

    Namespace Field2Office.API.Model.DiscreetDocument

        Public Partial Class DiscreetDocumentField
            Public Overridable Property Key As String
            Public Overridable Property Name As String
            Public Overridable Property Description As String
            Public Overridable Property DataType As String
            Public Overridable Property Indexed As Boolean
        End Class

        Public Partial Class DiscreetDocumentSchema
            Public Sub New()
                FieldDefs = New List(Of DiscreetDocumentField)
            End Sub

            Public Overridable Property Workspace As String
            Public Overridable Property Created As String
            Public Overridable Property LastUpdated As String
            Public Overridable Property Type As String
            Public Overridable Property Name As String
            Public Overridable Property Description As String
            Public Overridable Property FieldDefs As List(Of DiscreetDocumentField)
            Public Overridable Property Enabled As Nullable(Of Boolean)
        End Class
    End Namespace
End Namespace

VB.NET DiscreetDocumentSchema DTOs

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

HTTP + CSV

The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.

POST /{Workspace}/DiscreetDocumentSchema HTTP/1.1 
Host: dev.fieldsquared.com 
Accept: text/csv
Content-Type: text/csv
Content-Length: length

{"Workspace":"String","Created":"String","LastUpdated":"String","Type":"String","Name":"String","Description":"String","FieldDefs":[{"Key":"String","Name":"String","Description":"String","DataType":"String","Indexed":false}],"Enabled":false}