LogoLogo
  • Welcome!
  • GETTING STARTED
    • Signing Up
    • Choose a Product
    • Choose an Integration Option
    • Run Your First Test Job
    • Complete Your KYC
    • Fund Your Wallet
    • Go Live!
    • Pricing
  • SUPPORTED ID TYPES & DOCUMENTS
    • For Individuals (KYC)
      • Using ID Number
        • Supported Countries
          • Côte d'Ivoire
            • National ID (without Photo)
            • Resident ID (without Photo)
          • Ghana
            • Ghana Card
            • Passport
            • Voter's ID
          • Kenya
            • Alien Card
            • KRA Pin
            • National ID
            • National ID (without Photo)
            • Passport
            • Tax Information
          • Nigeria
            • Bank Account
            • BVN
            • NIN V2
            • NIN Slip Verification
            • V_NIN (Virtual NIN)
            • Phone Number
            • Voter's ID
          • South Africa
            • National ID
            • National ID (without Photo)
            • Phone Number
          • Uganda
            • National ID (without Photo)
            • Basic KYC in Uganda
          • Zambia
            • Bank Account
            • TPIN
          • Zimbabwe
            • National ID (without Photo)
        • Test Data
          • Customising Sandbox Test Data
        • ID Number Regex
        • Visual Samples of Supported ID Types
      • Using Document Image
        • Continents
          • Africa
          • Asia and the Middle East
          • Europe
          • North America
          • Oceania
          • South America
    • For Businesses (KYB)
      • Supported Countries
        • Nigeria
          • Business Registration
          • Tax Information
        • Kenya
          • Business Registration
        • South Africa
          • Business Registration
      • ID Number Regex
  • PRODUCTS
    • For Individuals (KYC)
      • AML Check
        • AML News Media
      • Basic KYC
      • Biometric KYC
      • Digital Address Verification
      • Document Verification
        • Document Verification
        • Enhanced Document Verification
      • Electronic Signature
      • Enhanced KYC
      • Phone Number Verification
      • SmartSelfie™ Authentication
      • SmartSelfie™ Compare
      • Smile Secure
    • For Businesses (KYB)
      • Business Verification
  • Integration Options
    • Mobile
      • Getting Started
      • Products
        • Biometric KYC
        • BVN Consent
        • Document Verification
        • Enhanced Document Verification
        • Enhanced KYC
        • SmartSelfie™ Enrollment and Authentication
        • Enhanced SmartSelfie™ Enrollment And Authentication
      • Customization
        • UI Components
      • Offline Mode
      • Release Notes
        • Android Release Notes
        • iOS Release Notes
        • Flutter Release Notes
        • React Native Release Notes
    • No-Code
      • Smile Links
        • Link FAQs
        • Rest API
    • Server to Server
      • Ruby
        • Installation
        • Signature
        • Products
          • Basic KYC
          • Enhanced KYC
          • Biometric KYC
          • Document Verification
          • SmartSelfie™ Authentication
          • KYB - Business Verification
          • AML Check
        • Generate Token for Web Integration
        • Utilities
      • Python
        • Installation
        • Signature
        • Products
          • Basic KYC
          • Enhanced KYC
          • Biometric KYC
          • Document Verification
          • SmartSelfie™ Authentication
          • Business Verification
        • Generate Token for Web Integration
        • Utilities
      • Java
        • Release Notes
        • Installation
        • Signature
        • Products
          • Basic KYC
          • Enhanced KYC
          • Biometric KYC
          • Document Verification
          • SmartSelfie™ Authentication
        • Generate Token for Web Integration
        • Utilities
      • Node.js
        • Installation
        • Signature
        • Products
          • Basic KYC
          • Enhanced KYC
          • Biometric KYC
          • Document Verification
          • Enhanced Document Verification
          • SmartSelfie™ Authentication
          • Business Verification
        • Generate Token for Web Integration
        • Utilities
      • PHP
        • Installation
        • Signature
        • Products
          • Basic KYC
          • Enhanced KYC
          • Biometric KYC
          • Document Verification
          • SmartSelfie™ Authentication
        • Generate Token for Web Integration
        • Utilities
    • Rest API
      • Signing your API Request
        • Using Signature
      • Products
      • Postman Collection
      • Utilities
    • Web / Mobile Web
      • Web Integration
        • Installation
        • Usage
        • End User Consent
        • Support
      • Javascript SDK
        • Installation
        • Usage
        • Migration
        • Deprecated Version
          • Installation
          • Usage
          • Notes
          • Support
  • FURTHER READING
    • FAQs
      • What are your support hours?
      • How do I set up a callback?
      • How to re-enroll, deactivate or delete a user?
      • Add or remove team members
      • What are top-level keys?
      • What are partner_params?
      • How do job types map to the new product names?
      • Is there an API I can use to monitor my wallet balance?
      • Is there an API I can query to check the availability status of an ID type?
      • How do I integrate Smile ID in other countries or query other ID types?
      • What are the image types I can upload to Smile ID?
      • Why aren't Kenyan IDs returning images for some IDs queried?
      • Why are some of my bank verification requests returning 'ID authority unavailable'?
      • How can I look up a specific user's data?
      • Selfie best-practices
      • Document capture best-practices
      • What happens under the hood?
      • Guide to the user consent screen
      • What is code 2302?
      • Using the Demo App and Scanning QR codes
    • Job status
    • KYC receipts
    • Result codes
      • Error codes
    • Securing your account with two-factor authentication (2FA)
    • Security Overview
    • Troubleshooting
      • Troubleshooting error 2204 & 2205 - "You're not authorized to do that"
      • Why is my Web API job taking so long?
      • Image capture issues on web client
