@openid4vc/openid4vci 0.3.0-alpha-20250820090758 → 0.3.0-alpha-20250821080409
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/dist/index.d.mts +8225 -2230
- package/dist/index.d.ts +8225 -2230
- package/dist/index.js +5 -8
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +5 -8
- package/dist/index.mjs.map +1 -1
- package/package.json +3 -3
package/dist/index.mjs
CHANGED
|
@@ -349,7 +349,7 @@ var zCredentialConfigurationSupportedCommon = z4.object({
|
|
|
349
349
|
credential_metadata: zCredentialConfigurationSupportedCommonCredentialMetadata.optional(),
|
|
350
350
|
// For typing purposes. Can be removed once we drop support for draft <= 15.
|
|
351
351
|
claims: z4.optional(z4.never())
|
|
352
|
-
});
|
|
352
|
+
}).passthrough();
|
|
353
353
|
var zCredentialConfigurationSupportedCommonDraft15 = z4.object({
|
|
354
354
|
format: z4.string(),
|
|
355
355
|
scope: z4.string().optional(),
|
|
@@ -368,7 +368,7 @@ var zCredentialConfigurationSupportedCommonDraft15 = z4.object({
|
|
|
368
368
|
display: z4.array(zCredentialConfigurationSupportedDisplayEntry).optional(),
|
|
369
369
|
// For typing purposes.
|
|
370
370
|
credential_metadata: z4.optional(z4.never())
|
|
371
|
-
});
|
|
371
|
+
}).passthrough();
|
|
372
372
|
|
|
373
373
|
// src/formats/credential/mso-mdoc/z-mso-mdoc.ts
|
|
374
374
|
var zMsoMdocFormatIdentifier = z5.literal("mso_mdoc");
|
|
@@ -414,7 +414,7 @@ var zSdJwtVcCredentialIssuerMetadataDraft14 = zCredentialConfigurationSupportedC
|
|
|
414
414
|
claims: z6.optional(zCredentialConfigurationSupportedClaimsDraft14),
|
|
415
415
|
order: z6.optional(z6.array(z6.string()))
|
|
416
416
|
});
|
|
417
|
-
var zSdJwtVcCredentialRequestFormatDraft14 =
|
|
417
|
+
var zSdJwtVcCredentialRequestFormatDraft14 = z6.object({
|
|
418
418
|
format: zSdJwtVcFormatIdentifier,
|
|
419
419
|
vct: z6.string(),
|
|
420
420
|
claims: z6.optional(zCredentialConfigurationSupportedClaimsDraft14)
|
|
@@ -714,10 +714,7 @@ var allCredentialIssuerMetadataFormats = [
|
|
|
714
714
|
var allCredentialIssuerMetadataFormatIdentifiers = allCredentialIssuerMetadataFormats.map(
|
|
715
715
|
(format) => format.shape.format.value
|
|
716
716
|
);
|
|
717
|
-
var zCredentialConfigurationSupportedWithFormats = z12.union([
|
|
718
|
-
zCredentialConfigurationSupportedCommon.passthrough(),
|
|
719
|
-
zCredentialConfigurationSupportedCommonDraft15.passthrough()
|
|
720
|
-
]).transform((data, ctx) => {
|
|
717
|
+
var zCredentialConfigurationSupportedWithFormats = z12.union([zCredentialConfigurationSupportedCommon, zCredentialConfigurationSupportedCommonDraft15]).transform((data, ctx) => {
|
|
721
718
|
if (!allCredentialIssuerMetadataFormatIdentifiers.includes(data.format)) return data;
|
|
722
719
|
const validators = allCredentialIssuerMetadataFormats.filter(
|
|
723
720
|
(formatValidator) => formatValidator.shape.format.value === data.format
|
|
@@ -1601,7 +1598,7 @@ async function retrieveDeferredCredentials(options) {
|
|
|
1601
1598
|
deferredCredentialErrorResponseResult
|
|
1602
1599
|
};
|
|
1603
1600
|
}
|
|
1604
|
-
const deferredCredentialResponseResult = isResponseContentType(ContentType2.Json, resourceResponse.response) ?
|
|
1601
|
+
const deferredCredentialResponseResult = isResponseContentType(ContentType2.Json, resourceResponse.response) ? zDeferredCredentialResponse.safeParse(await resourceResponse.response.clone().json()) : void 0;
|
|
1605
1602
|
if (!deferredCredentialResponseResult?.success) {
|
|
1606
1603
|
return {
|
|
1607
1604
|
...resourceResponse,
|