Configuration

Configure the TypeScript mDL SDK for your environment and requirements.

Configuration Options

The OwlEyesMDL constructor accepts a configuration object with the following options:

OptionTypeDefaultDescription
apiKeystringRequiredYour Owl Eyes API key
environment'sandbox' | 'production''sandbox'API environment
trustAnchorSourceTrustAnchorSource'aamva_vical'Trust anchor registry source
timeoutnumber30000Default timeout in milliseconds
retryConfigRetryConfigSee belowRetry configuration
loggingLoggingConfigSee belowLogging configuration

Full Configuration Example

config.tstypescript
Loading...

Trust Anchor Sources

Trust anchors are the root certificates used to validate mDL issuer certificates. The SDK supports multiple trust anchor sources:

SourceDescriptionCoverage
'aamva_vical'AAMVA Vehicle Identification Certificate Authority ListUnited States and Canada
'eu_trust_list'European Union Trust List (eIDAS 2.0)European Union member states
'combined'Both AAMVA VICAL and EU Trust ListGlobal coverage
customCustom trust anchor URLYour organization's trust anchors
Recommendation: Use 'aamva_vical' for US/Canada deployments,'eu_trust_list' for EU deployments, or 'combined' for international applications.

Environment Variables

We recommend storing sensitive configuration in environment variables:

.env.localbash
Loading...
config.tstypescript
Loading...

Initialization

After creating the verifier instance, call init() to initialize the SDK. This preloads trust anchors and validates your API key:

init.tstypescript
Loading...
Important: Always call init() and await its completion before creating sessions or performing verifications.