Powered by GitBook
On this page
  • Running AML Check on Ruby
  • Get your Partner ID
  • Get your API Key
  • Get the User's details
  • Submit the Job to Smile ID
  • Interpret your Results

Was this helpful?

  1. Integration Options
  2. Server to Server
  3. Ruby
  4. Products

AML Check

PreviousKYB - Business VerificationNextGenerate Token for Web Integration

Last updated 10 months ago

Was this helpful?

Required Class: AmlCheck Class

Running AML Check on Ruby

  1. Get your Smile ID Partner ID

  2. Get your API Key (take note of the environment you are running the job in)

  3. Get the required details from your users

  4. Submit the Job to Smile ID

  5. Interpret your results

Get your Partner ID

You can find your Partner ID in the menu list when logged into .

Get your API Key

  • Click on the Generate New API Key button

  • Copy your api key (ensure you are in the right environment)

Get the User's details

To submit a AML check job, you need the full name of the user, the birth year and the user's known nationalities.

Submit the Job to Smile ID

You can copy the sample code below and edit with your partner and job details.

require 'smile-identity-core'

# Initialize
partner_id = '<Your partner ID>'; # login to the Smile ID portal to view your partner id
api_key = '<Your API key>'; # copy your API key from the Smile ID portal
sid_server = '<0 or 1>'; # Use '0' for the sandbox server, use '1' for production server

connection = SmileIdentityCore::AmlCheck.new(partner_id, api_key, sid_server)

# Create required tracking parameters
request_params = {
    job_id: '<put your unique job ID here>',
    user_id: '<put your unique ID for the user here>',
    full_name: '<put the full name of the user>',
    countries: '<an array of the user country using ISO 3166-1 alpha-2 format>',
    birth_year: '<birth year of the user in the format yyyy>',
    # set search_existing_user to true to re-use the name and birth year from a previous
    # biometric kyc or document verification job. NOTE: user_id must be the same as
    # submitted with the biometric kyc or document verification job
    search_existing_user: '<true | false>',
    optional_info: '<hash of additional data>'
};


# Submit the job
response = connection.submit_job(request_params)

Example Response Body

Your response will return a JSON String containing the below:

{
  "Actions": {
    "Listed": "Listed"
  },
  "PartnerParams": {
    "job_type": 10,
    "user_id": "4cb0f26-2b567-5800-b05e-c0f095g6036",
    "job_id": "3ba0e15e-1a56-4799-a94d-b0e084f50256"
  },
  "SmileJobID": "0000000411",
  "no_of_persons_found": 1,
  "people": [
    {
      "addresses": ["Burbank"],
      "adverse_media": [
        {
          "date_published": "2021-09-24",
          "publisher": "Regulatory Times",
          "source_link": "https:regulatorytimes.com/article",
          "title": "Jon Doe angered regulators"
        }
      ],
      "aliases": ["John Doe"],
      "associations": [
        {
          "association_type": "PEP",
          "name": "Bob Smith",
          "relationship": "Bob Smith is an associate of John Leo Doe"
        }
      ],
      "dates_of_birth": ["1984-07-16"],
      "name": "John Leo Doe",
      "nationalities": ["American"],
      "news_summary": [
        {
          "newsCategoryLabel": "Terrorism",
          "newsCategory": "terrorism",
          "numberOfArticles": 46
        }
      ],
      "pep": {
        "pep_level": 1,
        "political_positions": [
          {
            "country": "United States",
            "from": "2020-01-05",
            "position": "Representative",
            "to": "2022-01-05"
          },
          {
            "country": "United States",
            "from": "2022-01-05",
            "position": "Senator",
            "to": null
          }
        ],
        "sources": [
          {
            "source_link": "https://www.senate.gov/senators/",
            "source_name": "senate.gov"
          }
        ]
      },
      "sanctions": [
        {
          "date_of_birth": "",
          "nationality": "American",
          "source_details": {
            "listed_date": "2020-01-05",
            "source_link": ["https://sanctionslist.com"],
            "source_name": "Office of Foreign Assets Control (OFAC)",
            "source_type": "Sanctions"
          }
        }
      ]
    }
  ],
  "ResultCode": "1030",
  "ResultText": "Found on list",
  "signature": "...",
  "timestamp": "2023-02-17T16:24:16.835Z"
}

Interpret your Results

Your api key is in the developer section of

You can read more about result codes and responses in the section of the docs.

the portal.
AML check
the portal
Generate a new API Key
Copy your API Key