ScannerVision Web Server

<back to all web services

PostConnections

The following routes are available for this service:
POST/connections
Imports System
Imports System.Collections
Imports System.Collections.Generic
Imports System.Runtime.Serialization
Imports ServiceStack
Imports ServiceStack.DataAnnotations
Imports ScannerVision.WebService.ServiceModel
Imports ScannerVision.Settings.Interfaces
Imports ScannerVision.Settings
Imports ScannerVision.Types.Connections

Namespace Global

    Namespace ScannerVision.Settings

        Public Enum PermissionType
            Group
            User
        End Enum
    End Namespace

    Namespace ScannerVision.Settings.Interfaces

        Public Interface IConnectionPermission
            Implements IInterface
            Property Allow As Boolean
            Property Connection As IConnectorConnection
            Property Type As PermissionType
        End Interface

        Public Interface IConnectionPropertyDescription
            Implements IInterface
            Property Description As String
            Property Name As String
            Property PropertyId As Guid
            Property PropertyType As PropertyType
        End Interface

        Public Interface IConnectorConnection
            Implements IStatus
            Property ConnectorId As Guid
            Property Description As String
            Property Id As String
            Property MaxConnections As Integer
            Property Name As String
            Property Permissions As ReadOnlyCollection(Of IConnectionPermission)
            Property PropertyDescriptions As ReadOnlyCollection(Of IConnectionPropertyDescription)
            Property SetupUser As IUser
        End Interface

        Public Interface IUser
            Implements IIdTemplatesItem
            Property Groups As ReadOnlyCollection(Of IUserGroup)
            Property EmailAddress As String
            Property HasPassword As Boolean
            Property HomeFolder As String
            Property Password As String
            Property SbcUser As Nullable(Of Boolean)
        End Interface

        Public Interface IUserGroup
            Implements IIdTemplatesItem
            Implements IGroup
            Property Users As ReadOnlyCollection(Of IUser)
        End Interface
    End Namespace

    Namespace ScannerVision.Types.Connections

        Public Enum PropertyType
            Binary = 1
            Boolean = 2
            ConnectionString = 3
            Credential = 4
            [Integer] = 5
            Picklist = 6
            [String] = 7
            OAuth2 = 8
            Certificate = 9
        End Enum
    End Namespace

    Namespace ScannerVision.WebService.ServiceModel

        Public Partial Class GetConnectionsResponse
            Public Overridable Property Connections As IEnumerable(Of IConnectorConnection)
            Public Overridable Property IsAuthenticated As Boolean
        End Class

        Public Partial Class PostConnections
            Public Overridable Property LoginCommand As String
            Public Overridable Property LogoutCommand As String
            Public Overridable Property Password As String
            Public Overridable Property SaveCommand As String
            Public Overridable Property UserName As String
        End Class
    End Namespace
End Namespace

VB.NET PostConnections 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 /connections HTTP/1.1 
Host: buildmax.org 
Accept: text/csv
Content-Type: text/csv
Content-Length: length

{"LoginCommand":"String","LogoutCommand":"String","Password":"String","SaveCommand":"String","UserName":"String"}
HTTP/1.1 200 OK
Content-Type: text/csv
Content-Length: length

{Unable to show example output for type 'GetConnectionsResponse' using the custom 'csv' filter}No parameterless constructor defined for this object.