@sphereon/ssi-sdk.oid4vci-holder 0.34.1-feature.SSISDK.26.RP.58 → 0.34.1-feature.SSISDK.45.189

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@sphereon/ssi-sdk.oid4vci-holder",
3
- "version": "0.34.1-feature.SSISDK.26.RP.58+9389054b",
3
+ "version": "0.34.1-feature.SSISDK.45.189+b7e0c23f",
4
4
  "source": "src/index.ts",
5
5
  "type": "module",
6
6
  "main": "./dist/index.cjs",
@@ -26,40 +26,41 @@
26
26
  "build": "tsup --config ../../tsup.config.ts --tsconfig ../../tsconfig.tsup.json"
27
27
  },
28
28
  "dependencies": {
29
- "@sphereon/did-auth-siop": "0.19.1-feature.SSISDK.13.32",
29
+ "@sphereon/did-auth-siop": "0.19.1-feature.DIIPv4.161",
30
30
  "@sphereon/kmp-mdoc-core": "0.2.0-SNAPSHOT.26",
31
- "@sphereon/oid4vci-client": "0.19.1-feature.SSISDK.13.32",
32
- "@sphereon/oid4vci-common": "0.19.1-feature.SSISDK.13.32",
33
- "@sphereon/ssi-sdk-ext.did-utils": "0.34.1-feature.SSISDK.26.RP.58+9389054b",
34
- "@sphereon/ssi-sdk-ext.identifier-resolution": "0.34.1-feature.SSISDK.26.RP.58+9389054b",
35
- "@sphereon/ssi-sdk-ext.jwt-service": "0.34.1-feature.SSISDK.26.RP.58+9389054b",
36
- "@sphereon/ssi-sdk-ext.key-utils": "0.34.1-feature.SSISDK.26.RP.58+9389054b",
37
- "@sphereon/ssi-sdk.contact-manager": "0.34.1-feature.SSISDK.26.RP.58+9389054b",
38
- "@sphereon/ssi-sdk.core": "0.34.1-feature.SSISDK.26.RP.58+9389054b",
39
- "@sphereon/ssi-sdk.credential-store": "0.34.1-feature.SSISDK.26.RP.58+9389054b",
40
- "@sphereon/ssi-sdk.credential-validation": "0.34.1-feature.SSISDK.26.RP.58+9389054b",
41
- "@sphereon/ssi-sdk.data-store": "0.34.1-feature.SSISDK.26.RP.58+9389054b",
42
- "@sphereon/ssi-sdk.issuance-branding": "0.34.1-feature.SSISDK.26.RP.58+9389054b",
43
- "@sphereon/ssi-sdk.mdl-mdoc": "0.34.1-feature.SSISDK.26.RP.58+9389054b",
44
- "@sphereon/ssi-sdk.oidf-client": "0.34.1-feature.SSISDK.26.RP.58+9389054b",
45
- "@sphereon/ssi-sdk.sd-jwt": "0.34.1-feature.SSISDK.26.RP.58+9389054b",
46
- "@sphereon/ssi-sdk.siopv2-oid4vp-common": "0.34.1-feature.SSISDK.26.RP.58+9389054b",
47
- "@sphereon/ssi-sdk.siopv2-oid4vp-op-auth": "0.34.1-feature.SSISDK.26.RP.58+9389054b",
48
- "@sphereon/ssi-sdk.xstate-machine-persistence": "0.34.1-feature.SSISDK.26.RP.58+9389054b",
49
- "@sphereon/ssi-types": "0.34.1-feature.SSISDK.26.RP.58+9389054b",
31
+ "@sphereon/oid4vci-client": "0.19.1-feature.DIIPv4.161",
32
+ "@sphereon/oid4vci-common": "0.19.1-feature.DIIPv4.161",
33
+ "@sphereon/ssi-sdk-ext.did-utils": "0.34.1-feature.SSISDK.45.189+b7e0c23f",
34
+ "@sphereon/ssi-sdk-ext.identifier-resolution": "0.34.1-feature.SSISDK.45.189+b7e0c23f",
35
+ "@sphereon/ssi-sdk-ext.jwt-service": "0.34.1-feature.SSISDK.45.189+b7e0c23f",
36
+ "@sphereon/ssi-sdk-ext.key-utils": "0.34.1-feature.SSISDK.45.189+b7e0c23f",
37
+ "@sphereon/ssi-sdk.contact-manager": "0.34.1-feature.SSISDK.45.189+b7e0c23f",
38
+ "@sphereon/ssi-sdk.core": "0.34.1-feature.SSISDK.45.189+b7e0c23f",
39
+ "@sphereon/ssi-sdk.credential-store": "0.34.1-feature.SSISDK.45.189+b7e0c23f",
40
+ "@sphereon/ssi-sdk.credential-validation": "0.34.1-feature.SSISDK.45.189+b7e0c23f",
41
+ "@sphereon/ssi-sdk.data-store": "0.34.1-feature.SSISDK.45.189+b7e0c23f",
42
+ "@sphereon/ssi-sdk.issuance-branding": "0.34.1-feature.SSISDK.45.189+b7e0c23f",
43
+ "@sphereon/ssi-sdk.mdl-mdoc": "0.34.1-feature.SSISDK.45.189+b7e0c23f",
44
+ "@sphereon/ssi-sdk.oidf-client": "0.34.1-feature.SSISDK.45.189+b7e0c23f",
45
+ "@sphereon/ssi-sdk.sd-jwt": "0.34.1-feature.SSISDK.45.189+b7e0c23f",
46
+ "@sphereon/ssi-sdk.siopv2-oid4vp-common": "0.34.1-feature.SSISDK.45.189+b7e0c23f",
47
+ "@sphereon/ssi-sdk.siopv2-oid4vp-op-auth": "0.34.1-feature.SSISDK.45.189+b7e0c23f",
48
+ "@sphereon/ssi-sdk.xstate-machine-persistence": "0.34.1-feature.SSISDK.45.189+b7e0c23f",
49
+ "@sphereon/ssi-types": "0.34.1-feature.SSISDK.45.189+b7e0c23f",
50
50
  "@veramo/core": "4.2.0",
51
51
  "@veramo/data-store": "4.2.0",
52
52
  "@veramo/utils": "4.2.0",
53
53
  "ajv": "^8.17.1",
54
54
  "ajv-formats": "^3.0.1",
55
+ "dcql": "1.0.1",
55
56
  "i18n-js": "^3.9.2",
56
57
  "lodash.memoize": "^4.1.2",
57
58
  "uuid": "^9.0.1",
58
59
  "xstate": "^4.38.3"
59
60
  },
