import { APIResource } from "../core/resource.mjs"; import * as Shared from "./shared.mjs"; import { APIPromise } from "../core/api-promise.mjs"; import { DefaultPagination, type DefaultPaginationParams, PagePromise } from "../core/pagination.mjs"; import { RequestOptions } from "../internal/request-options.mjs"; /** * Endpoints for Know Your Customer (KYC) and Know Your Business (KYB) verification, including managing beneficial owners and triggering verification for customers. */ export declare class Verifications extends APIResource { /** * Retrieve details of a specific verification by ID. * * @example * ```ts * const verification = await client.verifications.retrieve( * 'verificationId', * ); * ``` */ retrieve(verificationID: string, options?: RequestOptions): APIPromise; /** * Retrieve a list of verifications with optional filtering by customer ID and * status. * * @example * ```ts * // Automatically fetches more pages as needed. * for await (const verificationListResponse of client.verifications.list()) { * // ... * } * ``` */ list(query?: VerificationListParams | null | undefined, options?: RequestOptions): PagePromise; /** * Trigger KYC (individual) or KYB (business) verification for a customer. The * response indicates whether all required information has been provided. If data * is missing, the `errors` array describes exactly what needs to be supplied * before verification can proceed. * * Call this endpoint again after resolving errors to re-submit. * * @example * ```ts * const response = await client.verifications.submit({ * customerId: * 'Customer:019542f5-b3e7-1d02-0000-000000000001', * }); * ``` */ submit(body: VerificationSubmitParams, options?: RequestOptions): APIPromise; } export type VerificationListResponsesDefaultPagination = DefaultPagination; export interface VerificationRetrieveResponse { /** * Unique identifier for this verification */ id: string; /** * When this verification was created */ createdAt: string; /** * The ID of the customer being verified */ customerId: string; /** * List of issues preventing verification from proceeding. Empty when * verificationStatus is APPROVED or IN_PROGRESS. */ errors: Array; /** * Current status of the KYC/KYB verification */ verificationStatus: 'RESOLVE_ERRORS' | 'PENDING_MANUAL_REVIEW' | 'IN_PROGRESS' | 'APPROVED' | 'REJECTED' | 'READY_FOR_VERIFICATION'; /** * When this verification was last updated */ updatedAt?: string; } export interface VerificationListResponse { /** * Unique identifier for this verification */ id: string; /** * When this verification was created */ createdAt: string; /** * The ID of the customer being verified */ customerId: string; /** * List of issues preventing verification from proceeding. Empty when * verificationStatus is APPROVED or IN_PROGRESS. */ errors: Array; /** * Current status of the KYC/KYB verification */ verificationStatus: 'RESOLVE_ERRORS' | 'PENDING_MANUAL_REVIEW' | 'IN_PROGRESS' | 'APPROVED' | 'REJECTED' | 'READY_FOR_VERIFICATION'; /** * When this verification was last updated */ updatedAt?: string; } export interface VerificationSubmitResponse { /** * Unique identifier for this verification */ id: string; /** * When this verification was created */ createdAt: string; /** * The ID of the customer being verified */ customerId: string; /** * List of issues preventing verification from proceeding. Empty when * verificationStatus is APPROVED or IN_PROGRESS. */ errors: Array; /** * Current status of the KYC/KYB verification */ verificationStatus: 'RESOLVE_ERRORS' | 'PENDING_MANUAL_REVIEW' | 'IN_PROGRESS' | 'APPROVED' | 'REJECTED' | 'READY_FOR_VERIFICATION'; /** * When this verification was last updated */ updatedAt?: string; } export interface VerificationListParams extends DefaultPaginationParams { /** * Filter by customer ID */ customerId?: string; /** * Maximum number of results to return (default 20, max 100) */ limit?: number; /** * Filter by verification status */ verificationStatus?: 'RESOLVE_ERRORS' | 'PENDING_MANUAL_REVIEW' | 'IN_PROGRESS' | 'APPROVED' | 'REJECTED' | 'READY_FOR_VERIFICATION'; } export interface VerificationSubmitParams { /** * The ID of the customer to verify */ customerId: string; } export declare namespace Verifications { export { type VerificationRetrieveResponse as VerificationRetrieveResponse, type VerificationListResponse as VerificationListResponse, type VerificationSubmitResponse as VerificationSubmitResponse, type VerificationListResponsesDefaultPagination as VerificationListResponsesDefaultPagination, type VerificationListParams as VerificationListParams, type VerificationSubmitParams as VerificationSubmitParams, }; } //# sourceMappingURL=verifications.d.mts.map