ScannerVision Web Server

<back to all web services

ShowScanSettings

Requires Authentication
The following routes are available for this service:
All Verbs/{Brand}/showscansettings/{TemplateGuid}
Imports System
Imports System.Collections
Imports System.Collections.Generic
Imports System.Runtime.Serialization
Imports ServiceStack
Imports ServiceStack.DataAnnotations
Imports ScannerVision.WebService.ServiceModel
Imports ScannerVision.SystemTypes.SvMain.Interfaces
Imports ScannerVision.Template.Interfaces
Imports ScannerVision.Template
Imports ScannerVision.CSCommon.Types.Interfaces
Imports ScannerVision.Types
Imports ScannerVision.WebService.ServiceModel.Interfaces
Imports ScannerVision.Web.Types

Namespace Global

    Namespace ScannerVision.CSCommon.Types.Interfaces

        Public Interface IValidator
            Property ValidationErrors As IValidationErrors
            Property IsValid As Boolean
        End Interface
    End Namespace

    Namespace ScannerVision.SystemTypes.SvMain.Interfaces

        Public Interface IClientQuestion
            Implements ITemplateQuestion
            Property QuestionGuid As String
            Property ValueDisplayed As String
            Property ValueReturned As String
            Property Answered As Boolean
            Property RegexMatches As Boolean
            Property RegexHint As String
        End Interface

        Public Interface IClientTemplate
            Property Description As String
            Property Icon As Byte()
            Property ModificationInfo As ITemplateModificationInfo
            Property Name As String
            Property Questions As IEnumerable(Of IClientQuestion)
            Property Template As ITemplate
            Property TemplateGuid As String
        End Interface

        Public Interface ITemplateModificationInfo
            Property Guid As String
            Property TemplateModificationDateTime As Date
            Property IconModificationDateTime As Date
        End Interface
    End Namespace

    Namespace ScannerVision.Template

        Public Enum NotificationType
            FailureOnly
            SuccessOnly
            Always
        End Enum

        Public Enum PdfLoadResolution
            [Default]
            Dpi100
            Dpi150
            Dpi200
            Dpi300
            Dpi400
            Dpi500
            Dpi600
        End Enum

        Public Enum ScanColour
            BlackAndWhite
            Greyscale
            Colour
            Auto
        End Enum

        Public Enum ScanOrientation
            Portrait
            Landscape
        End Enum

        Public Enum ScanResolution
            Dpi100
            Dpi200
            Dpi300
            Dpi400
            Dpi600
        End Enum

        Public Enum ScanSide
            Simplex
            Duplex
        End Enum

        Public Enum ScanSize
            Auto
            A3
            A4
            A5
            B4
            B5
            Letter
            Legal
            Executive
            Folio
            AutoLong
            A4R
            A5R
            A6R
            B6R
        End Enum

        Public Enum ScanSource
            Adf
            Glass
            Auto
        End Enum

        Public Enum ScanType
            Text
            Photo
            TextAndPhoto
        End Enum

        Public Enum TemplateScheduleType
            Interval
            Fixed
        End Enum

        Public Enum TemplateType
            Workflow
            FreeForm
        End Enum
    End Namespace

    Namespace ScannerVision.Template.Interfaces

        Public Interface IBadDocumentRejection
            Implements IStatus
            Property RejectionPath As String
            Property ShareCredentials As ICredentials
        End Interface

        Public Interface ICapture
            Implements IInterface
            Property CaptureSources As ReadOnlyCollection(Of ICaptureSource)
        End Interface

        Public Interface ICaptureSource
            Implements IStatus
        End Interface

        Public Interface ICredentials
            Implements IInterface
            Property Username As String
            Property Password As String
        End Interface

        Public Interface IGeneral
            Implements IInterface
            Property Name As String
            Property Description As String
            Property Icon As String
            Property Schedule As ITemplateSchedule
            Property Rejection As IRejection
            Property BadDocumentRejection As IBadDocumentRejection
            Property PdfLoadResolution As Nullable(Of PdfLoadResolution)
        End Interface

        Public Interface INotification
            Implements IStatus
            Property Description As String
            Property To As String
            Property Subject As String
            Property Body As String
            Property Cc As String
            Property Bcc As String
            Property NotificationType As Nullable(Of NotificationType)
        End Interface

        Public Interface INotifications
            Implements IStatus
            Property Notifications As ReadOnlyCollection(Of INotification)
        End Interface

        Public Interface IRejection
            Property RejectAfter As Nullable(Of Integer)
            Property RejectionPath As String
            Property ShareCredentials As ICredentials
        End Interface

        Public Interface IStringMetadata
            Implements IMetadata
            Property IsSecure As Nullable(Of Boolean)
            Property SampleValue As String
            Property Value As String
        End Interface

        Public Interface ITemplate
            Implements IStatus
            Property TemplateVersion As String
            Property ScannerVisionVersion As String
            Property Guid As String
            Property BeginScript As String
            Property EndScript As String
            Property TemplateType As TemplateType
            Property General As IGeneral
            Property Capture As ICapture
            Property XmlMetadataImport As IXmlMetadataImport
            Property Notifications As INotifications
            Property Validator As IValidator
        End Interface

        Public Interface ITemplateSchedule
            Implements IInterface
            Property Time As Nullable(Of TimeSpan)
            Property EndTime As Nullable(Of TimeSpan)
            Property NoEndTime As Nullable(Of Boolean)
            Property Type As Nullable(Of TemplateScheduleType)
        End Interface

        Public Interface IXmlMetadataImport
            Implements IStatus
            Property SampleDocumentName As String
            Property TagMappings As ReadOnlyCollection(Of IXmlMetadataImportTagMapping)
            Property NamespaceMappings As ReadOnlyCollection(Of IXmlMetadataImportNamespaceMapping)
        End Interface

        Public Interface IXmlMetadataImportNamespaceMapping
            Implements IInterface
            Property Prefix As String
            Property Name As String
        End Interface

        Public Interface IXmlMetadataImportTagMapping
            Implements IInterface
            Property XPathExpression As String
            Property Metadata As IStringMetadata
        End Interface
    End Namespace

    Namespace ScannerVision.Types

        Public Interface IValidationError
            Property Property As String
            Property ErrorMessage As String
        End Interface

        Public Interface IValidationErrors
            Property Errors As ReadOnlyCollection(Of IValidationError)
        End Interface
    End Namespace

    Namespace ScannerVision.Web.Types

        Public Enum BoolSetting
            [True]
            [False]
        End Enum
    End Namespace

    Namespace ScannerVision.WebService.ServiceModel

        Public Enum Brand
            Desktop
            Hp
            Kyocera
            NeaScan
            Samsung
            FujiXerox
            Ta
            Utax
            Epson
            ScanFront400
            Sharp
            Ricoh
            FujiFilm
        End Enum

        Public Partial Class DtoBase
            Public Overridable Property Brand As Brand
        End Class

        Public Partial Class GetScanSettingsResponse
            Inherits GetTemplateResponse
            Public Overridable Property ScanSettings As IScanSettings
            Public Overridable Property ColourLabel As String
            Public Overridable Property OrientationLabel As String
            Public Overridable Property ResolutionLabel As String
            Public Overridable Property SidesLabel As String
            Public Overridable Property SizeLabel As String
            Public Overridable Property SourceLabel As String
            Public Overridable Property TypeLabel As String
            Public Overridable Property ScanContinuouslyLabel As String
            Public Overridable Property MixedSizesLabel As String
        End Class

        Public Partial Class GetTemplateResponse
            Inherits ScanResponseBase
            Public Overridable Property ServerAddress As String
            Public Overridable Property ServerPort As Integer
        End Class

        Public Partial Class RequestBase
            Inherits DtoBase
        End Class

        Public Partial Class ResponseBase
            Inherits DtoBase
            Public Overridable Property SelectedUiLanguage As String
            Public Overridable Property svSession As String
            Public Overridable Property Title As String
            Public Overridable Property PageTip As String
            Public Overridable Property NewBrowser As Boolean
            Public Overridable Property ScanFront400TA As Boolean
            Public Overridable Property ScanFront400UTAX As Boolean
        End Class

        Public Partial Class ScanResponseBase
            Inherits ResponseBase
            Public Overridable Property Template As IClientTemplate
            Public Overridable Property GlobalQuestions As IEnumerable(Of IClientQuestion)
            Public Overridable Property CanEnableScanButton As Boolean
        End Class

        Public Partial Class ShowScanSettings
            Inherits RequestBase
            Public Overridable Property TemplateGuid As String
        End Class
    End Namespace

    Namespace ScannerVision.WebService.ServiceModel.Interfaces

        Public Interface IScanSetting(Of T)
            Property IsLocked As Boolean
            Property Items As IList(Of IScanSettingItem(Of T))
            Property SelectedItem As String
        End Interface

        Public Interface IScanSettings
            Property Colour As IScanSetting(Of ScanColour)
            Property Orientation As IScanSetting(Of ScanOrientation)
            Property Resolution As IScanSetting(Of ScanResolution)
            Property Sides As IScanSetting(Of ScanSide)
            Property Size As IScanSetting(Of ScanSize)
            Property Source As IScanSetting(Of ScanSource)
            Property Type As IScanSetting(Of ScanType)
            Property ScanContinuously As IScanSetting(Of BoolSetting)
            Property MixedSizes As IScanSetting(Of BoolSetting)
        End Interface
    End Namespace
End Namespace

VB.NET ShowScanSettings DTOs

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

HTTP + OTHER

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

POST /{Brand}/showscansettings/{TemplateGuid} HTTP/1.1 
Host: buildmax.org 
Accept: text/jsonl
Content-Type: text/jsonl
Content-Length: length

{"TemplateGuid":"String","Brand":"Desktop"}
HTTP/1.1 200 OK
Content-Type: text/jsonl
Content-Length: length

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