@learncard/didkey-plugin 1.0.40 → 1.0.42
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/didkey-plugin.cjs.development.js +162 -6
- package/dist/didkey-plugin.cjs.development.js.map +2 -2
- package/dist/didkey-plugin.cjs.production.min.js +1 -1
- package/dist/didkey-plugin.cjs.production.min.js.map +3 -3
- package/dist/didkey-plugin.esm.js +162 -6
- package/dist/didkey-plugin.esm.js.map +2 -2
- package/package.json +4 -4
@@ -81,6 +81,7 @@ var require_types_cjs_development = __commonJS({
|
|
81
81
|
ClaimHookQueryValidator: () => ClaimHookQueryValidator,
|
82
82
|
ClaimHookTypeValidator: () => ClaimHookTypeValidator,
|
83
83
|
ClaimHookValidator: () => ClaimHookValidator,
|
84
|
+
ClaimTokenValidator: () => ClaimTokenValidator,
|
84
85
|
ConsentFlowContractDataForDidValidator: () => ConsentFlowContractDataForDidValidator,
|
85
86
|
ConsentFlowContractDataValidator: () => ConsentFlowContractDataValidator,
|
86
87
|
ConsentFlowContractDetailsValidator: () => ConsentFlowContractDetailsValidator,
|
@@ -95,6 +96,11 @@ var require_types_cjs_development = __commonJS({
|
|
95
96
|
ConsentFlowTransactionActionValidator: () => ConsentFlowTransactionActionValidator,
|
96
97
|
ConsentFlowTransactionValidator: () => ConsentFlowTransactionValidator,
|
97
98
|
ConsentFlowTransactionsQueryValidator: () => ConsentFlowTransactionsQueryValidator,
|
99
|
+
ContactMethodCreateValidator: () => ContactMethodCreateValidator,
|
100
|
+
ContactMethodQueryValidator: () => ContactMethodQueryValidator,
|
101
|
+
ContactMethodValidator: () => ContactMethodValidator,
|
102
|
+
ContactMethodVerificationRequestValidator: () => ContactMethodVerificationRequestValidator,
|
103
|
+
ContactMethodVerificationValidator: () => ContactMethodVerificationValidator,
|
98
104
|
ContextValidator: () => ContextValidator,
|
99
105
|
ContractCredentialValidator: () => ContractCredentialValidator,
|
100
106
|
CredentialInfoValidator: () => CredentialInfoValidator,
|
@@ -116,6 +122,11 @@ var require_types_cjs_development = __commonJS({
|
|
116
122
|
IdentifierTypeValidator: () => IdentifierTypeValidator,
|
117
123
|
IdentityObjectValidator: () => IdentityObjectValidator,
|
118
124
|
ImageValidator: () => ImageValidator,
|
125
|
+
InboxCredentialQueryValidator: () => InboxCredentialQueryValidator,
|
126
|
+
InboxCredentialValidator: () => InboxCredentialValidator,
|
127
|
+
IssueInboxCredentialResponseValidator: () => IssueInboxCredentialResponseValidator,
|
128
|
+
IssueInboxCredentialValidator: () => IssueInboxCredentialValidator,
|
129
|
+
IssueInboxSigningAuthorityValidator: () => IssueInboxSigningAuthorityValidator,
|
119
130
|
JWERecipientHeaderValidator: () => JWERecipientHeaderValidator,
|
120
131
|
JWERecipientValidator: () => JWERecipientValidator,
|
121
132
|
JWEValidator: () => JWEValidator2,
|
@@ -125,7 +136,10 @@ var require_types_cjs_development = __commonJS({
|
|
125
136
|
LCNBoostClaimLinkOptionsValidator: () => LCNBoostClaimLinkOptionsValidator,
|
126
137
|
LCNBoostClaimLinkSigningAuthorityValidator: () => LCNBoostClaimLinkSigningAuthorityValidator,
|
127
138
|
LCNBoostStatus: () => LCNBoostStatus,
|
139
|
+
LCNInboxContactMethodValidator: () => LCNInboxContactMethodValidator,
|
140
|
+
LCNInboxStatusEnumValidator: () => LCNInboxStatusEnumValidator,
|
128
141
|
LCNNotificationDataValidator: () => LCNNotificationDataValidator,
|
142
|
+
LCNNotificationInboxValidator: () => LCNNotificationInboxValidator,
|
129
143
|
LCNNotificationMessageValidator: () => LCNNotificationMessageValidator,
|
130
144
|
LCNNotificationTypeEnumValidator: () => LCNNotificationTypeEnumValidator,
|
131
145
|
LCNNotificationValidator: () => LCNNotificationValidator,
|
@@ -148,6 +162,7 @@ var require_types_cjs_development = __commonJS({
|
|
148
162
|
PaginatedContractCredentialsValidator: () => PaginatedContractCredentialsValidator,
|
149
163
|
PaginatedEncryptedCredentialRecordsValidator: () => PaginatedEncryptedCredentialRecordsValidator,
|
150
164
|
PaginatedEncryptedRecordsValidator: () => PaginatedEncryptedRecordsValidator,
|
165
|
+
PaginatedInboxCredentialsValidator: () => PaginatedInboxCredentialsValidator,
|
151
166
|
PaginatedLCNProfileManagersValidator: () => PaginatedLCNProfileManagersValidator,
|
152
167
|
PaginatedLCNProfilesAndManagersValidator: () => PaginatedLCNProfilesAndManagersValidator,
|
153
168
|
PaginatedLCNProfilesValidator: () => PaginatedLCNProfilesValidator,
|
@@ -165,6 +180,7 @@ var require_types_cjs_development = __commonJS({
|
|
165
180
|
RubricCriterionValidator: () => RubricCriterionValidator,
|
166
181
|
SentCredentialInfoValidator: () => SentCredentialInfoValidator,
|
167
182
|
ServiceValidator: () => ServiceValidator,
|
183
|
+
SetPrimaryContactMethodValidator: () => SetPrimaryContactMethodValidator,
|
168
184
|
StringQuery: () => StringQuery,
|
169
185
|
TermsOfUseValidator: () => TermsOfUseValidator,
|
170
186
|
UnsignedAchievementCredentialValidator: () => UnsignedAchievementCredentialValidator,
|
@@ -4672,7 +4688,7 @@ var require_types_cjs_development = __commonJS({
|
|
4672
4688
|
bio: z.string().default("").describe("Longer bio for the profile."),
|
4673
4689
|
did: z.string().describe("Decentralized Identifier for the profile. (auto-assigned)"),
|
4674
4690
|
isPrivate: z.boolean().optional().describe("Whether the profile is private or not and shows up in search results."),
|
4675
|
-
email: z.string().optional().describe("Contact email address for the profile."),
|
4691
|
+
email: z.string().optional().describe("Contact email address for the profile. (deprecated)"),
|
4676
4692
|
image: z.string().optional().describe("Profile image URL for the profile."),
|
4677
4693
|
heroImage: z.string().optional().describe("Hero image URL for the profile."),
|
4678
4694
|
websiteLink: z.string().optional().describe("Website link for the profile."),
|
@@ -4799,7 +4815,8 @@ var require_types_cjs_development = __commonJS({
|
|
4799
4815
|
status: LCNBoostStatus.optional(),
|
4800
4816
|
autoConnectRecipients: z.boolean().optional(),
|
4801
4817
|
meta: z.record(z.any()).optional(),
|
4802
|
-
claimPermissions: BoostPermissionsValidator.optional()
|
4818
|
+
claimPermissions: BoostPermissionsValidator.optional(),
|
4819
|
+
allowAnyoneToCreateChildren: z.boolean().optional()
|
4803
4820
|
});
|
4804
4821
|
var BoostQueryValidator = z.object({
|
4805
4822
|
uri: StringQuery,
|
@@ -4840,7 +4857,8 @@ var require_types_cjs_development = __commonJS({
|
|
4840
4857
|
name: z.string().max(15).regex(/^[a-z0-9-]+$/, {
|
4841
4858
|
message: "The input string must contain only lowercase letters, numbers, and hyphens."
|
4842
4859
|
}),
|
4843
|
-
did: z.string()
|
4860
|
+
did: z.string(),
|
4861
|
+
isPrimary: z.boolean().optional()
|
4844
4862
|
})
|
4845
4863
|
});
|
4846
4864
|
var AutoBoostConfigValidator = z.object({
|
@@ -5021,16 +5039,33 @@ var require_types_cjs_development = __commonJS({
|
|
5021
5039
|
"BOOST_ACCEPTED",
|
5022
5040
|
"PRESENTATION_REQUEST",
|
5023
5041
|
"PRESENTATION_RECEIVED",
|
5024
|
-
"CONSENT_FLOW_TRANSACTION"
|
5042
|
+
"CONSENT_FLOW_TRANSACTION",
|
5043
|
+
"ISSUANCE_CLAIMED",
|
5044
|
+
"ISSUANCE_DELIVERED"
|
5025
5045
|
]);
|
5026
5046
|
var LCNNotificationMessageValidator = z.object({
|
5027
5047
|
title: z.string().optional(),
|
5028
5048
|
body: z.string().optional()
|
5029
5049
|
});
|
5050
|
+
var LCNInboxContactMethodValidator = z.object({
|
5051
|
+
type: z.string(),
|
5052
|
+
value: z.string()
|
5053
|
+
});
|
5054
|
+
var LCNInboxStatusEnumValidator = z.enum(["PENDING", "DELIVERED", "CLAIMED", "EXPIRED"]);
|
5055
|
+
var LCNNotificationInboxValidator = z.object({
|
5056
|
+
issuanceId: z.string(),
|
5057
|
+
status: LCNInboxStatusEnumValidator,
|
5058
|
+
recipient: z.object({
|
5059
|
+
contactMethod: LCNInboxContactMethodValidator.optional(),
|
5060
|
+
learnCardId: z.string().optional()
|
5061
|
+
}),
|
5062
|
+
timestamp: z.string().datetime().optional()
|
5063
|
+
});
|
5030
5064
|
var LCNNotificationDataValidator = z.object({
|
5031
5065
|
vcUris: z.array(z.string()).optional(),
|
5032
5066
|
vpUris: z.array(z.string()).optional(),
|
5033
|
-
transaction: ConsentFlowTransactionValidator.optional()
|
5067
|
+
transaction: ConsentFlowTransactionValidator.optional(),
|
5068
|
+
inbox: LCNNotificationInboxValidator.optional()
|
5034
5069
|
});
|
5035
5070
|
var LCNNotificationValidator = z.object({
|
5036
5071
|
type: LCNNotificationTypeEnumValidator,
|
@@ -5038,7 +5073,8 @@ var require_types_cjs_development = __commonJS({
|
|
5038
5073
|
from: LCNProfileValidator.partial().and(z.object({ did: z.string() })),
|
5039
5074
|
message: LCNNotificationMessageValidator.optional(),
|
5040
5075
|
data: LCNNotificationDataValidator.optional(),
|
5041
|
-
sent: z.string().datetime().optional()
|
5076
|
+
sent: z.string().datetime().optional(),
|
5077
|
+
webhookUrl: z.string().optional()
|
5042
5078
|
});
|
5043
5079
|
var AUTH_GRANT_AUDIENCE_DOMAIN_PREFIX = "auth-grant:";
|
5044
5080
|
var AuthGrantValidator = z.object({
|
@@ -5062,6 +5098,126 @@ var require_types_cjs_development = __commonJS({
|
|
5062
5098
|
description: StringQuery,
|
5063
5099
|
status: AuthGrantStatusValidator
|
5064
5100
|
}).partial();
|
5101
|
+
var contactMethodBase = z.object({
|
5102
|
+
id: z.string(),
|
5103
|
+
isVerified: z.boolean(),
|
5104
|
+
verifiedAt: z.string().optional(),
|
5105
|
+
isPrimary: z.boolean(),
|
5106
|
+
createdAt: z.string()
|
5107
|
+
});
|
5108
|
+
var ContactMethodValidator = z.discriminatedUnion("type", [
|
5109
|
+
z.object({
|
5110
|
+
type: z.literal("email"),
|
5111
|
+
value: z.string().email()
|
5112
|
+
}).merge(contactMethodBase),
|
5113
|
+
z.object({
|
5114
|
+
type: z.literal("phone"),
|
5115
|
+
value: z.string()
|
5116
|
+
}).merge(contactMethodBase)
|
5117
|
+
]);
|
5118
|
+
var createContactMethodBase = z.object({
|
5119
|
+
isVerified: z.boolean().optional(),
|
5120
|
+
isPrimary: z.boolean().optional()
|
5121
|
+
});
|
5122
|
+
var ContactMethodCreateValidator = z.discriminatedUnion("type", [
|
5123
|
+
z.object({
|
5124
|
+
type: z.literal("email"),
|
5125
|
+
value: z.string().email()
|
5126
|
+
}).merge(createContactMethodBase),
|
5127
|
+
z.object({
|
5128
|
+
type: z.literal("phone"),
|
5129
|
+
value: z.string()
|
5130
|
+
}).merge(createContactMethodBase)
|
5131
|
+
]);
|
5132
|
+
var ContactMethodQueryValidator = z.discriminatedUnion("type", [
|
5133
|
+
z.object({
|
5134
|
+
type: z.literal("email"),
|
5135
|
+
value: z.string().email()
|
5136
|
+
}),
|
5137
|
+
z.object({
|
5138
|
+
type: z.literal("phone"),
|
5139
|
+
value: z.string()
|
5140
|
+
})
|
5141
|
+
]);
|
5142
|
+
var ContactMethodVerificationRequestValidator = z.object({
|
5143
|
+
value: z.string(),
|
5144
|
+
type: z.enum(["email", "phone"])
|
5145
|
+
});
|
5146
|
+
var ContactMethodVerificationValidator = z.object({
|
5147
|
+
token: z.string()
|
5148
|
+
});
|
5149
|
+
var SetPrimaryContactMethodValidator = z.object({
|
5150
|
+
contactMethodId: z.string()
|
5151
|
+
});
|
5152
|
+
var InboxCredentialValidator = z.object({
|
5153
|
+
id: z.string(),
|
5154
|
+
credential: z.string(),
|
5155
|
+
isSigned: z.boolean(),
|
5156
|
+
currentStatus: LCNInboxStatusEnumValidator,
|
5157
|
+
expiresAt: z.string(),
|
5158
|
+
createdAt: z.string(),
|
5159
|
+
issuerDid: z.string(),
|
5160
|
+
webhookUrl: z.string().optional(),
|
5161
|
+
"signingAuthority.endpoint": z.string().optional(),
|
5162
|
+
"signingAuthority.name": z.string().optional()
|
5163
|
+
});
|
5164
|
+
var PaginatedInboxCredentialsValidator = z.object({
|
5165
|
+
hasMore: z.boolean(),
|
5166
|
+
records: z.array(InboxCredentialValidator),
|
5167
|
+
cursor: z.string().optional()
|
5168
|
+
});
|
5169
|
+
var InboxCredentialQueryValidator = z.object({
|
5170
|
+
currentStatus: LCNInboxStatusEnumValidator,
|
5171
|
+
id: z.string(),
|
5172
|
+
isSigned: z.boolean(),
|
5173
|
+
issuerDid: z.string()
|
5174
|
+
}).partial();
|
5175
|
+
var IssueInboxSigningAuthorityValidator = z.object({
|
5176
|
+
endpoint: z.string().url(),
|
5177
|
+
name: z.string()
|
5178
|
+
});
|
5179
|
+
var IssueInboxCredentialValidator = z.object({
|
5180
|
+
recipient: ContactMethodQueryValidator.describe("The recipient of the credential"),
|
5181
|
+
credential: VCValidator.passthrough().or(VPValidator.passthrough()).or(UnsignedVCValidator.passthrough()).describe("The credential to issue. If not signed, the users default signing authority will be used, or the specified signing authority in the configuration."),
|
5182
|
+
configuration: z.object({
|
5183
|
+
signingAuthority: IssueInboxSigningAuthorityValidator.optional().describe("The signing authority to use for the credential. If not provided, the users default signing authority will be used if the credential is not signed."),
|
5184
|
+
webhookUrl: z.string().url().optional().describe("The webhook URL to receive credential issuance events."),
|
5185
|
+
expiresInDays: z.number().min(1).max(365).optional().describe("The number of days the credential will be valid for."),
|
5186
|
+
delivery: z.object({
|
5187
|
+
suppress: z.boolean().optional().default(false).describe("Whether to suppress delivery of the credential to the recipient. If true, the email/sms will not be sent to the recipient. Useful if you would like to manually send claim link to your users."),
|
5188
|
+
template: z.object({
|
5189
|
+
id: z.enum(["universal-inbox-claim"]).optional().describe("The template ID to use for the credential delivery. If not provided, the default template will be used."),
|
5190
|
+
model: z.object({
|
5191
|
+
issuer: z.object({
|
5192
|
+
name: z.string().optional().describe('The name of the organization (e.g., "State University").'),
|
5193
|
+
logoUrl: z.string().url().optional().describe("The URL of the organization's logo.")
|
5194
|
+
}).optional(),
|
5195
|
+
credential: z.object({
|
5196
|
+
name: z.string().optional().describe('The name of the credential (e.g., "Bachelor of Science").'),
|
5197
|
+
type: z.string().optional().describe('The type of the credential (e.g., "degree", "certificate").')
|
5198
|
+
}).optional(),
|
5199
|
+
recipient: z.object({
|
5200
|
+
name: z.string().optional().describe('The name of the recipient (e.g., "John Doe").')
|
5201
|
+
}).optional()
|
5202
|
+
}).describe("The template model to use for the credential delivery. Injects via template variables into email/sms templates. If not provided, the default template will be used.")
|
5203
|
+
}).optional().describe("The template to use for the credential delivery. If not provided, the default template will be used.")
|
5204
|
+
}).optional().describe("Configuration for the credential delivery i.e. email or SMS. When credentials are sent to a user who has a verified email or phone associated with their account, delivery is skipped, and the credential will be sent using in-app notifications. If not provided, the default configuration will be used.")
|
5205
|
+
}).optional().describe("Configuration for the credential issuance. If not provided, the default configuration will be used.")
|
5206
|
+
});
|
5207
|
+
var IssueInboxCredentialResponseValidator = z.object({
|
5208
|
+
issuanceId: z.string(),
|
5209
|
+
status: LCNInboxStatusEnumValidator,
|
5210
|
+
recipient: ContactMethodQueryValidator,
|
5211
|
+
claimUrl: z.string().url().optional(),
|
5212
|
+
recipientDid: z.string().optional()
|
5213
|
+
});
|
5214
|
+
var ClaimTokenValidator = z.object({
|
5215
|
+
token: z.string(),
|
5216
|
+
contactMethodId: z.string(),
|
5217
|
+
createdAt: z.string(),
|
5218
|
+
expiresAt: z.string(),
|
5219
|
+
used: z.boolean()
|
5220
|
+
});
|
5065
5221
|
}
|
5066
5222
|
});
|
5067
5223
|
var require_dist = __commonJS({
|