Skip to main content
Version: Node.js

KYC Match Reference

The KYC Match client is scoped to a single user, so in order to interact with the KYC Match service, you need to create a KycMatchUserClient instance for the user you want to verify.

KycMatchUserClients are created using the KycMatchClient accessible from the GlideClient instance.

KycMatchClient Reference

Methods

1. forUser

Description: forUser creates a KycMatchUserClient instance for the specified user.

Syntax:

forUser(identifier: UserIdentifier): Promise<KycMatchUserClient>;

Parameters:

ParameterTypeDescription
identifierUserIdentifierAn object representing a user (can be a phone number, ip address or custom user id)

UserIdentifier Properties:

PropertyTypeDescription
phoneNumberstringThe phone number of the user
ipAddressstringThe IP address of the user
userIdstringA custom user identifier

Only one of the properties should be provided.

Returns:

  • KycMatchUserClient: A client instance for the specified user.

Example:

import { GlideClient } from "glide-sdk";

async function main() {
const glide = new GlideClient({
clientId: "your-client-id",
clientSecret: "your-client-secret",
});

const kycMatchUserClient = await glide.kycMatch.forUser({
phoneNumber: '+555123456789'
});
}

main().catch(console.error);

KycMatchUserClient Reference

The KycMatchUserClient is used to interact with the KYC Match service for a specific user.

Methods

1. match

Description: match verifies if the provided KYC data matches with the user's information.

Syntax:

match(matchData: KycMatchData): Promise<KycMatchResponse>;

Parameters:

ParameterTypeDescription
matchDataKycMatchDataAn object containing the KYC data to match

KycMatchData Properties:

PropertyTypeDescription
idDocumentstringThe ID document number
namestringFull name
givenNamestringGiven name
familyNamestringFamily name
nameKanaHankakustringName in Kana Hankaku
nameKanaZenkakustringName in Kana Zenkaku
middleNamesstringMiddle names
familyNameAtBirthstringFamily name at birth
addressstringFull address
streetNamestringStreet name
streetNumbernumberStreet number
postalCodenumberPostal code
regionstringRegion
localitystringLocality
countrystringCountry
houseNumberExtensionstringHouse number extension
birthdatestringBirthdate in ISO format (YYYY-MM-DD)
emailstringEmail address
genderstringGender

Returns:

  • KycMatchResponse: An object containing the match results.

KycMatchResponse Properties:

PropertyTypeDescription
idDocumentMatchstringWhether the ID document matches
nameMatchstringWhether the name matches
givenNameMatchstringWhether the given name matches
familyNameMatchstringWhether the family name matches
nameKanaHankakuMatchstringWhether the Kana Hankaku name matches
nameKanaZenkakuMatchstringWhether the Kana Zenkaku name matches
middleNamesMatchstringWhether the middle names match
familyNameAtBirthMatchstringWhether the family name at birth matches
addressMatchstringWhether the address matches
streetNameMatchstringWhether the street name matches
streetNumberMatchstringWhether the street number matches
postalCodeMatchstringWhether the postal code matches
regionMatchstringWhether the region matches
localityMatchstringWhether the locality matches
countryMatchstringWhether the country matches
houseNumberExtensionMatchstringWhether the house number extension matches
birthdateMatchstringWhether the birthdate matches
emailMatchstringWhether the email matches
genderMatchstringWhether the gender matches

Each match property can have one of these values: "true", "false", or "not_available".

Example:

import { GlideClient } from "glide-sdk";

async function main() {
const glide = new GlideClient();
const kycMatchUserClient = await glide.kycMatch.forUser({
phoneNumber: '+555123456789'
});

const matchData = {
idDocument: '66666666q',
name: 'Federica Sanchez Arjona',
// ... other fields
};

const matchResult = await kycMatchUserClient.match(matchData);
console.log(matchResult);
// Output: { idDocumentMatch: "true", nameMatch: "true", ... }
}

main().catch(console.error);