GET | /clients/incomplete/count | Get the number of incomplete clients |
---|
Imports System
Imports System.Collections
Imports System.Collections.Generic
Imports System.Runtime.Serialization
Imports ServiceStack
Imports ServiceStack.DataAnnotations
Imports SanctionsSearch.Api2.ServiceModel.Operations.Clients
Imports SanctionsSearch.Api2.ServiceModel.Operations.Base
Imports SanctionsSearch.Api2.ServiceModel.Types
Namespace Global
Namespace SanctionsSearch.Api2.ServiceModel.Operations.Base
Public Partial Class ArrayOfResponseError
Inherits List(Of ResponseError)
End Class
<DataContract>
Public Partial Class BaseRequest
Implements IBaseRequest
'''<Summary>
'''The authentication credentials
'''</Summary>
<DataMember>
<ApiMember(Description:="The authentication credentials", IsRequired:=true, ParameterType:="header, body")>
Public Overridable Property Authentication As Authentication
End Class
Public Partial Class BaseResponse
Implements IBaseDataResponse
Implements IHasResponseStatus
'''<Summary>
'''The status of the response
'''</Summary>
<ApiMember(Description:="The status of the response")>
Public Overridable Property ResponseStatus As ResponseStatus
End Class
<DataContract>
Public Partial Class ResponseError
Public Sub New()
Meta = New Dictionary(Of String, String)
End Sub
<DataMember(Order:=1)>
Public Overridable Property ErrorCode As String
<DataMember(Order:=2)>
Public Overridable Property FieldName As String
<DataMember(Order:=3)>
Public Overridable Property Message As String
<DataMember(Order:=4)>
Public Overridable Property Meta As Dictionary(Of String, String)
End Class
<DataContract>
Public Partial Class ResponseStatus
Public Sub New()
Meta = New Dictionary(Of String, String)
End Sub
<DataMember(Order:=1)>
Public Overridable Property ErrorCode As String
<DataMember(Order:=2)>
Public Overridable Property Message As String
<DataMember(Order:=3)>
Public Overridable Property StackTrace As String
<DataMember(Order:=4)>
Public Overridable Property Errors As ArrayOfResponseError
<DataMember(Order:=5)>
Public Overridable Property Meta As Dictionary(Of String, String)
End Class
End Namespace
Namespace SanctionsSearch.Api2.ServiceModel.Operations.Clients
<DataContract>
Public Partial Class CountIncompleteClients
Inherits BaseRequest
'''<Summary>
'''How many days should have elapsed before counting a Client as incomplete (defaults to 7 days).Set to zero to count all incomplete clients
'''</Summary>
<DataMember>
<ApiMember(Description:="How many days should have elapsed before counting a Client as incomplete (defaults to 7 days).Set to zero to count all incomplete clients", ParameterType:="query")>
Public Overridable Property DaysIncomplete As Integer
'''<Summary>
'''Count clients that match the state specified (only PendingCompletion, or PendingVerification).
'''</Summary>
<DataMember>
<ApiMember(Description:="Count clients that match the state specified (only PendingCompletion, or PendingVerification).", ParameterType:="query")>
Public Overridable Property State As ClientState
'''<Summary>
'''Count clients that match the IsValidateMe flag specified (defaults to true).
'''</Summary>
<DataMember>
<ApiMember(Description:="Count clients that match the IsValidateMe flag specified (defaults to true).", ParameterType:="query")>
Public Overridable Property IsValidateMe As Boolean
End Class
Public Partial Class CountIncompleteClientsData
Inherits BaseResponse
Public Overridable Property NumberOfIncompleteClients As Long
End Class
<DataContract>
Public Partial Class CountIncompleteClientsResponse
<DataMember>
Public Overridable Property Data As CountIncompleteClientsData
End Class
End Namespace
Namespace SanctionsSearch.Api2.ServiceModel.Types
<DataContract>
Public Partial Class Authentication
'''<Summary>
'''The API User ID provided by us when you signed up to use our API. Can be provided in the request body, or as a header parameter (X-Api-User)
'''</Summary>
<DataMember>
<ApiMember(Description:="The API User ID provided by us when you signed up to use our API. Can be provided in the request body, or as a header parameter (X-Api-User)", IsRequired:=true, ParameterType:="header, body")>
Public Overridable Property ApiUserId As String
'''<Summary>
'''The API User Key provided by us when you signed up to use our API. Can be provided in the request body, or as a header parameter (X-Api-Key)
'''</Summary>
<DataMember>
<ApiMember(Description:="The API User Key provided by us when you signed up to use our API. Can be provided in the request body, or as a header parameter (X-Api-Key)", IsRequired:=true, ParameterType:="header, body")>
Public Overridable Property ApiUserKey As String
'''<Summary>
'''The User ID of the user making the request (e.g. a sub user). This is optional but can be used to associate API requests with a specific user, thereby allowing user permissions to be enforced. Can be provided in the body, or as a header parameter (X-User-Id).
'''</Summary>
<DataMember>
<ApiMember(Description:="The User ID of the user making the request (e.g. a sub user). This is optional but can be used to associate API requests with a specific user, thereby allowing user permissions to be enforced. Can be provided in the body, or as a header parameter (X-User-Id).", ParameterType:="header, body")>
Public Overridable Property UserId As String
End Class
<DataContract(Name:="ClientState", Namespace:="http://schemas.servicestack.net/types")>
Public Enum ClientState
Undefined
PendingCompletion
PendingOcr
PendingVerification
Verified
End Enum
End Namespace
End Namespace
VB.NET CountIncompleteClients 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.
GET /clients/incomplete/count HTTP/1.1 Host: api.sanctionssearch.com Accept: application/json
HTTP/1.1 200 OK Content-Type: application/json Content-Length: length {"data":{"numberOfIncompleteClients":0,"responseStatus":{"errorCode":"String","message":"String","stackTrace":"String","errors":[{"errorCode":"String","fieldName":"String","message":"String","meta":{"String":"String"}}],"meta":{"String":"String"}}}}