@mattrglobal/verifier-sdk-web 2.0.3-unstable.47 → 2.0.3-unstable.48

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.
@@ -493,13 +493,16 @@ const getHashParamValue = (hash, param) => {
493
493
  };
494
494
 
495
495
  const createSession = async ({credentialQuery: credentialQuery, challenge: challenge, redirectUri: redirectUri, apiBaseUrl: apiBaseUrl, walletProviderId: walletProviderId, dcApiSupported: dcApiSupported, applicationId: applicationId}) => {
496
+ const openid4VpConfiguration = !!walletProviderId || !!redirectUri ? {
497
+ redirectUri: redirectUri,
498
+ walletProviderId: walletProviderId
499
+ } : undefined;
496
500
  const postData = {
497
501
  credentialQuery: credentialQuery,
498
502
  challenge: challenge,
499
503
  applicationId: applicationId,
500
- redirectUri: redirectUri,
501
- walletProviderId: walletProviderId,
502
- dcApiSupported: dcApiSupported
504
+ dcApiSupported: dcApiSupported,
505
+ openid4VpConfiguration: openid4VpConfiguration
503
506
  };
504
507
  const responseResult = await safeFetch(`${apiBaseUrl}/v2/presentations/web/sessions`, {
505
508
  method: "POST",