Skip to content

v3.21.0

Compare
Choose a tag to compare
@laurent-yoti laurent-yoti released this 24 May 08:03
· 113 commits to master since this release

Added

Support of DBS / RTW / RTR verification via dynamic share.

With Yoti platform now enabling verification of identity profile through the Yoti app, this new SDK version exposes the feature.

  1. Create a dynamic scenario with an identity profile verification:
const identityProfileRequirement = {
     trust_framework: 'UK_TFIDA',
     scheme: {
       type: 'DBS',
       objective: 'BASIC',
}

const dynamicPolicy = new Yoti.DynamicPolicyBuilder()
  .withIdentityProfileRequirements(identityProfileRequirement)
  .build();

const dynamicScenario = new Yoti.DynamicScenarioBuilder()
  .withCallbackEndpoint('/identity-profile-report')
  .withPolicy(dynamicPolicy)
  .withSubject(subject)
  .build();

See examples for more option on identityProfileRequirement.

  1. Handle receipt with identity profile verification:
const activityDetails = await yotiClient.getActivityDetails(token);
const outcome = activityDetails.getOutcome(); // "SUCCESS" expected

const profile = activityDetails.getProfile();
const identityProfile = profile.getIdentityProfileReport().getValue(); // {identity_assertion, verification_report,  authentication_report}

See examples for more details about the on identityProfileReport.

Updated

Profile.getAttributeById()

The method getAttributeById('some_id') is now available on the profile, this can be used to find a specific attribute which share its name with others, like document_images (the method getAttributesByName() only returning the first occurrence).

See examples for more details about the on identityProfileReport.