Skip to content

Commit

Permalink
feat: add issuerVmId to the oauthToken
Browse files Browse the repository at this point in the history
  • Loading branch information
Pratap2018 committed Oct 24, 2024
1 parent 4311ce5 commit 84b720b
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions src/app-auth/services/app-auth.service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -88,11 +88,6 @@ export class AppAuthService {
}

if (!this.granterClient) {
console.log(
this.config.get('HID_NETWORK_RPC'),
this.authzWalletInstance.wallet,
);

this.granterClient = await SigningStargateClient.connectWithSigner(
this.config.get('HID_NETWORK_RPC'),
this.authzWalletInstance.wallet,
Expand Down Expand Up @@ -719,6 +714,10 @@ export class AppAuthService {
if (appDetail.issuerDid) {
payload['issuerDid'] = appDetail.issuerDid;
}
if (appDetail.issuerVerificationMethodId) {
payload['issuerVerificationMethodId'] =
appDetail.issuerVerificationMethodId;
}

if (
appDetail.dependentServices &&
Expand All @@ -729,6 +728,7 @@ export class AppAuthService {
}

const secret = this.config.get('JWT_SECRET');

const token = await this.jwt.signAsync(payload, {
expiresIn: expiresin.toString() + 'h',
secret,
Expand Down

0 comments on commit 84b720b

Please sign in to comment.