From 42688c6ae2e68d1a8521cec0a8b1321666a2844b Mon Sep 17 00:00:00 2001 From: sanderPostma Date: Wed, 30 Oct 2024 11:36:11 +0100 Subject: [PATCH] chore: import fixes --- .../lib/__tests__/issuerCallback.spec.ts | 10 ++++++---- packages/client/lib/__tests__/SdJwt.spec.ts | 8 ++++++-- .../issuer-rest/lib/__tests__/ClientIssuerIT.spec.ts | 6 +++--- .../lib/__tests__/IssuerTokenServer.spec.ts | 2 +- packages/issuer/lib/VcIssuer.ts | 2 +- packages/issuer/lib/__tests__/VcIssuerBuilder.spec.ts | 3 +-- packages/issuer/lib/builder/VcIssuerBuilder.ts | 2 +- packages/issuer/lib/builder/index.ts | 1 + 8 files changed, 20 insertions(+), 14 deletions(-) diff --git a/packages/callback-example/lib/__tests__/issuerCallback.spec.ts b/packages/callback-example/lib/__tests__/issuerCallback.spec.ts index 7541f357..528fb51a 100644 --- a/packages/callback-example/lib/__tests__/issuerCallback.spec.ts +++ b/packages/callback-example/lib/__tests__/issuerCallback.spec.ts @@ -16,7 +16,12 @@ import { ProofOfPossession, } from '@sphereon/oid4vci-common' import { CredentialOfferSession } from '@sphereon/oid4vci-common' -import { CredentialSupportedBuilderV1_13, VcIssuer, VcIssuerBuilder } from '@sphereon/oid4vci-issuer' +import { + AuthorizationServerMetadataBuilder, + CredentialSupportedBuilderV1_13, + VcIssuer, + VcIssuerBuilder +} from '@sphereon/oid4vci-issuer' import { MemoryStates } from '@sphereon/oid4vci-issuer' import { CredentialDataSupplierResult } from '@sphereon/oid4vci-issuer/dist/types' import { ICredential, IProofPurpose, IProofType, W3CVerifiableCredential } from '@sphereon/ssi-types' @@ -24,9 +29,6 @@ import { DIDDocument } from 'did-resolver' import * as jose from 'jose' import { generateDid, getIssuerCallbackV1_0_11, getIssuerCallbackV1_0_13, verifyCredential } from '../IssuerCallback' -import { - AuthorizationServerMetadataBuilder -} from '@sphereon/oid4vci-issuer/dist/builder/AuthorizationServerMetadataBuilder' const INITIATION_TEST_URI = 'openid-credential-offer://?credential_offer=%7B%22credential_issuer%22:%22https://credential-issuer.example.com%22,%22credential_configuration_ids%22:%5B%22UniversityDegreeCredential%22%5D,%22grants%22:%7B%22urn:ietf:params:oauth:grant-type:pre-authorized_code%22:%7B%22pre-authorized_code%22:%22oaKazRN8I0IbtZ0C7JuMn5%22,%22tx_code%22:%7B%22input_mode%22:%22text%22,%22description%22:%22Please%20enter%20the%20serial%20number%20of%20your%20physical%20drivers%20license%22%7D%7D%7D%7D' diff --git a/packages/client/lib/__tests__/SdJwt.spec.ts b/packages/client/lib/__tests__/SdJwt.spec.ts index 5774a484..5eae2943 100644 --- a/packages/client/lib/__tests__/SdJwt.spec.ts +++ b/packages/client/lib/__tests__/SdJwt.spec.ts @@ -9,8 +9,12 @@ import { import nock from 'nock'; import { OpenID4VCIClientV1_0_13 } from '..'; -import { createAccessTokenResponse, IssuerMetadataBuilderV1_13, VcIssuerBuilder } from '../../../issuer'; -import { AuthorizationServerMetadataBuilder } from '../../../issuer/lib/builder/AuthorizationServerMetadataBuilder' +import { + AuthorizationServerMetadataBuilder, + createAccessTokenResponse, + IssuerMetadataBuilderV1_13, + VcIssuerBuilder +} from '../../../issuer' export const UNIT_TEST_TIMEOUT = 30000; diff --git a/packages/issuer-rest/lib/__tests__/ClientIssuerIT.spec.ts b/packages/issuer-rest/lib/__tests__/ClientIssuerIT.spec.ts index 6aebef79..60a6c08b 100644 --- a/packages/issuer-rest/lib/__tests__/ClientIssuerIT.spec.ts +++ b/packages/issuer-rest/lib/__tests__/ClientIssuerIT.spec.ts @@ -15,11 +15,11 @@ import { PRE_AUTH_CODE_LITERAL, PRE_AUTH_GRANT_LITERAL } from '@sphereon/oid4vci-common' -import { VcIssuer } from '@sphereon/oid4vci-issuer/dist/VcIssuer' -import { CredentialSupportedBuilderV1_13, VcIssuerBuilder } from '@sphereon/oid4vci-issuer/dist/builder' import { AuthorizationServerMetadataBuilder -} from '@sphereon/oid4vci-issuer/dist/builder/AuthorizationServerMetadataBuilder' +} from '@sphereon/oid4vci-issuer' +import { VcIssuer } from '@sphereon/oid4vci-issuer/dist/VcIssuer' +import { CredentialSupportedBuilderV1_13, VcIssuerBuilder } from '@sphereon/oid4vci-issuer/dist/builder' import { MemoryStates } from '@sphereon/oid4vci-issuer/dist/state-manager' import { ExpressBuilder, ExpressSupport } from '@sphereon/ssi-express-support' import { IProofPurpose, IProofType } from '@sphereon/ssi-types' diff --git a/packages/issuer-rest/lib/__tests__/IssuerTokenServer.spec.ts b/packages/issuer-rest/lib/__tests__/IssuerTokenServer.spec.ts index 6e34c43c..d071d950 100644 --- a/packages/issuer-rest/lib/__tests__/IssuerTokenServer.spec.ts +++ b/packages/issuer-rest/lib/__tests__/IssuerTokenServer.spec.ts @@ -14,7 +14,7 @@ import { import { VcIssuer } from '@sphereon/oid4vci-issuer' import { AuthorizationServerMetadataBuilder -} from '@sphereon/oid4vci-issuer/dist/builder/AuthorizationServerMetadataBuilder' +} from '@sphereon/oid4vci-issuer' import { MemoryStates } from '@sphereon/oid4vci-issuer/dist/state-manager' import { ExpressBuilder, ExpressSupport } from '@sphereon/ssi-express-support' import { DIDDocument } from 'did-resolver' diff --git a/packages/issuer/lib/VcIssuer.ts b/packages/issuer/lib/VcIssuer.ts index 816f0c37..e2847eaf 100644 --- a/packages/issuer/lib/VcIssuer.ts +++ b/packages/issuer/lib/VcIssuer.ts @@ -37,7 +37,7 @@ import { } from '@sphereon/oid4vci-common' import { CredentialEventNames, CredentialOfferEventNames, EVENTS } from '@sphereon/oid4vci-common' import { CredentialIssuerMetadataOptsV1_0_13 } from '@sphereon/oid4vci-common' -import { OpenidFederationMetadata } from '@sphereon/oid4vci-common/dist/types/OpenidFederationMetadata' +import { OpenidFederationMetadata } from '@sphereon/oid4vci-common' import { CompactSdJwtVc, CredentialMapper, InitiatorType, SubSystem, System, W3CVerifiableCredential } from '@sphereon/ssi-types' import { assertValidPinNumber, createCredentialOfferObject, createCredentialOfferURIFromObject, CredentialOfferGrantInput } from './functions' diff --git a/packages/issuer/lib/__tests__/VcIssuerBuilder.spec.ts b/packages/issuer/lib/__tests__/VcIssuerBuilder.spec.ts index 49f3c230..4343ed47 100644 --- a/packages/issuer/lib/__tests__/VcIssuerBuilder.spec.ts +++ b/packages/issuer/lib/__tests__/VcIssuerBuilder.spec.ts @@ -1,8 +1,7 @@ import { uuidv4 } from '@sphereon/oid4vc-common' import { CredentialConfigurationSupportedV1_0_13, IssuerCredentialSubjectDisplay, IssueStatus, TokenErrorResponse } from '@sphereon/oid4vci-common' -import { AuthorizationServerMetadataBuilder } from '../builder/AuthorizationServerMetadataBuilder' -import { CredentialSupportedBuilderV1_13, VcIssuerBuilder } from '../index' +import { AuthorizationServerMetadataBuilder, CredentialSupportedBuilderV1_13, VcIssuerBuilder } from '../index' const authorizationServerMetadata = new AuthorizationServerMetadataBuilder() diff --git a/packages/issuer/lib/builder/VcIssuerBuilder.ts b/packages/issuer/lib/builder/VcIssuerBuilder.ts index 9b562c8b..5496886d 100644 --- a/packages/issuer/lib/builder/VcIssuerBuilder.ts +++ b/packages/issuer/lib/builder/VcIssuerBuilder.ts @@ -13,7 +13,7 @@ import { TxCode, URIState } from '@sphereon/oid4vci-common' -import { OpenidFederationMetadata } from '@sphereon/oid4vci-common/dist/types/OpenidFederationMetadata' +import { OpenidFederationMetadata } from '@sphereon/oid4vci-common' import { VcIssuer } from '../VcIssuer' import { MemoryStates } from '../state-manager' diff --git a/packages/issuer/lib/builder/index.ts b/packages/issuer/lib/builder/index.ts index 730e4e1f..92083c45 100644 --- a/packages/issuer/lib/builder/index.ts +++ b/packages/issuer/lib/builder/index.ts @@ -2,3 +2,4 @@ export * from './CredentialSupportedBuilderV1_13' export * from './VcIssuerBuilder' export * from './IssuerMetadataBuilderV1_13' export * from './DisplayBuilder' +export * from './AuthorizationServerMetadataBuilder'