Matador Docs
Institutional Compliance

Recipe - Counterparty Screening

Enforcing KYC/KYB checks on every transfer.

Recipe: Counterparty Screening

This policy enforces that funds can only be sent to addresses that possess a valid Identity Token (e.g., a Soulbound Token representing KYC status).

The Strategy

Define Oracle: Trust a specific Identity Provider contract.

Inspect Recipient: Check if the to address has a balance of the ID token.

Enforce: Revert if balance is 0.

KYC stays in sync

When counterparties lose their credential, policy enforcement updates automatically.

The Policy

import "abis/ERC721.json" as IdentityToken;

permission CounterpartyKyc -> 1.0.0 {
    parameters: {
        token: address,
        recipient: address
    }

    when: {
        IdentityToken.balanceOf(owner: parameters.recipient) > 0,
        calldata.to == parameters.recipient
    }
}

Integration

This replaces "manual address whitelisting." Instead of updating a whitelist every time you have a new counterparty, you simply require them to get verified by your provider. Once verified, they are automatically allowed.

On this page