Skip to content

KYC Rail

Customer verification and identity management endpoints.

Overview

The KYC rail provides comprehensive customer verification:

  • Identity verification
  • Document verification
  • Sanctions screening
  • PEP (Politically Exposed Persons) checks

Endpoints

Create Verification

http
POST /v1/kyc/verifications
typescript
const verification = await iof.kyc.createVerification({
  customerId: "cust_123",
  type: "identity",
  documents: [
    { type: "passport", fileId: "file_abc" },
    { type: "proof_of_address", fileId: "file_def" },
  ],
});

Response:

json
{
  "id": "kyc_verification_xyz",
  "status": "pending",
  "customerId": "cust_123",
  "type": "identity",
  "createdAt": "2024-01-15T10:30:00Z"
}

Get Verification

http
GET /v1/kyc/verifications/:id
typescript
const verification = await iof.kyc.getVerification("kyc_verification_xyz");

List Verifications

http
GET /v1/kyc/verifications
typescript
const verifications = await iof.kyc.listVerifications({
  customerId: "cust_123",
  status: "verified",
  limit: 20,
});

Upload Document

http
POST /v1/kyc/documents
typescript
const document = await iof.kyc.uploadDocument({
  customerId: "cust_123",
  type: "passport",
  file: fileBuffer,
  metadata: {
    country: "MY",
    expiryDate: "2028-01-01",
  },
});

Screen Customer

http
POST /v1/kyc/screen
typescript
const screening = await iof.kyc.screen({
  customerId: "cust_123",
  checks: ["sanctions", "pep", "adverse_media"],
});

Response:

json
{
  "id": "screen_abc",
  "customerId": "cust_123",
  "results": {
    "sanctions": { "matched": false },
    "pep": { "matched": false },
    "adverse_media": { "matched": false, "hits": 0 }
  },
  "riskScore": 15,
  "recommendation": "approve"
}

Verification Status

StatusDescription
pendingAwaiting processing
in_reviewManual review required
verifiedSuccessfully verified
rejectedVerification failed
expiredVerification expired

Document Types

TypeDescription
passportPassport document
national_idNational ID card
drivers_licenseDriver's license
proof_of_addressUtility bill, bank statement
company_registrationBusiness registration

Webhooks

EventDescription
kyc.submittedVerification submitted
kyc.verifiedVerification approved
kyc.rejectedVerification rejected
kyc.expiredVerification expired

Next Steps

Licensed under the Apache License 2.0