60
61
  "devDependencies": {
61
- "@sphereon/oid4vc-common": "0.19.1-feature.SSISDK.13.32",
62
- "@sphereon/ssi-sdk-ext.did-resolver-jwk": "0.34.1-feature.SSISDK.26.RP.58+9389054b",
62
+ "@sphereon/oid4vc-common": "0.19.1-feature.DIIPv4.161",
63
+ "@sphereon/ssi-sdk-ext.did-resolver-jwk": "0.34.1-feature.SSISDK.45.189+b7e0c23f",
63
64
  "@sphereon/ssi-sdk.siopv2-oid4vp-common": "workspace:*",
64
65
  "@types/i18n-js": "^3.8.9",
65
66
  "@types/lodash.memoize": "^4.1.9",
@@ -89,5 +90,5 @@
89
90
  "OID4VCI",
90
91
  "State Machine"
91
92
  ],
92
- "gitHead": "9389054b1da3dda085e28b2ec27063e20cc296c6"
93
+ "gitHead": "b7e0c23f77ccaa650fc21d52315e28de54f38188"
93
94
  }
@@ -4,13 +4,14 @@ import {
4
4
  AuthorizationRequestOpts,
5
5
  AuthorizationServerClientOpts,
6
6
  AuthorizationServerOpts,
7
+ CredentialConfigurationSupported,
7
8
  CredentialConfigurationSupportedJwtVcJsonLdAndLdpVcV1_0_15,
8
9
  CredentialDefinitionJwtVcJsonLdAndLdpVcV1_0_15,
9
10
  CredentialOfferRequestWithBaseUrl,
10
11
  DefaultURISchemes,
11
12
  EndpointMetadataResult,
12
13
  getTypesFromAuthorizationDetails,
13
- getTypesFromCredentialOffer,
14
+ getTypesFromCredentialSupported,
14
15
  getTypesFromObject,
15
16
  Jwt,
16
17
  NotificationRequest,
@@ -35,7 +36,6 @@ import {
35
36
  ConnectionType,
36
37
  CorrelationIdentifierType,
37
38
  CredentialCorrelationType,
38
- CredentialRole,
39
39
  ensureRawDocument,
40
40
  FindPartyArgs,
41
41
  IBasicCredentialLocaleBranding,
@@ -55,10 +55,10 @@ import {
55
55
  JoseSignatureAlgorithmString,
56
56
  JwtDecodedVerifiableCredential,
57
57
  Loggers,
58
- OriginalVerifiableCredential,
59
58
  parseDid,
60
59
  SdJwtDecodedVerifiableCredentialPayload,
61
60
  WrappedW3CVerifiableCredential,
61
+ CredentialRole,
62
62
  } from '@sphereon/ssi-types'
63
63
  import {
64
64
  CredentialPayload,
@@ -75,6 +75,7 @@ import { decodeJWT } from 'did-jwt'
75
75
  import { v4 as uuidv4 } from 'uuid'
76
76
  import { OID4VCIMachine } from '../machines/oid4vciMachine'
77
77
  import {
78
+ extractCredentialFromResponse,
78
79
  getBasicIssuerLocaleBranding,
79
80
  getCredentialBranding,
80
81
  getCredentialConfigsSupportedMerged,
@@ -229,7 +230,7 @@ export class OID4VCIHolder implements IAgentPlugin {
229
230
  oid4vciHolderStoreIssuerBranding: this.oid4vciHolderStoreIssuerBranding.bind(this),
230
231
  }
231
232
 
232
- private readonly vcFormatPreferences: Array<string> = ['dc+sd-jwt', 'vc+sd-jwt', 'mso_mdoc', 'jwt_vc_json', 'jwt_vc', 'ldp_vc']
233
+ private readonly vcFormatPreferences: Array<string> = ['dc+sd-jwt', 'vc+sd-jwt', 'mso_mdoc', 'jwt_vc_json', 'jwt_vc', 'ldp_vc'] // TODO see SSISDK-52 concerning vc+sd-jwt
233
234
  private readonly jsonldCryptographicSuitePreferences: Array<string> = [
234
235
  'Ed25519Signature2018',
235
236
  'EcdsaSecp256k1Signature2019',
@@ -443,7 +444,13 @@ export class OID4VCIHolder implements IAgentPlugin {
443
444
  }
444
445
 
445
446
  if (offer) {
446
- types = getTypesFromCredentialOffer(offer.original_credential_offer)
447
+ const credentialsSupported: CredentialConfigurationSupported[] = offer.original_credential_offer.credential_configuration_ids.flatMap(
448
+ (configId) => {
449
+ const config = oid4vciClient.endpointMetadata.credentialIssuerMetadata?.credential_configurations_supported[configId]
450
+ return config ? [config as CredentialConfigurationSupported] : []
451
+ },
452
+ )
453
+ types = credentialsSupported.map((credentialSupported) => getTypesFromCredentialSupported(credentialSupported))
447
454
  } else {
448
455
  types = asArray(authorizationRequestOpts.authorizationDetails)
449
456
  .map((authReqOpts) => getTypesFromAuthorizationDetails(authReqOpts) ?? [])
@@ -939,21 +946,8 @@ export class OID4VCIHolder implements IAgentPlugin {
939
946
  ? 'credential_accepted_holder_signed'
940
947
  : 'credential_deleted_holder_signed'
941
948
  logger.log(`Subject issuance/signing will be used, with event`, event)
942
- const credentialResponse = mappedCredentialToAccept.credentialToAccept.credentialResponse
943
- let issuerVC
944
- if ('credential' in credentialResponse) {
945
- issuerVC = credentialResponse.credential as OriginalVerifiableCredential
946
- } else if (
947
- 'credentials' in credentialResponse &&
948
- credentialResponse.credentials &&
949
- Array.isArray(credentialResponse.credentials) &&
950
- credentialResponse.credentials.length > 0
951
- ) {
952
- issuerVC = credentialResponse.credentials[0].credential as OriginalVerifiableCredential // FIXME SSISDK-13 (no multi-credential support yet)
953
- }
954
- if (!issuerVC) {
955
- return Promise.reject(Error('No credential found in credential response'))
956
- }
949
+
950
+ const issuerVC = extractCredentialFromResponse(mappedCredentialToAccept.credentialToAccept.credentialResponse)
957
951
  const wrappedIssuerVC = CredentialMapper.toWrappedVerifiableCredential(issuerVC, { hasher: this.hasher ?? defaultHasher })
958
952
  console.log(`Wrapped VC: ${wrappedIssuerVC.type}, ${wrappedIssuerVC.format}`)
959
953
  // We will use the subject of the VCI Issuer (the holder, as the issuer of the new credential, so the below is not a mistake!)
@@ -1,16 +1,15 @@
1
1
  import { LOG } from '@sphereon/oid4vci-client'
2
2
  import {
3
+ AuthorizationChallengeCodeResponse,
3
4
  CredentialConfigurationSupported,
4
- CredentialSupportedSdJwtVc,
5
5
  CredentialConfigurationSupportedSdJwtVcV1_0_15,
6
- CredentialOfferFormatV1_0_11,
7
6
  CredentialResponse,
7
+ CredentialResponseV1_0_15,
8
+ CredentialSupportedSdJwtVc,
8
9
  getSupportedCredentials,
9
10
  getTypesFromCredentialSupported,
10
11
  getTypesFromObject,
11
12
  MetadataDisplay,
12
- OpenId4VCIVersion,
13
- AuthorizationChallengeCodeResponse,
14
13
  } from '@sphereon/oid4vci-common'
15
14
  import { KeyUse } from '@sphereon/ssi-sdk-ext.did-resolver-jwk'
16
15
  import { getOrCreatePrimaryIdentifier, SupportedDidMethodEnum } from '@sphereon/ssi-sdk-ext.did-utils'
@@ -23,6 +22,7 @@ import {
23
22
  managedIdentifierToJwk,
24
23
  } from '@sphereon/ssi-sdk-ext.identifier-resolution'
25
24
  import { keyTypeFromCryptographicSuite } from '@sphereon/ssi-sdk-ext.key-utils'
25
+ import { defaultHasher } from '@sphereon/ssi-sdk.core'
26
26
  import { IBasicCredentialLocaleBranding, IBasicIssuerLocaleBranding } from '@sphereon/ssi-sdk.data-store'
27
27
  import {
28
28
  CredentialMapper,
@@ -40,8 +40,12 @@ import {
40
40
  } from '@sphereon/ssi-types'
41
41
  import { asArray } from '@veramo/utils'
42
42
  import { translate } from '../localization/Localization'
43
+ import { FirstPartyMachine } from '../machines/firstPartyMachine'
44
+ import { issuerLocaleBrandingFrom, oid4vciGetCredentialBrandingFrom, sdJwtGetCredentialBrandingFrom } from '../mappers/OIDC4VCIBrandingMapper'
45
+ import { FirstPartyMachineState, FirstPartyMachineStateTypes } from '../types/FirstPartyMachine'
43
46
  import {
44
47
  DidAgents,
48
+ GetBasicIssuerLocaleBrandingArgs,
45
49
  GetCredentialBrandingArgs,
46
50
  GetCredentialConfigsSupportedArgs,
47
51
  GetCredentialConfigsSupportedBySingleTypeOrIdArgs,
@@ -49,22 +53,17 @@ import {
49
53
  GetIssuanceCryptoSuiteArgs,
50
54
  GetIssuanceDidMethodArgs,
51
55
  GetIssuanceOptsArgs,
52
- GetBasicIssuerLocaleBrandingArgs,
53
56
  GetPreferredCredentialFormatsArgs,
54
57
  IssuanceOpts,
55
58
  MapCredentialToAcceptArgs,
56
59
  MappedCredentialToAccept,
57
60
  OID4VCIHolderEvent,
61
+ RequiredContext,
58
62
  SelectAppLocaleBrandingArgs,
63
+ StartFirstPartApplicationMachine,
59
64
  VerificationResult,
60
65
  VerifyCredentialToAcceptArgs,
61
- StartFirstPartApplicationMachine,
62
- RequiredContext,
63
66
  } from '../types/IOID4VCIHolder'
64
- import { oid4vciGetCredentialBrandingFrom, sdJwtGetCredentialBrandingFrom, issuerLocaleBrandingFrom } from '../mappers/OIDC4VCIBrandingMapper'
65
- import { FirstPartyMachine } from '../machines/firstPartyMachine'
66
- import { FirstPartyMachineState, FirstPartyMachineStateTypes } from '../types/FirstPartyMachine'
67
- import { defaultHasher } from '@sphereon/ssi-sdk.core'
68
67
 
69
68
  export const getCredentialBranding = async (args: GetCredentialBrandingArgs): Promise<Record<string, Array<IBasicCredentialLocaleBranding>>> => {
70
69
  const { credentialsSupported, context } = args
@@ -153,21 +152,7 @@ export const selectCredentialLocaleBranding = async (
153
152
  export const verifyCredentialToAccept = async (args: VerifyCredentialToAcceptArgs): Promise<VerificationResult> => {
154
153
  const { mappedCredential, hasher, onVerifyEBSICredentialIssuer, schemaValidation, context } = args
155
154
 
156
- const credentialResponse = mappedCredential.credentialToAccept.credentialResponse
157
- let credential
158
- if ('credential' in credentialResponse) {
159
- credential = credentialResponse.credential as OriginalVerifiableCredential
160
- } else if (
161
- 'credentials' in credentialResponse &&
162
- credentialResponse.credentials &&
163
- Array.isArray(credentialResponse.credentials) &&
164
- credentialResponse.credentials.length > 0
165
- ) {
166
- credential = credentialResponse.credentials[0].credential as OriginalVerifiableCredential // FIXME SSISDK-13 (no multi-credential support yet)
167
- }
168
- if (!credential) {
169
- return Promise.reject(Error('No credential found in credential response'))
170
- }
155
+ const credential = extractCredentialFromResponse(mappedCredential.credentialToAccept.credentialResponse)
171
156
 
172
157
  const wrappedVC = CredentialMapper.toWrappedVerifiableCredential(credential, { hasher: hasher ?? defaultHasher })
173
158
  if (
@@ -216,21 +201,7 @@ export const verifyCredentialToAccept = async (args: VerifyCredentialToAcceptArg
216
201
  export const mapCredentialToAccept = async (args: MapCredentialToAcceptArgs): Promise<MappedCredentialToAccept> => {
217
202
  const { credentialToAccept, hasher } = args
218
203
 
219
- const credentialResponse: CredentialResponse = credentialToAccept.credentialResponse
220
- let verifiableCredential: W3CVerifiableCredential | undefined
221
- if ('credential' in credentialResponse) {
222
- verifiableCredential = credentialResponse.credential
223
- } else if (
224
- 'credentials' in credentialResponse &&
225
- credentialResponse.credentials &&
226
- Array.isArray(credentialResponse.credentials) &&
227
- credentialResponse.credentials.length > 0
228
- ) {
229
- verifiableCredential = credentialResponse.credentials[0].credential // FIXME SSISDK-13 (no multi-credential support yet)
230
- }
231
- if (!verifiableCredential) {
232
- return Promise.reject(Error('No credential found in credential response'))
233
- }
204
+ const verifiableCredential = extractCredentialFromResponse(credentialToAccept.credentialResponse) as W3CVerifiableCredential
234
205
 
235
206
  const wrappedVerifiableCredential: WrappedVerifiableCredential = CredentialMapper.toWrappedVerifiableCredential(
236
207
  verifiableCredential as OriginalVerifiableCredential,
@@ -261,6 +232,7 @@ export const mapCredentialToAccept = async (args: MapCredentialToAcceptArgs): Pr
261
232
  ? uniformVerifiableCredential.decodedPayload.iss
262
233
  : uniformVerifiableCredential.issuer.id
263
234
 
235
+ const credentialResponse = credentialToAccept.credentialResponse as CredentialResponseV1_0_15
264
236
  return {
265
237
  correlationId,
266
238
  credentialToAccept,
@@ -271,6 +243,27 @@ export const mapCredentialToAccept = async (args: MapCredentialToAcceptArgs): Pr
271
243
  }
272
244
  }
273
245
 
246
+ export const extractCredentialFromResponse = (credentialResponse: CredentialResponse): OriginalVerifiableCredential => {
247
+ let credential: OriginalVerifiableCredential | undefined
248
+
249
+ if ('credential' in credentialResponse) {
250
+ credential = credentialResponse.credential as OriginalVerifiableCredential
251
+ } else if (
252
+ 'credentials' in credentialResponse &&
253
+ credentialResponse.credentials &&
254
+ Array.isArray(credentialResponse.credentials) &&
255
+ credentialResponse.credentials.length > 0
256
+ ) {
257
+ credential = credentialResponse.credentials[0].credential as OriginalVerifiableCredential // FIXME SSISDK-13 (no multi-credential support yet)
258
+ }
259
+
260
+ if (!credential) {
261
+ throw new Error('No credential found in credential response')
262
+ }
263
+
264
+ return credential
265
+ }
266
+
274
267
  export const getIdentifierOpts = async (args: GetIdentifierArgs): Promise<ManagedIdentifierResult> => {
275
268
  const { issuanceOpt, context } = args
276
269
  const { identifier: identifierArg } = issuanceOpt
@@ -391,7 +384,10 @@ export const getCredentialConfigsSupportedBySingleTypeOrId = async (
391
384
  }
392
385
 
393
386
  if (configurationId) {
394
- const allSupported = client.getCredentialsSupported(false)
387
+ if (!format) {
388
+ return Promise.reject(Error('format parameter missing from input'))
389
+ }
390
+ const allSupported = client.getCredentialsSupported(format)
395
391
  return Object.fromEntries(
396
392
  Object.entries(allSupported).filter(
397
393
  ([id, supported]) => id === configurationId || supported.id === configurationId || createIdFromTypes(supported) === configurationId,
@@ -399,29 +395,15 @@ export const getCredentialConfigsSupportedBySingleTypeOrId = async (
399
395
  )
400
396
  }
401
397
 
402
- if (!types && !client.credentialOffer) {
403
- return Promise.reject(Error('openID4VCIClient has no credentialOffer and no types where provided'))
404
- /*} else if (!format && !client.credentialOffer) {
405
- return Promise.reject(Error('openID4VCIClient has no credentialOffer and no formats where provided'))*/
398
+ if (!client.credentialOffer) {
399
+ return Promise.reject(Error('openID4VCIClient has no credentialOffer'))
406
400
  }
407
- // We should always have a credential offer at this point given the above
408
- if (!Array.isArray(format) && client.credentialOffer) {
409
- if (
410
- client.version() > OpenId4VCIVersion.VER_1_0_09 &&
411
- typeof client.credentialOffer.credential_offer === 'object' &&
412
- 'credentials' in client.credentialOffer.credential_offer
413
- ) {
414
- format = client.credentialOffer.credential_offer.credentials
415
- .filter((cred: CredentialOfferFormatV1_0_11 | string) => typeof cred !== 'string')
416
- .map((cred: CredentialOfferFormatV1_0_11 | string) => (cred as CredentialOfferFormatV1_0_11).format)
417
- if (format?.length === 0) {
418
- format = undefined // Otherwise we would match nothing
419
- }
420
- }
401
+ if (!types) {
402
+ return Promise.reject(Error('openID4VCIClient has no types'))
421
403
  }
422
404
 
423
405
  const offerSupported = getSupportedCredentials({
424
- types: types ? [types] : client.getCredentialOfferTypes(),
406
+ types: [types],
425
407
  format,
426
408
  version: client.version(),
427
409
  issuerMetadata: client.endpointMetadata.credentialIssuerMetadata,
@@ -601,7 +583,7 @@ export const getIssuanceCryptoSuite = async (opts: GetIssuanceCryptoSuiteArgs):
601
583
  case 'jwt':
602
584
  case 'jwt_vc_json':
603
585
  case 'jwt_vc':
604
- case 'vc+sd-jwt':
586
+ //case 'vc+sd-jwt': // TODO see SSISDK-52 concerning vc+sd-jwt
605
587
  case 'dc+sd-jwt':
606
588
  case 'mso_mdoc': {
607
589
  const supportedPreferences: Array<JoseSignatureAlgorithm | JoseSignatureAlgorithmString> = jwtCryptographicSuitePreferences.filter(
@@ -1,10 +1,11 @@
1
- import { BaseActionObject, Interpreter, ResolveTypegenMeta, ServiceMap, State, StateMachine, StatesConfig, TypegenDisabled } from 'xstate'
1
+ import { RPRegistrationMetadataPayload } from '@sphereon/did-auth-siop'
2
2
  import { OpenID4VCIClientState } from '@sphereon/oid4vci-client'
3
- import { DidAuthConfig, Party } from '@sphereon/ssi-sdk.data-store'
4
- import { PresentationDefinitionWithLocation, RPRegistrationMetadataPayload } from '@sphereon/did-auth-siop'
5
- import { UniqueDigitalCredential } from '@sphereon/ssi-sdk.credential-store'
6
3
  import { AuthorizationChallengeCodeResponse } from '@sphereon/oid4vci-common'
4
+ import { UniqueDigitalCredential } from '@sphereon/ssi-sdk.credential-store'
5
+ import { DidAuthConfig, Party } from '@sphereon/ssi-sdk.data-store'
7
6
  import { IIdentifier } from '@veramo/core'
7
+ import { DcqlQuery } from 'dcql'
8
+ import { BaseActionObject, Interpreter, ResolveTypegenMeta, ServiceMap, State, StateMachine, StatesConfig, TypegenDisabled } from 'xstate'
8
9
  import { ErrorDetails, RequiredContext } from './IOID4VCIHolder'
9
10
 
10
11
  export enum FirstPartyMachineStateTypes {
@@ -149,7 +150,7 @@ export type SiopV2AuthorizationRequestData = {
149
150
  clientIdScheme?: string
150
151
  clientId?: string
151
152
  entityId?: string
152
- presentationDefinitions?: PresentationDefinitionWithLocation[]
153
+ dcqlQuery: DcqlQuery
153
154
  }
154
155
 
155
156
  export type FirstPartyMachineNavigationArgs = {