File tree Expand file tree Collapse file tree 3 files changed +138
-102
lines changed Expand file tree Collapse file tree 3 files changed +138
-102
lines changed Original file line number Diff line number Diff line change 1
1
{
2
2
"name" : " agent" ,
3
3
"dependencies" : {
4
- "@credo-ts/askar" : " ^0.5.0 " ,
5
- "@credo-ts/cheqd" : " ^0.5.0 " ,
6
- "@credo-ts/core" : " ^0.5.0 " ,
7
- "@credo-ts/indy-vdr" : " ^0.5.0 " ,
8
- "@credo-ts/node" : " ^0.5.0 " ,
9
- "@credo-ts/openid4vc" : " ^0.5.0 " ,
4
+ "@credo-ts/askar" : " ^0.5.1 " ,
5
+ "@credo-ts/cheqd" : " ^0.5.1 " ,
6
+ "@credo-ts/core" : " ^0.5.1 " ,
7
+ "@credo-ts/indy-vdr" : " ^0.5.1 " ,
8
+ "@credo-ts/node" : " ^0.5.1 " ,
9
+ "@credo-ts/openid4vc" : " ^0.5.1 " ,
10
10
"@hyperledger/aries-askar-nodejs" : " ^0.2.0" ,
11
11
"@hyperledger/indy-vdr-nodejs" : " ^0.2.0" ,
12
12
"cors" : " ^2.8.5" ,
Original file line number Diff line number Diff line change @@ -16,6 +16,7 @@ import {
16
16
} from "./issuerMetadata" ;
17
17
import { OfferSessionMetadata } from "./session" ;
18
18
import { getAvailableDids } from "./did" ;
19
+ import { OpenId4VcIssuanceSessionRepository } from "@credo-ts/openid4vc/build/openid4vc-issuer/repository" ;
19
20
20
21
const issuerId = "e451c49f-1186-4fe4-816d-a942151dfd59" ;
21
22
@@ -52,18 +53,14 @@ export const credentialRequestToCredentialMapper: OpenId4VciCredentialRequestToC
52
53
async ( {
53
54
credentialsSupported,
54
55
credentialRequest,
56
+ issuanceSession,
55
57
// FIXME: it would be useful if holderBinding would include some metadata on the key type / alg used
56
58
// for the key binding
57
59
holderBinding,
58
60
} ) => {
59
61
const credentialSupported = credentialsSupported [ 0 ] ;
60
62
61
- // FIXME: issuanceSession will be passed to this method from 0.5.1 onward
62
- // https://github.com/openwallet-foundation/credo-ts/pull/1795
63
- const issuanceSession =
64
- await agent . modules . openId4VcIssuer . findIssuanceSessionForCredentialRequest (
65
- { credentialRequest }
66
- ) ;
63
+ // not sure if this check is needed anymore
67
64
if ( ! issuanceSession ) throw new Error ( "Issuance session not found" ) ;
68
65
if ( ! issuanceSession . issuanceMetadata )
69
66
throw new Error ( "No issuance metadata" ) ;
You can’t perform that action at this time.
0 commit comments