Sanctions Search API: v2

<back to all web services

RegisterAccount

Create a new account
"use strict";
export class Authentication {
    /** @param {{apiUserId?:string,apiUserKey?:string}} [init] */
    constructor(init) { Object.assign(this, init) }
    /**
     * @type {string}
     * @description The API User ID provided by us when you signed up to use our API */
    apiUserId;
    /**
     * @type {string}
     * @description The API User Key provided by us when you signed up to use our API */
    apiUserKey;
}
export class BaseRequest {
    /** @param {{authentication?:Authentication}} [init] */
    constructor(init) { Object.assign(this, init) }
    /**
     * @type {Authentication}
     * @description The authentication credentials */
    authentication;
}
export class ResponseError {
    /** @param {{errorCode?:string,fieldName?:string,message?:string,meta?:{ [index: string]: string; }}} [init] */
    constructor(init) { Object.assign(this, init) }
    /** @type {string} */
    errorCode;
    /** @type {string} */
    fieldName;
    /** @type {string} */
    message;
    /** @type {{ [index: string]: string; }} */
    meta;
}
export class ArrayOfResponseError extends Array {
    constructor(init) { super(init); Object.assign(this, init) }
}
export class ResponseStatus {
    /** @param {{errorCode?:string,message?:string,stackTrace?:string,errors?:ArrayOfResponseError,meta?:{ [index: string]: string; }}} [init] */
    constructor(init) { Object.assign(this, init) }
    /** @type {string} */
    errorCode;
    /** @type {string} */
    message;
    /** @type {string} */
    stackTrace;
    /** @type {ArrayOfResponseError} */
    errors;
    /** @type {{ [index: string]: string; }} */
    meta;
}
export class BaseResponse {
    /** @param {{responseStatus?:ResponseStatus}} [init] */
    constructor(init) { Object.assign(this, init) }
    /**
     * @type {ResponseStatus}
     * @description The status of the response */
    responseStatus;
}
export class RegisterAccountData extends BaseResponse {
    /** @param {{apiUserId?:string,apiUserKey?:string,responseStatus?:ResponseStatus}} [init] */
    constructor(init) { super(init); Object.assign(this, init) }
    /**
     * @type {string}
     * @description A unique identifier for the users API access */
    apiUserId;
    /**
     * @type {string}
     * @description A secure, randomly generated key used for API authentication */
    apiUserKey;
}
export class RegisterAccountResponse {
    /** @param {{data?:RegisterAccountData}} [init] */
    constructor(init) { Object.assign(this, init) }
    /**
     * @type {RegisterAccountData}
     * @description The response data */
    data;
}
export class RegisterAccountRequest {
    /** @param {{username?:string,password?:string,email?:string,fullName?:string,companyName?:string,companyPhone?:string,address1?:string,address2?:string,address3?:string,city?:string,postcode?:string,country?:string,companyType?:string,companyIndustry?:string,companyNetwork?:string,agreeToTerms?:boolean,agreeToDataProtection?:boolean,agreeToContact?:boolean,agreeToPrivacy?:boolean,voucherCode?:string,accountActivationCode?:string,vatNumber?:string,vatCountry?:string}} [init] */
    constructor(init) { Object.assign(this, init) }
    /**
     * @type {string}
     * @description The desired login username for the account */
    username;
    /**
     * @type {string}
     * @description The password for account login */
    password;
    /**
     * @type {string}
     * @description The contact email address for the account holder */
    email;
    /**
     * @type {string}
     * @description The full legal name of the account holder */
    fullName;
    /**
     * @type {string}
     * @description The registered name of the company associated with this account */
    companyName;
    /**
     * @type {string}
     * @description The primary contact phone number of the company */
    companyPhone;
    /**
     * @type {string}
     * @description The first line of the company’s address (e.g., street name and number) */
    address1;
    /**
     * @type {string}
     * @description The second line of the company’s address (optional) */
    address2;
    /**
     * @type {string}
     * @description The third line of the company’s address (optional) */
    address3;
    /**
     * @type {string}
     * @description The city where the company is located (optional) */
    city;
    /**
     * @type {string}
     * @description The postal or ZIP code of the company’s address */
    postcode;
    /**
     * @type {string}
     * @description The country where the company is registered */
    country;
    /**
     * @type {string}
     * @description The classification of the company (e.g., LLC, Corporation, Sole Proprietorship) */
    companyType;
    /**
     * @type {string}
     * @description The industry sector the company operates in */
    companyIndustry;
    /**
     * @type {string}
     * @description The trade body, network, or affiliation the company is a member of (if applicable) */
    companyNetwork;
    /**
     * @type {boolean}
     * @description Indicates agreement to the terms and conditions (required) */
    agreeToTerms;
    /**
     * @type {boolean}
     * @description Indicates agreement to the data protection statement (required) */
    agreeToDataProtection;
    /**
     * @type {boolean}
     * @description Indicates consent to be contacted (optional) */
    agreeToContact;
    /**
     * @type {boolean}
     * @description Indicates agreement to the privacy policy (required) */
    agreeToPrivacy;
    /**
     * @type {string}
     * @description An optional voucher code for discounts or promotions */
    voucherCode;
    /**
     * @type {string}
     * @description An optional code that grants access to certain features or subscriptions */
    accountActivationCode;
    /**
     * @type {string}
     * @description The company's VAT registration number (if applicable) */
    vatNumber;
    /**
     * @type {string}
     * @description The country where the company is VAT-registered */
    vatCountry;
}
export class RegisterAccount extends BaseRequest {
    /** @param {{request?:RegisterAccountRequest,authentication?:Authentication}} [init] */
    constructor(init) { super(init); Object.assign(this, init) }
    /** @type {RegisterAccountRequest} */
    request;
}

