# Anti Money Laundering (AML)

## What is this request?

If you are in doubt about the security of a wallet and you think it is a dangerous wallet, you can question the security of the wallet with this service.

***There are a lot of tags we have investigated. Also there is a score for these tags. For scoring 100 is bad and 0 is good.***

## What can I do with this service?

With this service, ensure the security of the wallets on our platform and minimize all possible risks.

<figure><img src="https://1886408235-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FFkgTXq4xOn9ai8pmc0n4%2Fuploads%2FIHxf41in3auSb8xWwLQU%2Fimage.png?alt=media&#x26;token=0b42566b-1ccb-48e5-869a-9264202406c6" alt="Example from getdefy.co"><figcaption><p>Example from getdefy.co</p></figcaption></figure>

## Tutorial

```javascript
var axios = require('axios');

axios.get('https://api.getdefy.co/v2/analyze/aml', {
    params: {
      address: '0x787970ad122d5947579e613c2464d9540081b46f',
      network: 'polygon',
      apikey: 'API_KEY',
      webhook: 'WEBHOOK_URL',
    },
  })
  .then(function (response) {
    console.log(JSON.stringify(response.data));
  })
  .catch(function (error) {
    console.log(error);
  });
```

#### Options

* `address` (required): A user address (i.e. `0x1a2b3x...`). If specified, the user attached to the query is ignored and the address will be used instead.
* `apikey` (required): API key for requests. If you want you set apikey params to header.
* `network` (required): Address Network. Use can get network list with service. Also you can learn network code on [**Supported Networks.**](https://docs.getdefy.co/developer-resources/supported-chains)
* `webhook` (optional): Live AML webhook URL.

There are a lot of tags we have investigated. Also there is a score for these tags. ***For scoring 100 is bad and 0 is good.***

### What is direct prefix?

There some direct prefix in tags. Direct means that the searched wallet is not a suspicious wallet, but has contacted a suspicious wallet.&#x20;

### What is indirect prefix?

There some indirect prefix in tags. Indirect means that the searched wallet is not directly a suspicious wallet, but has contacted a direct suspicious wallet.&#x20;

<mark style="color:blue;">`GET`</mark> `https://api.getdefy.co/v2/analyze/aml`

#### Query Parameters

| Name                                      | Type   | Description          |
| ----------------------------------------- | ------ | -------------------- |
| address<mark style="color:red;">\*</mark> | String | Wallet Address       |
| network<mark style="color:red;">\*</mark> | String | Wallet Network       |
| apikey<mark style="color:red;">\*</mark>  | String | API Key              |
| webhook                                   | String | Live AML Webhook URL |

{% tabs %}
{% tab title="200: OK" %}
{% code lineNumbers="true" %}

```json
{
    "code": 0,
    "message": "OK",
    "data": {
        "score": 100,
        "tags": {
            "mixer": false,
            "fake_kyc": false,
            "cybercrime": false,
            "new_wallet": false,
            "sanctioned": false,
            "direct_mixer": true,
            "indirect_mixer": true,
            "invalid_tokens": false,
            "direct_fake_kyc": false,
            "financial_crime": false,
            "stealing_attack": false,
            "money_laundering": false,
            "direct_cybercrime": false,
            "direct_sanctioned": false,
            "gambling_accounts": false,
            "indirect_fake_kyc": false,
            "blacklisted_tokens": false,
            "indirect_cybercrime": false,
            "indirect_sanctioned": false,
            "phishing_activities": false,
            "blacklisted_accounts": false,
            "blackmail_activities": false,
            "darkweb_transactions": false,
            "direct_financial_crime": false,
            "direct_stealing_attack": false,
            "direct_money_laundering": false,
            "direct_gambling_accounts": true,
            "indirect_financial_crime": false,
            "indirect_stealing_attack": false,
            "direct_blacklisted_tokens": false,
            "indirect_money_laundering": false,
            "direct_phishing_activities": false,
            "indirect_gambling_accounts": true,
            "direct_blacklisted_accounts": true,
            "direct_blackmail_activities": false,
            "direct_darkweb_transactions": false,
            "indirect_blacklisted_tokens": true,
            "indirect_phishing_activities": false,
            "indirect_blacklisted_accounts": true,
            "indirect_blackmail_activities": false,
            "indirect_darkweb_transactions": false,
            "number_of_malicious_contracts_created": false,
            "direct_number_of_malicious_contracts_created": false,
            "indirect_number_of_malicious_contracts_created": false
        }
    }
}
```

{% endcode %}
{% endtab %}

{% tab title="400: Bad Request" %}
{% code lineNumbers="true" %}

```json
{
  "message": "Error Message",
  "status": 5000
}
```

{% endcode %}
{% endtab %}
{% endtabs %}
