@mattrglobal/verifier-sdk-web 2.2.1-unstable.43 → 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.
- package/dist/lib/verifier-js-no-deps.cjs.js +6 -1
- package/dist/lib/verifier-js-no-deps.cjs.js.map +1 -1
- package/dist/lib/verifier-js.cjs.js +6 -1
- package/dist/lib/verifier-js.cjs.js.map +1 -1
- package/dist/typings/verifier/types/verifier-web-sdk.d.ts +6 -1
- package/dist/verifier-js.development.js +6 -1
- package/dist/verifier-js.development.js.map +1 -1
- package/dist/verifier-js.production.esm.js +1 -1
- package/dist/verifier-js.production.esm.js.map +1 -1
- package/dist/verifier-js.production.js +1 -1
- package/dist/verifier-js.production.js.map +1 -1
- package/package.json +2 -2
|
@@ -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({
|