JavaScript RegisterAccount DTOs

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

HTTP + SOAP11

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

POST /soap11 HTTP/1.1 
Host: api.sanctionssearch.com 
Content-Type: text/xml; charset=utf-8
Content-Length: length
SOAPAction: RegisterAccount

<?xml version="1.0" encoding="utf-8"?>
<soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
<soap:Body>

<RegisterAccount xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.servicestack.net/types">
  <Authentication>
    <ApiUserId>String</ApiUserId>
    <ApiUserKey>String</ApiUserKey>
  </Authentication>
  <Request>
    <AccountActivationCode>String</AccountActivationCode>
    <Address1>String</Address1>
    <Address2>String</Address2>
    <Address3>String</Address3>
    <AgreeToContact>false</AgreeToContact>
    <AgreeToDataProtection>false</AgreeToDataProtection>
    <AgreeToPrivacy>false</AgreeToPrivacy>
    <AgreeToTerms>false</AgreeToTerms>
    <City>String</City>
    <CompanyIndustry>String</CompanyIndustry>
    <CompanyName>String</CompanyName>
    <CompanyNetwork>String</CompanyNetwork>
    <CompanyPhone>String</CompanyPhone>
    <CompanyType>String</CompanyType>
    <Country>String</Country>
    <Email>String</Email>
    <FullName>String</FullName>
    <Password>String</Password>
    <Postcode>String</Postcode>
    <Username>String</Username>
    <VATCountry>String</VATCountry>
    <VATNumber>String</VATNumber>
    <VoucherCode>String</VoucherCode>
  </Request>
</RegisterAccount>

</soap:Body>
</soap:Envelope>
HTTP/1.1 200 OK
Content-Type: application/xml
Content-Length: length

<?xml version="1.0" encoding="utf-8"?>
<soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
<soap:Body>

<RegisterAccountResponse xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.servicestack.net/types">
  <Data>
    <ResponseStatus>
      <ErrorCode>String</ErrorCode>
      <Message>String</Message>
      <StackTrace>String</StackTrace>
      <Errors>
        <ResponseError>
          <ErrorCode>String</ErrorCode>
          <FieldName>String</FieldName>
          <Message>String</Message>
          <Meta xmlns:d6p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
            <d6p1:KeyValueOfstringstring>
              <d6p1:Key>String</d6p1:Key>
              <d6p1:Value>String</d6p1:Value>
            </d6p1:KeyValueOfstringstring>
          </Meta>
        </ResponseError>
      </Errors>
      <Meta xmlns:d4p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
        <d4p1:KeyValueOfstringstring>
          <d4p1:Key>String</d4p1:Key>
          <d4p1:Value>String</d4p1:Value>
        </d4p1:KeyValueOfstringstring>
      </Meta>
    </ResponseStatus>
    <ApiUserId>String</ApiUserId>
    <ApiUserKey>String</ApiUserKey>
  </Data>
</RegisterAccountResponse>

</soap:Body>
</soap:Envelope>