@mattrglobal/verifier-sdk-web 2.2.1-unstable.42 → 2.2.1-unstable.44

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -7,7 +7,7 @@
7
7
  * Do Not Translate or Localize
8
8
  *
9
9
  * Bundle of @mattrglobal/verifier-sdk-web
10
- * Generated: 2026-07-07
10
+ * Generated: 2026-07-09
11
11
  * Version: 2.2.0
12
12
  * Dependencies:
13
13
  */
@@ -986,7 +986,7 @@ const requestCredentials = async options => {
986
986
  }
987
987
  assertType(RequestCredentialsOptionsValidator, "Invalid request credential options")(options);
988
988
  const {apiBaseUrl: apiBaseUrl, applicationId: applicationId} = initializeOptions;
989
- const {challenge: challenge = generateChallenge(), credentialQuery: credentialQuery, openid4vpConfiguration: openid4vpConfiguration, state: state} = options;
989
+ const {challenge: challenge = generateChallenge(), credentialQuery: credentialQuery, openid4vpConfiguration: openid4vpConfiguration, state: state, onSessionCreate: onSessionCreate} = options;
990
990
  const dcApiSupported = isDigitalCredentialsApiSupported();
991
991
  const openId4VpRedirectUri = deriveOpenId4vpRedirectUri(openid4vpConfiguration);
992
992
  const createSessionResult = await createSession({
@@ -1008,6 +1008,11 @@ const requestCredentials = async options => {
1008
1008
  }
1009
1009
  const session = createSessionResult.value;
1010
1010
  const {sessionKey: sessionKey, sessionId: sessionId} = session;
1011
+ if (onSessionCreate) {
1012
+ try {
1013
+ await onSessionCreate(session);
1014
+ } catch (_b) {}
1015
+ }
1011
1016
  if (session.type === SessionType.DigitalCredentialsApi) {
1012
1017
  const {request: request, sessionTtl: sessionTtl} = session;
1013
1018
  return await requestCredentialsWithDigitalCredentialsApi({