The Vouch SDK ships with complete TypeScript type declarations. Every parameter object, response shape, and configuration option has a corresponding exported interface, so your editor can provide autocomplete and catch mismatches at compile time rather than at runtime.
Import any combination of interfaces using import type — the type-only import syntax ensures none of these contribute to your bundle:
Use these interfaces to build type-safe service wrappers and repository layers in your application. Wrapping SDK calls behind a typed interface makes them easier to test in isolation and keeps your domain logic decoupled from the SDK directly.
VouchOptions
Configuration options for the Vouch constructor. Pass this as the second argument to override default URLs.
IdentityVerifyResult
Returned by both vouch.identity.verify() and vouch.identity.submitVerification(). The data object contains the decision fields you should act on.
FraudAssessParams
Input to vouch.fraud.assess(). Describes the user and transaction being evaluated.
FraudAssessResult
Returned by vouch.fraud.assess(). Drive automated decisions from flag; use score and triggeredSignals for analytics and audit trails.
A single milestone entry in the milestones array when creating an escrow agreement.
CreateAgreementParams
Input to vouch.escrow.create(). Defines the parties, total amount, currency, and milestone breakdown.
AgreementResponse
Returned by vouch.escrow.create() and vouch.escrow.status(). Contains the full agreement record including all milestone states.
AssessPaymentParams
Input to vouch.escrow.assess(). Describes the buyer and the payment amount being assessed before funds are collected.
AssessPaymentResponse
Returned by vouch.escrow.assess(). Contains the fraud decision and, on non-RED outcomes, the virtual account details for payment collection.
virtualAccount is omitted from the response when flag is "RED". Always check the flag before attempting to read payment details.