11import {
22 AccessTokenResponse ,
3- Alg , CredentialOfferPayloadV1_0_13 ,
3+ Alg ,
4+ CredentialOfferPayloadV1_0_13 ,
45 CredentialOfferRequestWithBaseUrl ,
56 Jwt ,
67 OpenId4VCIVersion ,
7- ProofOfPossession , resolveCredentialOfferURI ,
8- WellKnownEndpoints
9- } from '@sphereon/oid4vci-common'
8+ ProofOfPossession ,
9+ resolveCredentialOfferURI ,
10+ WellKnownEndpoints ,
11+ } from '@sphereon/oid4vci-common' ;
1012// eslint-disable-next-line @typescript-eslint/ban-ts-comment
1113// @ts -ignore
1214import nock from 'nock' ;
@@ -311,25 +313,25 @@ describe('OID4VCI-Client should', () => {
311313 } ) ;
312314
313315 nock ( ISSUER_URL )
314- . post ( / t o k e n .* / )
315- . reply ( 200 , JSON . stringify ( mockedAccessTokenResponse ) ) ;
316+ . post ( / t o k e n .* / )
317+ . reply ( 200 , JSON . stringify ( mockedAccessTokenResponse ) ) ;
316318
317319 /* The actual access token calls */
318320 const accessTokenClient : AccessTokenClient = new AccessTokenClient ( ) ;
319321 const accessTokenResponse = await accessTokenClient . acquireAccessToken ( { credentialOffer : credentialOffer , pin : '1234' } ) ;
320322 expect ( accessTokenResponse . successBody ) . toEqual ( mockedAccessTokenResponse ) ;
321323 // Get the credential
322324 nock ( ISSUER_URL )
323- . post ( / c r e d e n t i a l / )
324- . reply ( 200 , {
325- format : 'jwt-vc' ,
326- credential : mockedVC ,
327- } ) ;
325+ . post ( / c r e d e n t i a l / )
326+ . reply ( 200 , {
327+ format : 'jwt-vc' ,
328+ credential : mockedVC ,
329+ } ) ;
328330 const credReqClient = CredentialRequestClientBuilder . fromCredentialOffer ( { credentialOffer : credentialOffer } )
329- . withFormat ( 'jwt_vc' )
331+ . withFormat ( 'jwt_vc' )
330332
331- . withTokenFromResponse ( accessTokenResponse . successBody ! )
332- . build ( ) ;
333+ . withTokenFromResponse ( accessTokenResponse . successBody ! )
334+ . build ( ) ;
333335
334336 const proof : ProofOfPossession = await ProofOfPossessionBuilder . fromJwt ( {
335337 jwt : jwtDid ,
@@ -338,13 +340,13 @@ describe('OID4VCI-Client should', () => {
338340 } ,
339341 version : OpenId4VCIVersion . VER_1_0_11 ,
340342 } )
341- . withEndpointMetadata ( {
342- issuer : 'https://issuer.research.identiproof.io' ,
343- credential_endpoint : 'https://issuer.research.identiproof.io/credential' ,
344- token_endpoint : 'https://issuer.research.identiproof.io/token' ,
345- } )
346- . withKid ( 'did:example:ebfeb1f712ebc6f1c276e12ec21/keys/1' )
347- . build ( ) ;
343+ . withEndpointMetadata ( {
344+ issuer : 'https://issuer.research.identiproof.io' ,
345+ credential_endpoint : 'https://issuer.research.identiproof.io/credential' ,
346+ token_endpoint : 'https://issuer.research.identiproof.io/token' ,
347+ } )
348+ . withKid ( 'did:example:ebfeb1f712ebc6f1c276e12ec21/keys/1' )
349+ . build ( ) ;
348350 const credResponse = await credReqClient . acquireCredentialsUsingProof ( {
349351 proofInput : proof ,
350352 credentialTypes : credentialOffer . original_credential_offer . credential_configuration_ids [ 0 ] ,
0 commit comments