@learncard/helpers 1.1.29 → 1.1.31

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.
@@ -56,6 +56,7 @@ var require_types_cjs_development = __commonJS({
56
56
  AchievementSubjectValidator: () => AchievementSubjectValidator,
57
57
  AchievementTypeValidator: () => AchievementTypeValidator,
58
58
  AchievementValidator: () => AchievementValidator,
59
+ AddTagInputValidator: () => AddTagInputValidator,
59
60
  AddressValidator: () => AddressValidator,
60
61
  AlignmentTargetTypeValidator: () => AlignmentTargetTypeValidator,
61
62
  AlignmentValidator: () => AlignmentValidator,
@@ -95,14 +96,22 @@ var require_types_cjs_development = __commonJS({
95
96
  ContactMethodVerificationValidator: () => ContactMethodVerificationValidator,
96
97
  ContextValidator: () => ContextValidator,
97
98
  ContractCredentialValidator: () => ContractCredentialValidator,
99
+ CountSkillsInputValidator: () => CountSkillsInputValidator,
100
+ CountSkillsResultValidator: () => CountSkillsResultValidator,
98
101
  CreateContactMethodSessionResponseValidator: () => CreateContactMethodSessionResponseValidator,
99
102
  CreateContactMethodSessionValidator: () => CreateContactMethodSessionValidator,
103
+ CreateManagedFrameworkBatchInputValidator: () => CreateManagedFrameworkBatchInputValidator,
104
+ CreateManagedFrameworkInputValidator: () => CreateManagedFrameworkInputValidator,
105
+ CreateSkillInputValidator: () => CreateSkillInputValidator,
106
+ CreateSkillsBatchInputValidator: () => CreateSkillsBatchInputValidator,
100
107
  CredentialInfoValidator: () => CredentialInfoValidator,
101
108
  CredentialRecordValidator: () => CredentialRecordValidator,
102
109
  CredentialSchemaValidator: () => CredentialSchemaValidator,
103
110
  CredentialStatusValidator: () => CredentialStatusValidator,
104
111
  CredentialSubjectValidator: () => CredentialSubjectValidator,
105
112
  CriteriaValidator: () => CriteriaValidator,
113
+ DeleteFrameworkInputValidator: () => DeleteFrameworkInputValidator,
114
+ DeleteSkillInputValidator: () => DeleteSkillInputValidator,
106
115
  DidDocumentValidator: () => DidDocumentValidator,
107
116
  EncryptedCredentialRecordValidator: () => EncryptedCredentialRecordValidator,
108
117
  EncryptedRecordValidator: () => EncryptedRecordValidator,
@@ -110,8 +119,13 @@ var require_types_cjs_development = __commonJS({
110
119
  EndorsementSubjectValidator: () => EndorsementSubjectValidator,
111
120
  EvidenceValidator: () => EvidenceValidator,
112
121
  FlatAuthGrantValidator: () => FlatAuthGrantValidator,
122
+ FrameworkWithSkillsValidator: () => FrameworkWithSkillsValidator,
113
123
  FullClaimHookValidator: () => FullClaimHookValidator,
114
124
  GeoCoordinatesValidator: () => GeoCoordinatesValidator,
125
+ GetFullSkillTreeInputValidator: () => GetFullSkillTreeInputValidator,
126
+ GetFullSkillTreeResultValidator: () => GetFullSkillTreeResultValidator,
127
+ GetSkillPathInputValidator: () => GetSkillPathInputValidator,
128
+ GetSkillPathResultValidator: () => GetSkillPathResultValidator,
115
129
  IdentifierEntryValidator: () => IdentifierEntryValidator,
116
130
  IdentifierTypeValidator: () => IdentifierTypeValidator,
117
131
  IdentityObjectValidator: () => IdentityObjectValidator,
@@ -150,6 +164,7 @@ var require_types_cjs_development = __commonJS({
150
164
  LCNProfileValidator: () => LCNProfileValidator,
151
165
  LCNSigningAuthorityForUserValidator: () => LCNSigningAuthorityForUserValidator,
152
166
  LCNSigningAuthorityValidator: () => LCNSigningAuthorityValidator,
167
+ LinkProviderFrameworkInputValidator: () => LinkProviderFrameworkInputValidator,
153
168
  PaginatedBoostRecipientsValidator: () => PaginatedBoostRecipientsValidator,
154
169
  PaginatedBoostRecipientsWithChildrenValidator: () => PaginatedBoostRecipientsWithChildrenValidator,
155
170
  PaginatedBoostsValidator: () => PaginatedBoostsValidator,
@@ -167,6 +182,8 @@ var require_types_cjs_development = __commonJS({
167
182
  PaginatedLCNProfileManagersValidator: () => PaginatedLCNProfileManagersValidator,
168
183
  PaginatedLCNProfilesAndManagersValidator: () => PaginatedLCNProfilesAndManagersValidator,
169
184
  PaginatedLCNProfilesValidator: () => PaginatedLCNProfilesValidator,
185
+ PaginatedSkillFrameworksValidator: () => PaginatedSkillFrameworksValidator,
186
+ PaginatedSkillTreeValidator: () => PaginatedSkillTreeValidator,
170
187
  PaginationOptionsValidator: () => PaginationOptionsValidator,
171
188
  PaginationResponseValidator: () => PaginationResponseValidator,
172
189
  ProfileValidator: () => ProfileValidator,
@@ -174,6 +191,8 @@ var require_types_cjs_development = __commonJS({
174
191
  RefreshServiceValidator: () => RefreshServiceValidator,
175
192
  RegExpValidator: () => RegExpValidator,
176
193
  RelatedValidator: () => RelatedValidator,
194
+ ReplaceSkillFrameworkSkillsInputValidator: () => ReplaceSkillFrameworkSkillsInputValidator,
195
+ ReplaceSkillFrameworkSkillsResultValidator: () => ReplaceSkillFrameworkSkillsResultValidator,
177
196
  ResultDescriptionValidator: () => ResultDescriptionValidator,
178
197
  ResultStatusTypeValidator: () => ResultStatusTypeValidator,
179
198
  ResultTypeValidator: () => ResultTypeValidator,
@@ -182,11 +201,27 @@ var require_types_cjs_development = __commonJS({
182
201
  SentCredentialInfoValidator: () => SentCredentialInfoValidator,
183
202
  ServiceValidator: () => ServiceValidator,
184
203
  SetPrimaryContactMethodValidator: () => SetPrimaryContactMethodValidator,
204
+ SkillDeletionStrategyValidator: () => SkillDeletionStrategyValidator,
205
+ SkillFrameworkAdminInputValidator: () => SkillFrameworkAdminInputValidator,
206
+ SkillFrameworkAdminsValidator: () => SkillFrameworkAdminsValidator,
207
+ SkillFrameworkIdInputValidator: () => SkillFrameworkIdInputValidator,
208
+ SkillFrameworkQueryValidator: () => SkillFrameworkQueryValidator,
209
+ SkillFrameworkStatusEnum: () => SkillFrameworkStatusEnum,
210
+ SkillFrameworkValidator: () => SkillFrameworkValidator,
211
+ SkillQueryValidator: () => SkillQueryValidator,
212
+ SkillStatusEnum: () => SkillStatusEnum,
213
+ SkillTreeNodeInputValidator: () => SkillTreeNodeInputValidator,
214
+ SkillTreeNodeValidator: () => SkillTreeNodeValidator,
215
+ SkillValidator: () => SkillValidator,
185
216
  StringQuery: () => StringQuery,
217
+ SyncFrameworkInputValidator: () => SyncFrameworkInputValidator,
218
+ TagValidator: () => TagValidator,
186
219
  TermsOfUseValidator: () => TermsOfUseValidator,
187
220
  UnsignedAchievementCredentialValidator: () => UnsignedAchievementCredentialValidator,
188
221
  UnsignedVCValidator: () => UnsignedVCValidator,
189
222
  UnsignedVPValidator: () => UnsignedVPValidator,
223
+ UpdateFrameworkInputValidator: () => UpdateFrameworkInputValidator,
224
+ UpdateSkillInputValidator: () => UpdateSkillInputValidator,
190
225
  VC2EvidenceValidator: () => VC2EvidenceValidator,
191
226
  VCValidator: () => VCValidator,
192
227
  VPValidator: () => VPValidator,
@@ -4646,7 +4681,14 @@ var require_types_cjs_development = __commonJS({
4646
4681
  }
4647
4682
  })
4648
4683
  );
4649
- var StringQuery = z.string().or(z.object({ $in: z.string().array() })).or(z.object({ $regex: RegExpValidator }));
4684
+ var BaseStringQuery = z.string().or(z.object({ $in: z.string().array() })).or(z.object({ $regex: RegExpValidator }));
4685
+ var StringQuery = z.union([
4686
+ BaseStringQuery,
4687
+ z.object({
4688
+ $or: BaseStringQuery.array()
4689
+ })
4690
+ ]);
4691
+ extendZodWithOpenApi(z);
4650
4692
  var LCNProfileDisplayValidator = z.object({
4651
4693
  backgroundColor: z.string().optional(),
4652
4694
  backgroundImage: z.string().optional(),
@@ -4731,7 +4773,8 @@ var require_types_cjs_development = __commonJS({
4731
4773
  to: z.string(),
4732
4774
  from: z.string(),
4733
4775
  sent: z.string().datetime(),
4734
- received: z.string().datetime().optional()
4776
+ received: z.string().datetime().optional(),
4777
+ metadata: z.record(z.unknown()).optional()
4735
4778
  });
4736
4779
  var BoostPermissionsValidator = z.object({
4737
4780
  role: z.string(),
@@ -4804,7 +4847,7 @@ var require_types_cjs_development = __commonJS({
4804
4847
  claimPermissions: BoostPermissionsValidator.optional(),
4805
4848
  allowAnyoneToCreateChildren: z.boolean().optional()
4806
4849
  });
4807
- var BoostQueryValidator = z.object({
4850
+ var BaseBoostQueryValidator = z.object({
4808
4851
  uri: StringQuery,
4809
4852
  name: StringQuery,
4810
4853
  type: StringQuery,
@@ -4813,6 +4856,12 @@ var require_types_cjs_development = __commonJS({
4813
4856
  status: LCNBoostStatus.or(z.object({ $in: LCNBoostStatus.array() })),
4814
4857
  autoConnectRecipients: z.boolean()
4815
4858
  }).partial();
4859
+ var BoostQueryValidator = z.union([
4860
+ z.object({
4861
+ $or: BaseBoostQueryValidator.array()
4862
+ }),
4863
+ BaseBoostQueryValidator
4864
+ ]);
4816
4865
  var PaginatedBoostsValidator = PaginationResponseValidator.extend({
4817
4866
  records: BoostValidator.array()
4818
4867
  });
@@ -4868,11 +4917,25 @@ var require_types_cjs_development = __commonJS({
4868
4917
  var ConsentFlowContractValidator = z.object({
4869
4918
  read: z.object({
4870
4919
  anonymize: z.boolean().optional(),
4871
- credentials: z.object({ categories: z.record(z.object({ required: z.boolean(), defaultEnabled: z.boolean().optional() })).default({}) }).default({}),
4920
+ credentials: z.object({
4921
+ categories: z.record(
4922
+ z.object({
4923
+ required: z.boolean(),
4924
+ defaultEnabled: z.boolean().optional()
4925
+ })
4926
+ ).default({})
4927
+ }).default({}),
4872
4928
  personal: z.record(z.object({ required: z.boolean(), defaultEnabled: z.boolean().optional() })).default({})
4873
4929
  }).default({}),
4874
4930
  write: z.object({
4875
- credentials: z.object({ categories: z.record(z.object({ required: z.boolean(), defaultEnabled: z.boolean().optional() })).default({}) }).default({}),
4931
+ credentials: z.object({
4932
+ categories: z.record(
4933
+ z.object({
4934
+ required: z.boolean(),
4935
+ defaultEnabled: z.boolean().optional()
4936
+ })
4937
+ ).default({})
4938
+ }).default({}),
4876
4939
  personal: z.record(z.object({ required: z.boolean(), defaultEnabled: z.boolean().optional() })).default({})
4877
4940
  }).default({})
4878
4941
  });
@@ -5015,6 +5078,17 @@ var require_types_cjs_development = __commonJS({
5015
5078
  var PaginatedConsentFlowTransactionsValidator = PaginationResponseValidator.extend({
5016
5079
  records: ConsentFlowTransactionValidator.array()
5017
5080
  });
5081
+ var BaseSkillFrameworkQueryValidator = z.object({
5082
+ id: StringQuery,
5083
+ name: StringQuery,
5084
+ description: StringQuery,
5085
+ sourceURI: StringQuery,
5086
+ status: StringQuery
5087
+ }).partial();
5088
+ var SkillFrameworkQueryValidator = z.union([
5089
+ z.object({ $or: BaseSkillFrameworkQueryValidator.array() }),
5090
+ BaseSkillFrameworkQueryValidator
5091
+ ]);
5018
5092
  var ContractCredentialValidator = z.object({
5019
5093
  credentialUri: z.string(),
5020
5094
  termsUri: z.string(),
@@ -5069,8 +5143,9 @@ var require_types_cjs_development = __commonJS({
5069
5143
  vcUris: z.array(z.string()).optional(),
5070
5144
  vpUris: z.array(z.string()).optional(),
5071
5145
  transaction: ConsentFlowTransactionValidator.optional(),
5072
- inbox: LCNNotificationInboxValidator.optional()
5073
- });
5146
+ inbox: LCNNotificationInboxValidator.optional(),
5147
+ metadata: z.record(z.unknown()).optional()
5148
+ }).passthrough();
5074
5149
  var LCNNotificationValidator = z.object({
5075
5150
  type: LCNNotificationTypeEnumValidator,
5076
5151
  to: LCNProfileValidator.partial().and(z.object({ did: z.string() })),
@@ -5193,31 +5268,55 @@ var require_types_cjs_development = __commonJS({
5193
5268
  });
5194
5269
  var IssueInboxCredentialValidator = z.object({
5195
5270
  recipient: ContactMethodQueryValidator.describe("The recipient of the credential"),
5196
- 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."),
5271
+ credential: VCValidator.passthrough().or(VPValidator.passthrough()).or(UnsignedVCValidator.passthrough()).describe(
5272
+ "The credential to issue. If not signed, the users default signing authority will be used, or the specified signing authority in the configuration."
5273
+ ),
5197
5274
  configuration: z.object({
5198
- 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."),
5275
+ signingAuthority: IssueInboxSigningAuthorityValidator.optional().describe(
5276
+ "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."
5277
+ ),
5199
5278
  webhookUrl: z.string().url().optional().describe("The webhook URL to receive credential issuance events."),
5200
5279
  expiresInDays: z.number().min(1).max(365).optional().describe("The number of days the credential will be valid for."),
5201
5280
  delivery: z.object({
5202
- 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."),
5281
+ suppress: z.boolean().optional().default(false).describe(
5282
+ "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."
5283
+ ),
5203
5284
  template: z.object({
5204
- 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."),
5285
+ id: z.enum(["universal-inbox-claim"]).optional().describe(
5286
+ "The template ID to use for the credential delivery. If not provided, the default template will be used."
5287
+ ),
5205
5288
  model: z.object({
5206
5289
  issuer: z.object({
5207
- name: z.string().optional().describe('The name of the organization (e.g., "State University").'),
5290
+ name: z.string().optional().describe(
5291
+ 'The name of the organization (e.g., "State University").'
5292
+ ),
5208
5293
  logoUrl: z.string().url().optional().describe("The URL of the organization's logo.")
5209
5294
  }).optional(),
5210
5295
  credential: z.object({
5211
- name: z.string().optional().describe('The name of the credential (e.g., "Bachelor of Science").'),
5212
- type: z.string().optional().describe('The type of the credential (e.g., "degree", "certificate").')
5296
+ name: z.string().optional().describe(
5297
+ 'The name of the credential (e.g., "Bachelor of Science").'
5298
+ ),
5299
+ type: z.string().optional().describe(
5300
+ 'The type of the credential (e.g., "degree", "certificate").'
5301
+ )
5213
5302
  }).optional(),
5214
5303
  recipient: z.object({
5215
- name: z.string().optional().describe('The name of the recipient (e.g., "John Doe").')
5304
+ name: z.string().optional().describe(
5305
+ 'The name of the recipient (e.g., "John Doe").'
5306
+ )
5216
5307
  }).optional()
5217
- }).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.")
5218
- }).optional().describe("The template to use for the credential delivery. If not provided, the default template will be used.")
5219
- }).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.")
5220
- }).optional().describe("Configuration for the credential issuance. If not provided, the default configuration will be used.")
5308
+ }).describe(
5309
+ "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."
5310
+ )
5311
+ }).optional().describe(
5312
+ "The template to use for the credential delivery. If not provided, the default template will be used."
5313
+ )
5314
+ }).optional().describe(
5315
+ "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."
5316
+ )
5317
+ }).optional().describe(
5318
+ "Configuration for the credential issuance. If not provided, the default configuration will be used."
5319
+ )
5221
5320
  });
5222
5321
  var IssueInboxCredentialResponseValidator = z.object({
5223
5322
  issuanceId: z.string(),
@@ -5279,6 +5378,191 @@ var require_types_cjs_development = __commonJS({
5279
5378
  expiresAt: z.string(),
5280
5379
  used: z.boolean()
5281
5380
  });
5381
+ var TagValidator = z.object({
5382
+ id: z.string(),
5383
+ name: z.string().min(1),
5384
+ slug: z.string().min(1),
5385
+ createdAt: z.string().optional(),
5386
+ updatedAt: z.string().optional()
5387
+ });
5388
+ var SkillStatusEnum = z.enum(["active", "archived"]);
5389
+ var SkillValidator = z.object({
5390
+ id: z.string(),
5391
+ statement: z.string(),
5392
+ description: z.string().optional(),
5393
+ code: z.string().optional(),
5394
+ icon: z.string().optional(),
5395
+ type: z.string().default("skill"),
5396
+ status: SkillStatusEnum.default("active"),
5397
+ frameworkId: z.string().optional(),
5398
+ createdAt: z.string().optional(),
5399
+ updatedAt: z.string().optional()
5400
+ });
5401
+ var BaseSkillQueryValidator = z.object({
5402
+ id: StringQuery,
5403
+ statement: StringQuery,
5404
+ description: StringQuery,
5405
+ code: StringQuery,
5406
+ type: StringQuery,
5407
+ status: SkillStatusEnum.or(z.object({ $in: SkillStatusEnum.array() }))
5408
+ }).partial();
5409
+ var SkillQueryValidator = z.union([
5410
+ z.object({
5411
+ $or: BaseSkillQueryValidator.array()
5412
+ }),
5413
+ BaseSkillQueryValidator
5414
+ ]);
5415
+ var SkillFrameworkStatusEnum = z.enum(["active", "archived"]);
5416
+ var SkillFrameworkValidator = z.object({
5417
+ id: z.string(),
5418
+ name: z.string(),
5419
+ description: z.string().optional(),
5420
+ image: z.string().optional(),
5421
+ sourceURI: z.string().url().optional(),
5422
+ status: SkillFrameworkStatusEnum.default("active"),
5423
+ createdAt: z.string().optional(),
5424
+ updatedAt: z.string().optional()
5425
+ });
5426
+ var PaginatedSkillFrameworksValidator = PaginationResponseValidator.extend({
5427
+ records: SkillFrameworkValidator.array()
5428
+ });
5429
+ var SkillTreeNodeValidator = SkillValidator.extend({
5430
+ children: z.array(z.lazy(() => SkillTreeNodeValidator)),
5431
+ hasChildren: z.boolean(),
5432
+ childrenCursor: z.string().nullable().optional()
5433
+ }).openapi({ ref: "SkillTreeNode" });
5434
+ var PaginatedSkillTreeValidator = z.object({
5435
+ hasMore: z.boolean(),
5436
+ cursor: z.string().nullable(),
5437
+ records: z.array(SkillTreeNodeValidator)
5438
+ });
5439
+ var SkillTreeNodeInputValidator = z.lazy(
5440
+ () => z.object({
5441
+ id: z.string().optional(),
5442
+ statement: z.string(),
5443
+ description: z.string().optional(),
5444
+ code: z.string().optional(),
5445
+ icon: z.string().optional(),
5446
+ type: z.string().optional(),
5447
+ status: SkillStatusEnum.optional(),
5448
+ children: z.array(SkillTreeNodeInputValidator).optional()
5449
+ })
5450
+ ).openapi({ ref: "SkillTreeNodeInput" });
5451
+ var LinkProviderFrameworkInputValidator = z.object({
5452
+ frameworkId: z.string()
5453
+ });
5454
+ var CreateManagedFrameworkInputValidator = z.object({
5455
+ id: z.string().optional(),
5456
+ name: z.string().min(1),
5457
+ description: z.string().optional(),
5458
+ image: z.string().optional(),
5459
+ sourceURI: z.string().url().optional(),
5460
+ status: SkillFrameworkStatusEnum.optional(),
5461
+ skills: z.array(SkillTreeNodeInputValidator).optional(),
5462
+ boostUris: z.array(z.string()).optional()
5463
+ });
5464
+ var UpdateFrameworkInputValidator = z.object({
5465
+ id: z.string(),
5466
+ name: z.string().min(1).optional(),
5467
+ description: z.string().optional(),
5468
+ image: z.string().optional(),
5469
+ sourceURI: z.string().url().optional(),
5470
+ status: SkillFrameworkStatusEnum.optional()
5471
+ }).refine(
5472
+ (data) => data.name !== void 0 || data.description !== void 0 || data.image !== void 0 || data.sourceURI !== void 0 || data.status !== void 0,
5473
+ {
5474
+ message: "At least one field must be provided to update",
5475
+ path: ["name"]
5476
+ }
5477
+ );
5478
+ var DeleteFrameworkInputValidator = z.object({ id: z.string() });
5479
+ var CreateManagedFrameworkBatchInputValidator = z.object({
5480
+ frameworks: z.array(
5481
+ CreateManagedFrameworkInputValidator.extend({
5482
+ skills: z.array(SkillTreeNodeInputValidator).optional()
5483
+ })
5484
+ ).min(1)
5485
+ });
5486
+ var SkillFrameworkAdminInputValidator = z.object({
5487
+ frameworkId: z.string(),
5488
+ profileId: z.string()
5489
+ });
5490
+ var SkillFrameworkIdInputValidator = z.object({ frameworkId: z.string() });
5491
+ var SkillFrameworkAdminsValidator = LCNProfileValidator.array();
5492
+ var SyncFrameworkInputValidator = z.object({ id: z.string() });
5493
+ var AddTagInputValidator = z.object({
5494
+ slug: z.string().min(1),
5495
+ name: z.string().min(1)
5496
+ });
5497
+ var CreateSkillInputValidator = z.object({
5498
+ frameworkId: z.string(),
5499
+ skill: SkillTreeNodeInputValidator,
5500
+ parentId: z.string().nullable().optional()
5501
+ });
5502
+ var UpdateSkillInputValidator = z.object({
5503
+ frameworkId: z.string(),
5504
+ id: z.string(),
5505
+ statement: z.string().optional(),
5506
+ description: z.string().optional(),
5507
+ code: z.string().optional(),
5508
+ icon: z.string().optional(),
5509
+ type: z.string().optional(),
5510
+ status: SkillStatusEnum.optional()
5511
+ }).refine(
5512
+ (data) => data.statement !== void 0 || data.description !== void 0 || data.code !== void 0 || data.icon !== void 0 || data.type !== void 0 || data.status !== void 0,
5513
+ {
5514
+ message: "At least one field must be provided to update a skill",
5515
+ path: ["statement"]
5516
+ }
5517
+ );
5518
+ var SkillDeletionStrategyValidator = z.enum(["recursive", "reparent"]);
5519
+ var DeleteSkillInputValidator = z.object({
5520
+ frameworkId: z.string(),
5521
+ id: z.string(),
5522
+ strategy: SkillDeletionStrategyValidator.optional().default("reparent")
5523
+ });
5524
+ var CreateSkillsBatchInputValidator = z.object({
5525
+ frameworkId: z.string(),
5526
+ skills: z.array(SkillTreeNodeInputValidator).min(1),
5527
+ parentId: z.string().nullable().optional()
5528
+ });
5529
+ var ReplaceSkillFrameworkSkillsInputValidator = z.object({
5530
+ frameworkId: z.string(),
5531
+ skills: z.array(SkillTreeNodeInputValidator).min(0)
5532
+ });
5533
+ var ReplaceSkillFrameworkSkillsResultValidator = z.object({
5534
+ created: z.number().int().min(0),
5535
+ updated: z.number().int().min(0),
5536
+ deleted: z.number().int().min(0),
5537
+ unchanged: z.number().int().min(0),
5538
+ total: z.number().int().min(0)
5539
+ });
5540
+ var CountSkillsInputValidator = z.object({
5541
+ frameworkId: z.string(),
5542
+ skillId: z.string().optional(),
5543
+ recursive: z.boolean().optional().default(false),
5544
+ onlyCountCompetencies: z.boolean().optional().default(false)
5545
+ });
5546
+ var CountSkillsResultValidator = z.object({
5547
+ count: z.number().int().min(0)
5548
+ });
5549
+ var GetFullSkillTreeInputValidator = z.object({
5550
+ frameworkId: z.string()
5551
+ });
5552
+ var GetFullSkillTreeResultValidator = z.object({
5553
+ skills: z.array(SkillTreeNodeValidator)
5554
+ });
5555
+ var GetSkillPathInputValidator = z.object({
5556
+ frameworkId: z.string(),
5557
+ skillId: z.string()
5558
+ });
5559
+ var GetSkillPathResultValidator = z.object({
5560
+ path: z.array(SkillValidator)
5561
+ });
5562
+ var FrameworkWithSkillsValidator = z.object({
5563
+ framework: SkillFrameworkValidator,
5564
+ skills: PaginatedSkillTreeValidator
5565
+ });
5282
5566
  }
5283
5567
  });
5284
5568
 
@@ -5300,7 +5584,8 @@ __export(src_exports, {
5300
5584
  RegExpTransformer: () => RegExpTransformer,
5301
5585
  isEncrypted: () => isEncrypted,
5302
5586
  isHex: () => isHex,
5303
- isVC2Format: () => isVC2Format
5587
+ isVC2Format: () => isVC2Format,
5588
+ unwrapBoostCredential: () => unwrapBoostCredential
5304
5589
  });
5305
5590
  module.exports = __toCommonJS(src_exports);
5306
5591
  var import_types = __toESM(require_dist());
@@ -5341,3 +5626,10 @@ var isVC2Format = /* @__PURE__ */ __name((credential) => {
5341
5626
  }
5342
5627
  return credential["@context"].includes("https://www.w3.org/ns/credentials/v2");
5343
5628
  }, "isVC2Format");
5629
+ var unwrapBoostCredential = /* @__PURE__ */ __name((vc) => {
5630
+ if (vc?.type?.includes("CertifiedBoostCredential") && vc?.boostCredential) {
5631
+ return vc.boostCredential;
5632
+ } else {
5633
+ return vc;
5634
+ }
5635
+ }, "unwrapBoostCredential");