Sanctions Search API: v2

<back to all web services

GetDbsSearches

DBS
The following routes are available for this service:
GET/dbsGet all DBS Searches
namespace SanctionsSearch.Api2.ServiceModel.Operations.Base

open System
open System.Collections
open System.Collections.Generic
open System.Runtime.Serialization
open ServiceStack
open ServiceStack.DataAnnotations

    [<DataContract>]
    [<AllowNullLiteral>]
    type Authentication() = 
        ///<summary>
        ///The API User ID provided by us when you signed up to use our API
        ///</summary>
        [<DataMember>]
        [<ApiMember(Description="The API User ID provided by us when you signed up to use our API", IsRequired=true, ParameterType="header, body")>]
        member val ApiUserId:String = null with get,set

        ///<summary>
        ///The API User Key provided by us when you signed up to use our API
        ///</summary>
        [<DataMember>]
        [<ApiMember(Description="The API User Key provided by us when you signed up to use our API", IsRequired=true, ParameterType="header, body")>]
        member val ApiUserKey:String = null with get,set

    [<DataContract>]
    [<AllowNullLiteral>]
    type BaseRequest() = 
        ///<summary>
        ///The authentication credentials
        ///</summary>
        [<DataMember>]
        [<ApiMember(Description="The authentication credentials", IsRequired=true, ParameterType="header, body")>]
        member val Authentication:Authentication = null with get,set

    [<DataContract>]
    [<AllowNullLiteral>]
    type PagedRequest() = 
        inherit BaseRequest()
        ///<summary>
        ///The maximum number of records to be returned in one page
        ///</summary>
        [<DataMember(Name="page[limit]")>]
        [<ApiMember(Description="The maximum number of records to be returned in one page", ParameterType="query")>]
        member val PageLimit:Int32 = new Int32() with get,set

        ///<summary>
        ///The starting point in the list of records from where the data should be fetched. Zero based index.
        ///</summary>
        [<DataMember(Name="page[offset]")>]
        [<ApiMember(Description="The starting point in the list of records from where the data should be fetched. Zero based index.", ParameterType="query")>]
        member val PageOffset:Int32 = new Int32() with get,set

        ///<summary>
        ///The term to determine the order in which the data is returned
        ///</summary>
        [<DataMember>]
        [<ApiMember(Description="The term to determine the order in which the data is returned", ParameterType="query")>]
        member val Sort:String = null with get,set

    [<DataContract>]
    [<AllowNullLiteral>]
    type GetDbsSearches() = 
        inherit PagedRequest()
        ///<summary>
        ///Filter the results to those that have a Name including the specified value
        ///</summary>
        [<DataMember>]
        [<ApiMember(Description="Filter the results to those that have a Name including the specified value", ParameterType="query")>]
        member val Name:String = null with get,set

        ///<summary>
        ///Filter the results to those that were created after (or on) this date
        ///</summary>
        [<DataMember>]
        [<ApiMember(Description="Filter the results to those that were created after (or on) this date", ParameterType="query")>]
        member val DateFrom:Nullable<DateTime> = new Nullable<DateTime>() with get,set

        ///<summary>
        ///Filter the results to those that were created before this date
        ///</summary>
        [<DataMember>]
        [<ApiMember(Description="Filter the results to those that were created before this date", ParameterType="query")>]
        member val DateTo:Nullable<DateTime> = new Nullable<DateTime>() with get,set

        ///<summary>
        ///Filter the results to those where the applicant has provided their information (true), or not (false), or either (null)
        ///</summary>
        [<DataMember>]
        [<ApiMember(Description="Filter the results to those where the applicant has provided their information (true), or not (false), or either (null)", ParameterType="query")>]
        member val IsApplicantInfoCompleted:Nullable<Boolean> = new Nullable<Boolean>() with get,set

        ///<summary>
        ///Filter the results to those where the ID Checker has verified the applicant's ID (true), or not (false), or either (null)
        ///</summary>
        [<DataMember>]
        [<ApiMember(Description="Filter the results to those where the ID Checker has verified the applicant's ID (true), or not (false), or either (null)", ParameterType="query")>]
        member val IsIdCheckCompleted:Nullable<Boolean> = new Nullable<Boolean>() with get,set

        ///<summary>
        ///Filter the results to those where the application is complete and ready to be submitted (true), or not (false), or either (null)
        ///</summary>
        [<DataMember>]
        [<ApiMember(Description="Filter the results to those where the application is complete and ready to be submitted (true), or not (false), or either (null)", ParameterType="query")>]
        member val IsApplicationCompleted:Nullable<Boolean> = new Nullable<Boolean>() with get,set

        ///<summary>
        ///Filter the results to those where the application has been submitted (true), or not (false), or either (null)
        ///</summary>
        [<DataMember>]
        [<ApiMember(Description="Filter the results to those where the application has been submitted (true), or not (false), or either (null)", ParameterType="query")>]
        member val IsApplicationSubmitted:Nullable<Boolean> = new Nullable<Boolean>() with get,set

        ///<summary>
        ///Filter the results to those where the application has been disclosed (true), or not (false), or either (null)
        ///</summary>
        [<DataMember>]
        [<ApiMember(Description="Filter the results to those where the application has been disclosed (true), or not (false), or either (null)", ParameterType="query")>]
        member val IsApplicationDisclosed:Nullable<Boolean> = new Nullable<Boolean>() with get,set

        ///<summary>
        ///If the searches are being accessed by a sub user, specify their username here to only return searches they have permissions to view
        ///</summary>
        [<DataMember>]
        [<ApiMember(Description="If the searches are being accessed by a sub user, specify their username here to only return searches they have permissions to view", ParameterType="query")>]
        member val SubUserName:String = null with get,set

    [<AllowNullLiteral>]
    type DbsSearchShort() = 
        member val Id:Int64 = new Int64() with get,set
        member val DateSearched:DateTime = new DateTime() with get,set
        member val DateUpdated:DateTime = new DateTime() with get,set
        member val Status:String = null with get,set
        member val DisclosureStatus:String = null with get,set
        member val IsApplicantInfoCompleted:Boolean = new Boolean() with get,set
        member val IsIdCheckCompleted:Boolean = new Boolean() with get,set
        member val IsApplicationCompleted:Boolean = new Boolean() with get,set
        member val IsApplicationSubmitted:Boolean = new Boolean() with get,set
        member val IsApplicationDisclosed:Boolean = new Boolean() with get,set
        member val DisclosureLevel:String = null with get,set
        member val Name:String = null with get,set
        member val Reference:String = null with get,set

    [<AllowNullLiteral>]
    type ArrayOfDbsSearchShort() = 
        inherit ResizeArray<DbsSearchShort>()

    [<AllowNullLiteral>]
    type GetDbsSearchesData() = 
        inherit PagedResponse<GetDbsSearches>()
        member val Searches:ArrayOfDbsSearchShort = null with get,set

    [<DataContract>]
    [<AllowNullLiteral>]
    type GetDbsSearchesResponse() = 
        [<DataMember>]
        member val Data:GetDbsSearchesData = null with get,set

    [<DataContract>]
    [<AllowNullLiteral>]
    type ResponseError() = 
        [<DataMember(Order=1)>]
        member val ErrorCode:String = null with get,set

        [<DataMember(Order=2)>]
        member val FieldName:String = null with get,set

        [<DataMember(Order=3)>]
        member val Message:String = null with get,set

        [<DataMember(Order=4)>]
        member val Meta:Dictionary<String, String> = new Dictionary<String, String>() with get,set

    [<AllowNullLiteral>]
    type ArrayOfResponseError() = 
        inherit ResizeArray<ResponseError>()

    [<DataContract>]
    [<AllowNullLiteral>]
    type ResponseStatus() = 
        [<DataMember(Order=1)>]
        member val ErrorCode:String = null with get,set

        [<DataMember(Order=2)>]
        member val Message:String = null with get,set

        [<DataMember(Order=3)>]
        member val StackTrace:String = null with get,set

        [<DataMember(Order=4)>]
        member val Errors:ArrayOfResponseError = null with get,set

        [<DataMember(Order=5)>]
        member val Meta:Dictionary<String, String> = new Dictionary<String, String>() with get,set

    [<AllowNullLiteral>]
    type BaseResponse() = 
        ///<summary>
        ///The status of the response
        ///</summary>
        [<ApiMember(Description="The status of the response")>]
        member val ResponseStatus:ResponseStatus = null with get,set

    [<AllowNullLiteral>]
    type PagedResponse<T>() = 
        inherit BaseResponse()
        ///<summary>
        ///The response Metadata
        ///</summary>
        [<ApiMember(Description="The response Metadata")>]
        member val Meta:Meta<T> = null with get,set

    [<AllowNullLiteral>]
    type Links() = 
        [<ApiMember>]
        member val Self:String = null with get,set

    [<AllowNullLiteral>]
    type MetaLinks() = 
        inherit Links()
        ///<summary>
        ///The link to the first page of records
        ///</summary>
        [<ApiMember(Description="The link to the first page of records")>]
        member val First:String = null with get,set

        ///<summary>
        ///The link to the last page of records
        ///</summary>
        [<ApiMember(Description="The link to the last page of records")>]
        member val Last:String = null with get,set

        ///<summary>
        ///The link to the next page of records, if applicable
        ///</summary>
        [<ApiMember(Description="The link to the next page of records, if applicable")>]
        member val Next:String = null with get,set

        ///<summary>
        ///The link to the last page of records, if applicable
        ///</summary>
        [<ApiMember(Description="The link to the last page of records, if applicable")>]
        member val Prev:String = null with get,set

    [<AllowNullLiteral>]
    type Meta<T>() = 
        ///<summary>
        ///Pagination links
        ///</summary>
        [<ApiMember(Description="Pagination links")>]
        member val Links:MetaLinks = null with get,set

        ///<summary>
        ///The total number of records for the query
        ///</summary>
        [<ApiMember(Description="The total number of records for the query")>]
        member val TotalCount:Nullable<Int32> = new Nullable<Int32>() with get,set

        ///<summary>
        ///The maximum number of records to be returned in one page
        ///</summary>
        [<ApiMember(Description="The maximum number of records to be returned in one page")>]
        member val PageLimit:Nullable<Int32> = new Nullable<Int32>() with get,set

        ///<summary>
        ///The starting point in the list of records from where the data should be fetched. Zero based index.
        ///</summary>
        [<ApiMember(Description="The starting point in the list of records from where the data should be fetched. Zero based index.")>]
        member val PageOffset:Nullable<Int32> = new Nullable<Int32>() with get,set

F# GetDbsSearches 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

HTTP + JSON

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

GET /dbs HTTP/1.1 
Host: api.sanctionssearch.com 
Accept: application/json
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: length

{"data":{"searches":[{"id":0,"dateSearched":"\/Date(-62135596800000-0000)\/","dateUpdated":"\/Date(-62135596800000-0000)\/","status":"String","disclosureStatus":"String","isApplicantInfoCompleted":false,"isIdCheckCompleted":false,"isApplicationCompleted":false,"isApplicationSubmitted":false,"isApplicationDisclosed":false,"disclosureLevel":"String","name":"String","reference":"String"}],"meta":{"links":{"first":"String","last":"String","next":"String","prev":"String","self":"String"},"totalCount":0,"pageLimit":0,"pageOffset":0},"responseStatus":{"errorCode":"String","message":"String","stackTrace":"String","errors":[{"errorCode":"String","fieldName":"String","message":"String","meta":{"String":"String"}}],"meta":{"String":"String"}}}}