Skip to main content
A scope is a country:regulator:activity string that tells the SDK which regulatory context to operate in. Scopes range from the broad base (no filtering) to highly specific leaf values like MX:AV:AVI (Mexican virtual-asset businesses) or MX:CNBV:TRANSMISOR (CNBV money transmitters). Scopes do two things at once: they partition data so that list operations return only records belonging to that scope, and they select the regulatory fields and enums that apply — transaction fields, alert codes, document requirements, and identifier validators are all scope-specific.

The scopeData hierarchy

Scope-specific fields live inside a scopeData sub-object rather than at the top level, keeping base fields (name, type, etc.) separate from scope-specific data:
{
  name: "Juan García",           // Base fields — always present
  scopeData: {
    MX: {                        // Country layer
      rfc: "GAJL850101ABC",
      curp: "GAJL850101HDFRRL09",
      actividadVulnerable: {     // Regulator/track layer
        AVI: {                   // Activity layer
          username: "jgarcia_crypto",
        },
        TSC: { /* ... */ }
      },
      cnbv: {
        TRANSMISOR: { /* ... */ }
      }
    }
  }
}
When using a scoped SDK, these nested fields are flattened into the top level of create/update inputs — the SDK handles the nesting for you.

Choosing a scope in the SDK

Pass the scope option to get a scope-aware SDK instance with the correct TypeScript types:
import { ComplianceSDK } from "@artu-ai/compliance-sdk";

// Activity-scoped instance — all operations default to MX:AV:AVI
const sdk = new ComplianceSDK({
  apiKey: process.env.ARTU_API_KEY!,
  environment: "test",
  scope: "MX:AV:AVI",
});
For static typing (recommended when your service targets a single scope), import the scope-specific sub-export instead:
// Mexico base
import { ComplianceSDK } from "@artu-ai/compliance-sdk/mx";

// Actividad Vulnerable — virtual assets
import { ComplianceSDK } from "@artu-ai/compliance-sdk/mx/av/avi";

// CNBV — money transmitters
import { ComplianceSDK } from "@artu-ai/compliance-sdk/mx/cnbv/transmisor";
Sub-exports give you correct model types (MexAVIClient, MexAVITransaction, etc.) and autocomplete for scope-specific fields without any runtime configuration.

URL slug convention

Dashboard URLs and query keys represent scopes as lowercase hyphen-separated slugs:
Scope stringURL slug
MXmx
MX:AVmx-av
MX:AV:AVImx-av-avi
MX:CNBV:TRANSMISORmx-cnbv-transmisor
The conversion is: replace : with - and lowercase everything.

Available scopes

ScopeDescription
MXMexico — all regulatory tracks
MX:AVActividad Vulnerable — non-financial businesses under LFPIORPI
MX:AV:ARIArrendamiento de Inmuebles (real estate leasing)
MX:AV:AVIActivos Virtuales (virtual assets / crypto)
MX:AV:INMInmuebles (real estate purchase/sale)
MX:AV:JYSJuegos y Sorteos (gambling, lotteries, contests)
MX:AV:MJRMetales y Joyas (precious metals and jewelry)
MX:AV:MPCMutuo, Préstamos y Créditos (non-bank loans and credit)
MX:AV:TSCTarjetas de Servicio y Crédito (service and credit cards)
MX:CNBVCNBV-regulated financial entities
MX:CNBV:TRANSMISORTransmisores de Dinero (money transmitters)