@thejob/schema 2.4.1 → 2.6.0

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.js CHANGED
@@ -3385,6 +3385,14 @@ var CampaignSchema = object31({
3385
3385
  * state transition, so it belongs in the state.
3386
3386
  */
3387
3387
  dryRun: boolean17().optional().default(true).label("Dry Run"),
3388
+ /**
3389
+ * Re-eligibility: when someone this campaign already mailed may get it again.
3390
+ *
3391
+ * Absent: on every run they match (job alerts, digests). `0`: once per
3392
+ * person. `N`: again only after N days. Opt-in, because most recurring
3393
+ * campaigns exist to mail the same people repeatedly.
3394
+ */
3395
+ resendAfterDays: number14().integer().min(0).max(365).nullable().optional().default(void 0).label("Resend After (days)"),
3388
3396
  maxRecipients: number14().integer().min(1).max(CAMPAIGN_MAX_RECIPIENTS_CEILING).optional().default(void 0).label("Max Recipients"),
3389
3397
  utm: object31({
3390
3398
  campaign: string22().optional().max(120).label("utm_campaign"),
@@ -3818,55 +3826,443 @@ var EntitlementConsumeSchema = object38({
3818
3826
  idempotencyKey: string27().trim().required().min(8).max(128).label("Idempotency Key")
3819
3827
  }).label("Entitlement Consume");
3820
3828
 
3829
+ // src/taxonomy/taxonomy.schema.ts
3830
+ import { array as array18, boolean as boolean19, number as number18, object as object39, string as string28 } from "yup";
3831
+
3832
+ // src/taxonomy/taxonomy.constant.ts
3833
+ var SupportedConceptSources = ["seed", "manual", "import"];
3834
+ var SupportedTaxonomySources = ["seed", "manual"];
3835
+ var SupportedTaxonomyNodeKinds = ["category", "subcategory", "group"];
3836
+ var SupportedPrefilterRules = [
3837
+ "spoken_language",
3838
+ "no_letters",
3839
+ "url_or_email",
3840
+ "fragment"
3841
+ ];
3842
+ var SupportedUnmatchedResolutions = ["pending", "added", "rejected"];
3843
+ var SupportedUnmatchedReasons = ["ambiguous"];
3844
+ var SupportedProposalKinds = ["concept", "alias", "placement"];
3845
+ var SupportedProposalFilters = [...SupportedProposalKinds, "uncategorized"];
3846
+ var SupportedProposalStatuses = ["draft", "approved", "discarded"];
3847
+ var SupportedProposalMessageRoles = ["operator", "model"];
3848
+ var SupportedResolverVerdicts = [
3849
+ "same",
3850
+ "narrower",
3851
+ "broader",
3852
+ "related",
3853
+ "new_concept",
3854
+ "out_of_scope"
3855
+ ];
3856
+ var SupportedAuditStatuses = ["pending", "correct", "wrong"];
3857
+ var SupportedReleaseKinds = ["seed", "manual", "review", "auto"];
3858
+ var SupportedReleaseStatuses = ["open", "rolled_back"];
3859
+ var SupportedMatchTypes = ["exact", "canonical", "fuzzy", "none"];
3860
+ var SupportedTaxonomyJobKinds = [
3861
+ "describe-concepts",
3862
+ "retype-concepts",
3863
+ "generate-aliases",
3864
+ "alias-backfill",
3865
+ "close-gaps",
3866
+ "propose-placements",
3867
+ "place-unplaced",
3868
+ "calibrate-placement",
3869
+ "reseed",
3870
+ "reindex",
3871
+ "calibrate-resolver",
3872
+ "golden",
3873
+ "resolve-backlog"
3874
+ ];
3875
+ var SupportedTaxonomyJobStates = ["running", "succeeded", "failed", "cancelled"];
3876
+ var CONCEPT_ID_PATTERN = /^[a-z][a-z0-9-]*_[a-z0-9-]+$/;
3877
+ var VOCABULARY_ID_PATTERN = /^[a-z][a-z0-9-]{0,31}$/;
3878
+ var TAXONOMY_NODE_ID_PATTERN = /^[A-Za-z0-9_]{1,64}$/;
3879
+ var CONCEPT_TYPE_PATTERN = /^[a-z][a-z0-9_]{0,63}$/;
3880
+ var SCHEDULE_MIN_HOURS = 1;
3881
+ var SCHEDULE_MAX_HOURS = 24 * 30;
3882
+
3883
+ // src/taxonomy/taxonomy.schema.ts
3884
+ var conceptId = () => string28().matches(CONCEPT_ID_PATTERN, "conceptId must look like <vocabulary>_<slug>");
3885
+ var vocabularyId = () => string28().matches(VOCABULARY_ID_PATTERN, "vocabulary must match [a-z][a-z0-9-]{0,31}");
3886
+ var nodeId = () => string28().matches(TAXONOMY_NODE_ID_PATTERN, "node ids look like CAT_01_TECH");
3887
+ var strings = () => array18(string28().trim().min(1).required());
3888
+ var VocabularyTypeSchema = object39({
3889
+ id: string28().matches(CONCEPT_TYPE_PATTERN, "type ids match [a-z][a-z0-9_]*").required().label("Type ID"),
3890
+ /** Shown to the model when it classifies a concept; include examples. */
3891
+ description: string28().defined().label("Description")
3892
+ }).label("Vocabulary Type");
3893
+ var VocabularySchema = object39({
3894
+ vocabularyId: vocabularyId().required().label("Vocabulary ID"),
3895
+ name: string28().trim().min(1).required().label("Name"),
3896
+ /** What one concept is called in prompts and messages: "skill", "role". */
3897
+ noun: string28().trim().min(1).required().label("Noun"),
3898
+ nounPlural: string28().trim().min(1).required().label("Noun (plural)"),
3899
+ /** What belongs in this vocabulary, for prompts. */
3900
+ description: string28().trim().min(1).required().label("Description"),
3901
+ /** Where its terms are written, for the "swap it in" test: "a job posting". */
3902
+ appearsIn: string28().trim().min(1).required().label("Appears In"),
3903
+ /** Things that are NOT concepts of this vocabulary, for prompts. */
3904
+ outOfScope: string28().trim().min(1).required().label("Out of Scope"),
3905
+ types: array18(VocabularyTypeSchema.required()).min(1).required().test(
3906
+ "unique-type-ids",
3907
+ "type ids must be unique",
3908
+ (types) => !types || new Set(types.map((t) => t.id)).size === types.length
3909
+ ).label("Types"),
3910
+ /** The type a concept gets when nothing more specific is known. One of `types`. */
3911
+ defaultType: string28().required().test("default-type-listed", "defaultType must be one of the type ids", function(value) {
3912
+ const types = this.parent.types ?? [];
3913
+ return types.some((t) => t.id === value);
3914
+ }).label("Default Type"),
3915
+ prefilter: array18(string28().oneOf(SupportedPrefilterRules).required()).default([]).label("Prefilter"),
3916
+ /**
3917
+ * Words that qualify a term without changing what it names ("fluent",
3918
+ * "native"), dropped from its canonical lookup form in THIS vocabulary only.
3919
+ */
3920
+ qualifiers: strings().optional().label("Qualifiers"),
3921
+ /** Extra instructions per model task; each is optional. */
3922
+ guidance: object39({
3923
+ describe: string28().optional(),
3924
+ classify: string28().optional(),
3925
+ aliases: string28().optional(),
3926
+ verify: string28().optional(),
3927
+ place: string28().optional()
3928
+ }).label("Guidance"),
3929
+ source: string28().oneOf(SupportedTaxonomySources).required().label("Source"),
3930
+ createdAt: number18().required().label("Created At"),
3931
+ updatedAt: number18().required().label("Updated At")
3932
+ }).label("Vocabulary");
3933
+ var TaxonomyNodeSchema = object39({
3934
+ nodeId: nodeId().required().label("Node ID"),
3935
+ vocabulary: vocabularyId().required().label("Vocabulary"),
3936
+ kind: string28().oneOf(SupportedTaxonomyNodeKinds).required().label("Kind"),
3937
+ name: string28().trim().min(1).required().label("Name"),
3938
+ /** Groups carry a description; categories and subcategories usually do not. */
3939
+ description: string28().optional().label("Description"),
3940
+ aliases: strings().default([]).label("Aliases"),
3941
+ /** null for categories (the roots). */
3942
+ parentId: string28().nullable().defined().label("Parent ID"),
3943
+ /** Ancestor ids from the root down to and including this node. */
3944
+ path: array18(string28().required()).default([]).label("Path"),
3945
+ source: string28().oneOf(SupportedTaxonomySources).optional().label("Source"),
3946
+ createdAt: number18().required().label("Created At"),
3947
+ updatedAt: number18().required().label("Updated At")
3948
+ }).label("Taxonomy Node");
3949
+ var ConceptMembershipSchema = object39({
3950
+ categoryId: string28().required().label("Category ID"),
3951
+ categoryName: string28().required().label("Category Name"),
3952
+ subcategoryId: string28().required().label("Subcategory ID"),
3953
+ subcategoryName: string28().required().label("Subcategory Name"),
3954
+ groupId: string28().required().label("Group ID"),
3955
+ groupName: string28().required().label("Group Name"),
3956
+ /** The source record this membership came from; '' when written by hand. */
3957
+ sourceId: string28().default("").label("Source ID")
3958
+ }).label("Concept Membership");
3959
+ var ConceptSchema = object39({
3960
+ /** `<vocabulary>_<slug>`, e.g. `skills_power-bi`. Primary key. */
3961
+ conceptId: conceptId().required().label("Concept ID"),
3962
+ vocabulary: vocabularyId().required().label("Vocabulary"),
3963
+ name: string28().trim().min(1).max(200).required().label("Name"),
3964
+ /** One of the vocabulary's type ids; checked against the vocabulary by the service. */
3965
+ type: string28().trim().matches(CONCEPT_TYPE_PATTERN, "type must be a type id").required().label("Type"),
3966
+ description: string28().trim().max(2e3).default("").label("Description"),
3967
+ aliases: strings().default([]).label("Aliases"),
3968
+ memberships: array18(ConceptMembershipSchema.required()).default([]).label("Memberships"),
3969
+ /** Always concepts of the same vocabulary. */
3970
+ relatedConceptIds: strings().default([]).label("Related Concepts"),
3971
+ source: string28().oneOf(SupportedConceptSources).required().label("Source"),
3972
+ createdAt: number18().required().label("Created At"),
3973
+ updatedAt: number18().required().label("Updated At"),
3974
+ /** Resume marker of `retype-concepts`: set once the type was examined. */
3975
+ retypedAt: number18().optional().label("Retyped At"),
3976
+ /** Resume marker of `generate-aliases`: set even when no alias was added. */
3977
+ aliasedAt: number18().optional().label("Aliased At"),
3978
+ /** Set while `description` is a stand-in; removed once a real one is written. */
3979
+ descriptionPending: boolean19().isTrue().optional().label("Description Pending")
3980
+ }).label("Concept");
3981
+ var UnmatchedTermSchema = object39({
3982
+ vocabulary: vocabularyId().required().label("Vocabulary"),
3983
+ /** The raw input as first received. */
3984
+ term: string28().required().label("Term"),
3985
+ /** The dedupe key, so "React JS" and "react.js" share a row. */
3986
+ normalizedTerm: string28().required().label("Normalized Term"),
3987
+ count: number18().integer().min(0).required().label("Count"),
3988
+ firstSeenAt: number18().required().label("First Seen At"),
3989
+ lastSeenAt: number18().required().label("Last Seen At"),
3990
+ /** Which callers sent it, capped. */
3991
+ sources: array18(
3992
+ object39({
3993
+ service: string28().required(),
3994
+ context: string28().optional()
3995
+ }).required()
3996
+ ).default([]).label("Sources"),
3997
+ resolution: string28().oneOf(SupportedUnmatchedResolutions).required().label("Resolution"),
3998
+ resolvedConceptId: string28().optional().label("Resolved Concept"),
3999
+ /** `ambiguous`: the concept exists; the caller gave no context that picked one. */
4000
+ reason: string28().oneOf(SupportedUnmatchedReasons).optional().label("Reason"),
4001
+ /** The concepts an ambiguous term could mean. */
4002
+ candidates: array18(string28().required()).optional().label("Candidates"),
4003
+ /** Who rejected it when it was not a human: `prefilter:<rule>` or `model`. */
4004
+ rejectedBy: string28().optional().label("Rejected By")
4005
+ }).label("Unmatched Term");
4006
+ var ProposalCandidateSchema = object39({
4007
+ groupId: string28().required(),
4008
+ groupName: string28().required(),
4009
+ subcategoryId: string28().required(),
4010
+ subcategoryName: string28().required(),
4011
+ categoryId: string28().required(),
4012
+ categoryName: string28().required(),
4013
+ score: number18().required(),
4014
+ nearestMembers: array18(string28().required()).default([])
4015
+ }).label("Proposal Candidate");
4016
+ var ProposalMessageSchema = object39({
4017
+ role: string28().oneOf(SupportedProposalMessageRoles).required(),
4018
+ /** The operator's instruction, or the model's note on what it changed and why. */
4019
+ content: string28().defined(),
4020
+ /** Which model answered. Absent on operator turns. */
4021
+ model: string28().optional(),
4022
+ at: number18().required()
4023
+ }).label("Proposal Message");
4024
+ var SuggestedHomeSchema = object39({
4025
+ categoryName: string28().defined(),
4026
+ subcategoryName: string28().defined(),
4027
+ groupName: string28().defined()
4028
+ }).label("Suggested Home");
4029
+ var ResolverVerificationSchema = object39({
4030
+ verdict: string28().oneOf(SupportedResolverVerdicts).required(),
4031
+ /** The shown concept the verdict is about; null for `new_concept` / `out_of_scope`. */
4032
+ conceptId: string28().nullable().defined(),
4033
+ evidence: string28().defined(),
4034
+ /** What the judge took the term to mean, abbreviations expanded. */
4035
+ means: string28().optional(),
4036
+ /** For `same`: did the independent confirm step agree? */
4037
+ consistent: boolean19().optional(),
4038
+ confirm: object39({
4039
+ answer: string28().oneOf(["yes", "no"]).required(),
4040
+ evidence: string28().defined()
4041
+ }).optional().default(void 0)
4042
+ }).label("Resolver Verification");
4043
+ var ConceptProposalSchema = object39({
4044
+ proposalId: string28().required().label("Proposal ID"),
4045
+ vocabulary: vocabularyId().required().label("Vocabulary"),
4046
+ /** The miss this closes; `normalizedTerm` links back to its unmatched row. */
4047
+ term: string28().required().label("Term"),
4048
+ normalizedTerm: string28().required().label("Normalized Term"),
4049
+ /** Demand at proposal time, so the queue ranks without a join. */
4050
+ count: number18().integer().min(0).required().label("Count"),
4051
+ /** Other misses folded into this draft because they name the same new concept. */
4052
+ mergedTerms: array18(
4053
+ object39({
4054
+ term: string28().required(),
4055
+ normalizedTerm: string28().required(),
4056
+ count: number18().integer().min(0).required()
4057
+ }).required()
4058
+ ).optional().label("Merged Terms"),
4059
+ /** Absent on drafts that predate the field: read as `concept`. */
4060
+ kind: string28().oneOf(SupportedProposalKinds).optional().label("Kind"),
4061
+ /** For `alias`: the concept the term names. For `placement`: the concept to place. */
4062
+ targetConceptId: string28().optional().label("Target Concept"),
4063
+ targetName: string28().optional().label("Target Name"),
4064
+ // The draft concept, editable until approved. Empty strings are valid here:
4065
+ // an alias draft carries no draft concept of its own.
4066
+ name: string28().defined().label("Name"),
4067
+ type: string28().defined().label("Type"),
4068
+ description: string28().defined().label("Description"),
4069
+ aliases: array18(string28().required()).default([]).label("Aliases"),
4070
+ /** Empty when no group fits: approved that way, the concept goes live uncategorized. */
4071
+ memberships: array18(ConceptMembershipSchema.required()).default([]).label("Memberships"),
4072
+ suggestedHome: SuggestedHomeSchema.nullable().optional().default(void 0).label("Suggested Home"),
4073
+ /** Resolved to concepts that exist; names that matched nothing are dropped. */
4074
+ relatedConceptIds: array18(string28().required()).default([]).label("Related Concepts"),
4075
+ /** Every placement candidate considered, best first. */
4076
+ candidates: array18(ProposalCandidateSchema.required()).default([]).label("Candidates"),
4077
+ needsReview: boolean19().required().label("Needs Review"),
4078
+ reason: string28().optional().label("Reason"),
4079
+ verification: ResolverVerificationSchema.optional().default(void 0).label("Verification"),
4080
+ /** What the auto-accept gate decided for an alias verdict. */
4081
+ autoAccept: object39({
4082
+ accepted: boolean19().required(),
4083
+ reason: string28().optional(),
4084
+ tier: string28().optional(),
4085
+ calibrationId: string28().optional(),
4086
+ releaseId: string28().optional()
4087
+ }).optional().default(void 0).label("Auto Accept"),
4088
+ /** Which model drafted it. */
4089
+ model: string28().defined().label("Model"),
4090
+ /** The refinement conversation, oldest first. */
4091
+ messages: array18(ProposalMessageSchema.required()).default([]).label("Messages"),
4092
+ status: string28().oneOf(SupportedProposalStatuses).required().label("Status"),
4093
+ /** Set when approved: the concept this became. */
4094
+ resolvedConceptId: string28().optional().label("Resolved Concept"),
4095
+ createdAt: number18().required().label("Created At"),
4096
+ updatedAt: number18().required().label("Updated At")
4097
+ }).label("Concept Proposal");
4098
+ var ReleaseSchema = object39({
4099
+ releaseId: string28().required().label("Release ID"),
4100
+ kind: string28().oneOf(SupportedReleaseKinds).required().label("Kind"),
4101
+ status: string28().oneOf(SupportedReleaseStatuses).required().label("Status"),
4102
+ createdBy: string28().required().label("Created By"),
4103
+ createdAt: number18().required().label("Created At"),
4104
+ note: string28().optional().label("Note"),
4105
+ rolledBackAt: number18().optional().label("Rolled Back At"),
4106
+ rolledBackBy: string28().optional().label("Rolled Back By")
4107
+ }).label("Release");
4108
+ var AuditSchema = object39({
4109
+ auditId: string28().required().label("Audit ID"),
4110
+ releaseId: string28().required().label("Release ID"),
4111
+ key: string28().required().label("Key"),
4112
+ term: string28().required().label("Term"),
4113
+ conceptId: string28().required().label("Concept ID"),
4114
+ tier: string28().optional().label("Tier"),
4115
+ status: string28().oneOf(SupportedAuditStatuses).required().label("Status"),
4116
+ createdAt: number18().required().label("Created At"),
4117
+ resolvedAt: number18().optional().label("Resolved At"),
4118
+ resolvedBy: string28().optional().label("Resolved By")
4119
+ }).label("Audit");
4120
+ var ResolverSettingsSchema = object39({
4121
+ autoAccept: object39({
4122
+ /** Stop switch for WRITING auto keys. Off until a calibration passes. */
4123
+ enabled: boolean19().required(),
4124
+ /** Minimum calibrated precision (Wilson 95% lower bound) for a tier to auto-accept. */
4125
+ target: number18().min(0.5).lessThan(1).required(),
4126
+ maxPerRun: number18().integer().min(0).required(),
4127
+ maxPerDay: number18().integer().min(0).required(),
4128
+ /** Share of each auto release sampled into the audit queue (0..1). */
4129
+ auditRate: number18().min(0).max(1).required()
4130
+ }).label("Auto Accept"),
4131
+ /** Stop switch for SERVING auto keys: false hides them from lookups at once. */
4132
+ serveAutoKeys: boolean19().required().label("Serve Auto Keys"),
4133
+ /** Minimum Meilisearch ranking score (0..1) for a fuzzy hit to be considered. */
4134
+ fuzzyMinScore: number18().min(0).max(1).required().label("Fuzzy Min Score"),
4135
+ /** Per-client limit on public search, per minute per replica. 0 disables it. */
4136
+ searchRateLimitPerMin: number18().integer().min(0).required().label("Search Rate Limit"),
4137
+ /** Master switch for scheduled maintenance jobs. */
4138
+ scheduledJobs: boolean19().required().label("Scheduled Jobs"),
4139
+ updatedAt: number18().optional().label("Updated At"),
4140
+ updatedBy: string28().optional().label("Updated By"),
4141
+ /** Why auto-accept was last switched off automatically. */
4142
+ trippedReason: string28().optional().label("Tripped Reason")
4143
+ }).label("Resolver Settings");
4144
+ var TaxonomyScheduleSchema = object39({
4145
+ kind: string28().oneOf(SupportedTaxonomyJobKinds).required().label("Job"),
4146
+ enabled: boolean19().required().label("Enabled"),
4147
+ everyHours: number18().min(SCHEDULE_MIN_HOURS).max(SCHEDULE_MAX_HOURS).required().label("Every (hours)"),
4148
+ /** Last time the scheduler fired this job. */
4149
+ lastRunAt: number18().optional().label("Last Run At"),
4150
+ updatedAt: number18().required().label("Updated At")
4151
+ }).label("Taxonomy Schedule");
4152
+ var NormalizeContextSchema = object39({
4153
+ /** The title of the record the terms come from. */
4154
+ title: string28().max(200).optional(),
4155
+ /** Backbone node ids (category, subcategory or group). */
4156
+ categoryIds: array18(nodeId().required()).max(10).optional(),
4157
+ /** Other terms from the same record, in the same vocabulary. */
4158
+ siblings: array18(string28().max(200).required()).max(50).optional()
4159
+ }).label("Normalize Context");
4160
+
4161
+ // src/taxonomy/taxonomy-filter.schema.ts
4162
+ import { boolean as boolean20, object as object40 } from "yup";
4163
+ var ConceptFilterShape = object40({
4164
+ /** Type ids. Open: which types exist is the vocabulary's data. */
4165
+ type: tokens("Type"),
4166
+ /** Category node ids the concept is placed under (`memberships.categoryId`). */
4167
+ categoryId: tokens("Category"),
4168
+ /** True: only live concepts with no backbone home (the uncategorized backlog). */
4169
+ unplaced: boolean20().optional().label("Unplaced")
4170
+ }).label("Concept Filter");
4171
+ var ConceptFilterSchema = rejectUnknownKeys(
4172
+ ConceptFilterShape,
4173
+ () => Object.keys(ConceptFilterShape.fields)
4174
+ );
4175
+ var TaxonomyNodeFilterShape = object40({
4176
+ kind: enumFacet(SupportedTaxonomyNodeKinds, "Kind"),
4177
+ /** Parent node ids: a node's children. */
4178
+ parentId: tokens("Parent")
4179
+ }).label("Taxonomy Node Filter");
4180
+ var TaxonomyNodeFilterSchema = rejectUnknownKeys(
4181
+ TaxonomyNodeFilterShape,
4182
+ () => Object.keys(TaxonomyNodeFilterShape.fields)
4183
+ );
4184
+ var UnmatchedFilterShape = object40({
4185
+ resolution: enumFacet(SupportedUnmatchedResolutions, "Resolution"),
4186
+ reason: enumFacet(SupportedUnmatchedReasons, "Reason")
4187
+ }).label("Unmatched Filter");
4188
+ var UnmatchedFilterSchema = rejectUnknownKeys(
4189
+ UnmatchedFilterShape,
4190
+ () => Object.keys(UnmatchedFilterShape.fields)
4191
+ );
4192
+ var ConceptProposalFilterShape = object40({
4193
+ status: enumFacet(SupportedProposalStatuses, "Status"),
4194
+ /** A kind, or `uncategorized`: concept and placement drafts with no home yet. */
4195
+ kind: enumFacet(SupportedProposalFilters, "Kind")
4196
+ }).label("Concept Proposal Filter");
4197
+ var ConceptProposalFilterSchema = rejectUnknownKeys(
4198
+ ConceptProposalFilterShape,
4199
+ () => Object.keys(ConceptProposalFilterShape.fields)
4200
+ );
4201
+ var ReleaseFilterShape = object40({
4202
+ kind: enumFacet(SupportedReleaseKinds, "Kind"),
4203
+ status: enumFacet(SupportedReleaseStatuses, "Status")
4204
+ }).label("Release Filter");
4205
+ var ReleaseFilterSchema = rejectUnknownKeys(
4206
+ ReleaseFilterShape,
4207
+ () => Object.keys(ReleaseFilterShape.fields)
4208
+ );
4209
+ var AuditFilterShape = object40({
4210
+ status: enumFacet(SupportedAuditStatuses, "Status")
4211
+ }).label("Audit Filter");
4212
+ var AuditFilterSchema = rejectUnknownKeys(
4213
+ AuditFilterShape,
4214
+ () => Object.keys(AuditFilterShape.fields)
4215
+ );
4216
+
3821
4217
  // src/user/user.schema.ts
3822
- import { array as array21, boolean as boolean22, number as number20, object as object51, string as string40 } from "yup";
4218
+ import { array as array22, boolean as boolean24, number as number21, object as object53, string as string41 } from "yup";
3823
4219
 
3824
4220
  // src/user/work-experience.schema.ts
3825
- import { boolean as boolean19, object as object39, string as string28 } from "yup";
3826
- var WorkExperienceSchema = object39().shape({
4221
+ import { boolean as boolean21, object as object41, string as string29 } from "yup";
4222
+ var WorkExperienceSchema = object41().shape({
3827
4223
  company: PageSchema.pick(["name", "slug", "type", "logo"]).deepPartial().concat(PageSchema.pick(["name", "type"])).required().label("Company"),
3828
- designation: string28().trim().required().label("Designation"),
4224
+ designation: string29().trim().required().label("Designation"),
3829
4225
  duration: DurationSchema({
3830
4226
  format: "YYYY-MM",
3831
4227
  startLabel: "Start Date",
3832
4228
  endLabel: "End Date"
3833
4229
  }).required().label("Duration"),
3834
- description: string28().trim().max(3e3).optional().label("Description"),
4230
+ description: string29().trim().max(3e3).optional().label("Description"),
3835
4231
  location: LocationSchema.required().label("Location"),
3836
- isRemote: boolean19().oneOf([true, false]).default(false).label("Is Remote")
4232
+ isRemote: boolean21().oneOf([true, false]).default(false).label("Is Remote")
3837
4233
  }).noUnknown().strict().label("Work Experience");
3838
4234
 
3839
4235
  // src/user/education.schema.ts
3840
- import { boolean as boolean20, object as object40, string as string29 } from "yup";
3841
- var EducationSchema = object40({
4236
+ import { boolean as boolean22, object as object42, string as string30 } from "yup";
4237
+ var EducationSchema = object42({
3842
4238
  institute: PageSchema.pick(["name", "slug", "type", "logo"]).deepPartial().concat(PageSchema.pick(["name", "type"])).required().label("Institute"),
3843
- course: string29().trim().required().label("Course"),
3844
- fieldOfStudy: string29().trim().required().label("Field of Study"),
4239
+ course: string30().trim().required().label("Course"),
4240
+ fieldOfStudy: string30().trim().required().label("Field of Study"),
3845
4241
  duration: DurationSchema({
3846
4242
  format: "YYYY-MM",
3847
4243
  startLabel: "Start Date",
3848
4244
  endLabel: "End Date"
3849
4245
  }).required().label("Duration"),
3850
- description: string29().trim().max(3e3).optional().label("Description"),
3851
- isDistanceLearning: boolean20().default(false).label("Is Distance Learning"),
4246
+ description: string30().trim().max(3e3).optional().label("Description"),
4247
+ isDistanceLearning: boolean22().default(false).label("Is Distance Learning"),
3852
4248
  location: LocationSchema.required().label("Location"),
3853
- studyType: string29().oneOf(SupportedStudyTypes).trim().max(50).required().label("Study Type")
4249
+ studyType: string30().oneOf(SupportedStudyTypes).trim().max(50).required().label("Study Type")
3854
4250
  }).noUnknown().strict().label("Education");
3855
4251
 
3856
4252
  // src/user/user-skill.schema.ts
3857
- import { object as object41, string as string30 } from "yup";
3858
- var UserSkillSchema = object41({
3859
- name: string30().required().label("Name"),
3860
- proficiencyLevel: string30().oneOf(SupportedProficiencyLevels).required().label("Proficiency Level"),
4253
+ import { object as object43, string as string31 } from "yup";
4254
+ var UserSkillSchema = object43({
4255
+ name: string31().required().label("Name"),
4256
+ proficiencyLevel: string31().oneOf(SupportedProficiencyLevels).required().label("Proficiency Level"),
3861
4257
  lastUsed: dateString().format("YYYY-MM").nullable().optional().label("Last Used")
3862
4258
  }).noUnknown().strict().label("Skill");
3863
4259
 
3864
4260
  // src/user/project.schema.ts
3865
- import { object as object42, string as string31 } from "yup";
3866
- var UserProjectSchema = object42({
3867
- name: string31().trim().max(50).required().label("Name"),
3868
- url: string31().optional().label("URL"),
3869
- description: string31().trim().min(100).max(3e3).required().label("Description"),
4261
+ import { object as object44, string as string32 } from "yup";
4262
+ var UserProjectSchema = object44({
4263
+ name: string32().trim().max(50).required().label("Name"),
4264
+ url: string32().optional().label("URL"),
4265
+ description: string32().trim().min(100).max(3e3).required().label("Description"),
3870
4266
  duration: DurationSchema({
3871
4267
  format: "YYYY-MM",
3872
4268
  startLabel: "Start Date",
@@ -3875,68 +4271,68 @@ var UserProjectSchema = object42({
3875
4271
  }).noUnknown().strict().label("Project");
3876
4272
 
3877
4273
  // src/user/user-certification.schema.ts
3878
- import { object as object43, string as string32 } from "yup";
3879
- var UserCertificationSchema = object43({
3880
- name: string32().trim().max(100).required().label("Name"),
4274
+ import { object as object45, string as string33 } from "yup";
4275
+ var UserCertificationSchema = object45({
4276
+ name: string33().trim().max(100).required().label("Name"),
3881
4277
  // TODO: Add validation for authority
3882
- authority: string32().trim().max(100).required().label("Authority"),
3883
- licenseNumber: string32().trim().max(50).optional().label("License Number"),
4278
+ authority: string33().trim().max(100).required().label("Authority"),
4279
+ licenseNumber: string33().trim().max(50).optional().label("License Number"),
3884
4280
  duration: DurationSchema({
3885
4281
  format: "YYYY-MM",
3886
4282
  startLabel: "Start Date",
3887
4283
  endLabel: "End Date"
3888
4284
  }).optional().nullable().label("Duration"),
3889
- url: string32().optional().label("URL")
4285
+ url: string33().optional().label("URL")
3890
4286
  }).noUnknown().strict().label("Certification");
3891
4287
 
3892
4288
  // src/user/user-interest.schema.ts
3893
- import { object as object44, string as string33 } from "yup";
3894
- var UserInterestSchema = object44({
4289
+ import { object as object46, string as string34 } from "yup";
4290
+ var UserInterestSchema = object46({
3895
4291
  /** The taxonomy entry's id. */
3896
- id: string33().trim().required().label("Interest Id"),
4292
+ id: string34().trim().required().label("Interest Id"),
3897
4293
  /** Display name, e.g. "Cloud Computing". */
3898
- name: string33().trim().required().label("Interest"),
4294
+ name: string34().trim().required().label("Interest"),
3899
4295
  /** Material-symbols icon name, e.g. "cloud". */
3900
- logo: string33().trim().required().label("Interest Logo")
4296
+ logo: string34().trim().required().label("Interest Logo")
3901
4297
  }).required().label("Interest");
3902
4298
 
3903
4299
  // src/user/user-language.schema.ts
3904
- import { object as object45, string as string34 } from "yup";
3905
- var UserLanguageSchema = object45({
3906
- name: string34().trim().required().label("Name"),
3907
- proficiencyLevel: string34().oneOf(SupportedProficiencyLevels).trim().max(50).required().label("Proficiency Level")
4300
+ import { object as object47, string as string35 } from "yup";
4301
+ var UserLanguageSchema = object47({
4302
+ name: string35().trim().required().label("Name"),
4303
+ proficiencyLevel: string35().oneOf(SupportedProficiencyLevels).trim().max(50).required().label("Proficiency Level")
3908
4304
  }).noUnknown().strict().label("Language");
3909
4305
 
3910
4306
  // src/user/user-additional-info.schema.ts
3911
- import { object as object46, string as string35 } from "yup";
3912
- var UserAdditionalInfoSchema = object46({
3913
- title: string35().trim().max(60).required().label("Title"),
3914
- description: string35().trim().max(1e3).required().label("Description")
4307
+ import { object as object48, string as string36 } from "yup";
4308
+ var UserAdditionalInfoSchema = object48({
4309
+ title: string36().trim().max(60).required().label("Title"),
4310
+ description: string36().trim().max(1e3).required().label("Description")
3915
4311
  }).noUnknown().strict().label("User Additional Info");
3916
4312
 
3917
4313
  // src/user/general-detail.schema.ts
3918
- import { number as number18, object as object47, string as string36 } from "yup";
3919
- var UserGeneralDetailSchema = object47({
3920
- id: string36().optional().label("ID"),
3921
- name: object47().shape({
3922
- first: string36().trim().max(50).required().label("First Name"),
3923
- last: string36().trim().max(50).optional().label("Last Name")
4314
+ import { number as number19, object as object49, string as string37 } from "yup";
4315
+ var UserGeneralDetailSchema = object49({
4316
+ id: string37().optional().label("ID"),
4317
+ name: object49().shape({
4318
+ first: string37().trim().max(50).required().label("First Name"),
4319
+ last: string37().trim().max(50).optional().label("Last Name")
3924
4320
  }).required().label("Name"),
3925
- headline: string36().trim().max(200).optional().label("Headline"),
3926
- image: string36().optional().label("Image"),
4321
+ headline: string37().trim().max(200).optional().label("Headline"),
4322
+ image: string37().optional().label("Image"),
3927
4323
  // The DISPLAYED avatar (`image`) is a flattened export with any status frame
3928
4324
  // ("#OpenToWork", …) already burned into the pixels. `imageOriginal` keeps the
3929
4325
  // un-framed source the user uploaded, so the image builder can reopen it and
3930
4326
  // apply a DIFFERENT frame instead of stacking a second one on top of the first.
3931
4327
  // Optional and absent on every pre-existing user: treat a missing value as
3932
4328
  // "only the flattened image is available".
3933
- imageOriginal: string36().optional().label("Original Image"),
3934
- aboutMe: string36().trim().max(3e3).optional().label("About Me"),
3935
- email: string36().required().label("Email"),
3936
- mobile: string36().nullable().optional().label("Mobile"),
3937
- emailVerified: string36().nullable().optional().label("Email Verified"),
3938
- mobileVerified: string36().nullable().optional().label("Mobile Verified"),
3939
- experienceLevel: string36().oneOf(SupportedExperienceLevels).required().label("Experience level"),
4329
+ imageOriginal: string37().optional().label("Original Image"),
4330
+ aboutMe: string37().trim().max(3e3).optional().label("About Me"),
4331
+ email: string37().required().label("Email"),
4332
+ mobile: string37().nullable().optional().label("Mobile"),
4333
+ emailVerified: string37().nullable().optional().label("Email Verified"),
4334
+ mobileVerified: string37().nullable().optional().label("Mobile Verified"),
4335
+ experienceLevel: string37().oneOf(SupportedExperienceLevels).required().label("Experience level"),
3940
4336
  /**
3941
4337
  * The user's HIGHEST qualification, e.g. `bachelor`.
3942
4338
  *
@@ -3955,7 +4351,7 @@ var UserGeneralDetailSchema = object47({
3955
4351
  * UNCONSTRAINED on education rather than filtering the user out — the same
3956
4352
  * opt-out reasoning `notificationPrefs` uses.
3957
4353
  */
3958
- educationLevel: string36().oneOf(SupportedEducationLevels).optional().label("Education level"),
4354
+ educationLevel: string37().oneOf(SupportedEducationLevels).optional().label("Education level"),
3959
4355
  location: LocationSchema.required().label("Location"),
3960
4356
  /**
3961
4357
  * Where the account was created, captured once and never rewritten.
@@ -3971,38 +4367,38 @@ var UserGeneralDetailSchema = object47({
3971
4367
  * - `location` derived from the user's self-entered profile location
3972
4368
  * - `default` assumed (no signal available); presumption, not evidence
3973
4369
  */
3974
- signupContext: object47().shape({
4370
+ signupContext: object49().shape({
3975
4371
  // ISO 3166-1 alpha-2, uppercase — the shape `cf-ipcountry` returns, so
3976
4372
  // measured and inferred values are directly comparable.
3977
- country: string36().trim().uppercase().length(2).required().label("Signup Country"),
3978
- locale: string36().trim().required().label("Signup Locale"),
3979
- source: string36().oneOf(SupportedSignupContextSources).required().label("Signup Context Source"),
3980
- at: number18().required().label("Signup Context At")
4373
+ country: string37().trim().uppercase().length(2).required().label("Signup Country"),
4374
+ locale: string37().trim().required().label("Signup Locale"),
4375
+ source: string37().oneOf(SupportedSignupContextSources).required().label("Signup Context Source"),
4376
+ at: number19().required().label("Signup Context At")
3981
4377
  }).optional().default(void 0).label("Signup Context"),
3982
- profileVisibility: string36().oneOf(SupportedUserProfileVisibilities).default("public" /* Public */).label("Profile Visibility")
4378
+ profileVisibility: string37().oneOf(SupportedUserProfileVisibilities).default("public" /* Public */).label("Profile Visibility")
3983
4379
  }).noUnknown().strict().label("General Detail");
3984
4380
 
3985
4381
  // src/user/user-job-preferences.schema.ts
3986
- import { array as array18, boolean as boolean21, date as date2, number as number19, object as object48, string as string37 } from "yup";
3987
- var UserJobPreferencesSchema = object48({
4382
+ import { array as array19, boolean as boolean23, date as date2, number as number20, object as object50, string as string38 } from "yup";
4383
+ var UserJobPreferencesSchema = object50({
3988
4384
  /**
3989
4385
  * Whether the job seeker is openly signalling availability. Surfaces the
3990
4386
  * "Open to work" badge on the public profile and boosts visibility in
3991
4387
  * recruiter search. Defaults to `false` - users must opt in.
3992
4388
  */
3993
- openToWork: boolean21().default(false).label("Open to Work"),
4389
+ openToWork: boolean23().default(false).label("Open to Work"),
3994
4390
  /**
3995
4391
  * How urgently the user is looking for their next job. Drives match scoring
3996
4392
  * and can downgrade the visibility of expired or low-relevance postings for
3997
4393
  * users in `passively_browsing` mode.
3998
4394
  */
3999
- jobSearchUrgency: string37().oneOf(SupportedJobSearchUrgencies).required().label("Job Search Urgency"),
4395
+ jobSearchUrgency: string38().oneOf(SupportedJobSearchUrgencies).required().label("Job Search Urgency"),
4000
4396
  /**
4001
4397
  * Locations the user wants to work in. Stores the full `LocationSchema`
4002
4398
  * shape (country, city, state, geo, etc.) as returned by the locations
4003
4399
  * autocomplete API.
4004
4400
  */
4005
- jobLocations: array18().of(LocationSchema.required().label("Job Location")).min(1, "Pick at least one preferred location.").required().label("Job Locations"),
4401
+ jobLocations: array19().of(LocationSchema.required().label("Job Location")).min(1, "Pick at least one preferred location.").required().label("Job Locations"),
4006
4402
  /**
4007
4403
  * Seniority levels the user wants jobs to be matched against. Multi-select
4008
4404
  * (up to 2) for borderline candidates.
@@ -4013,7 +4409,7 @@ var UserJobPreferencesSchema = object48({
4013
4409
  * Both reuse the same `ExperienceLevel` taxonomy from `common.constant.ts`
4014
4410
  * so search/match logic doesn't have to translate between two vocabularies.
4015
4411
  */
4016
- targetExperienceLevels: array18().of(string37().oneOf(SupportedExperienceLevels).required()).min(1, "Pick at least one experience level.").max(2, "You can select at most 2 experience levels.").required().label("Target Experience Levels"),
4412
+ targetExperienceLevels: array19().of(string38().oneOf(SupportedExperienceLevels).required()).min(1, "Pick at least one experience level.").max(2, "You can select at most 2 experience levels.").required().label("Target Experience Levels"),
4017
4413
  /**
4018
4414
  * Specializations the user is searching for - free-form titles.
4019
4415
  *
@@ -4022,19 +4418,19 @@ var UserJobPreferencesSchema = object48({
4022
4418
  * surfaces a curated "Popular Roles" picker for discovery, but the user
4023
4419
  * can ultimately add any title; matching/normalization happens downstream.
4024
4420
  */
4025
- jobRoles: array18().of(string37().trim().max(120).required()).min(1, "Pick at least one role.").required().label("Job Roles"),
4421
+ jobRoles: array19().of(string38().trim().max(120).required()).min(1, "Pick at least one role.").required().label("Job Roles"),
4026
4422
  /**
4027
4423
  * Minimum acceptable annual base salary, in `minSalaryCurrency`.
4028
4424
  * Stored as an integer in the currency's major unit (e.g. dollars, not cents).
4029
4425
  * Defaults to 0 ("any salary") rather than being optional - every job-seeker
4030
4426
  * has a floor, even if it's zero.
4031
4427
  */
4032
- minSalary: number19().integer().min(MIN_SALARY_LOWER_BOUND).max(MIN_SALARY_UPPER_BOUND).default(0).required().label("Minimum Salary"),
4033
- minSalaryCurrency: string37().oneOf(SupportedSalaryCurrencies).default("USD").required().label("Minimum Salary Currency"),
4428
+ minSalary: number20().integer().min(MIN_SALARY_LOWER_BOUND).max(MIN_SALARY_UPPER_BOUND).default(0).required().label("Minimum Salary"),
4429
+ minSalaryCurrency: string38().oneOf(SupportedSalaryCurrencies).default("USD").required().label("Minimum Salary Currency"),
4034
4430
  /**
4035
4431
  * Marketing-attribution capture from the final onboarding step.
4036
4432
  */
4037
- referralSource: string37().oneOf(SupportedReferralSources).required().label("Referral Source"),
4433
+ referralSource: string38().oneOf(SupportedReferralSources).required().label("Referral Source"),
4038
4434
  /**
4039
4435
  * Resumes the user has uploaded. Embedded directly on the user document
4040
4436
  * (capped at 5) - they're cheap to denormalize, every wizard step that
@@ -4048,18 +4444,18 @@ var UserJobPreferencesSchema = object48({
4048
4444
  * AI resume-builder flow - onboarding uploads land here, AI-built resumes
4049
4445
  * live in their own collection.
4050
4446
  */
4051
- resumes: array18().of(
4052
- object48({
4447
+ resumes: array19().of(
4448
+ object50({
4053
4449
  // Stable id assigned on upload - used to address a specific entry
4054
4450
  // for delete / set-primary operations without exposing the GCS URL
4055
4451
  // as a route key.
4056
- id: string37().required().label("ID"),
4057
- url: string37().required().label("Resume URL"),
4058
- filename: string37().trim().max(255).optional().label("Filename"),
4059
- sizeBytes: number19().integer().min(0).optional().label("Size (bytes)"),
4060
- mimeType: string37().trim().max(120).optional().label("MIME Type"),
4452
+ id: string38().required().label("ID"),
4453
+ url: string38().required().label("Resume URL"),
4454
+ filename: string38().trim().max(255).optional().label("Filename"),
4455
+ sizeBytes: number20().integer().min(0).optional().label("Size (bytes)"),
4456
+ mimeType: string38().trim().max(120).optional().label("MIME Type"),
4061
4457
  uploadedAt: date2().required().label("Uploaded At"),
4062
- isPrimary: boolean21().default(false).label("Is Primary")
4458
+ isPrimary: boolean23().default(false).label("Is Primary")
4063
4459
  }).noUnknown().strict().label("Resume")
4064
4460
  ).max(5, "You can keep at most 5 resumes on file.").default([]).label("Resumes"),
4065
4461
  /**
@@ -4086,92 +4482,92 @@ var UserJobPreferencesSchema = object48({
4086
4482
  * APIs. If `user.<field>` is empty there, the correct behavior is empty,
4087
4483
  * because the user has not confirmed it yet.
4088
4484
  */
4089
- pendingPrefill: object48({
4090
- headline: string37().trim().optional().label("Pending Headline"),
4091
- aboutMe: string37().trim().optional().label("Pending About Me"),
4092
- mobile: string37().trim().optional().label("Pending Mobile"),
4485
+ pendingPrefill: object50({
4486
+ headline: string38().trim().optional().label("Pending Headline"),
4487
+ aboutMe: string38().trim().optional().label("Pending About Me"),
4488
+ mobile: string38().trim().optional().label("Pending Mobile"),
4093
4489
  location: LocationSchema.optional().default(void 0).label("Pending Location"),
4094
- experienceLevel: string37().oneOf(SupportedExperienceLevels).optional().label("Pending Experience Level"),
4095
- socialAccounts: array18().of(SocialAccountSchema.required()).optional().label("Pending Social Accounts"),
4096
- workExperiences: array18().of(WorkExperienceSchema.required()).optional().label("Pending Work Experiences"),
4097
- educations: array18().of(EducationSchema.required()).optional().label("Pending Educations")
4490
+ experienceLevel: string38().oneOf(SupportedExperienceLevels).optional().label("Pending Experience Level"),
4491
+ socialAccounts: array19().of(SocialAccountSchema.required()).optional().label("Pending Social Accounts"),
4492
+ workExperiences: array19().of(WorkExperienceSchema.required()).optional().label("Pending Work Experiences"),
4493
+ educations: array19().of(EducationSchema.required()).optional().label("Pending Educations")
4098
4494
  }).nullable().optional().default(void 0).label("Pending Prefill")
4099
4495
  }).noUnknown().strict().label("User Job Preferences Schema");
4100
4496
 
4101
4497
  // src/user/user-recruiter-profile.schema.ts
4102
- import { array as array19, object as object49, string as string38 } from "yup";
4103
- var RecruiterPageLinkSchema = object49({
4498
+ import { array as array20, object as object51, string as string39 } from "yup";
4499
+ var RecruiterPageLinkSchema = object51({
4104
4500
  page: PageSchema.pick(["name", "slug", "type", "logo"]).deepPartial().concat(PageSchema.pick(["name", "type"])).required().label("Company Page"),
4105
- jobTitle: string38().trim().max(100).optional().label("Job Title")
4501
+ jobTitle: string39().trim().max(100).optional().label("Job Title")
4106
4502
  }).noUnknown().strict().label("Recruiter Page Link");
4107
- var UserRecruiterProfileSchema = object49({
4108
- recruiterProfile: object49({
4109
- hiringFor: array19().of(RecruiterPageLinkSchema).default([]).label("Hiring For")
4503
+ var UserRecruiterProfileSchema = object51({
4504
+ recruiterProfile: object51({
4505
+ hiringFor: array20().of(RecruiterPageLinkSchema).default([]).label("Hiring For")
4110
4506
  }).optional().default(void 0).label("Recruiter Profile")
4111
4507
  }).noUnknown().strict().label("User Recruiter Profile");
4112
4508
 
4113
4509
  // src/user/user-coordinator-profile.schema.ts
4114
- import { array as array20, object as object50, string as string39 } from "yup";
4115
- var CoordinatorPageLinkSchema = object50({
4510
+ import { array as array21, object as object52, string as string40 } from "yup";
4511
+ var CoordinatorPageLinkSchema = object52({
4116
4512
  page: PageSchema.pick(["name", "slug", "type", "logo"]).deepPartial().concat(PageSchema.pick(["name", "type"])).required().label("Institute Page"),
4117
- jobTitle: string39().trim().max(100).optional().label("Job Title")
4513
+ jobTitle: string40().trim().max(100).optional().label("Job Title")
4118
4514
  }).noUnknown().strict().label("Coordinator Page Link");
4119
- var UserCoordinatorProfileSchema = object50({
4120
- coordinatorProfile: object50({
4121
- coordinatesAt: array20().of(CoordinatorPageLinkSchema).default([]).label("Coordinates At")
4515
+ var UserCoordinatorProfileSchema = object52({
4516
+ coordinatorProfile: object52({
4517
+ coordinatesAt: array21().of(CoordinatorPageLinkSchema).default([]).label("Coordinates At")
4122
4518
  }).optional().default(void 0).label("Coordinator Profile")
4123
4519
  }).noUnknown().strict().label("User Coordinator Profile");
4124
4520
 
4125
4521
  // src/user/user.schema.ts
4126
- var UserSchema = object51({
4522
+ var UserSchema = object53({
4127
4523
  /**
4128
4524
  * Related auth account id from auth Server (e.g. Better auth https://auth.thejob.dev)
4129
4525
  */
4130
- authAccountId: string40().required().label("Auth Account ID"),
4526
+ authAccountId: string41().required().label("Auth Account ID"),
4131
4527
  /**
4132
4528
  * Social media information about the user (e.g. LinkedIn, GitHub, etc.)
4133
4529
  */
4134
- socialAccounts: array21().of(SocialAccountSchema).default([]).label("Social Accounts"),
4530
+ socialAccounts: array22().of(SocialAccountSchema).default([]).label("Social Accounts"),
4135
4531
  /**
4136
4532
  * Work experience information about the user
4137
4533
  */
4138
- workExperiences: array21().of(WorkExperienceSchema).required().default([]).label("Work Experiences"),
4534
+ workExperiences: array22().of(WorkExperienceSchema).required().default([]).label("Work Experiences"),
4139
4535
  /**
4140
4536
  * Education information about the user
4141
4537
  */
4142
- educations: array21().of(EducationSchema).required().default([]).label("Educations"),
4538
+ educations: array22().of(EducationSchema).required().default([]).label("Educations"),
4143
4539
  /**
4144
4540
  * Skills information about the user
4145
4541
  */
4146
- skills: array21().of(UserSkillSchema).required().default([]).label("Skills"),
4542
+ skills: array22().of(UserSkillSchema).required().default([]).label("Skills"),
4147
4543
  /**
4148
4544
  * Projects information about the user
4149
4545
  */
4150
- projects: array21().of(UserProjectSchema).default([]).label("Projects"),
4546
+ projects: array22().of(UserProjectSchema).default([]).label("Projects"),
4151
4547
  /**
4152
4548
  * Certifications information about the user
4153
4549
  */
4154
- certifications: array21().of(UserCertificationSchema).default([]).label("Certifications"),
4550
+ certifications: array22().of(UserCertificationSchema).default([]).label("Certifications"),
4155
4551
  /**
4156
4552
  * Interests information about the user.
4157
4553
  */
4158
- interests: array21().of(UserInterestSchema).optional().default([]).label("Interests"),
4554
+ interests: array22().of(UserInterestSchema).optional().default([]).label("Interests"),
4159
4555
  /**
4160
4556
  * Languages information about the user
4161
4557
  */
4162
- languages: array21().of(UserLanguageSchema).required().default([]).label("Languages"),
4558
+ languages: array22().of(UserLanguageSchema).required().default([]).label("Languages"),
4163
4559
  /**
4164
4560
  * Additional information about the user
4165
4561
  */
4166
- additionalInfo: array21().of(UserAdditionalInfoSchema).default([]).label("Additional Information"),
4562
+ additionalInfo: array22().of(UserAdditionalInfoSchema).default([]).label("Additional Information"),
4167
4563
  /**
4168
4564
  * Status of the user account
4169
4565
  */
4170
- status: string40().oneOf(SupportedUserStatuses).required().label("Status"),
4566
+ status: string41().oneOf(SupportedUserStatuses).required().label("Status"),
4171
4567
  /**
4172
4568
  * Roles assigned to the user
4173
4569
  */
4174
- roles: array21().of(string40().oneOf(SupportedUserRoles)).required().default(DefaultUserRoles).label("Roles"),
4570
+ roles: array22().of(string41().oneOf(SupportedUserRoles)).required().default(DefaultUserRoles).label("Roles"),
4175
4571
  /**
4176
4572
  * Explicit consent to receive marketing email (newsletters, job alerts by
4177
4573
  * broadcast, product updates). Marketing sends are HARD-GATED on
@@ -4183,18 +4579,18 @@ var UserSchema = object51({
4183
4579
  * unsubscribe sets `subscribed=false` so consent and the email-service
4184
4580
  * suppression list stay consistent. Defaults to NOT subscribed (opt-in).
4185
4581
  */
4186
- marketingConsent: object51({
4187
- subscribed: boolean22().default(false).label("Subscribed to marketing email"),
4582
+ marketingConsent: object53({
4583
+ subscribed: boolean24().default(false).label("Subscribed to marketing email"),
4188
4584
  /** Epoch ms of the last consent change (opt-in or opt-out). */
4189
- updatedAt: number20().optional().label("Consent updated at"),
4585
+ updatedAt: number21().optional().label("Consent updated at"),
4190
4586
  /** Where the consent change originated, e.g. `onboarding`, `unsubscribe`, `settings`. */
4191
- source: string40().optional().label("Consent source"),
4587
+ source: string41().optional().label("Consent source"),
4192
4588
  /**
4193
4589
  * How often the user receives job-alert emails. `off` disables job alerts
4194
4590
  * only; other marketing stays governed by `subscribed`. Unset means the
4195
4591
  * user has not chosen a cadence yet.
4196
4592
  */
4197
- jobAlertFrequency: string40().oneOf(SupportedJobAlertFrequencies).optional().label("Job alert frequency")
4593
+ jobAlertFrequency: string41().oneOf(SupportedJobAlertFrequencies).optional().label("Job alert frequency")
4198
4594
  }).default({ subscribed: false }).label("Marketing Consent"),
4199
4595
  /**
4200
4596
  * Per-channel toggles for NOTIFICATION email — mail about activity on the
@@ -4209,11 +4605,11 @@ var UserSchema = object51({
4209
4605
  *
4210
4606
  * Transactional mail (magic-link, verification) ignores this object entirely.
4211
4607
  */
4212
- notificationPrefs: object51({
4213
- groupActivity: boolean22().default(true).label("Group activity email"),
4214
- jobActivity: boolean22().default(true).label("Job activity email"),
4215
- applicationUpdates: boolean22().default(true).label("Application update email"),
4216
- productUpdates: boolean22().default(false).label("Product update email")
4608
+ notificationPrefs: object53({
4609
+ groupActivity: boolean24().default(true).label("Group activity email"),
4610
+ jobActivity: boolean24().default(true).label("Job activity email"),
4611
+ applicationUpdates: boolean24().default(true).label("Application update email"),
4612
+ productUpdates: boolean24().default(false).label("Product update email")
4217
4613
  }).default({
4218
4614
  groupActivity: true,
4219
4615
  jobActivity: true,
@@ -4240,21 +4636,21 @@ var UserSchema = object51({
4240
4636
  * subscription (see `PushSubscriptionSchema`). This flag is the user's
4241
4637
  * intent, the subscription is the browser grant, and both are required.
4242
4638
  */
4243
- pushConsent: object51({
4244
- subscribed: boolean22().default(false).label("Subscribed to push notifications"),
4639
+ pushConsent: object53({
4640
+ subscribed: boolean24().default(false).label("Subscribed to push notifications"),
4245
4641
  /** Epoch ms of the last consent change (opt-in or opt-out). */
4246
- updatedAt: number20().optional().label("Push consent updated at"),
4642
+ updatedAt: number21().optional().label("Push consent updated at"),
4247
4643
  /** Where the change originated, e.g. `onboarding`, `settings`, `prompt`. */
4248
- source: string40().optional().label("Push consent source")
4644
+ source: string41().optional().label("Push consent source")
4249
4645
  }).default({ subscribed: false }).label("Push Consent"),
4250
4646
  /**
4251
4647
  * Vector embedding of the user's profile for semantic/hybrid search.
4252
4648
  * Generated from a structured summary of skills, experience, education, etc.
4253
4649
  * Only generated for public profiles with sufficient completeness (≥60%).
4254
4650
  */
4255
- embedding: object51({
4256
- vector: array21(number20().required()).optional().label("Embedding vector"),
4257
- model: string40().optional().label("Embedding model")
4651
+ embedding: object53({
4652
+ vector: array22(number21().required()).optional().label("Embedding vector"),
4653
+ model: string41().optional().label("Embedding model")
4258
4654
  }).nullable().optional().label("Embedding"),
4259
4655
  /**
4260
4656
  * Epoch ms the account was created, assigned by the storing service.
@@ -4269,12 +4665,12 @@ var UserSchema = object51({
4269
4665
  * `updatedAt` is deliberately NOT added alongside it: nothing derives from it
4270
4666
  * yet, and an optional field is only safe to add when something needs it.
4271
4667
  */
4272
- createdAt: number20().optional().label("Created At")
4668
+ createdAt: number21().optional().label("Created At")
4273
4669
  }).concat(UserGeneralDetailSchema).concat(UserJobPreferencesSchema).concat(UserRecruiterProfileSchema).concat(UserCoordinatorProfileSchema).noUnknown().strict().label("User Schema");
4274
4670
 
4275
4671
  // src/user/push-subscription.schema.ts
4276
- import { number as number21, object as object52, string as string41 } from "yup";
4277
- var PushSubscriptionSchema = object52({
4672
+ import { number as number22, object as object54, string as string42 } from "yup";
4673
+ var PushSubscriptionSchema = object54({
4278
4674
  /**
4279
4675
  * The user this subscription belongs to, by the `shortId` every service
4280
4676
  * keys a user on, matching `UserSchema.shortId`.
@@ -4288,7 +4684,7 @@ var PushSubscriptionSchema = object52({
4288
4684
  * `shortId` of its OWN (see `PushSubscriptionRecord`); one field cannot be
4289
4685
  * both the row's id and its owner's.
4290
4686
  */
4291
- userShortId: string41().required().label("User Short ID"),
4687
+ userShortId: string42().required().label("User Short ID"),
4292
4688
  /**
4293
4689
  * The push service URL the browser issued. Vendor-specific (FCM, Mozilla,
4294
4690
  * Apple) and effectively unbounded in length, so it carries no length cap.
@@ -4297,16 +4693,16 @@ var PushSubscriptionSchema = object52({
4297
4693
  * browser sends back unchanged, and what a 404/410 response identifies as
4298
4694
  * dead. Upserts and deletes both key on it.
4299
4695
  */
4300
- endpoint: string41().required().label("Push Endpoint"),
4696
+ endpoint: string42().required().label("Push Endpoint"),
4301
4697
  /**
4302
4698
  * Encryption material from the browser. Web Push payloads are encrypted to
4303
4699
  * these keys, so a row missing either one cannot be delivered to at all.
4304
4700
  */
4305
- keys: object52({
4701
+ keys: object54({
4306
4702
  /** Client public key, base64url. */
4307
- p256dh: string41().required().label("P256DH Key"),
4703
+ p256dh: string42().required().label("P256DH Key"),
4308
4704
  /** Client auth secret, base64url. */
4309
- auth: string41().required().label("Auth Secret")
4705
+ auth: string42().required().label("Auth Secret")
4310
4706
  }).required().label("Push Keys"),
4311
4707
  /**
4312
4708
  * Epoch ms the push service says the subscription expires, when it says
@@ -4314,22 +4710,22 @@ var PushSubscriptionSchema = object52({
4314
4710
  * informational and never the basis for pruning. A 404/410 on send is the
4315
4711
  * only reliable death signal.
4316
4712
  */
4317
- expirationTime: number21().nullable().optional().label("Expiration Time"),
4713
+ expirationTime: number22().nullable().optional().label("Expiration Time"),
4318
4714
  /**
4319
4715
  * The subscribing browser's user agent, kept so a user can recognise their
4320
4716
  * own devices in a "where you receive notifications" list. Display only:
4321
4717
  * never parsed, and never used to decide delivery.
4322
4718
  */
4323
- userAgent: string41().optional().label("User Agent"),
4719
+ userAgent: string42().optional().label("User Agent"),
4324
4720
  /** Epoch ms the subscription was first registered. */
4325
- createdAt: number21().optional().label("Created At"),
4721
+ createdAt: number22().optional().label("Created At"),
4326
4722
  /**
4327
4723
  * Epoch ms this subscription was last confirmed live, refreshed when the
4328
4724
  * browser re-registers it. A subscription that stops being refreshed is a
4329
4725
  * device that stopped visiting, which is useful for pruning rows that never
4330
4726
  * fail loudly enough to be caught by a 410.
4331
4727
  */
4332
- lastSeenAt: number21().optional().label("Last Seen At"),
4728
+ lastSeenAt: number22().optional().label("Last Seen At"),
4333
4729
  /**
4334
4730
  * Epoch ms the owner explicitly signed out on this device, or absent.
4335
4731
  *
@@ -4339,12 +4735,12 @@ var PushSubscriptionSchema = object52({
4339
4735
  * so that a MISSING row keeps one meaning to the browser ("stop, this device
4340
4736
  * was removed"), which it acts on by dropping its own subscription.
4341
4737
  */
4342
- signedOutAt: number21().nullable().optional().label("Signed Out At")
4738
+ signedOutAt: number22().nullable().optional().label("Signed Out At")
4343
4739
  }).noUnknown().strict().label("Push Subscription Schema");
4344
4740
 
4345
4741
  // src/user/user-completeness.schema.ts
4346
- import { object as object53 } from "yup";
4347
- var UserCompletenessSchema = object53({
4742
+ import { object as object55 } from "yup";
4743
+ var UserCompletenessSchema = object55({
4348
4744
  additionalInfo: CompletenessScoreSchema(0).label("Additional Info"),
4349
4745
  // Optional
4350
4746
  certifications: CompletenessScoreSchema(0).label("Certifications"),
@@ -4368,10 +4764,14 @@ var StudentCompletenessSchema = UserCompletenessSchema.omit([
4368
4764
  export {
4369
4765
  AnswerChoiceType,
4370
4766
  ApplicationReceivePreference,
4767
+ AuditFilterSchema,
4768
+ AuditSchema,
4371
4769
  BillingPeriod,
4372
4770
  BillingSubscriptionSchema,
4373
4771
  BillingTransactionSchema,
4374
4772
  CAMPAIGN_MAX_RECIPIENTS_CEILING,
4773
+ CONCEPT_ID_PATTERN,
4774
+ CONCEPT_TYPE_PATTERN,
4375
4775
  CONSUME_MAX_UNITS,
4376
4776
  CampaignDataSourceSchema,
4377
4777
  CampaignEndKind,
@@ -4387,6 +4787,11 @@ export {
4387
4787
  Common,
4388
4788
  CompensationType,
4389
4789
  CompletenessScoreSchema,
4790
+ ConceptFilterSchema,
4791
+ ConceptMembershipSchema,
4792
+ ConceptProposalFilterSchema,
4793
+ ConceptProposalSchema,
4794
+ ConceptSchema,
4390
4795
  ContactTypes,
4391
4796
  CoordinatorPageLinkSchema,
4392
4797
  CountryFilterSchema,
@@ -4452,6 +4857,7 @@ export {
4452
4857
  MailingListFilterSchema,
4453
4858
  MailingListSchema,
4454
4859
  MoneySchema,
4860
+ NormalizeContextSchema,
4455
4861
  NotificationType,
4456
4862
  OccurrenceStatus,
4457
4863
  PREFILL_MIRRORED_KEYS,
@@ -4471,6 +4877,8 @@ export {
4471
4877
  PostSchema,
4472
4878
  PostStatus,
4473
4879
  ProficiencyLevel,
4880
+ ProposalCandidateSchema,
4881
+ ProposalMessageSchema,
4474
4882
  PushSubscriptionSchema,
4475
4883
  QuestionSchema,
4476
4884
  QuestionType,
@@ -4478,9 +4886,15 @@ export {
4478
4886
  ReadAndAcknowledgeQuestionSchema,
4479
4887
  RecruiterPageLinkSchema,
4480
4888
  ReferralSource,
4889
+ ReleaseFilterSchema,
4890
+ ReleaseSchema,
4481
4891
  ReportReason,
4482
4892
  ReportSchema,
4893
+ ResolverSettingsSchema,
4894
+ ResolverVerificationSchema,
4483
4895
  ResourceType,
4896
+ SCHEDULE_MAX_HOURS,
4897
+ SCHEDULE_MIN_HOURS,
4484
4898
  SITEMAP_FORMAT,
4485
4899
  SYSTEM_DATE_FORMAT,
4486
4900
  SavedSearchSchema,
@@ -4495,14 +4909,17 @@ export {
4495
4909
  StudentCompletenessSchema,
4496
4910
  StudyType,
4497
4911
  SubscriptionStatus,
4912
+ SuggestedHomeSchema,
4498
4913
  SupportedAnswerChoiceTypes,
4499
4914
  SupportedApplicationReceivePreferences,
4915
+ SupportedAuditStatuses,
4500
4916
  SupportedBillingPeriods,
4501
4917
  SupportedCampaignEndKinds,
4502
4918
  SupportedCampaignIntervalUnits,
4503
4919
  SupportedCampaignStatuses,
4504
4920
  SupportedCampaignTriggerKinds,
4505
4921
  SupportedCompensationTypes,
4922
+ SupportedConceptSources,
4506
4923
  SupportedContactTypes,
4507
4924
  SupportedEducationLevels,
4508
4925
  SupportedEmployeeCounts,
@@ -4527,6 +4944,7 @@ export {
4527
4944
  SupportedJobSearchUrgencies,
4528
4945
  SupportedJobStatuses,
4529
4946
  SupportedJobSubCategories,
4947
+ SupportedMatchTypes,
4530
4948
  SupportedNotificationTypes,
4531
4949
  SupportedOccurrenceStatuses,
4532
4950
  SupportedPaddleEnvironments,
@@ -4536,11 +4954,19 @@ export {
4536
4954
  SupportedPlanKinds,
4537
4955
  SupportedPlanStatuses,
4538
4956
  SupportedPostStatuses,
4957
+ SupportedPrefilterRules,
4539
4958
  SupportedProficiencyLevels,
4959
+ SupportedProposalFilters,
4960
+ SupportedProposalKinds,
4961
+ SupportedProposalMessageRoles,
4962
+ SupportedProposalStatuses,
4540
4963
  SupportedQuestionTypes,
4541
4964
  SupportedQuotaPeriods,
4542
4965
  SupportedReferralSources,
4966
+ SupportedReleaseKinds,
4967
+ SupportedReleaseStatuses,
4543
4968
  SupportedReportReasons,
4969
+ SupportedResolverVerdicts,
4544
4970
  SupportedResourceTypes,
4545
4971
  SupportedSalaryCurrencies,
4546
4972
  SupportedSavedSearchStatuses,
@@ -4548,19 +4974,31 @@ export {
4548
4974
  SupportedSocialAccounts,
4549
4975
  SupportedStudyTypes,
4550
4976
  SupportedSubscriptionStatuses,
4977
+ SupportedTaxonomyJobKinds,
4978
+ SupportedTaxonomyJobStates,
4979
+ SupportedTaxonomyNodeKinds,
4980
+ SupportedTaxonomySources,
4551
4981
  SupportedTemplateVariableBindingKinds,
4552
4982
  SupportedTransactionStatuses,
4983
+ SupportedUnmatchedReasons,
4984
+ SupportedUnmatchedResolutions,
4553
4985
  SupportedUserProfileVisibilities,
4554
4986
  SupportedUserRoles,
4555
4987
  SupportedUserStatuses,
4556
4988
  SupportedWorkModes,
4557
4989
  TAXONOMY_LABELS,
4990
+ TAXONOMY_NODE_ID_PATTERN,
4991
+ TaxonomyNodeFilterSchema,
4992
+ TaxonomyNodeSchema,
4993
+ TaxonomyScheduleSchema,
4558
4994
  TemplateVariableBindingKind,
4559
4995
  TemplateVariableBindingSchema,
4560
4996
  TerminalCampaignStatuses,
4561
4997
  TerminalGeoSyncStatuses,
4562
4998
  TermsAcceptedSchema,
4563
4999
  TransactionStatus,
5000
+ UnmatchedFilterSchema,
5001
+ UnmatchedTermSchema,
4564
5002
  UserAdditionalInfoSchema,
4565
5003
  UserCertificationSchema,
4566
5004
  UserCompletenessSchema,
@@ -4579,6 +5017,9 @@ export {
4579
5017
  UserSchema,
4580
5018
  UserSkillSchema,
4581
5019
  UserStatus,
5020
+ VOCABULARY_ID_PATTERN,
5021
+ VocabularySchema,
5022
+ VocabularyTypeSchema,
4582
5023
  WorkExperienceSchema,
4583
5024
  WorkMode,
4584
5025
  canTransitionCampaign,