AML API Integration – Documentation

About the Service

Welcome to the documentation for AML API v2. Our advanced API is designed to perform comprehensive checks on cryptocurrency wallets for compliance with anti-money laundering (AML) requirements.

The API provides several endpoints:

All requests are made over a secure HTTPS protocol and require the transmission of an api_key, timestamp, and an HMAC-SHA256 signature to ensure security.

Base URL: https://api.chkaml.com/v2

Rate Limit: 200 requests per minute.

Advantages of Our Service

API Request Details

For the /aml_check endpoint, your request must include the following parameters:

The response is returned in JSON format and includes:

Integration Examples

Select a programming language to view sample code:


import requests, time, hmac, hashlib

api_key    = "YOUR_API_KEY"
api_secret = "YOUR_API_SECRET"
wallet     = "0xABC123..."
timestamp  = int(time.time())

# Create the message for signing
message   = f"wallet={wallet}×tamp={timestamp}"
signature = hmac.new(api_secret.encode(), message.encode(), hashlib.sha256).hexdigest()

payload = {
  "wallet": wallet,
  "api_key": api_key,
  "timestamp": timestamp,
  "signature": signature
}

response = requests.post("https://api.chkaml.com/v2/aml_check", json=payload)
data     = response.json()

print("Verification Status:", data.get("status"))
print("Analysis Result:", data.get("result"))
        

// Using axios and crypto in Node.js
const axios  = require('axios');
const crypto = require('crypto');

const apiKey    = 'YOUR_API_KEY';
const apiSecret = 'YOUR_API_SECRET';
const wallet    = '0xABC123...';
const timestamp = Math.floor(Date.now() / 1000);

// Create the message for signing
const message   = `wallet=${wallet}×tamp=${timestamp}`;
const signature = crypto.createHmac('sha256', apiSecret).update(message).digest('hex');

axios.post('https://api.chkaml.com/v2/aml_check', {
  wallet, api_key: apiKey, timestamp, signature
})
.then(response => {
  console.log("Verification Status:", response.data.status);
  console.log("Analysis Result:", response.data.result);
})
.catch(error => {
  console.error("Request Error:", error);
});
        

 $wallet,
  "api_key"   => $apiKey,
  "timestamp" => $timestamp,
  "signature" => $signature
];

$options = [
  'http' => [
    'header'  => "Content-type: application/json\r\n",
    'method'  => 'POST',
    'content' => json_encode($data),
  ],
];

$context = stream_context_create($options);
$result  = file_get_contents("https://api.chkaml.com/v2/aml_check", false, $context);
if ($result === FALSE) {
  die('Request Error');
}

$response = json_decode($result, true);
echo "Verification Status: " . $response['status'] . "\n";
echo "Analysis Result: " . $response['result'] . "\n";
?>
        

// Java example using HttpURLConnection and javax.crypto for HMAC
import java.io.*;
import java.net.*;
import javax.crypto.Mac;
import javax.crypto.spec.SecretKeySpec;
import org.json.JSONObject;

public class AMLCheck {
    public static void main(String[] args) {
        try {
            String apiKey    = "YOUR_API_KEY";
            String apiSecret = "YOUR_API_SECRET";
            String wallet    = "0xABC123...";
            long timestamp   = System.currentTimeMillis() / 1000;
            
            String message = "wallet=" + wallet + "×tamp=" + timestamp;
            Mac hmac = Mac.getInstance("HmacSHA256");
            SecretKeySpec keySpec = new SecretKeySpec(apiSecret.getBytes("UTF-8"), "HmacSHA256");
            hmac.init(keySpec);
            String signature = bytesToHex(hmac.doFinal(message.getBytes("UTF-8")));
            
            URL url = new URL("https://api.chkaml.com/v2/aml_check");
            HttpURLConnection conn = (HttpURLConnection) url.openConnection();
            conn.setRequestMethod("POST");
            conn.setRequestProperty("Content-Type", "application/json; utf-8");
            conn.setDoOutput(true);
            
            JSONObject jsonInput = new JSONObject();
            jsonInput.put("wallet", wallet);
            jsonInput.put("api_key", apiKey);
            jsonInput.put("timestamp", timestamp);
            jsonInput.put("signature", signature);
            
            try(OutputStream os = conn.getOutputStream()){
                byte[] input = jsonInput.toString().getBytes("utf-8");
                os.write(input, 0, input.length);
            }
            
            BufferedReader br = new BufferedReader(new InputStreamReader(conn.getInputStream(), "utf-8"));
            StringBuilder response = new StringBuilder();
            String line;
            while ((line = br.readLine()) != null) {
                response.append(line.trim());
            }
            
            JSONObject jsonResponse = new JSONObject(response.toString());
            System.out.println("Verification Status: " + jsonResponse.getString("status"));
            System.out.println("Analysis Result: " + jsonResponse.getString("result"));
        } catch (Exception e) {
            e.printStackTrace();
        }
    }
    
    private static String bytesToHex(byte[] bytes) {
        StringBuilder hexString = new StringBuilder();
        for (byte b : bytes) {
            hexString.append(String.format("%02x", b));
        }
        return hexString.toString();
    }
}
        

require 'net/http'
require 'uri'
require 'json'
require 'openssl'

api_key    = "YOUR_API_KEY"
api_secret = "YOUR_API_SECRET"
wallet     = "0xABC123..."
timestamp  = Time.now.to_i

# Create the message for signing
message   = "wallet=#{wallet}×tamp=#{timestamp}"
signature = OpenSSL::HMAC.hexdigest("sha256", api_secret, message)

uri = URI.parse("https://api.chkaml.com/v2/aml_check")
http = Net::HTTP.new(uri.host, uri.port)
http.use_ssl = true

request = Net::HTTP::Post.new(uri.request_uri, {'Content-Type' => 'application/json'})
request.body = {
  wallet: wallet,
  api_key: api_key,
  timestamp: timestamp,
  signature: signature
}.to_json

response = http.request(request)
result   = JSON.parse(response.body)
puts "Verification Status: #{result['status']}"
puts "Analysis Result: #{result['result']}"
        

Frequently Asked Questions (FAQ)

How do I obtain an API key?

An API key is provided with the Paid Plan. After payment, your active API key will be displayed in your account dashboard.

What should I do if my request returns an error?

Please check the accuracy of the parameters, especially the signature and timestamp. If errors persist, contact our support team.

Can I use the API for bulk verifications?

Yes, but please note the limit of no more than 200 requests per minute.

Contact Information

If you have any questions or suggestions, please contact us via email at [email protected]

Conclusion

This documentation provides a detailed description of our AML API integration. We continuously work to improve our service to ensure high-quality verifications and analytics. Thank you for your attention!