lancer-shared 1.2.345 → 1.2.347

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.
@@ -1,1465 +1,592 @@
1
- const ROOM_EXTENDED_TYPE_MAP = {
2
- proposal: ['fl-proposal'],
3
- dm: ['direct_message'],
4
- invite: ['client-invitation', 'direct_hire_FL_profile'],
5
- };
6
- const ROOM_TYPES_MATCHING_EMPTY_EXTENDED_TYPE = new Set([
7
- 'proposal',
1
+ var util;
2
+ (function (util) {
3
+ util.assertEqual = (val) => val;
4
+ function assertIs(_arg) { }
5
+ util.assertIs = assertIs;
6
+ function assertNever(_x) {
7
+ throw new Error();
8
+ }
9
+ util.assertNever = assertNever;
10
+ util.arrayToEnum = (items) => {
11
+ const obj = {};
12
+ for (const item of items) {
13
+ obj[item] = item;
14
+ }
15
+ return obj;
16
+ };
17
+ util.getValidEnumValues = (obj) => {
18
+ const validKeys = util.objectKeys(obj).filter((k) => typeof obj[obj[k]] !== "number");
19
+ const filtered = {};
20
+ for (const k of validKeys) {
21
+ filtered[k] = obj[k];
22
+ }
23
+ return util.objectValues(filtered);
24
+ };
25
+ util.objectValues = (obj) => {
26
+ return util.objectKeys(obj).map(function (e) {
27
+ return obj[e];
28
+ });
29
+ };
30
+ util.objectKeys = typeof Object.keys === "function" // eslint-disable-line ban/ban
31
+ ? (obj) => Object.keys(obj) // eslint-disable-line ban/ban
32
+ : (object) => {
33
+ const keys = [];
34
+ for (const key in object) {
35
+ if (Object.prototype.hasOwnProperty.call(object, key)) {
36
+ keys.push(key);
37
+ }
38
+ }
39
+ return keys;
40
+ };
41
+ util.find = (arr, checker) => {
42
+ for (const item of arr) {
43
+ if (checker(item))
44
+ return item;
45
+ }
46
+ return undefined;
47
+ };
48
+ util.isInteger = typeof Number.isInteger === "function"
49
+ ? (val) => Number.isInteger(val) // eslint-disable-line ban/ban
50
+ : (val) => typeof val === "number" && isFinite(val) && Math.floor(val) === val;
51
+ function joinValues(array, separator = " | ") {
52
+ return array
53
+ .map((val) => (typeof val === "string" ? `'${val}'` : val))
54
+ .join(separator);
55
+ }
56
+ util.joinValues = joinValues;
57
+ util.jsonStringifyReplacer = (_, value) => {
58
+ if (typeof value === "bigint") {
59
+ return value.toString();
60
+ }
61
+ return value;
62
+ };
63
+ })(util || (util = {}));
64
+ var objectUtil;
65
+ (function (objectUtil) {
66
+ objectUtil.mergeShapes = (first, second) => {
67
+ return {
68
+ ...first,
69
+ ...second, // second overwrites first
70
+ };
71
+ };
72
+ })(objectUtil || (objectUtil = {}));
73
+ const ZodParsedType = util.arrayToEnum([
74
+ "string",
75
+ "nan",
76
+ "number",
77
+ "integer",
78
+ "float",
79
+ "boolean",
80
+ "date",
81
+ "bigint",
82
+ "symbol",
83
+ "function",
84
+ "undefined",
85
+ "null",
86
+ "array",
87
+ "object",
88
+ "unknown",
89
+ "promise",
90
+ "void",
91
+ "never",
92
+ "map",
93
+ "set",
8
94
  ]);
9
- const ROOM_CRM_STATUS_ORDER = [
10
- 'new',
11
- 'qualified',
12
- 'follow_up',
13
- 'won',
14
- 'archived',
15
- ];
16
- const ROOM_CRM_STATUS_LABELS = {
17
- new: 'New',
18
- follow_up: 'Follow Up',
19
- qualified: 'In Conversation',
20
- won: 'Active Contract',
21
- archived: 'Archived',
22
- };
23
- const DEFAULT_ROOM_CRM_STATUS = 'new';
24
- const ROOM_CRM_STATUS_IDS = {
25
- new: 1,
26
- follow_up: 2,
27
- qualified: 3,
28
- won: 4,
29
- archived: 5,
30
- };
31
- const ROOM_CRM_STATUS_BY_ID = {
32
- 1: 'new',
33
- 2: 'follow_up',
34
- 3: 'qualified',
35
- 4: 'won',
36
- 5: 'archived',
95
+ const getParsedType = (data) => {
96
+ const t = typeof data;
97
+ switch (t) {
98
+ case "undefined":
99
+ return ZodParsedType.undefined;
100
+ case "string":
101
+ return ZodParsedType.string;
102
+ case "number":
103
+ return isNaN(data) ? ZodParsedType.nan : ZodParsedType.number;
104
+ case "boolean":
105
+ return ZodParsedType.boolean;
106
+ case "function":
107
+ return ZodParsedType.function;
108
+ case "bigint":
109
+ return ZodParsedType.bigint;
110
+ case "symbol":
111
+ return ZodParsedType.symbol;
112
+ case "object":
113
+ if (Array.isArray(data)) {
114
+ return ZodParsedType.array;
115
+ }
116
+ if (data === null) {
117
+ return ZodParsedType.null;
118
+ }
119
+ if (data.then &&
120
+ typeof data.then === "function" &&
121
+ data.catch &&
122
+ typeof data.catch === "function") {
123
+ return ZodParsedType.promise;
124
+ }
125
+ if (typeof Map !== "undefined" && data instanceof Map) {
126
+ return ZodParsedType.map;
127
+ }
128
+ if (typeof Set !== "undefined" && data instanceof Set) {
129
+ return ZodParsedType.set;
130
+ }
131
+ if (typeof Date !== "undefined" && data instanceof Date) {
132
+ return ZodParsedType.date;
133
+ }
134
+ return ZodParsedType.object;
135
+ default:
136
+ return ZodParsedType.unknown;
137
+ }
37
138
  };
38
- // Explicit board order avoids scattered "exclude then append" logic in consumers.
39
- const ROOM_CRM_KANBAN_STATUS_ORDER = [
40
- 'new',
41
- 'qualified',
42
- 'follow_up',
43
- 'won',
44
- 'archived',
45
- ];
46
- const isRoomCrmStatus = (status) => {
47
- return ROOM_CRM_STATUS_ORDER.includes(status);
139
+
140
+ const ZodIssueCode = util.arrayToEnum([
141
+ "invalid_type",
142
+ "invalid_literal",
143
+ "custom",
144
+ "invalid_union",
145
+ "invalid_union_discriminator",
146
+ "invalid_enum_value",
147
+ "unrecognized_keys",
148
+ "invalid_arguments",
149
+ "invalid_return_type",
150
+ "invalid_date",
151
+ "invalid_string",
152
+ "too_small",
153
+ "too_big",
154
+ "invalid_intersection_types",
155
+ "not_multiple_of",
156
+ "not_finite",
157
+ ]);
158
+ const quotelessJson = (obj) => {
159
+ const json = JSON.stringify(obj, null, 2);
160
+ return json.replace(/"([^"]+)":/g, "$1:");
48
161
  };
49
- const normalizeRoomCrmStatus = (status) => {
50
- if (!status) {
51
- return DEFAULT_ROOM_CRM_STATUS;
162
+ class ZodError extends Error {
163
+ get errors() {
164
+ return this.issues;
52
165
  }
53
- const normalizedStatus = status.trim().toLowerCase();
54
- if (isRoomCrmStatus(normalizedStatus)) {
55
- return normalizedStatus;
166
+ constructor(issues) {
167
+ super();
168
+ this.issues = [];
169
+ this.addIssue = (sub) => {
170
+ this.issues = [...this.issues, sub];
171
+ };
172
+ this.addIssues = (subs = []) => {
173
+ this.issues = [...this.issues, ...subs];
174
+ };
175
+ const actualProto = new.target.prototype;
176
+ if (Object.setPrototypeOf) {
177
+ // eslint-disable-next-line ban/ban
178
+ Object.setPrototypeOf(this, actualProto);
179
+ }
180
+ else {
181
+ this.__proto__ = actualProto;
182
+ }
183
+ this.name = "ZodError";
184
+ this.issues = issues;
56
185
  }
57
- return DEFAULT_ROOM_CRM_STATUS;
58
- };
59
- const normalizeRoomCrmStatuses = (statuses) => {
60
- if (!statuses?.length) {
61
- return [];
186
+ format(_mapper) {
187
+ const mapper = _mapper ||
188
+ function (issue) {
189
+ return issue.message;
190
+ };
191
+ const fieldErrors = { _errors: [] };
192
+ const processError = (error) => {
193
+ for (const issue of error.issues) {
194
+ if (issue.code === "invalid_union") {
195
+ issue.unionErrors.map(processError);
196
+ }
197
+ else if (issue.code === "invalid_return_type") {
198
+ processError(issue.returnTypeError);
199
+ }
200
+ else if (issue.code === "invalid_arguments") {
201
+ processError(issue.argumentsError);
202
+ }
203
+ else if (issue.path.length === 0) {
204
+ fieldErrors._errors.push(mapper(issue));
205
+ }
206
+ else {
207
+ let curr = fieldErrors;
208
+ let i = 0;
209
+ while (i < issue.path.length) {
210
+ const el = issue.path[i];
211
+ const terminal = i === issue.path.length - 1;
212
+ if (!terminal) {
213
+ curr[el] = curr[el] || { _errors: [] };
214
+ // if (typeof el === "string") {
215
+ // curr[el] = curr[el] || { _errors: [] };
216
+ // } else if (typeof el === "number") {
217
+ // const errorArray: any = [];
218
+ // errorArray._errors = [];
219
+ // curr[el] = curr[el] || errorArray;
220
+ // }
221
+ }
222
+ else {
223
+ curr[el] = curr[el] || { _errors: [] };
224
+ curr[el]._errors.push(mapper(issue));
225
+ }
226
+ curr = curr[el];
227
+ i++;
228
+ }
229
+ }
230
+ }
231
+ };
232
+ processError(this);
233
+ return fieldErrors;
62
234
  }
63
- const normalizeListStatus = (rawStatus) => {
64
- const normalizedStatus = rawStatus.trim().toLowerCase();
65
- if (!normalizedStatus) {
66
- return null;
67
- }
68
- if (isRoomCrmStatus(normalizedStatus)) {
69
- return normalizedStatus;
235
+ static assert(value) {
236
+ if (!(value instanceof ZodError)) {
237
+ throw new Error(`Not a ZodError: ${value}`);
70
238
  }
71
- return null;
72
- };
73
- return Array.from(new Set(statuses
74
- .map((status) => normalizeListStatus(status))
75
- .filter((status) => status !== null)));
239
+ }
240
+ toString() {
241
+ return this.message;
242
+ }
243
+ get message() {
244
+ return JSON.stringify(this.issues, util.jsonStringifyReplacer, 2);
245
+ }
246
+ get isEmpty() {
247
+ return this.issues.length === 0;
248
+ }
249
+ flatten(mapper = (issue) => issue.message) {
250
+ const fieldErrors = {};
251
+ const formErrors = [];
252
+ for (const sub of this.issues) {
253
+ if (sub.path.length > 0) {
254
+ fieldErrors[sub.path[0]] = fieldErrors[sub.path[0]] || [];
255
+ fieldErrors[sub.path[0]].push(mapper(sub));
256
+ }
257
+ else {
258
+ formErrors.push(mapper(sub));
259
+ }
260
+ }
261
+ return { formErrors, fieldErrors };
262
+ }
263
+ get formErrors() {
264
+ return this.flatten();
265
+ }
266
+ }
267
+ ZodError.create = (issues) => {
268
+ const error = new ZodError(issues);
269
+ return error;
76
270
  };
77
- const ROOM_CRM_ARCHIVED_REASON_ORDER = [
78
- 'completed',
79
- 'not_fit',
80
- 'lost',
81
- 'no_response',
82
- 'other',
83
- ];
84
- const ROOM_CRM_ARCHIVED_REASON_LABELS = {
85
- completed: 'Completed',
86
- not_fit: 'Not fit',
87
- lost: 'Lost',
88
- no_response: 'No response',
89
- other: 'Other',
271
+
272
+ const errorMap = (issue, _ctx) => {
273
+ let message;
274
+ switch (issue.code) {
275
+ case ZodIssueCode.invalid_type:
276
+ if (issue.received === ZodParsedType.undefined) {
277
+ message = "Required";
278
+ }
279
+ else {
280
+ message = `Expected ${issue.expected}, received ${issue.received}`;
281
+ }
282
+ break;
283
+ case ZodIssueCode.invalid_literal:
284
+ message = `Invalid literal value, expected ${JSON.stringify(issue.expected, util.jsonStringifyReplacer)}`;
285
+ break;
286
+ case ZodIssueCode.unrecognized_keys:
287
+ message = `Unrecognized key(s) in object: ${util.joinValues(issue.keys, ", ")}`;
288
+ break;
289
+ case ZodIssueCode.invalid_union:
290
+ message = `Invalid input`;
291
+ break;
292
+ case ZodIssueCode.invalid_union_discriminator:
293
+ message = `Invalid discriminator value. Expected ${util.joinValues(issue.options)}`;
294
+ break;
295
+ case ZodIssueCode.invalid_enum_value:
296
+ message = `Invalid enum value. Expected ${util.joinValues(issue.options)}, received '${issue.received}'`;
297
+ break;
298
+ case ZodIssueCode.invalid_arguments:
299
+ message = `Invalid function arguments`;
300
+ break;
301
+ case ZodIssueCode.invalid_return_type:
302
+ message = `Invalid function return type`;
303
+ break;
304
+ case ZodIssueCode.invalid_date:
305
+ message = `Invalid date`;
306
+ break;
307
+ case ZodIssueCode.invalid_string:
308
+ if (typeof issue.validation === "object") {
309
+ if ("includes" in issue.validation) {
310
+ message = `Invalid input: must include "${issue.validation.includes}"`;
311
+ if (typeof issue.validation.position === "number") {
312
+ message = `${message} at one or more positions greater than or equal to ${issue.validation.position}`;
313
+ }
314
+ }
315
+ else if ("startsWith" in issue.validation) {
316
+ message = `Invalid input: must start with "${issue.validation.startsWith}"`;
317
+ }
318
+ else if ("endsWith" in issue.validation) {
319
+ message = `Invalid input: must end with "${issue.validation.endsWith}"`;
320
+ }
321
+ else {
322
+ util.assertNever(issue.validation);
323
+ }
324
+ }
325
+ else if (issue.validation !== "regex") {
326
+ message = `Invalid ${issue.validation}`;
327
+ }
328
+ else {
329
+ message = "Invalid";
330
+ }
331
+ break;
332
+ case ZodIssueCode.too_small:
333
+ if (issue.type === "array")
334
+ message = `Array must contain ${issue.exact ? "exactly" : issue.inclusive ? `at least` : `more than`} ${issue.minimum} element(s)`;
335
+ else if (issue.type === "string")
336
+ message = `String must contain ${issue.exact ? "exactly" : issue.inclusive ? `at least` : `over`} ${issue.minimum} character(s)`;
337
+ else if (issue.type === "number")
338
+ message = `Number must be ${issue.exact
339
+ ? `exactly equal to `
340
+ : issue.inclusive
341
+ ? `greater than or equal to `
342
+ : `greater than `}${issue.minimum}`;
343
+ else if (issue.type === "date")
344
+ message = `Date must be ${issue.exact
345
+ ? `exactly equal to `
346
+ : issue.inclusive
347
+ ? `greater than or equal to `
348
+ : `greater than `}${new Date(Number(issue.minimum))}`;
349
+ else
350
+ message = "Invalid input";
351
+ break;
352
+ case ZodIssueCode.too_big:
353
+ if (issue.type === "array")
354
+ message = `Array must contain ${issue.exact ? `exactly` : issue.inclusive ? `at most` : `less than`} ${issue.maximum} element(s)`;
355
+ else if (issue.type === "string")
356
+ message = `String must contain ${issue.exact ? `exactly` : issue.inclusive ? `at most` : `under`} ${issue.maximum} character(s)`;
357
+ else if (issue.type === "number")
358
+ message = `Number must be ${issue.exact
359
+ ? `exactly`
360
+ : issue.inclusive
361
+ ? `less than or equal to`
362
+ : `less than`} ${issue.maximum}`;
363
+ else if (issue.type === "bigint")
364
+ message = `BigInt must be ${issue.exact
365
+ ? `exactly`
366
+ : issue.inclusive
367
+ ? `less than or equal to`
368
+ : `less than`} ${issue.maximum}`;
369
+ else if (issue.type === "date")
370
+ message = `Date must be ${issue.exact
371
+ ? `exactly`
372
+ : issue.inclusive
373
+ ? `smaller than or equal to`
374
+ : `smaller than`} ${new Date(Number(issue.maximum))}`;
375
+ else
376
+ message = "Invalid input";
377
+ break;
378
+ case ZodIssueCode.custom:
379
+ message = `Invalid input`;
380
+ break;
381
+ case ZodIssueCode.invalid_intersection_types:
382
+ message = `Intersection results could not be merged`;
383
+ break;
384
+ case ZodIssueCode.not_multiple_of:
385
+ message = `Number must be a multiple of ${issue.multipleOf}`;
386
+ break;
387
+ case ZodIssueCode.not_finite:
388
+ message = "Number must be finite";
389
+ break;
390
+ default:
391
+ message = _ctx.defaultError;
392
+ util.assertNever(issue);
393
+ }
394
+ return { message };
90
395
  };
91
396
 
92
- const defaultQuestions = [
93
- {
94
- question: 'What is your company website URL?',
95
- answer: '',
96
- exampleAnswer: 'Website: www.yourwebsite.com',
97
- },
98
- {
99
- question: 'Please list any certifications that you have',
100
- answer: '',
101
- exampleAnswer: 'AWS Certified Solutions Architect\nGoogle Cloud Certified Professional Developer\nMicrosoft Certified: Azure Developer Associate\nCertified Scrum Master (CSM)',
102
- },
103
- {
104
- question: 'What past project or job have you had that is most like this one and why?',
105
- answer: "{{PROJECT}} is definitely the closest match - we {{ACTION}} their {{TYPE}} from scratch {{DETAIL}}. The {{CHALLENGE}} was particularly challenging since we needed {{REQUIREMENT}}. Very similar {{ASPECT}} to what you're looking for.",
106
- exampleAnswer: "{{PROJECT}} is definitely the closest match - we {{ACTION}} their {{TYPE}} from scratch {{DETAIL}}. The {{CHALLENGE}} was particularly challenging since we needed {{REQUIREMENT}}. Very similar {{ASPECT}} to what you're looking for.",
107
- },
108
- {
109
- question: 'What tools/frameworks/methods have you worked with?',
110
- answer: 'For {{AREA}}, we primarily use {{TOOL}} and {{METHOD}}. For {{AREA}}, we use {{TOOL}}. For the {{PROJECT}} project I mentioned, we used this exact approach and it worked really well for {{OUTCOME}}. We typically {{METHOD}} depending on client needs.',
111
- exampleAnswer: 'For {{AREA}}, we primarily use {{TOOL}} and {{METHOD}}. For {{AREA}}, we use {{TOOL}}. For the {{PROJECT}} project I mentioned, we used this exact approach and it worked really well for {{OUTCOME}}. We typically {{METHOD}} depending on client needs.',
112
- },
113
- {
114
- question: 'Do you have suggestions to make this project run successfully?',
115
- answer: "Based on our experience with {{PROJECT}}, I'd suggest starting with {{APPROACH}} to {{BENEFIT}}. {{INSIGHT}}, and we've found that {{LESSON}} saves {{BENEFIT}} later. Our team's experience in {{DOMAIN}} makes us a good fit here.",
116
- exampleAnswer: "Based on our experience with {{PROJECT}}, I'd suggest starting with {{APPROACH}} to {{BENEFIT}}. {{INSIGHT}}, and we've found that {{LESSON}} saves {{BENEFIT}} later. Our team's experience in {{DOMAIN}} makes us a good fit here.",
117
- },
118
- {
119
- question: 'Why do you think you are a good fit for this particular project?',
120
- answer: "Based on our experience with {{PROJECT}}, I'd suggest starting with {{APPROACH}} to {{BENEFIT}}. {{INSIGHT}}, and we've found that {{LESSON}} saves {{BENEFIT}} later. Our team's experience in {{DOMAIN}} makes us a good fit here.",
121
- exampleAnswer: "Based on our experience with {{PROJECT}}, I'd suggest starting with {{APPROACH}} to {{BENEFIT}}. {{INSIGHT}}, and we've found that {{LESSON}} saves {{BENEFIT}} later. Our team's experience in {{DOMAIN}} makes us a good fit here.",
122
- },
123
- {
124
- question: 'Do you have any questions about the job description?',
125
- answer: "I'm curious about {{QUESTION}}? Also, are you looking to {{REQUIREMENT}} that we should have experience with? This would help us better understand the scope.",
126
- exampleAnswer: "I'm curious about {{QUESTION}}? Also, are you looking to {{REQUIREMENT}} that we should have experience with? This would help us better understand the scope.",
127
- },
128
- {
129
- question: 'How would you approach this type of project?',
130
- answer: "For projects like this, we start by {{STEP}}, focusing on {{FACTOR}}. From {{PROJECT}}, we learned that {{INSIGHT}} can drive {{TYPE}}, such as {{RESULT}}. We'd adapt this approach based on your specific goals and requirements.",
131
- exampleAnswer: "For projects like this, we start by {{STEP}}, focusing on {{FACTOR}}. From {{PROJECT}}, we learned that {{INSIGHT}} can drive {{TYPE}}, such as {{RESULT}}. We'd adapt this approach based on your specific goals and requirements.",
132
- },
133
- ];
397
+ let overrideErrorMap = errorMap;
398
+ function setErrorMap(map) {
399
+ overrideErrorMap = map;
400
+ }
401
+ function getErrorMap() {
402
+ return overrideErrorMap;
403
+ }
134
404
 
135
- const GOAT_COUNTRIES = [
136
- 'USA',
137
- 'United States',
138
- 'United Kingdom',
139
- 'CAN',
140
- 'Canada',
141
- 'AUS',
142
- 'Australia',
143
- 'ISR',
144
- 'Israel',
145
- 'United Arab Emirates',
146
- 'Singapore',
147
- 'Switzerland',
148
- 'Saudi Arabia',
149
- 'CHN',
150
- 'China',
151
- 'Austria',
152
- 'BEL',
153
- 'Belgium',
154
- 'Bulgaria',
155
- 'Croatia',
156
- 'CYP',
157
- 'Cyprus',
158
- 'CZH',
159
- 'Czech Republic',
160
- 'Denmark',
161
- 'Estonia',
162
- 'FIN',
163
- 'Finland',
164
- 'FRA',
165
- 'France',
166
- 'DEU',
167
- 'Germany',
168
- 'Greece',
169
- 'HUN',
170
- 'Hungry',
171
- 'Ireland',
172
- 'Italy',
173
- 'Latvia',
174
- 'Lithuania',
175
- 'LUX',
176
- 'Luxhembourg',
177
- 'Malta',
178
- 'Netherlands',
179
- 'POL',
180
- 'Poland',
181
- 'Portugal',
182
- 'Romania',
183
- 'Slovakia',
184
- 'Slovenia',
185
- 'Spain',
186
- 'SWE',
187
- 'Sweden',
188
- 'Norway',
189
- 'New Zealand',
190
- 'GBR',
191
- 'NLD',
192
- 'Qatar',
193
- 'SGP',
194
- 'ESP',
195
- 'ITA',
196
- 'Puerto Rico',
197
- 'Costa Rica',
198
- 'Iceland',
199
- 'QAT',
200
- 'Monaco',
201
- ];
405
+ const makeIssue = (params) => {
406
+ const { data, path, errorMaps, issueData } = params;
407
+ const fullPath = [...path, ...(issueData.path || [])];
408
+ const fullIssue = {
409
+ ...issueData,
410
+ path: fullPath,
411
+ };
412
+ if (issueData.message !== undefined) {
413
+ return {
414
+ ...issueData,
415
+ path: fullPath,
416
+ message: issueData.message,
417
+ };
418
+ }
419
+ let errorMessage = "";
420
+ const maps = errorMaps
421
+ .filter((m) => !!m)
422
+ .slice()
423
+ .reverse();
424
+ for (const map of maps) {
425
+ errorMessage = map(fullIssue, { data, defaultError: errorMessage }).message;
426
+ }
427
+ return {
428
+ ...issueData,
429
+ path: fullPath,
430
+ message: errorMessage,
431
+ };
432
+ };
433
+ const EMPTY_PATH = [];
434
+ function addIssueToContext(ctx, issueData) {
435
+ const overrideMap = getErrorMap();
436
+ const issue = makeIssue({
437
+ issueData: issueData,
438
+ data: ctx.data,
439
+ path: ctx.path,
440
+ errorMaps: [
441
+ ctx.common.contextualErrorMap, // contextual error map is first priority
442
+ ctx.schemaErrorMap, // then schema-bound map if available
443
+ overrideMap, // then global override map
444
+ overrideMap === errorMap ? undefined : errorMap, // then global default map
445
+ ].filter((x) => !!x),
446
+ });
447
+ ctx.common.issues.push(issue);
448
+ }
449
+ class ParseStatus {
450
+ constructor() {
451
+ this.value = "valid";
452
+ }
453
+ dirty() {
454
+ if (this.value === "valid")
455
+ this.value = "dirty";
456
+ }
457
+ abort() {
458
+ if (this.value !== "aborted")
459
+ this.value = "aborted";
460
+ }
461
+ static mergeArray(status, results) {
462
+ const arrayValue = [];
463
+ for (const s of results) {
464
+ if (s.status === "aborted")
465
+ return INVALID$3;
466
+ if (s.status === "dirty")
467
+ status.dirty();
468
+ arrayValue.push(s.value);
469
+ }
470
+ return { status: status.value, value: arrayValue };
471
+ }
472
+ static async mergeObjectAsync(status, pairs) {
473
+ const syncPairs = [];
474
+ for (const pair of pairs) {
475
+ const key = await pair.key;
476
+ const value = await pair.value;
477
+ syncPairs.push({
478
+ key,
479
+ value,
480
+ });
481
+ }
482
+ return ParseStatus.mergeObjectSync(status, syncPairs);
483
+ }
484
+ static mergeObjectSync(status, pairs) {
485
+ const finalObject = {};
486
+ for (const pair of pairs) {
487
+ const { key, value } = pair;
488
+ if (key.status === "aborted")
489
+ return INVALID$3;
490
+ if (value.status === "aborted")
491
+ return INVALID$3;
492
+ if (key.status === "dirty")
493
+ status.dirty();
494
+ if (value.status === "dirty")
495
+ status.dirty();
496
+ if (key.value !== "__proto__" &&
497
+ (typeof value.value !== "undefined" || pair.alwaysSet)) {
498
+ finalObject[key.value] = value.value;
499
+ }
500
+ }
501
+ return { status: status.value, value: finalObject };
502
+ }
503
+ }
504
+ const INVALID$3 = Object.freeze({
505
+ status: "aborted",
506
+ });
507
+ const DIRTY = (value) => ({ status: "dirty", value });
508
+ const OK = (value) => ({ status: "valid", value });
509
+ const isAborted = (x) => x.status === "aborted";
510
+ const isDirty = (x) => x.status === "dirty";
511
+ const isValid = (x) => x.status === "valid";
512
+ const isAsync = (x) => typeof Promise !== "undefined" && x instanceof Promise;
202
513
 
203
- const invoiceStatusNames = {
204
- open: "Open",
205
- paid: "Paid",
206
- past_due: "Past Due",
207
- payment_failed: "Payment Failed",
514
+ /******************************************************************************
515
+ Copyright (c) Microsoft Corporation.
516
+
517
+ Permission to use, copy, modify, and/or distribute this software for any
518
+ purpose with or without fee is hereby granted.
519
+
520
+ THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
521
+ REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
522
+ AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
523
+ INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
524
+ LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
525
+ OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
526
+ PERFORMANCE OF THIS SOFTWARE.
527
+ ***************************************************************************** */
528
+
529
+ function __classPrivateFieldGet(receiver, state, kind, f) {
530
+ if (typeof state === "function" ? receiver !== state || true : !state.has(receiver)) throw new TypeError("Cannot read private member from an object whose class did not declare it");
531
+ return state.get(receiver);
532
+ }
533
+
534
+ function __classPrivateFieldSet(receiver, state, value, kind, f) {
535
+ if (typeof state === "function" ? receiver !== state || true : !state.has(receiver)) throw new TypeError("Cannot write private member to an object whose class did not declare it");
536
+ return (state.set(receiver, value)), value;
537
+ }
538
+
539
+ typeof SuppressedError === "function" ? SuppressedError : function (error, suppressed, message) {
540
+ var e = new Error(message);
541
+ return e.name = "SuppressedError", e.error = error, e.suppressed = suppressed, e;
208
542
  };
209
543
 
210
- const JOB_FILTER_OPTIONS = {
211
- REGIONS: ['Worldwide', 'USOnly', 'UKOnly', 'All'],
212
- PROJECT_DURATION: [
213
- 'Less than 1 month',
214
- '1 to 3 months',
215
- '3 to 6 months',
216
- 'More than 6 months',
217
- 'Unspecified',
218
- ],
219
- ENGAGEMENT_TYPE: [
220
- 'Less than 30 hrs/week',
221
- 'More than 30 hrs/week',
222
- 'Unspecified',
223
- ],
224
- VENDOR_TYPE: ['Independent', 'Agency', 'Unspecified'],
225
- PAYMENT_TYPE: ['Unspecified', 'Hourly', 'Fixed-price'],
226
- TALENT_TYPE: ['Agency', 'Independent', 'Unspecified'],
227
- ENGLISH_LEVELS: [
228
- 'Fluent',
229
- 'Conversational',
230
- 'Native or Bilingual',
231
- 'Unspecified',
232
- ],
233
- EXPERIENCE_LEVELS: ['Entry level', 'Intermediate', 'Expert'],
234
- REQUIRED_EARNINGS: [100, 1000, 10000],
235
- REQUIRED_JSS: ['>80%', '>90%', '100%', 'RT'],
236
- HIERARCHICAL_CATEGORIES: [
237
- {
238
- label: 'Accounting & Consulting',
239
- value: 'accounting-consulting',
240
- children: [
241
- 'Accounting & Bookkeeping',
242
- 'Financial Planning',
243
- 'Management Consulting & Analysis',
244
- 'Other - Accounting & Consulting',
245
- 'Personal & Professional Coaching',
246
- 'Recruiting & Human Resources',
247
- ],
248
- },
249
- {
250
- label: 'Admin Support',
251
- value: 'admin-support',
252
- children: [
253
- 'Data Entry & Transcription Services',
254
- 'Market Research & Product Reviews',
255
- 'Project Management',
256
- 'Virtual Assistance',
257
- ],
258
- },
259
- {
260
- label: 'Customer Service',
261
- value: 'customer-service',
262
- children: [
263
- 'Community Management & Tagging',
264
- 'Customer Service & Tech Support',
265
- ],
266
- },
267
- {
268
- label: 'Data Science & Analytics',
269
- value: 'data-science-analytics',
270
- children: [
271
- 'AI & Machine Learning',
272
- 'Data Analysis & Testing',
273
- 'Data Extraction/ETL',
274
- 'Data Mining & Management',
275
- ],
276
- },
277
- {
278
- label: 'Design & Creative',
279
- value: 'design-creative',
280
- children: [
281
- 'Art & Illustration',
282
- 'Audio & Music Production',
283
- 'Branding & Logo Design',
284
- 'Graphic, Editorial & Presentation Design',
285
- 'NFT, AR/VR & Game Art',
286
- 'Performing Arts',
287
- 'Photography',
288
- 'Product Design',
289
- 'Video & Animation',
290
- ],
291
- },
292
- {
293
- label: 'Engineering & Architecture',
294
- value: 'engineering-architecture',
295
- children: [
296
- '3D Modeling & CAD',
297
- 'Building & Landscape Architecture',
298
- 'Chemical Engineering',
299
- 'Civil & Structural Engineering',
300
- 'Contract Manufacturing',
301
- 'Electrical & Electronic Engineering',
302
- 'Energy & Mechanical Engineering',
303
- ],
304
- },
305
- {
306
- label: 'IT & Networking',
307
- value: 'it-networking',
308
- children: [
309
- 'Database Management & Administration',
310
- 'DevOps & Solution Architecture',
311
- 'ERP/CRM Software',
312
- 'Information Security & Compliance',
313
- 'Network & System Administration',
314
- ],
315
- },
316
- {
317
- label: 'Legal',
318
- value: 'legal',
319
- children: [
320
- 'Corporate & Contract Law',
321
- 'Finance & Tax Law',
322
- 'International & Immigration Law',
323
- 'Public Law',
324
- ],
325
- },
326
- {
327
- label: 'Sales & Marketing',
328
- value: 'sales-marketing',
329
- children: [
330
- 'Digital Marketing',
331
- 'Lead Generation & Telemarketing',
332
- 'Marketing, PR & Brand Strategy',
333
- ],
334
- },
335
- {
336
- label: 'Translation',
337
- value: 'translation',
338
- children: [
339
- 'Language Tutoring & Interpretation',
340
- 'Translation & Localization Services',
341
- ],
342
- },
343
- {
344
- label: 'Software Development',
345
- value: 'software-development',
346
- children: [
347
- 'AI Apps & Integration',
348
- 'Blockchain, NFT & Cryptocurrency',
349
- 'Desktop Application Development',
350
- 'Ecommerce Development',
351
- 'Game Design & Development',
352
- 'Mobile Development',
353
- 'Other - Software Development',
354
- 'Product Management & Scrum',
355
- 'QA Testing',
356
- 'Scripts & Utilities',
357
- 'Web & Mobile Design',
358
- 'Web Development',
359
- ],
360
- },
361
- {
362
- label: 'Writing',
363
- value: 'writing',
364
- children: [
365
- 'Content Writing',
366
- 'Editing & Proofreading Services',
367
- 'Professional & Business Writing',
368
- 'Sales & Marketing Copywriting',
369
- ],
370
- },
371
- ],
372
- CATEGORIES: [
373
- 'Interior & Trade Show Design',
374
- 'Physical Sciences',
375
- 'Personal & Professional Coaching',
376
- 'Accounting & Bookkeeping',
377
- 'Financial Planning',
378
- 'Recruiting & Human Resources',
379
- 'Management Consulting & Analysis',
380
- 'Other - Accounting & Consulting',
381
- 'Data Entry & Transcription Services',
382
- 'Virtual Assistance',
383
- 'Project Management',
384
- 'Market Research & Product Reviews',
385
- 'Community Management & Tagging',
386
- 'Customer Service & Tech Support',
387
- 'Data Analysis & Testing',
388
- 'Data Extraction/ETL',
389
- 'Data Mining & Management',
390
- 'AI & Machine Learning',
391
- 'Art & Illustration',
392
- 'Audio & Music Production',
393
- 'Branding & Logo Design',
394
- 'NFT, AR/VR & Game Art',
395
- 'Graphic, Editorial & Presentation Design',
396
- 'Performing Arts',
397
- 'Photography',
398
- 'Product Design',
399
- 'Video & Animation',
400
- 'Building & Landscape Architecture',
401
- 'Chemical Engineering',
402
- 'Civil & Structural Engineering',
403
- 'Contract Manufacturing',
404
- 'Electrical & Electronic Engineering',
405
- 'Energy & Mechanical Engineering',
406
- '3D Modeling & CAD',
407
- 'Database Management & Administration',
408
- 'ERP/CRM Software',
409
- 'Information Security & Compliance',
410
- 'Network & System Administration',
411
- 'DevOps & Solution Architecture',
412
- 'Corporate & Contract Law',
413
- 'International & Immigration Law',
414
- 'Finance & Tax Law',
415
- 'Public Law',
416
- 'Digital Marketing',
417
- 'Lead Generation & Telemarketing',
418
- 'Marketing, PR & Brand Strategy',
419
- 'Language Tutoring & Interpretation',
420
- 'Translation & Localization Services',
421
- 'Blockchain, NFT & Cryptocurrency',
422
- 'AI Apps & Integration',
423
- 'Desktop Application Development',
424
- 'Ecommerce Development',
425
- 'Game Design & Development',
426
- 'Mobile Development',
427
- 'Other - Software Development',
428
- 'Product Management & Scrum',
429
- 'QA Testing',
430
- 'Scripts & Utilities',
431
- 'Web & Mobile Design',
432
- 'Web Development',
433
- 'Sales & Marketing Copywriting',
434
- 'Content Writing',
435
- 'Editing & Proofreading Services',
436
- 'Professional & Business Writing',
437
- ],
438
- CLIENT_INDUSTRY: [
439
- 'Aerospace',
440
- 'Agriculture & Forestry',
441
- 'Art & Design',
442
- 'Automotive',
443
- 'Aviation',
444
- 'Education',
445
- 'Energy & Utilities',
446
- 'Engineering & Architecture',
447
- 'Fashion & Beauty',
448
- 'Finance & Accounting',
449
- 'Food & Beverage',
450
- 'Government & Public Sector',
451
- 'Health & Fitness',
452
- 'HR & Business Services',
453
- 'Legal',
454
- 'Manufacturing & Construction',
455
- 'Media & Entertainment',
456
- 'Military & Defense',
457
- 'Mining',
458
- 'Real Estate',
459
- 'Retail & Consumer Goods',
460
- 'Sales & Marketing',
461
- 'Science & Medicine',
462
- 'Sports & Recreation',
463
- 'Supply Chain & Logistics',
464
- 'Tech & IT',
465
- 'Transportation & Warehousing',
466
- 'Travel & Hospitality',
467
- ],
468
- CLIENT_SIZE: [
469
- 'Individual client',
470
- 'Small company (2-9 people)',
471
- 'Mid-sized company (10-99 people)',
472
- 'Large company (100-1,000 people)',
473
- 'Large company (1,000+ people)',
474
- 'Unspecified',
475
- ],
476
- };
477
- const HIERARCHICAL_CATEGORIES_TO_CHILDREN = JOB_FILTER_OPTIONS.HIERARCHICAL_CATEGORIES.reduce((acc, category) => {
478
- acc[category.label] = category.children;
479
- return acc;
480
- }, {});
481
- const regionNames = {
482
- Worldwide: 'Worldwide',
483
- USOnly: 'US Only',
484
- UKOnly: 'UK Only',
485
- All: 'All',
486
- };
487
- const CLIENT_SIZE_TO_NUMBER = {
488
- 'Individual client': 1,
489
- 'Small company (2-9 people)': 2,
490
- 'Mid-sized company (10-99 people)': 10,
491
- 'Large company (100-1,000 people)': 100,
492
- 'Large company (1,000+ people)': 1000,
493
- Unspecified: null,
494
- };
544
+ var errorUtil;
545
+ (function (errorUtil) {
546
+ errorUtil.errToObj = (message) => typeof message === "string" ? { message } : message || {};
547
+ errorUtil.toString = (message) => typeof message === "string" ? message : message === null || message === void 0 ? void 0 : message.message;
548
+ })(errorUtil || (errorUtil = {}));
495
549
 
496
- const jobStatusOrder = [
497
- "leads",
498
- "contacted",
499
- "viewed",
500
- "replied",
501
- "won",
502
- ];
503
- const getPreviousStatus = (status) => {
504
- if (status === "won")
505
- return "replied";
506
- const index = jobStatusOrder.indexOf(status);
507
- return index > 0 ? jobStatusOrder[index - 1] : null;
508
- };
509
- const getNextStatus = (status) => {
510
- const index = jobStatusOrder.indexOf(status);
511
- return index < jobStatusOrder.length - 1 ? jobStatusOrder[index + 1] : null;
512
- };
513
-
514
- const countryMapping = {
515
- USA: "United States",
516
- GBR: "United Kingdom",
517
- AUS: "Australia",
518
- CAN: "Canada",
519
- IND: "India",
520
- NLD: "Netherlands",
521
- ARE: "United Arab Emirates",
522
- DEU: "Germany",
523
- SAU: "Saudi Arabia",
524
- FRA: "France",
525
- TUR: "Turkey",
526
- CHE: "Switzerland",
527
- ISR: "Israel",
528
- ITA: "Italy",
529
- ESP: "Spain",
530
- PAK: "Pakistan",
531
- SGP: "Singapore",
532
- KAZ: "Kazakhstan",
533
- UKR: "Ukraine",
534
- IRL: "Ireland",
535
- SWE: "Sweden",
536
- ZAF: "South Africa",
537
- CHN: "China",
538
- NOR: "Norway",
539
- POL: "Poland",
540
- COL: "Colombia",
541
- NZL: "New Zealand",
542
- ROU: "Romania",
543
- BRA: "Brazil",
544
- GRC: "Greece",
545
- BGR: "Bulgaria",
546
- DNK: "Denmark",
547
- PHL: "Philippines",
548
- BEL: "Belgium",
549
- AUT: "Austria",
550
- HKG: "Hong Kong",
551
- QAT: "Qatar",
552
- BGD: "Bangladesh",
553
- PRT: "Portugal",
554
- CYP: "Cyprus",
555
- LKA: "Sri Lanka",
556
- NGA: "Nigeria",
557
- VNM: "Vietnam",
558
- JPN: "Japan",
559
- LVA: "Latvia",
560
- THA: "Thailand",
561
- CZE: "Czech Republic",
562
- MEX: "Mexico",
563
- EGY: "Egypt",
564
- KEN: "Kenya",
565
- KWT: "Kuwait",
566
- CHL: "Chile",
567
- EST: "Estonia",
568
- UZB: "Uzbekistan",
569
- FIN: "Finland",
570
- HRV: "Croatia",
571
- HUN: "Hungary",
572
- KOR: "South Korea",
573
- LTU: "Lithuania",
574
- PRI: "Puerto Rico",
575
- ALB: "Albania",
576
- BHR: "Bahrain",
577
- GEO: "Georgia",
578
- GTM: "Guatemala",
579
- IDN: "Indonesia",
580
- LBN: "Lebanon",
581
- UGA: "Uganda",
582
- ARG: "Argentina",
583
- ARM: "Armenia",
584
- BMU: "Bermuda",
585
- CRI: "Costa Rica",
586
- CYM: "Cayman Islands",
587
- GHA: "Ghana",
588
- ISL: "Iceland",
589
- JOR: "Jordan",
590
- LUX: "Luxembourg",
591
- MAR: "Morocco",
592
- MKD: "Macedonia",
593
- MLT: "Malta",
594
- MYS: "Malaysia",
595
- OMN: "Oman",
596
- SRB: "Serbia",
597
- TWN: "Taiwan",
598
- BHS: "Bahamas",
599
- DZA: "Algeria",
600
- ETH: "Ethiopia",
601
- GUY: "Guyana",
602
- PAN: "Panama",
603
- PER: "Peru",
604
- SVK: "Slovakia",
605
- SVN: "Slovenia",
606
- TTO: "Trinidad and Tobago",
607
- URY: "Uruguay",
608
- VEN: "Venezuela",
609
- VIR: "Virgin Islands",
610
- ABW: "Aruba",
611
- CMR: "Cameroon",
612
- CUW: "Curaçao",
613
- GIB: "Gibraltar",
614
- HND: "Honduras",
615
- JAM: "Jamaica",
616
- JEY: "Jersey",
617
- MDV: "Maldives",
618
- MUS: "Mauritius",
619
- TUN: "Tunisia",
620
- RUS: "Russia",
621
- IRN: "Iran",
622
- IRQ: "Iraq",
623
- AZE: "Azerbaijan",
624
- CIV: "Cote d'Ivoire",
625
- PSE: "Palestine",
626
- MNE: "Montenegro",
627
- BIH: "Bosnia and Herzegovina",
628
- IMN: "Isle of Man",
629
- PNG: "Papua New Guinea",
630
- VCT: "Saint Vincent and the Grenadines",
631
- VGB: "British Virgin Islands",
632
- };
633
-
634
- const regionMapping = {
635
- Africa: [
636
- "Algeria",
637
- "Angola",
638
- "Benin",
639
- "Botswana",
640
- "Burkina Faso",
641
- "Burundi",
642
- "Cabo Verde",
643
- "Cameroon",
644
- "Central African Republic",
645
- "Chad",
646
- "Comoros",
647
- "Congo",
648
- "Congo, the Democratic Republic of the",
649
- "Cote d'Ivoire",
650
- "Djibouti",
651
- "Egypt",
652
- "Equatorial Guinea",
653
- "Eritrea",
654
- "Eswatini",
655
- "Ethiopia",
656
- "Gabon",
657
- "Gambia",
658
- "Ghana",
659
- "Guinea",
660
- "Guinea-Bissau",
661
- "Kenya",
662
- "Lesotho",
663
- "Liberia",
664
- "Libya",
665
- "Madagascar",
666
- "Malawi",
667
- "Mali",
668
- "Mauritania",
669
- "Mauritius",
670
- "Morocco",
671
- "Mozambique",
672
- "Namibia",
673
- "Niger",
674
- "Nigeria",
675
- "Rwanda",
676
- "Sao Tome and Principe",
677
- "Senegal",
678
- "Seychelles",
679
- "Sierra Leone",
680
- "Somalia",
681
- "South Africa",
682
- "South Sudan",
683
- "Sudan",
684
- "Tanzania",
685
- "Togo",
686
- "Tunisia",
687
- "Uganda",
688
- "Zambia",
689
- "Zimbabwe",
690
- ],
691
- Americas: [
692
- "Anguilla",
693
- "Antigua and Barbuda",
694
- "Argentina",
695
- "Aruba",
696
- "Bahamas",
697
- "Barbados",
698
- "Belize",
699
- "Bermuda",
700
- "Bolivia",
701
- "Brazil",
702
- "British Virgin Islands",
703
- "Canada",
704
- "Cayman Islands",
705
- "Chile",
706
- "Colombia",
707
- "Costa Rica",
708
- "Cuba",
709
- "Curacao",
710
- "Dominica",
711
- "Dominican Republic",
712
- "Ecuador",
713
- "El Salvador",
714
- "Falkland Islands",
715
- "French Guiana",
716
- "Grenada",
717
- "Guadeloupe",
718
- "Guatemala",
719
- "Guyana",
720
- "Haiti",
721
- "Honduras",
722
- "Jamaica",
723
- "Martinique",
724
- "Mexico",
725
- "Montserrat",
726
- "Nicaragua",
727
- "Panama",
728
- "Paraguay",
729
- "Peru",
730
- "Puerto Rico",
731
- "Saint Kitts and Nevis",
732
- "Saint Lucia",
733
- "Saint Vincent and the Grenadines",
734
- "Suriname",
735
- "Trinidad and Tobago",
736
- "Turks and Caicos Islands",
737
- "United States",
738
- "United States Virgin Islands",
739
- "Uruguay",
740
- "Venezuela",
741
- ],
742
- Antarctica: ["French Southern And Antarctic Lands"],
743
- Asia: [
744
- "Afghanistan",
745
- "Armenia",
746
- "Azerbaijan",
747
- "Bahrain",
748
- "Bangladesh",
749
- "Bhutan",
750
- "Brunei Darussalam",
751
- "Cambodia",
752
- "China",
753
- "East Timor",
754
- "Georgia",
755
- "Hong Kong",
756
- "India",
757
- "Indonesia",
758
- "Iran",
759
- "Iraq",
760
- "Israel",
761
- "Japan",
762
- "Jordan",
763
- "Kazakhstan",
764
- "Kuwait",
765
- "Kyrgyzstan",
766
- "Laos",
767
- "Lebanon",
768
- "Macao",
769
- "Malaysia",
770
- "Maldives",
771
- "Mongolia",
772
- "Myanmar",
773
- "Nepal",
774
- "Palestine",
775
- "Oman",
776
- "Pakistan",
777
- "Palestinian Territories",
778
- "Philippines",
779
- "Qatar",
780
- "Russia",
781
- "Saudi Arabia",
782
- "Singapore",
783
- "South Korea",
784
- "Sri Lanka",
785
- "Syria",
786
- "Taiwan",
787
- "Tajikistan",
788
- "Turkey",
789
- "Thailand",
790
- "Turkmenistan",
791
- "United Arab Emirates",
792
- "Uzbekistan",
793
- "Vietnam",
794
- "Yemen",
795
- ],
796
- Europe: [
797
- "Albania",
798
- "Andorra",
799
- "Austria",
800
- "Belarus",
801
- "Belgium",
802
- "Bosnia and Herzegovina",
803
- "Bulgaria",
804
- "Croatia",
805
- "Cyprus",
806
- "Czech Republic",
807
- "Denmark",
808
- "Estonia",
809
- "Faroe Islands",
810
- "Finland",
811
- "France",
812
- "Germany",
813
- "Gibraltar",
814
- "Greece",
815
- "Guernsey",
816
- "Hungary",
817
- "Iceland",
818
- "Ireland",
819
- "Isle of Man",
820
- "Italy",
821
- "Jersey",
822
- "Latvia",
823
- "Liechtenstein",
824
- "Lithuania",
825
- "Luxembourg",
826
- "Malta",
827
- "Moldova",
828
- "Monaco",
829
- "Montenegro",
830
- "Netherlands",
831
- "Macedonia",
832
- "Norway",
833
- "Poland",
834
- "Portugal",
835
- "Romania",
836
- "San Marino",
837
- "Serbia",
838
- "Slovakia",
839
- "Slovenia",
840
- "Spain",
841
- "Sweden",
842
- "Switzerland",
843
- "Ukraine",
844
- "United Kingdom",
845
- "Vatican City",
846
- ],
847
- Oceania: [
848
- "American Samoa",
849
- "Australia",
850
- "Cook Islands",
851
- "Fiji",
852
- "French Polynesia",
853
- "Guam",
854
- "Kiribati",
855
- "Marshall Islands",
856
- "Micronesia",
857
- "Nauru",
858
- "New Caledonia",
859
- "New Zealand",
860
- "Niue",
861
- "Northern Mariana Islands",
862
- "Palau",
863
- "Papua New Guinea",
864
- "Samoa",
865
- "Solomon Islands",
866
- "Tokelau",
867
- "Tonga",
868
- "Tuvalu",
869
- "Vanuatu",
870
- "Wallis and Futuna",
871
- ],
872
- };
873
-
874
- var util;
875
- (function (util) {
876
- util.assertEqual = (val) => val;
877
- function assertIs(_arg) { }
878
- util.assertIs = assertIs;
879
- function assertNever(_x) {
880
- throw new Error();
881
- }
882
- util.assertNever = assertNever;
883
- util.arrayToEnum = (items) => {
884
- const obj = {};
885
- for (const item of items) {
886
- obj[item] = item;
887
- }
888
- return obj;
889
- };
890
- util.getValidEnumValues = (obj) => {
891
- const validKeys = util.objectKeys(obj).filter((k) => typeof obj[obj[k]] !== "number");
892
- const filtered = {};
893
- for (const k of validKeys) {
894
- filtered[k] = obj[k];
895
- }
896
- return util.objectValues(filtered);
897
- };
898
- util.objectValues = (obj) => {
899
- return util.objectKeys(obj).map(function (e) {
900
- return obj[e];
901
- });
902
- };
903
- util.objectKeys = typeof Object.keys === "function" // eslint-disable-line ban/ban
904
- ? (obj) => Object.keys(obj) // eslint-disable-line ban/ban
905
- : (object) => {
906
- const keys = [];
907
- for (const key in object) {
908
- if (Object.prototype.hasOwnProperty.call(object, key)) {
909
- keys.push(key);
910
- }
911
- }
912
- return keys;
913
- };
914
- util.find = (arr, checker) => {
915
- for (const item of arr) {
916
- if (checker(item))
917
- return item;
918
- }
919
- return undefined;
920
- };
921
- util.isInteger = typeof Number.isInteger === "function"
922
- ? (val) => Number.isInteger(val) // eslint-disable-line ban/ban
923
- : (val) => typeof val === "number" && isFinite(val) && Math.floor(val) === val;
924
- function joinValues(array, separator = " | ") {
925
- return array
926
- .map((val) => (typeof val === "string" ? `'${val}'` : val))
927
- .join(separator);
928
- }
929
- util.joinValues = joinValues;
930
- util.jsonStringifyReplacer = (_, value) => {
931
- if (typeof value === "bigint") {
932
- return value.toString();
933
- }
934
- return value;
935
- };
936
- })(util || (util = {}));
937
- var objectUtil;
938
- (function (objectUtil) {
939
- objectUtil.mergeShapes = (first, second) => {
940
- return {
941
- ...first,
942
- ...second, // second overwrites first
943
- };
944
- };
945
- })(objectUtil || (objectUtil = {}));
946
- const ZodParsedType = util.arrayToEnum([
947
- "string",
948
- "nan",
949
- "number",
950
- "integer",
951
- "float",
952
- "boolean",
953
- "date",
954
- "bigint",
955
- "symbol",
956
- "function",
957
- "undefined",
958
- "null",
959
- "array",
960
- "object",
961
- "unknown",
962
- "promise",
963
- "void",
964
- "never",
965
- "map",
966
- "set",
967
- ]);
968
- const getParsedType = (data) => {
969
- const t = typeof data;
970
- switch (t) {
971
- case "undefined":
972
- return ZodParsedType.undefined;
973
- case "string":
974
- return ZodParsedType.string;
975
- case "number":
976
- return isNaN(data) ? ZodParsedType.nan : ZodParsedType.number;
977
- case "boolean":
978
- return ZodParsedType.boolean;
979
- case "function":
980
- return ZodParsedType.function;
981
- case "bigint":
982
- return ZodParsedType.bigint;
983
- case "symbol":
984
- return ZodParsedType.symbol;
985
- case "object":
986
- if (Array.isArray(data)) {
987
- return ZodParsedType.array;
988
- }
989
- if (data === null) {
990
- return ZodParsedType.null;
991
- }
992
- if (data.then &&
993
- typeof data.then === "function" &&
994
- data.catch &&
995
- typeof data.catch === "function") {
996
- return ZodParsedType.promise;
997
- }
998
- if (typeof Map !== "undefined" && data instanceof Map) {
999
- return ZodParsedType.map;
1000
- }
1001
- if (typeof Set !== "undefined" && data instanceof Set) {
1002
- return ZodParsedType.set;
1003
- }
1004
- if (typeof Date !== "undefined" && data instanceof Date) {
1005
- return ZodParsedType.date;
1006
- }
1007
- return ZodParsedType.object;
1008
- default:
1009
- return ZodParsedType.unknown;
1010
- }
1011
- };
1012
-
1013
- const ZodIssueCode = util.arrayToEnum([
1014
- "invalid_type",
1015
- "invalid_literal",
1016
- "custom",
1017
- "invalid_union",
1018
- "invalid_union_discriminator",
1019
- "invalid_enum_value",
1020
- "unrecognized_keys",
1021
- "invalid_arguments",
1022
- "invalid_return_type",
1023
- "invalid_date",
1024
- "invalid_string",
1025
- "too_small",
1026
- "too_big",
1027
- "invalid_intersection_types",
1028
- "not_multiple_of",
1029
- "not_finite",
1030
- ]);
1031
- const quotelessJson = (obj) => {
1032
- const json = JSON.stringify(obj, null, 2);
1033
- return json.replace(/"([^"]+)":/g, "$1:");
1034
- };
1035
- class ZodError extends Error {
1036
- get errors() {
1037
- return this.issues;
1038
- }
1039
- constructor(issues) {
1040
- super();
1041
- this.issues = [];
1042
- this.addIssue = (sub) => {
1043
- this.issues = [...this.issues, sub];
1044
- };
1045
- this.addIssues = (subs = []) => {
1046
- this.issues = [...this.issues, ...subs];
1047
- };
1048
- const actualProto = new.target.prototype;
1049
- if (Object.setPrototypeOf) {
1050
- // eslint-disable-next-line ban/ban
1051
- Object.setPrototypeOf(this, actualProto);
1052
- }
1053
- else {
1054
- this.__proto__ = actualProto;
1055
- }
1056
- this.name = "ZodError";
1057
- this.issues = issues;
1058
- }
1059
- format(_mapper) {
1060
- const mapper = _mapper ||
1061
- function (issue) {
1062
- return issue.message;
1063
- };
1064
- const fieldErrors = { _errors: [] };
1065
- const processError = (error) => {
1066
- for (const issue of error.issues) {
1067
- if (issue.code === "invalid_union") {
1068
- issue.unionErrors.map(processError);
1069
- }
1070
- else if (issue.code === "invalid_return_type") {
1071
- processError(issue.returnTypeError);
1072
- }
1073
- else if (issue.code === "invalid_arguments") {
1074
- processError(issue.argumentsError);
1075
- }
1076
- else if (issue.path.length === 0) {
1077
- fieldErrors._errors.push(mapper(issue));
1078
- }
1079
- else {
1080
- let curr = fieldErrors;
1081
- let i = 0;
1082
- while (i < issue.path.length) {
1083
- const el = issue.path[i];
1084
- const terminal = i === issue.path.length - 1;
1085
- if (!terminal) {
1086
- curr[el] = curr[el] || { _errors: [] };
1087
- // if (typeof el === "string") {
1088
- // curr[el] = curr[el] || { _errors: [] };
1089
- // } else if (typeof el === "number") {
1090
- // const errorArray: any = [];
1091
- // errorArray._errors = [];
1092
- // curr[el] = curr[el] || errorArray;
1093
- // }
1094
- }
1095
- else {
1096
- curr[el] = curr[el] || { _errors: [] };
1097
- curr[el]._errors.push(mapper(issue));
1098
- }
1099
- curr = curr[el];
1100
- i++;
1101
- }
1102
- }
1103
- }
1104
- };
1105
- processError(this);
1106
- return fieldErrors;
1107
- }
1108
- static assert(value) {
1109
- if (!(value instanceof ZodError)) {
1110
- throw new Error(`Not a ZodError: ${value}`);
1111
- }
1112
- }
1113
- toString() {
1114
- return this.message;
1115
- }
1116
- get message() {
1117
- return JSON.stringify(this.issues, util.jsonStringifyReplacer, 2);
1118
- }
1119
- get isEmpty() {
1120
- return this.issues.length === 0;
1121
- }
1122
- flatten(mapper = (issue) => issue.message) {
1123
- const fieldErrors = {};
1124
- const formErrors = [];
1125
- for (const sub of this.issues) {
1126
- if (sub.path.length > 0) {
1127
- fieldErrors[sub.path[0]] = fieldErrors[sub.path[0]] || [];
1128
- fieldErrors[sub.path[0]].push(mapper(sub));
1129
- }
1130
- else {
1131
- formErrors.push(mapper(sub));
1132
- }
1133
- }
1134
- return { formErrors, fieldErrors };
1135
- }
1136
- get formErrors() {
1137
- return this.flatten();
1138
- }
1139
- }
1140
- ZodError.create = (issues) => {
1141
- const error = new ZodError(issues);
1142
- return error;
1143
- };
1144
-
1145
- const errorMap = (issue, _ctx) => {
1146
- let message;
1147
- switch (issue.code) {
1148
- case ZodIssueCode.invalid_type:
1149
- if (issue.received === ZodParsedType.undefined) {
1150
- message = "Required";
1151
- }
1152
- else {
1153
- message = `Expected ${issue.expected}, received ${issue.received}`;
1154
- }
1155
- break;
1156
- case ZodIssueCode.invalid_literal:
1157
- message = `Invalid literal value, expected ${JSON.stringify(issue.expected, util.jsonStringifyReplacer)}`;
1158
- break;
1159
- case ZodIssueCode.unrecognized_keys:
1160
- message = `Unrecognized key(s) in object: ${util.joinValues(issue.keys, ", ")}`;
1161
- break;
1162
- case ZodIssueCode.invalid_union:
1163
- message = `Invalid input`;
1164
- break;
1165
- case ZodIssueCode.invalid_union_discriminator:
1166
- message = `Invalid discriminator value. Expected ${util.joinValues(issue.options)}`;
1167
- break;
1168
- case ZodIssueCode.invalid_enum_value:
1169
- message = `Invalid enum value. Expected ${util.joinValues(issue.options)}, received '${issue.received}'`;
1170
- break;
1171
- case ZodIssueCode.invalid_arguments:
1172
- message = `Invalid function arguments`;
1173
- break;
1174
- case ZodIssueCode.invalid_return_type:
1175
- message = `Invalid function return type`;
1176
- break;
1177
- case ZodIssueCode.invalid_date:
1178
- message = `Invalid date`;
1179
- break;
1180
- case ZodIssueCode.invalid_string:
1181
- if (typeof issue.validation === "object") {
1182
- if ("includes" in issue.validation) {
1183
- message = `Invalid input: must include "${issue.validation.includes}"`;
1184
- if (typeof issue.validation.position === "number") {
1185
- message = `${message} at one or more positions greater than or equal to ${issue.validation.position}`;
1186
- }
1187
- }
1188
- else if ("startsWith" in issue.validation) {
1189
- message = `Invalid input: must start with "${issue.validation.startsWith}"`;
1190
- }
1191
- else if ("endsWith" in issue.validation) {
1192
- message = `Invalid input: must end with "${issue.validation.endsWith}"`;
1193
- }
1194
- else {
1195
- util.assertNever(issue.validation);
1196
- }
1197
- }
1198
- else if (issue.validation !== "regex") {
1199
- message = `Invalid ${issue.validation}`;
1200
- }
1201
- else {
1202
- message = "Invalid";
1203
- }
1204
- break;
1205
- case ZodIssueCode.too_small:
1206
- if (issue.type === "array")
1207
- message = `Array must contain ${issue.exact ? "exactly" : issue.inclusive ? `at least` : `more than`} ${issue.minimum} element(s)`;
1208
- else if (issue.type === "string")
1209
- message = `String must contain ${issue.exact ? "exactly" : issue.inclusive ? `at least` : `over`} ${issue.minimum} character(s)`;
1210
- else if (issue.type === "number")
1211
- message = `Number must be ${issue.exact
1212
- ? `exactly equal to `
1213
- : issue.inclusive
1214
- ? `greater than or equal to `
1215
- : `greater than `}${issue.minimum}`;
1216
- else if (issue.type === "date")
1217
- message = `Date must be ${issue.exact
1218
- ? `exactly equal to `
1219
- : issue.inclusive
1220
- ? `greater than or equal to `
1221
- : `greater than `}${new Date(Number(issue.minimum))}`;
1222
- else
1223
- message = "Invalid input";
1224
- break;
1225
- case ZodIssueCode.too_big:
1226
- if (issue.type === "array")
1227
- message = `Array must contain ${issue.exact ? `exactly` : issue.inclusive ? `at most` : `less than`} ${issue.maximum} element(s)`;
1228
- else if (issue.type === "string")
1229
- message = `String must contain ${issue.exact ? `exactly` : issue.inclusive ? `at most` : `under`} ${issue.maximum} character(s)`;
1230
- else if (issue.type === "number")
1231
- message = `Number must be ${issue.exact
1232
- ? `exactly`
1233
- : issue.inclusive
1234
- ? `less than or equal to`
1235
- : `less than`} ${issue.maximum}`;
1236
- else if (issue.type === "bigint")
1237
- message = `BigInt must be ${issue.exact
1238
- ? `exactly`
1239
- : issue.inclusive
1240
- ? `less than or equal to`
1241
- : `less than`} ${issue.maximum}`;
1242
- else if (issue.type === "date")
1243
- message = `Date must be ${issue.exact
1244
- ? `exactly`
1245
- : issue.inclusive
1246
- ? `smaller than or equal to`
1247
- : `smaller than`} ${new Date(Number(issue.maximum))}`;
1248
- else
1249
- message = "Invalid input";
1250
- break;
1251
- case ZodIssueCode.custom:
1252
- message = `Invalid input`;
1253
- break;
1254
- case ZodIssueCode.invalid_intersection_types:
1255
- message = `Intersection results could not be merged`;
1256
- break;
1257
- case ZodIssueCode.not_multiple_of:
1258
- message = `Number must be a multiple of ${issue.multipleOf}`;
1259
- break;
1260
- case ZodIssueCode.not_finite:
1261
- message = "Number must be finite";
1262
- break;
1263
- default:
1264
- message = _ctx.defaultError;
1265
- util.assertNever(issue);
1266
- }
1267
- return { message };
1268
- };
1269
-
1270
- let overrideErrorMap = errorMap;
1271
- function setErrorMap(map) {
1272
- overrideErrorMap = map;
1273
- }
1274
- function getErrorMap() {
1275
- return overrideErrorMap;
1276
- }
1277
-
1278
- const makeIssue = (params) => {
1279
- const { data, path, errorMaps, issueData } = params;
1280
- const fullPath = [...path, ...(issueData.path || [])];
1281
- const fullIssue = {
1282
- ...issueData,
1283
- path: fullPath,
1284
- };
1285
- if (issueData.message !== undefined) {
1286
- return {
1287
- ...issueData,
1288
- path: fullPath,
1289
- message: issueData.message,
1290
- };
1291
- }
1292
- let errorMessage = "";
1293
- const maps = errorMaps
1294
- .filter((m) => !!m)
1295
- .slice()
1296
- .reverse();
1297
- for (const map of maps) {
1298
- errorMessage = map(fullIssue, { data, defaultError: errorMessage }).message;
1299
- }
1300
- return {
1301
- ...issueData,
1302
- path: fullPath,
1303
- message: errorMessage,
1304
- };
1305
- };
1306
- const EMPTY_PATH = [];
1307
- function addIssueToContext(ctx, issueData) {
1308
- const overrideMap = getErrorMap();
1309
- const issue = makeIssue({
1310
- issueData: issueData,
1311
- data: ctx.data,
1312
- path: ctx.path,
1313
- errorMaps: [
1314
- ctx.common.contextualErrorMap, // contextual error map is first priority
1315
- ctx.schemaErrorMap, // then schema-bound map if available
1316
- overrideMap, // then global override map
1317
- overrideMap === errorMap ? undefined : errorMap, // then global default map
1318
- ].filter((x) => !!x),
1319
- });
1320
- ctx.common.issues.push(issue);
1321
- }
1322
- class ParseStatus {
1323
- constructor() {
1324
- this.value = "valid";
1325
- }
1326
- dirty() {
1327
- if (this.value === "valid")
1328
- this.value = "dirty";
1329
- }
1330
- abort() {
1331
- if (this.value !== "aborted")
1332
- this.value = "aborted";
1333
- }
1334
- static mergeArray(status, results) {
1335
- const arrayValue = [];
1336
- for (const s of results) {
1337
- if (s.status === "aborted")
1338
- return INVALID$3;
1339
- if (s.status === "dirty")
1340
- status.dirty();
1341
- arrayValue.push(s.value);
1342
- }
1343
- return { status: status.value, value: arrayValue };
1344
- }
1345
- static async mergeObjectAsync(status, pairs) {
1346
- const syncPairs = [];
1347
- for (const pair of pairs) {
1348
- const key = await pair.key;
1349
- const value = await pair.value;
1350
- syncPairs.push({
1351
- key,
1352
- value,
1353
- });
1354
- }
1355
- return ParseStatus.mergeObjectSync(status, syncPairs);
1356
- }
1357
- static mergeObjectSync(status, pairs) {
1358
- const finalObject = {};
1359
- for (const pair of pairs) {
1360
- const { key, value } = pair;
1361
- if (key.status === "aborted")
1362
- return INVALID$3;
1363
- if (value.status === "aborted")
1364
- return INVALID$3;
1365
- if (key.status === "dirty")
1366
- status.dirty();
1367
- if (value.status === "dirty")
1368
- status.dirty();
1369
- if (key.value !== "__proto__" &&
1370
- (typeof value.value !== "undefined" || pair.alwaysSet)) {
1371
- finalObject[key.value] = value.value;
1372
- }
1373
- }
1374
- return { status: status.value, value: finalObject };
1375
- }
1376
- }
1377
- const INVALID$3 = Object.freeze({
1378
- status: "aborted",
1379
- });
1380
- const DIRTY = (value) => ({ status: "dirty", value });
1381
- const OK = (value) => ({ status: "valid", value });
1382
- const isAborted = (x) => x.status === "aborted";
1383
- const isDirty = (x) => x.status === "dirty";
1384
- const isValid = (x) => x.status === "valid";
1385
- const isAsync = (x) => typeof Promise !== "undefined" && x instanceof Promise;
1386
-
1387
- /******************************************************************************
1388
- Copyright (c) Microsoft Corporation.
1389
-
1390
- Permission to use, copy, modify, and/or distribute this software for any
1391
- purpose with or without fee is hereby granted.
1392
-
1393
- THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
1394
- REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
1395
- AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
1396
- INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
1397
- LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
1398
- OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
1399
- PERFORMANCE OF THIS SOFTWARE.
1400
- ***************************************************************************** */
1401
-
1402
- function __classPrivateFieldGet(receiver, state, kind, f) {
1403
- if (typeof state === "function" ? receiver !== state || true : !state.has(receiver)) throw new TypeError("Cannot read private member from an object whose class did not declare it");
1404
- return state.get(receiver);
1405
- }
1406
-
1407
- function __classPrivateFieldSet(receiver, state, value, kind, f) {
1408
- if (typeof state === "function" ? receiver !== state || true : !state.has(receiver)) throw new TypeError("Cannot write private member to an object whose class did not declare it");
1409
- return (state.set(receiver, value)), value;
1410
- }
1411
-
1412
- typeof SuppressedError === "function" ? SuppressedError : function (error, suppressed, message) {
1413
- var e = new Error(message);
1414
- return e.name = "SuppressedError", e.error = error, e.suppressed = suppressed, e;
1415
- };
1416
-
1417
- var errorUtil;
1418
- (function (errorUtil) {
1419
- errorUtil.errToObj = (message) => typeof message === "string" ? { message } : message || {};
1420
- errorUtil.toString = (message) => typeof message === "string" ? message : message === null || message === void 0 ? void 0 : message.message;
1421
- })(errorUtil || (errorUtil = {}));
1422
-
1423
- var _ZodEnum_cache, _ZodNativeEnum_cache;
1424
- class ParseInputLazyPath {
1425
- constructor(parent, value, path, key) {
1426
- this._cachedPath = [];
1427
- this.parent = parent;
1428
- this.data = value;
1429
- this._path = path;
1430
- this._key = key;
1431
- }
1432
- get path() {
1433
- if (!this._cachedPath.length) {
1434
- if (this._key instanceof Array) {
1435
- this._cachedPath.push(...this._path, ...this._key);
1436
- }
1437
- else {
1438
- this._cachedPath.push(...this._path, this._key);
1439
- }
1440
- }
1441
- return this._cachedPath;
1442
- }
1443
- }
1444
- const handleResult = (ctx, result) => {
1445
- if (isValid(result)) {
1446
- return { success: true, data: result.value };
1447
- }
1448
- else {
1449
- if (!ctx.common.issues.length) {
1450
- throw new Error("Validation failed but no issues detected.");
1451
- }
1452
- return {
1453
- success: false,
1454
- get error() {
1455
- if (this._error)
1456
- return this._error;
1457
- const error = new ZodError(ctx.common.issues);
1458
- this._error = error;
1459
- return this._error;
1460
- },
1461
- };
1462
- }
550
+ var _ZodEnum_cache, _ZodNativeEnum_cache;
551
+ class ParseInputLazyPath {
552
+ constructor(parent, value, path, key) {
553
+ this._cachedPath = [];
554
+ this.parent = parent;
555
+ this.data = value;
556
+ this._path = path;
557
+ this._key = key;
558
+ }
559
+ get path() {
560
+ if (!this._cachedPath.length) {
561
+ if (this._key instanceof Array) {
562
+ this._cachedPath.push(...this._path, ...this._key);
563
+ }
564
+ else {
565
+ this._cachedPath.push(...this._path, this._key);
566
+ }
567
+ }
568
+ return this._cachedPath;
569
+ }
570
+ }
571
+ const handleResult = (ctx, result) => {
572
+ if (isValid(result)) {
573
+ return { success: true, data: result.value };
574
+ }
575
+ else {
576
+ if (!ctx.common.issues.length) {
577
+ throw new Error("Validation failed but no issues detected.");
578
+ }
579
+ return {
580
+ success: false,
581
+ get error() {
582
+ if (this._error)
583
+ return this._error;
584
+ const error = new ZodError(ctx.common.issues);
585
+ this._error = error;
586
+ return this._error;
587
+ },
588
+ };
589
+ }
1463
590
  };
1464
591
  function processCreateParams(params) {
1465
592
  if (!params)
@@ -5272,109 +4399,6 @@ var z = /*#__PURE__*/Object.freeze({
5272
4399
  ZodError: ZodError
5273
4400
  });
5274
4401
 
5275
- const accountStatusSchema = z.enum([
5276
- 'pending_credentials_verification',
5277
- 'valid_credentials',
5278
- 'invalid_credentials',
5279
- ]);
5280
-
5281
- // Enum definitions for fixed options
5282
- const projectDurationEnum = z.enum(JOB_FILTER_OPTIONS.PROJECT_DURATION);
5283
- const engagementTypeEnum = z.enum(JOB_FILTER_OPTIONS.ENGAGEMENT_TYPE);
5284
- const vendorTypeEnum = z.enum(JOB_FILTER_OPTIONS.VENDOR_TYPE);
5285
- const paymentTypeEnum = z.enum(JOB_FILTER_OPTIONS.PAYMENT_TYPE);
5286
- const categoryEnum = z.enum(JOB_FILTER_OPTIONS.CATEGORIES);
5287
- const clientIndustryEnum = z.enum(JOB_FILTER_OPTIONS.CLIENT_INDUSTRY);
5288
- const clientSizeEnum = z.enum(JOB_FILTER_OPTIONS.CLIENT_SIZE);
5289
- const talentTypeEnum = z.enum(JOB_FILTER_OPTIONS.TALENT_TYPE);
5290
- const englishLevelEnum = z.enum(JOB_FILTER_OPTIONS.ENGLISH_LEVELS);
5291
- const experienceLevelEnum = z.enum(JOB_FILTER_OPTIONS.EXPERIENCE_LEVELS);
5292
- const regionEnum = z.enum(JOB_FILTER_OPTIONS.REGIONS);
5293
- const requiredEarningsEnum = z.union([
5294
- z.literal(100),
5295
- z.literal(1000),
5296
- z.literal(10000),
5297
- ]);
5298
- const requiredJSSEnum = z.enum(JOB_FILTER_OPTIONS.REQUIRED_JSS);
5299
- const isPaymentVerifiedEnum = z.enum(['all', 'true', 'false']);
5300
- const isPhoneVerifiedEnum = z.enum(['all', 'true', 'false']);
5301
- const hasQuestionsEnum = z.enum(['all', 'yes', 'no']);
5302
- const searchQueryModeEnum = z.enum(['builder', 'custom']);
5303
- // Main job filters schema
5304
- const jobFiltersSchema = z.object({
5305
- keywords: z
5306
- .object({
5307
- includes: z.string().nullable(),
5308
- excludes: z.string().nullable(),
5309
- })
5310
- .nullable(),
5311
- searchQuery: z.string().nullable(),
5312
- searchQueryMode: searchQueryModeEnum.nullable().optional(),
5313
- isFeatured: z.enum(['all', 'true', 'false']).nullable(),
5314
- regions: z.array(regionEnum).nullable(),
5315
- categories: z
5316
- .object({
5317
- includes: z.array(categoryEnum).nullable(),
5318
- excludes: z.array(categoryEnum).nullable(),
5319
- })
5320
- .nullable(),
5321
- payment: z
5322
- .object({
5323
- paymentType: z.array(paymentTypeEnum).nullable(),
5324
- minFixedPrice: z.number().nullable(),
5325
- maxFixedPrice: z.number().nullable(),
5326
- minHourlyRate: z.number().nullable(),
5327
- maxHourlyRate: z.number().nullable(),
5328
- })
5329
- .nullable(),
5330
- projectDuration: z.array(projectDurationEnum).nullable(),
5331
- experienceLevel: z.array(experienceLevelEnum).nullable(),
5332
- questions: z
5333
- .object({
5334
- hasQuestions: z.array(hasQuestionsEnum),
5335
- })
5336
- .nullable(),
5337
- engagementType: z.array(engagementTypeEnum).nullable(),
5338
- clientInfo: z
5339
- .object({
5340
- isPaymentVerified: isPaymentVerifiedEnum.default('all'),
5341
- isPhoneVerified: isPhoneVerifiedEnum.default('all'),
5342
- enterpriseClient: z.enum(['all', 'true', 'false']).default('all'),
5343
- clientLocationIncludes: z.array(z.string()).nullable(),
5344
- clientLocationExcludes: z.array(z.string()).nullable(),
5345
- minReviewScore: z.number().min(0).max(5).nullable(),
5346
- maxReviewScore: z.number().min(0).max(5).nullable(),
5347
- minTotalSpent: z.number().min(0).nullable(),
5348
- maxTotalSpent: z.number().min(0).nullable(),
5349
- minHireRate: z.number().min(0).max(100).nullable(),
5350
- maxHireRate: z.number().min(0).max(100).nullable(),
5351
- clientIndustry: z.array(clientIndustryEnum).nullable(),
5352
- companySize: z.array(clientSizeEnum).nullable(),
5353
- minJobsPosted: z.number().nullable(),
5354
- minAvgHourlyRate: z.number().nullable(),
5355
- maxAvgHourlyRate: z.number().nullable(),
5356
- minNumReviews: z.number().nullable(),
5357
- memberSinceFrom: z.string().date().nullable(),
5358
- memberSinceTo: z.string().date().nullable(),
5359
- })
5360
- .nullable(),
5361
- includeClientsWithZeroReviews: z.boolean().nullable(),
5362
- includeClientsWithLessThanXPostedJobs: z.number().nullable(),
5363
- totalSpentIncludeClientsWithLessThanXPostedJobs: z.number().nullable(),
5364
- averageHourlyRateIncludeClientsWithLessThanXPostedJobs: z.number().nullable(),
5365
- vendorQualifications: z
5366
- .object({
5367
- locationIncludes: z.array(z.string()).nullable(),
5368
- locationExcludes: z.array(z.string()).nullable(),
5369
- talentTypes: z.array(talentTypeEnum).nullable(),
5370
- englishLevels: z.array(englishLevelEnum).nullable(),
5371
- includeRisingTalent: z.string().nullable(),
5372
- requiredEarnings: requiredEarningsEnum.nullable(),
5373
- requiredJSS: z.array(requiredJSSEnum).nullable(),
5374
- })
5375
- .nullable(),
5376
- });
5377
-
5378
4402
  const booleanSchema = z
5379
4403
  .union([z.boolean(), z.literal('true'), z.literal('false')])
5380
4404
  .transform((value) => value === true || value === 'true');
@@ -5682,6 +4706,389 @@ const nuxtStateJobSchema = objectType({
5682
4706
  talentFeePromotion: booleanType().nullish(),
5683
4707
  });
5684
4708
 
4709
+ const JOB_FILTER_OPTIONS = {
4710
+ REGIONS: ['Worldwide', 'USOnly', 'UKOnly', 'All'],
4711
+ PROJECT_DURATION: [
4712
+ 'Less than 1 month',
4713
+ '1 to 3 months',
4714
+ '3 to 6 months',
4715
+ 'More than 6 months',
4716
+ 'Unspecified',
4717
+ ],
4718
+ ENGAGEMENT_TYPE: [
4719
+ 'Less than 30 hrs/week',
4720
+ 'More than 30 hrs/week',
4721
+ 'Unspecified',
4722
+ ],
4723
+ VENDOR_TYPE: ['Independent', 'Agency', 'Unspecified'],
4724
+ PAYMENT_TYPE: ['Unspecified', 'Hourly', 'Fixed-price'],
4725
+ TALENT_TYPE: ['Agency', 'Independent', 'Unspecified'],
4726
+ ENGLISH_LEVELS: [
4727
+ 'Fluent',
4728
+ 'Conversational',
4729
+ 'Native or Bilingual',
4730
+ 'Unspecified',
4731
+ ],
4732
+ EXPERIENCE_LEVELS: ['Entry level', 'Intermediate', 'Expert'],
4733
+ REQUIRED_EARNINGS: [100, 1000, 10000],
4734
+ REQUIRED_JSS: ['>80%', '>90%', '100%', 'RT'],
4735
+ HIERARCHICAL_CATEGORIES: [
4736
+ {
4737
+ label: 'Accounting & Consulting',
4738
+ value: 'accounting-consulting',
4739
+ children: [
4740
+ 'Accounting & Bookkeeping',
4741
+ 'Financial Planning',
4742
+ 'Management Consulting & Analysis',
4743
+ 'Other - Accounting & Consulting',
4744
+ 'Personal & Professional Coaching',
4745
+ 'Recruiting & Human Resources',
4746
+ ],
4747
+ },
4748
+ {
4749
+ label: 'Admin Support',
4750
+ value: 'admin-support',
4751
+ children: [
4752
+ 'Data Entry & Transcription Services',
4753
+ 'Market Research & Product Reviews',
4754
+ 'Project Management',
4755
+ 'Virtual Assistance',
4756
+ ],
4757
+ },
4758
+ {
4759
+ label: 'Customer Service',
4760
+ value: 'customer-service',
4761
+ children: [
4762
+ 'Community Management & Tagging',
4763
+ 'Customer Service & Tech Support',
4764
+ ],
4765
+ },
4766
+ {
4767
+ label: 'Data Science & Analytics',
4768
+ value: 'data-science-analytics',
4769
+ children: [
4770
+ 'AI & Machine Learning',
4771
+ 'Data Analysis & Testing',
4772
+ 'Data Extraction/ETL',
4773
+ 'Data Mining & Management',
4774
+ ],
4775
+ },
4776
+ {
4777
+ label: 'Design & Creative',
4778
+ value: 'design-creative',
4779
+ children: [
4780
+ 'Art & Illustration',
4781
+ 'Audio & Music Production',
4782
+ 'Branding & Logo Design',
4783
+ 'Graphic, Editorial & Presentation Design',
4784
+ 'NFT, AR/VR & Game Art',
4785
+ 'Performing Arts',
4786
+ 'Photography',
4787
+ 'Product Design',
4788
+ 'Video & Animation',
4789
+ ],
4790
+ },
4791
+ {
4792
+ label: 'Engineering & Architecture',
4793
+ value: 'engineering-architecture',
4794
+ children: [
4795
+ '3D Modeling & CAD',
4796
+ 'Building & Landscape Architecture',
4797
+ 'Chemical Engineering',
4798
+ 'Civil & Structural Engineering',
4799
+ 'Contract Manufacturing',
4800
+ 'Electrical & Electronic Engineering',
4801
+ 'Energy & Mechanical Engineering',
4802
+ ],
4803
+ },
4804
+ {
4805
+ label: 'IT & Networking',
4806
+ value: 'it-networking',
4807
+ children: [
4808
+ 'Database Management & Administration',
4809
+ 'DevOps & Solution Architecture',
4810
+ 'ERP/CRM Software',
4811
+ 'Information Security & Compliance',
4812
+ 'Network & System Administration',
4813
+ ],
4814
+ },
4815
+ {
4816
+ label: 'Legal',
4817
+ value: 'legal',
4818
+ children: [
4819
+ 'Corporate & Contract Law',
4820
+ 'Finance & Tax Law',
4821
+ 'International & Immigration Law',
4822
+ 'Public Law',
4823
+ ],
4824
+ },
4825
+ {
4826
+ label: 'Sales & Marketing',
4827
+ value: 'sales-marketing',
4828
+ children: [
4829
+ 'Digital Marketing',
4830
+ 'Lead Generation & Telemarketing',
4831
+ 'Marketing, PR & Brand Strategy',
4832
+ ],
4833
+ },
4834
+ {
4835
+ label: 'Translation',
4836
+ value: 'translation',
4837
+ children: [
4838
+ 'Language Tutoring & Interpretation',
4839
+ 'Translation & Localization Services',
4840
+ ],
4841
+ },
4842
+ {
4843
+ label: 'Software Development',
4844
+ value: 'software-development',
4845
+ children: [
4846
+ 'AI Apps & Integration',
4847
+ 'Blockchain, NFT & Cryptocurrency',
4848
+ 'Desktop Application Development',
4849
+ 'Ecommerce Development',
4850
+ 'Game Design & Development',
4851
+ 'Mobile Development',
4852
+ 'Other - Software Development',
4853
+ 'Product Management & Scrum',
4854
+ 'QA Testing',
4855
+ 'Scripts & Utilities',
4856
+ 'Web & Mobile Design',
4857
+ 'Web Development',
4858
+ ],
4859
+ },
4860
+ {
4861
+ label: 'Writing',
4862
+ value: 'writing',
4863
+ children: [
4864
+ 'Content Writing',
4865
+ 'Editing & Proofreading Services',
4866
+ 'Professional & Business Writing',
4867
+ 'Sales & Marketing Copywriting',
4868
+ ],
4869
+ },
4870
+ ],
4871
+ CATEGORIES: [
4872
+ 'Interior & Trade Show Design',
4873
+ 'Physical Sciences',
4874
+ 'Personal & Professional Coaching',
4875
+ 'Accounting & Bookkeeping',
4876
+ 'Financial Planning',
4877
+ 'Recruiting & Human Resources',
4878
+ 'Management Consulting & Analysis',
4879
+ 'Other - Accounting & Consulting',
4880
+ 'Data Entry & Transcription Services',
4881
+ 'Virtual Assistance',
4882
+ 'Project Management',
4883
+ 'Market Research & Product Reviews',
4884
+ 'Community Management & Tagging',
4885
+ 'Customer Service & Tech Support',
4886
+ 'Data Analysis & Testing',
4887
+ 'Data Extraction/ETL',
4888
+ 'Data Mining & Management',
4889
+ 'AI & Machine Learning',
4890
+ 'Art & Illustration',
4891
+ 'Audio & Music Production',
4892
+ 'Branding & Logo Design',
4893
+ 'NFT, AR/VR & Game Art',
4894
+ 'Graphic, Editorial & Presentation Design',
4895
+ 'Performing Arts',
4896
+ 'Photography',
4897
+ 'Product Design',
4898
+ 'Video & Animation',
4899
+ 'Building & Landscape Architecture',
4900
+ 'Chemical Engineering',
4901
+ 'Civil & Structural Engineering',
4902
+ 'Contract Manufacturing',
4903
+ 'Electrical & Electronic Engineering',
4904
+ 'Energy & Mechanical Engineering',
4905
+ '3D Modeling & CAD',
4906
+ 'Database Management & Administration',
4907
+ 'ERP/CRM Software',
4908
+ 'Information Security & Compliance',
4909
+ 'Network & System Administration',
4910
+ 'DevOps & Solution Architecture',
4911
+ 'Corporate & Contract Law',
4912
+ 'International & Immigration Law',
4913
+ 'Finance & Tax Law',
4914
+ 'Public Law',
4915
+ 'Digital Marketing',
4916
+ 'Lead Generation & Telemarketing',
4917
+ 'Marketing, PR & Brand Strategy',
4918
+ 'Language Tutoring & Interpretation',
4919
+ 'Translation & Localization Services',
4920
+ 'Blockchain, NFT & Cryptocurrency',
4921
+ 'AI Apps & Integration',
4922
+ 'Desktop Application Development',
4923
+ 'Ecommerce Development',
4924
+ 'Game Design & Development',
4925
+ 'Mobile Development',
4926
+ 'Other - Software Development',
4927
+ 'Product Management & Scrum',
4928
+ 'QA Testing',
4929
+ 'Scripts & Utilities',
4930
+ 'Web & Mobile Design',
4931
+ 'Web Development',
4932
+ 'Sales & Marketing Copywriting',
4933
+ 'Content Writing',
4934
+ 'Editing & Proofreading Services',
4935
+ 'Professional & Business Writing',
4936
+ ],
4937
+ CLIENT_INDUSTRY: [
4938
+ 'Aerospace',
4939
+ 'Agriculture & Forestry',
4940
+ 'Art & Design',
4941
+ 'Automotive',
4942
+ 'Aviation',
4943
+ 'Education',
4944
+ 'Energy & Utilities',
4945
+ 'Engineering & Architecture',
4946
+ 'Fashion & Beauty',
4947
+ 'Finance & Accounting',
4948
+ 'Food & Beverage',
4949
+ 'Government & Public Sector',
4950
+ 'Health & Fitness',
4951
+ 'HR & Business Services',
4952
+ 'Legal',
4953
+ 'Manufacturing & Construction',
4954
+ 'Media & Entertainment',
4955
+ 'Military & Defense',
4956
+ 'Mining',
4957
+ 'Real Estate',
4958
+ 'Retail & Consumer Goods',
4959
+ 'Sales & Marketing',
4960
+ 'Science & Medicine',
4961
+ 'Sports & Recreation',
4962
+ 'Supply Chain & Logistics',
4963
+ 'Tech & IT',
4964
+ 'Transportation & Warehousing',
4965
+ 'Travel & Hospitality',
4966
+ ],
4967
+ CLIENT_SIZE: [
4968
+ 'Individual client',
4969
+ 'Small company (2-9 people)',
4970
+ 'Mid-sized company (10-99 people)',
4971
+ 'Large company (100-1,000 people)',
4972
+ 'Large company (1,000+ people)',
4973
+ 'Unspecified',
4974
+ ],
4975
+ };
4976
+ const HIERARCHICAL_CATEGORIES_TO_CHILDREN = JOB_FILTER_OPTIONS.HIERARCHICAL_CATEGORIES.reduce((acc, category) => {
4977
+ acc[category.label] = category.children;
4978
+ return acc;
4979
+ }, {});
4980
+ const regionNames = {
4981
+ Worldwide: 'Worldwide',
4982
+ USOnly: 'US Only',
4983
+ UKOnly: 'UK Only',
4984
+ All: 'All',
4985
+ };
4986
+ const CLIENT_SIZE_TO_NUMBER = {
4987
+ 'Individual client': 1,
4988
+ 'Small company (2-9 people)': 2,
4989
+ 'Mid-sized company (10-99 people)': 10,
4990
+ 'Large company (100-1,000 people)': 100,
4991
+ 'Large company (1,000+ people)': 1000,
4992
+ Unspecified: null,
4993
+ };
4994
+
4995
+ // Enum definitions for fixed options
4996
+ const projectDurationEnum = z.enum(JOB_FILTER_OPTIONS.PROJECT_DURATION);
4997
+ const engagementTypeEnum = z.enum(JOB_FILTER_OPTIONS.ENGAGEMENT_TYPE);
4998
+ const vendorTypeEnum = z.enum(JOB_FILTER_OPTIONS.VENDOR_TYPE);
4999
+ const paymentTypeEnum = z.enum(JOB_FILTER_OPTIONS.PAYMENT_TYPE);
5000
+ const categoryEnum = z.enum(JOB_FILTER_OPTIONS.CATEGORIES);
5001
+ const clientIndustryEnum = z.enum(JOB_FILTER_OPTIONS.CLIENT_INDUSTRY);
5002
+ const clientSizeEnum = z.enum(JOB_FILTER_OPTIONS.CLIENT_SIZE);
5003
+ const talentTypeEnum = z.enum(JOB_FILTER_OPTIONS.TALENT_TYPE);
5004
+ const englishLevelEnum = z.enum(JOB_FILTER_OPTIONS.ENGLISH_LEVELS);
5005
+ const experienceLevelEnum = z.enum(JOB_FILTER_OPTIONS.EXPERIENCE_LEVELS);
5006
+ const regionEnum = z.enum(JOB_FILTER_OPTIONS.REGIONS);
5007
+ const requiredEarningsEnum = z.union([
5008
+ z.literal(100),
5009
+ z.literal(1000),
5010
+ z.literal(10000),
5011
+ ]);
5012
+ const requiredJSSEnum = z.enum(JOB_FILTER_OPTIONS.REQUIRED_JSS);
5013
+ const isPaymentVerifiedEnum = z.enum(['all', 'true', 'false']);
5014
+ const isPhoneVerifiedEnum = z.enum(['all', 'true', 'false']);
5015
+ const hasQuestionsEnum = z.enum(['all', 'yes', 'no']);
5016
+ const searchQueryModeEnum = z.enum(['builder', 'custom']);
5017
+ // Main job filters schema
5018
+ const jobFiltersSchema = z.object({
5019
+ keywords: z
5020
+ .object({
5021
+ includes: z.string().nullable(),
5022
+ excludes: z.string().nullable(),
5023
+ })
5024
+ .nullable(),
5025
+ searchQuery: z.string().nullable(),
5026
+ searchQueryMode: searchQueryModeEnum.nullable().optional(),
5027
+ isFeatured: z.enum(['all', 'true', 'false']).nullable(),
5028
+ regions: z.array(regionEnum).nullable(),
5029
+ categories: z
5030
+ .object({
5031
+ includes: z.array(categoryEnum).nullable(),
5032
+ excludes: z.array(categoryEnum).nullable(),
5033
+ })
5034
+ .nullable(),
5035
+ payment: z
5036
+ .object({
5037
+ paymentType: z.array(paymentTypeEnum).nullable(),
5038
+ minFixedPrice: z.number().nullable(),
5039
+ maxFixedPrice: z.number().nullable(),
5040
+ minHourlyRate: z.number().nullable(),
5041
+ maxHourlyRate: z.number().nullable(),
5042
+ })
5043
+ .nullable(),
5044
+ projectDuration: z.array(projectDurationEnum).nullable(),
5045
+ experienceLevel: z.array(experienceLevelEnum).nullable(),
5046
+ questions: z
5047
+ .object({
5048
+ hasQuestions: z.array(hasQuestionsEnum),
5049
+ })
5050
+ .nullable(),
5051
+ engagementType: z.array(engagementTypeEnum).nullable(),
5052
+ clientInfo: z
5053
+ .object({
5054
+ isPaymentVerified: isPaymentVerifiedEnum.default('all'),
5055
+ isPhoneVerified: isPhoneVerifiedEnum.default('all'),
5056
+ enterpriseClient: z.enum(['all', 'true', 'false']).default('all'),
5057
+ clientLocationIncludes: z.array(z.string()).nullable(),
5058
+ clientLocationExcludes: z.array(z.string()).nullable(),
5059
+ minReviewScore: z.number().min(0).max(5).nullable(),
5060
+ maxReviewScore: z.number().min(0).max(5).nullable(),
5061
+ minTotalSpent: z.number().min(0).nullable(),
5062
+ maxTotalSpent: z.number().min(0).nullable(),
5063
+ minHireRate: z.number().min(0).max(100).nullable(),
5064
+ maxHireRate: z.number().min(0).max(100).nullable(),
5065
+ clientIndustry: z.array(clientIndustryEnum).nullable(),
5066
+ companySize: z.array(clientSizeEnum).nullable(),
5067
+ minJobsPosted: z.number().nullable(),
5068
+ minAvgHourlyRate: z.number().nullable(),
5069
+ maxAvgHourlyRate: z.number().nullable(),
5070
+ minNumReviews: z.number().nullable(),
5071
+ memberSinceFrom: z.string().date().nullable(),
5072
+ memberSinceTo: z.string().date().nullable(),
5073
+ })
5074
+ .nullable(),
5075
+ includeClientsWithZeroReviews: z.boolean().nullable(),
5076
+ includeClientsWithLessThanXPostedJobs: z.number().nullable(),
5077
+ totalSpentIncludeClientsWithLessThanXPostedJobs: z.number().nullable(),
5078
+ averageHourlyRateIncludeClientsWithLessThanXPostedJobs: z.number().nullable(),
5079
+ vendorQualifications: z
5080
+ .object({
5081
+ locationIncludes: z.array(z.string()).nullable(),
5082
+ locationExcludes: z.array(z.string()).nullable(),
5083
+ talentTypes: z.array(talentTypeEnum).nullable(),
5084
+ englishLevels: z.array(englishLevelEnum).nullable(),
5085
+ includeRisingTalent: z.string().nullable(),
5086
+ requiredEarnings: requiredEarningsEnum.nullable(),
5087
+ requiredJSS: z.array(requiredJSSEnum).nullable(),
5088
+ })
5089
+ .nullable(),
5090
+ });
5091
+
5685
5092
  // Filter Option Schema
5686
5093
  const filterOptionItemSchema = z.object({
5687
5094
  key: z.string(),
@@ -6313,94 +5720,830 @@ const bidRangeSchema = objectType({
6313
5720
  avg: numberType().nullable(),
6314
5721
  low: numberType().nullable(),
6315
5722
  });
6316
- const jobActivitySchema = objectType({
6317
- proposals: objectType({
6318
- min: numberType().nullable(),
6319
- max: numberType().nullable(),
6320
- }),
6321
- lastViewedByClient: stringType().nullable(),
6322
- lastViewedByClientTimestamp: numberType().nullable(),
6323
- hires: numberType().nullable(),
6324
- interviewing: numberType().nullable(),
6325
- invitesSent: numberType().nullable(),
6326
- unansweredInvites: numberType().nullable(),
6327
- updatedAt: numberType().nullable(),
5723
+ const jobActivitySchema = objectType({
5724
+ proposals: objectType({
5725
+ min: numberType().nullable(),
5726
+ max: numberType().nullable(),
5727
+ }),
5728
+ lastViewedByClient: stringType().nullable(),
5729
+ lastViewedByClientTimestamp: numberType().nullable(),
5730
+ hires: numberType().nullable(),
5731
+ interviewing: numberType().nullable(),
5732
+ invitesSent: numberType().nullable(),
5733
+ unansweredInvites: numberType().nullable(),
5734
+ updatedAt: numberType().nullable(),
5735
+ });
5736
+ const jobActivityDeltaSchema = objectType({
5737
+ proposals: numberType(),
5738
+ interviewing: numberType(),
5739
+ hires: numberType(),
5740
+ invitesSent: numberType(),
5741
+ unansweredInvites: numberType(),
5742
+ });
5743
+ const metadataSchema = objectType({
5744
+ hours: stringType().nullable(),
5745
+ duration: stringType().nullable(),
5746
+ experienceLevel: stringType().nullable(),
5747
+ hourlyRate: z
5748
+ .object({
5749
+ min: numberType().nullable(),
5750
+ max: numberType().nullable(),
5751
+ })
5752
+ .nullable(),
5753
+ paymentType: stringType().nullable(),
5754
+ fixedPrice: numberType().nullable(),
5755
+ });
5756
+ const jobActivityOffsetHours = [4, 24];
5757
+ const jobActivityOffsetEnum = z.enum(jobActivityOffsetHours.map((h) => `${h}h`));
5758
+ const upworkJobSchema = objectType({
5759
+ id: stringType().nullable(),
5760
+ uid: stringType().nullable(),
5761
+ createdAt: numberType().nullable(),
5762
+ title: stringType().nullable(),
5763
+ category: stringType().nullable(),
5764
+ skills: arrayType(jobSkillsSchema).nullable(),
5765
+ datetime: numberType().nullable(),
5766
+ description: stringType().nullable(),
5767
+ descriptionLength: numberType().nullable(),
5768
+ connectsRequired: numberType().nullable(),
5769
+ projectType: stringType().nullable(),
5770
+ projectDuration: stringType().nullable(),
5771
+ questions: arrayType(stringType()).nullable(),
5772
+ jobUrl: stringType().nullable(),
5773
+ metadata: metadataSchema.nullable(),
5774
+ clientInfo: clientInfoSchema.nullable(),
5775
+ vendorQualifications: vendorQualificationSchema.nullable(),
5776
+ processed: booleanType().nullable(),
5777
+ isFeatured: booleanType().nullable(),
5778
+ clientReviews: arrayType(clientReviewSchema).nullable(),
5779
+ region: regionSchema.nullable(),
5780
+ bidRange: bidRangeSchema.nullable(),
5781
+ jobActivity: jobActivitySchema.nullable(),
5782
+ occupation: stringType().nullable(),
5783
+ activityUpdates: z
5784
+ .union([z.literal(1), z.literal(2), z.literal(3)])
5785
+ .nullable(),
5786
+ activity: recordType(jobActivityOffsetEnum, jobActivitySchema).nullish(),
5787
+ activityDelta: jobActivityDeltaSchema.nullish(),
5788
+ });
5789
+ const jobActivityOffsetHourSchema = custom((val) => jobActivityOffsetHours.includes(val));
5790
+ const jobActivityUpdateSchema = objectType({
5791
+ jobUrl: stringType(),
5792
+ data: jobActivitySchema,
5793
+ offsetHour: jobActivityOffsetHourSchema,
5794
+ scrapedAt: numberType(),
5795
+ });
5796
+ const jobActivitySnapshotSchema = objectType({
5797
+ jobUrl: stringType(),
5798
+ activity: jobActivitySchema,
5799
+ postedAt: numberType(),
5800
+ scrapedAt: numberType(),
5801
+ hoursSincePosted: numberType(),
5802
+ });
5803
+ const feedJobSchema = objectType({
5804
+ uid: stringType().nullable(),
5805
+ title: stringType().nullable(),
5806
+ jobUrl: stringType().nullable(),
5807
+ datetime: stringType().nullable(),
5808
+ isFeatured: booleanType().nullable(),
5809
+ region: regionSchema.nullable(),
5810
+ });
5811
+
5812
+ const roomNoteSchema = z.object({
5813
+ note: z.string().nullable(),
5814
+ createdAt: z.number(),
5815
+ updatedAt: z.number(),
5816
+ });
5817
+ const roomCrmStatusEnum = z.enum([
5818
+ 'new',
5819
+ 'follow_up',
5820
+ 'qualified',
5821
+ 'won',
5822
+ 'archived',
5823
+ ]);
5824
+ const roomCrmArchivedReasonEnum = z.enum([
5825
+ 'completed',
5826
+ 'not_fit',
5827
+ 'lost',
5828
+ 'no_response',
5829
+ 'other',
5830
+ ]);
5831
+ const pipelineColumnSchema = z.object({
5832
+ id: z.string(),
5833
+ label: z.string(),
5834
+ color: z.string(),
5835
+ position: z.number(),
5836
+ });
5837
+ const roomJobClientHistorySchema = z.object({
5838
+ jobUrl: z.string().nullable(),
5839
+ title: z.string().nullable(),
5840
+ campaignId: z.string().nullable().optional(),
5841
+ clientInfo: clientInfoSchema.nullable(),
5842
+ });
5843
+ const roomSchema = z.object({
5844
+ id: z.string(),
5845
+ roomId: z.string(),
5846
+ roomName: z.string(),
5847
+ topic: z.string(),
5848
+ organizationUid: z.string(),
5849
+ organizationType: z.string(),
5850
+ recentTimestamp: z.number(),
5851
+ organizationName: z.string(),
5852
+ context: z.object({
5853
+ freelancerId: z.string(),
5854
+ freelancerOrgId: z.string(),
5855
+ freelancerName: z.string().optional(),
5856
+ clientId: z.string().optional(),
5857
+ clientName: z.string().optional(),
5858
+ jobTitle: z.string().optional(),
5859
+ currentStatus: z.string().optional(),
5860
+ associatedAgencyOrgId: z.string().optional(),
5861
+ }),
5862
+ numUnread: z.number(),
5863
+ latestStory: z
5864
+ .object({
5865
+ message: z.string(),
5866
+ created: z.number(),
5867
+ messageId: z.string().optional(),
5868
+ senderName: z.string().optional(),
5869
+ })
5870
+ .optional(),
5871
+ lastChecked: z.number().optional(),
5872
+ hasNewMessages: z.boolean().optional(),
5873
+ updatedAt: z.number().optional(),
5874
+ lastFetchedAt: z.number().optional(),
5875
+ roomTypeExtended: z.string().optional(),
5876
+ roomNote: roomNoteSchema.optional(),
5877
+ crmStatus: z.string().optional(),
5878
+ crmStatusUpdatedAt: z.number().optional(),
5879
+ crmArchivedReason: roomCrmArchivedReasonEnum.optional().nullable(),
5880
+ dealValue: z.number().nullable().optional(),
5881
+ jobClientHistory: roomJobClientHistorySchema.optional(),
5882
+ });
5883
+ const roomsMetadataSchema = z.object({
5884
+ accountId: z.string(),
5885
+ lastUpdated: z.number(),
5886
+ totalRooms: z.number(),
5887
+ });
5888
+ const roomMessageSchema = z
5889
+ .object({
5890
+ messageId: z.string(),
5891
+ userId: z.string(),
5892
+ message: z.string(),
5893
+ created: z.number(),
5894
+ userName: z.string().optional(),
5895
+ orgId: z.string().optional(),
5896
+ senderName: z.string().optional(),
5897
+ attachmentUrl: z.string().optional(),
5898
+ startedPreparingDownloadAt: z.number().optional(),
5899
+ })
5900
+ .passthrough();
5901
+ const getRoomsResponseSchema = z.object({
5902
+ data: z.array(roomSchema),
5903
+ pagination: z.object({
5904
+ hasMore: z.boolean(),
5905
+ nextCursor: z.string().nullable(),
5906
+ limit: z.number(),
5907
+ total: z.number(),
5908
+ }),
5909
+ });
5910
+ const getPipelineListRoomsResponseSchema = z.object({
5911
+ data: z.array(roomSchema.extend({ bidderAccountId: z.string() })),
5912
+ pagination: z.object({
5913
+ hasMore: z.boolean(),
5914
+ nextCursor: z.string().nullable(),
5915
+ limit: z.number(),
5916
+ total: z.number(),
5917
+ }),
5918
+ });
5919
+ const roomTagSchema = z.object({
5920
+ id: z.string(),
5921
+ name: z.string(),
5922
+ color: z.string().optional(),
5923
+ createdAt: z.number(),
5924
+ updatedAt: z.number().optional(),
5925
+ });
5926
+ const createRoomTagRequestBodySchema = z.object({
5927
+ name: z.string(),
5928
+ color: z.string().optional(),
5929
+ });
5930
+ const assignRoomTagsRequestBodySchema = z.object({
5931
+ tagIds: z.array(z.string()),
5932
+ });
5933
+ const updateRoomNotesRequestBodySchema = z.object({
5934
+ note: z.string(),
5935
+ });
5936
+ const updateRoomCrmStatusRequestBodySchema = z.object({
5937
+ status: z.string(),
5938
+ archivedReason: roomCrmArchivedReasonEnum.optional(),
5939
+ });
5940
+ const updateRoomDealValueRequestBodySchema = z.object({
5941
+ dealValue: z.number().nullable(),
6328
5942
  });
6329
- const jobActivityDeltaSchema = objectType({
6330
- proposals: numberType(),
6331
- interviewing: numberType(),
6332
- hires: numberType(),
6333
- invitesSent: numberType(),
6334
- unansweredInvites: numberType(),
5943
+ const roomTaskSchema = z.object({
5944
+ id: z.string(),
5945
+ roomId: z.string(),
5946
+ title: z.string(),
5947
+ completed: z.boolean(),
5948
+ dueDate: z.number().nullable().optional(),
5949
+ createdAt: z.number(),
5950
+ updatedAt: z.number().optional(),
5951
+ completedAt: z.number().nullable().optional(),
5952
+ organizationId: z.string(),
5953
+ bidderAccountId: z.string(),
6335
5954
  });
6336
- const metadataSchema = objectType({
6337
- hours: stringType().nullable(),
6338
- duration: stringType().nullable(),
6339
- experienceLevel: stringType().nullable(),
6340
- hourlyRate: z
6341
- .object({
6342
- min: numberType().nullable(),
6343
- max: numberType().nullable(),
6344
- })
6345
- .nullable(),
6346
- paymentType: stringType().nullable(),
6347
- fixedPrice: numberType().nullable(),
5955
+ const createRoomTaskRequestBodySchema = z.object({
5956
+ title: z.string(),
5957
+ dueDate: z.number().nullable().optional(),
6348
5958
  });
6349
- const jobActivityOffsetHours = [4, 24];
6350
- const jobActivityOffsetEnum = z.enum(jobActivityOffsetHours.map((h) => `${h}h`));
6351
- const upworkJobSchema = objectType({
6352
- id: stringType().nullable(),
6353
- uid: stringType().nullable(),
6354
- createdAt: numberType().nullable(),
6355
- title: stringType().nullable(),
6356
- category: stringType().nullable(),
6357
- skills: arrayType(jobSkillsSchema).nullable(),
6358
- datetime: numberType().nullable(),
6359
- description: stringType().nullable(),
6360
- descriptionLength: numberType().nullable(),
6361
- connectsRequired: numberType().nullable(),
6362
- projectType: stringType().nullable(),
6363
- projectDuration: stringType().nullable(),
6364
- questions: arrayType(stringType()).nullable(),
6365
- jobUrl: stringType().nullable(),
6366
- metadata: metadataSchema.nullable(),
6367
- clientInfo: clientInfoSchema.nullable(),
6368
- vendorQualifications: vendorQualificationSchema.nullable(),
6369
- processed: booleanType().nullable(),
6370
- isFeatured: booleanType().nullable(),
6371
- clientReviews: arrayType(clientReviewSchema).nullable(),
6372
- region: regionSchema.nullable(),
6373
- bidRange: bidRangeSchema.nullable(),
6374
- jobActivity: jobActivitySchema.nullable(),
6375
- occupation: stringType().nullable(),
6376
- activityUpdates: z
6377
- .union([z.literal(1), z.literal(2), z.literal(3)])
6378
- .nullable(),
6379
- activity: recordType(jobActivityOffsetEnum, jobActivitySchema).nullish(),
6380
- activityDelta: jobActivityDeltaSchema.nullish(),
5959
+ const updateRoomTaskRequestBodySchema = z.object({
5960
+ title: z.string().optional(),
5961
+ completed: z.boolean().optional(),
5962
+ dueDate: z.number().nullable().optional(),
6381
5963
  });
6382
- const jobActivityOffsetHourSchema = custom((val) => jobActivityOffsetHours.includes(val));
6383
- const jobActivityUpdateSchema = objectType({
6384
- jobUrl: stringType(),
6385
- data: jobActivitySchema,
6386
- offsetHour: jobActivityOffsetHourSchema,
6387
- scrapedAt: numberType(),
5964
+ const updatePipelineColumnsRequestBodySchema = z.object({
5965
+ columns: z.array(pipelineColumnSchema),
6388
5966
  });
6389
- const jobActivitySnapshotSchema = objectType({
6390
- jobUrl: stringType(),
6391
- activity: jobActivitySchema,
6392
- postedAt: numberType(),
6393
- scrapedAt: numberType(),
6394
- hoursSincePosted: numberType(),
5967
+ const sendMessageRequestSchema = z.object({
5968
+ message: z.string(),
5969
+ file: z.instanceof(File).optional(),
6395
5970
  });
6396
- const feedJobSchema = objectType({
6397
- uid: stringType().nullable(),
6398
- title: stringType().nullable(),
6399
- jobUrl: stringType().nullable(),
6400
- datetime: stringType().nullable(),
6401
- isFeatured: booleanType().nullable(),
6402
- region: regionSchema.nullable(),
5971
+ const freeSlotsRequestBodySchema = z.object({
5972
+ userId: z.string(),
5973
+ durationMinutes: z.number(),
6403
5974
  });
5975
+ const bookSlotRequestBodySchema = z.object({
5976
+ ownerUid: z.string(),
5977
+ duration: z.number(),
5978
+ platform: z.string(),
5979
+ startTime: z.number(),
5980
+ endTime: z.number(),
5981
+ });
5982
+
5983
+ const ROOM_EXTENDED_TYPE_MAP = {
5984
+ proposal: ['fl-proposal'],
5985
+ dm: ['direct_message'],
5986
+ invite: ['client-invitation', 'direct_hire_FL_profile'],
5987
+ };
5988
+ const ROOM_TYPES_MATCHING_EMPTY_EXTENDED_TYPE = new Set([
5989
+ 'proposal',
5990
+ ]);
5991
+ // Pipeline column colors available for user selection
5992
+ const PIPELINE_COLUMN_COLORS = [
5993
+ 'blue',
5994
+ 'emerald',
5995
+ 'amber',
5996
+ 'violet',
5997
+ 'slate',
5998
+ 'rose',
5999
+ 'cyan',
6000
+ 'orange',
6001
+ 'indigo',
6002
+ 'pink',
6003
+ ];
6004
+ const DEFAULT_PIPELINE_COLUMNS = [
6005
+ { id: 'new', label: 'New', color: 'blue', position: 0 },
6006
+ { id: 'qualified', label: 'Qualified', color: 'emerald', position: 1 },
6007
+ { id: 'follow_up', label: 'Follow Up', color: 'amber', position: 2 },
6008
+ { id: 'won', label: 'Active Contract', color: 'violet', position: 3 },
6009
+ { id: 'completed', label: 'Completed', color: 'slate', position: 4 },
6010
+ ];
6011
+ const DEFAULT_PIPELINE_COLUMN_ID = 'new';
6012
+ const DEFAULT_ROOM_CRM_STATUS = DEFAULT_PIPELINE_COLUMN_ID;
6013
+ // Statuses whose deal value is excluded from pipeline totals
6014
+ const PIPELINE_DEAL_VALUE_EXCLUDED_COLUMN_IDS = ['new'];
6015
+ const ROOM_CRM_ARCHIVED_REASON_ORDER = roomCrmArchivedReasonEnum.options;
6016
+ const VALID_CRM_STATUSES = new Set([
6017
+ ...roomCrmStatusEnum.options,
6018
+ 'completed',
6019
+ 'in_conversation',
6020
+ 'active_contract',
6021
+ ]);
6022
+ function normalizeRoomCrmStatus(status) {
6023
+ if (status && VALID_CRM_STATUSES.has(status)) {
6024
+ return status;
6025
+ }
6026
+ return 'new';
6027
+ }
6028
+ const PIPELINE_LIST_SORT_FIELDS = [
6029
+ 'recentTimestamp',
6030
+ 'dealValue',
6031
+ 'totalSpent',
6032
+ 'memberSince',
6033
+ 'hireRate',
6034
+ 'rating',
6035
+ 'avgRate',
6036
+ ];
6037
+ function normalizeRoomCrmStatuses(statuses) {
6038
+ if (!statuses || !statuses.length) {
6039
+ return [];
6040
+ }
6041
+ return Array.from(new Set(statuses
6042
+ .map((s) => s.trim().toLowerCase())
6043
+ .filter((s) => VALID_CRM_STATUSES.has(s))));
6044
+ }
6045
+
6046
+ const defaultQuestions = [
6047
+ {
6048
+ question: 'What is your company website URL?',
6049
+ answer: '',
6050
+ exampleAnswer: 'Website: www.yourwebsite.com',
6051
+ },
6052
+ {
6053
+ question: 'Please list any certifications that you have',
6054
+ answer: '',
6055
+ exampleAnswer: 'AWS Certified Solutions Architect\nGoogle Cloud Certified Professional Developer\nMicrosoft Certified: Azure Developer Associate\nCertified Scrum Master (CSM)',
6056
+ },
6057
+ {
6058
+ question: 'What past project or job have you had that is most like this one and why?',
6059
+ answer: "{{PROJECT}} is definitely the closest match - we {{ACTION}} their {{TYPE}} from scratch {{DETAIL}}. The {{CHALLENGE}} was particularly challenging since we needed {{REQUIREMENT}}. Very similar {{ASPECT}} to what you're looking for.",
6060
+ exampleAnswer: "{{PROJECT}} is definitely the closest match - we {{ACTION}} their {{TYPE}} from scratch {{DETAIL}}. The {{CHALLENGE}} was particularly challenging since we needed {{REQUIREMENT}}. Very similar {{ASPECT}} to what you're looking for.",
6061
+ },
6062
+ {
6063
+ question: 'What tools/frameworks/methods have you worked with?',
6064
+ answer: 'For {{AREA}}, we primarily use {{TOOL}} and {{METHOD}}. For {{AREA}}, we use {{TOOL}}. For the {{PROJECT}} project I mentioned, we used this exact approach and it worked really well for {{OUTCOME}}. We typically {{METHOD}} depending on client needs.',
6065
+ exampleAnswer: 'For {{AREA}}, we primarily use {{TOOL}} and {{METHOD}}. For {{AREA}}, we use {{TOOL}}. For the {{PROJECT}} project I mentioned, we used this exact approach and it worked really well for {{OUTCOME}}. We typically {{METHOD}} depending on client needs.',
6066
+ },
6067
+ {
6068
+ question: 'Do you have suggestions to make this project run successfully?',
6069
+ answer: "Based on our experience with {{PROJECT}}, I'd suggest starting with {{APPROACH}} to {{BENEFIT}}. {{INSIGHT}}, and we've found that {{LESSON}} saves {{BENEFIT}} later. Our team's experience in {{DOMAIN}} makes us a good fit here.",
6070
+ exampleAnswer: "Based on our experience with {{PROJECT}}, I'd suggest starting with {{APPROACH}} to {{BENEFIT}}. {{INSIGHT}}, and we've found that {{LESSON}} saves {{BENEFIT}} later. Our team's experience in {{DOMAIN}} makes us a good fit here.",
6071
+ },
6072
+ {
6073
+ question: 'Why do you think you are a good fit for this particular project?',
6074
+ answer: "Based on our experience with {{PROJECT}}, I'd suggest starting with {{APPROACH}} to {{BENEFIT}}. {{INSIGHT}}, and we've found that {{LESSON}} saves {{BENEFIT}} later. Our team's experience in {{DOMAIN}} makes us a good fit here.",
6075
+ exampleAnswer: "Based on our experience with {{PROJECT}}, I'd suggest starting with {{APPROACH}} to {{BENEFIT}}. {{INSIGHT}}, and we've found that {{LESSON}} saves {{BENEFIT}} later. Our team's experience in {{DOMAIN}} makes us a good fit here.",
6076
+ },
6077
+ {
6078
+ question: 'Do you have any questions about the job description?',
6079
+ answer: "I'm curious about {{QUESTION}}? Also, are you looking to {{REQUIREMENT}} that we should have experience with? This would help us better understand the scope.",
6080
+ exampleAnswer: "I'm curious about {{QUESTION}}? Also, are you looking to {{REQUIREMENT}} that we should have experience with? This would help us better understand the scope.",
6081
+ },
6082
+ {
6083
+ question: 'How would you approach this type of project?',
6084
+ answer: "For projects like this, we start by {{STEP}}, focusing on {{FACTOR}}. From {{PROJECT}}, we learned that {{INSIGHT}} can drive {{TYPE}}, such as {{RESULT}}. We'd adapt this approach based on your specific goals and requirements.",
6085
+ exampleAnswer: "For projects like this, we start by {{STEP}}, focusing on {{FACTOR}}. From {{PROJECT}}, we learned that {{INSIGHT}} can drive {{TYPE}}, such as {{RESULT}}. We'd adapt this approach based on your specific goals and requirements.",
6086
+ },
6087
+ ];
6088
+
6089
+ const GOAT_COUNTRIES = [
6090
+ 'USA',
6091
+ 'United States',
6092
+ 'United Kingdom',
6093
+ 'CAN',
6094
+ 'Canada',
6095
+ 'AUS',
6096
+ 'Australia',
6097
+ 'ISR',
6098
+ 'Israel',
6099
+ 'United Arab Emirates',
6100
+ 'Singapore',
6101
+ 'Switzerland',
6102
+ 'Saudi Arabia',
6103
+ 'CHN',
6104
+ 'China',
6105
+ 'Austria',
6106
+ 'BEL',
6107
+ 'Belgium',
6108
+ 'Bulgaria',
6109
+ 'Croatia',
6110
+ 'CYP',
6111
+ 'Cyprus',
6112
+ 'CZH',
6113
+ 'Czech Republic',
6114
+ 'Denmark',
6115
+ 'Estonia',
6116
+ 'FIN',
6117
+ 'Finland',
6118
+ 'FRA',
6119
+ 'France',
6120
+ 'DEU',
6121
+ 'Germany',
6122
+ 'Greece',
6123
+ 'HUN',
6124
+ 'Hungry',
6125
+ 'Ireland',
6126
+ 'Italy',
6127
+ 'Latvia',
6128
+ 'Lithuania',
6129
+ 'LUX',
6130
+ 'Luxhembourg',
6131
+ 'Malta',
6132
+ 'Netherlands',
6133
+ 'POL',
6134
+ 'Poland',
6135
+ 'Portugal',
6136
+ 'Romania',
6137
+ 'Slovakia',
6138
+ 'Slovenia',
6139
+ 'Spain',
6140
+ 'SWE',
6141
+ 'Sweden',
6142
+ 'Norway',
6143
+ 'New Zealand',
6144
+ 'GBR',
6145
+ 'NLD',
6146
+ 'Qatar',
6147
+ 'SGP',
6148
+ 'ESP',
6149
+ 'ITA',
6150
+ 'Puerto Rico',
6151
+ 'Costa Rica',
6152
+ 'Iceland',
6153
+ 'QAT',
6154
+ 'Monaco',
6155
+ ];
6156
+
6157
+ const invoiceStatusNames = {
6158
+ open: "Open",
6159
+ paid: "Paid",
6160
+ past_due: "Past Due",
6161
+ payment_failed: "Payment Failed",
6162
+ };
6163
+
6164
+ const jobStatusOrder = [
6165
+ "leads",
6166
+ "contacted",
6167
+ "viewed",
6168
+ "replied",
6169
+ "won",
6170
+ ];
6171
+ const getPreviousStatus = (status) => {
6172
+ if (status === "won")
6173
+ return "replied";
6174
+ const index = jobStatusOrder.indexOf(status);
6175
+ return index > 0 ? jobStatusOrder[index - 1] : null;
6176
+ };
6177
+ const getNextStatus = (status) => {
6178
+ const index = jobStatusOrder.indexOf(status);
6179
+ return index < jobStatusOrder.length - 1 ? jobStatusOrder[index + 1] : null;
6180
+ };
6181
+
6182
+ const countryMapping = {
6183
+ USA: "United States",
6184
+ GBR: "United Kingdom",
6185
+ AUS: "Australia",
6186
+ CAN: "Canada",
6187
+ IND: "India",
6188
+ NLD: "Netherlands",
6189
+ ARE: "United Arab Emirates",
6190
+ DEU: "Germany",
6191
+ SAU: "Saudi Arabia",
6192
+ FRA: "France",
6193
+ TUR: "Turkey",
6194
+ CHE: "Switzerland",
6195
+ ISR: "Israel",
6196
+ ITA: "Italy",
6197
+ ESP: "Spain",
6198
+ PAK: "Pakistan",
6199
+ SGP: "Singapore",
6200
+ KAZ: "Kazakhstan",
6201
+ UKR: "Ukraine",
6202
+ IRL: "Ireland",
6203
+ SWE: "Sweden",
6204
+ ZAF: "South Africa",
6205
+ CHN: "China",
6206
+ NOR: "Norway",
6207
+ POL: "Poland",
6208
+ COL: "Colombia",
6209
+ NZL: "New Zealand",
6210
+ ROU: "Romania",
6211
+ BRA: "Brazil",
6212
+ GRC: "Greece",
6213
+ BGR: "Bulgaria",
6214
+ DNK: "Denmark",
6215
+ PHL: "Philippines",
6216
+ BEL: "Belgium",
6217
+ AUT: "Austria",
6218
+ HKG: "Hong Kong",
6219
+ QAT: "Qatar",
6220
+ BGD: "Bangladesh",
6221
+ PRT: "Portugal",
6222
+ CYP: "Cyprus",
6223
+ LKA: "Sri Lanka",
6224
+ NGA: "Nigeria",
6225
+ VNM: "Vietnam",
6226
+ JPN: "Japan",
6227
+ LVA: "Latvia",
6228
+ THA: "Thailand",
6229
+ CZE: "Czech Republic",
6230
+ MEX: "Mexico",
6231
+ EGY: "Egypt",
6232
+ KEN: "Kenya",
6233
+ KWT: "Kuwait",
6234
+ CHL: "Chile",
6235
+ EST: "Estonia",
6236
+ UZB: "Uzbekistan",
6237
+ FIN: "Finland",
6238
+ HRV: "Croatia",
6239
+ HUN: "Hungary",
6240
+ KOR: "South Korea",
6241
+ LTU: "Lithuania",
6242
+ PRI: "Puerto Rico",
6243
+ ALB: "Albania",
6244
+ BHR: "Bahrain",
6245
+ GEO: "Georgia",
6246
+ GTM: "Guatemala",
6247
+ IDN: "Indonesia",
6248
+ LBN: "Lebanon",
6249
+ UGA: "Uganda",
6250
+ ARG: "Argentina",
6251
+ ARM: "Armenia",
6252
+ BMU: "Bermuda",
6253
+ CRI: "Costa Rica",
6254
+ CYM: "Cayman Islands",
6255
+ GHA: "Ghana",
6256
+ ISL: "Iceland",
6257
+ JOR: "Jordan",
6258
+ LUX: "Luxembourg",
6259
+ MAR: "Morocco",
6260
+ MKD: "Macedonia",
6261
+ MLT: "Malta",
6262
+ MYS: "Malaysia",
6263
+ OMN: "Oman",
6264
+ SRB: "Serbia",
6265
+ TWN: "Taiwan",
6266
+ BHS: "Bahamas",
6267
+ DZA: "Algeria",
6268
+ ETH: "Ethiopia",
6269
+ GUY: "Guyana",
6270
+ PAN: "Panama",
6271
+ PER: "Peru",
6272
+ SVK: "Slovakia",
6273
+ SVN: "Slovenia",
6274
+ TTO: "Trinidad and Tobago",
6275
+ URY: "Uruguay",
6276
+ VEN: "Venezuela",
6277
+ VIR: "Virgin Islands",
6278
+ ABW: "Aruba",
6279
+ CMR: "Cameroon",
6280
+ CUW: "Curaçao",
6281
+ GIB: "Gibraltar",
6282
+ HND: "Honduras",
6283
+ JAM: "Jamaica",
6284
+ JEY: "Jersey",
6285
+ MDV: "Maldives",
6286
+ MUS: "Mauritius",
6287
+ TUN: "Tunisia",
6288
+ RUS: "Russia",
6289
+ IRN: "Iran",
6290
+ IRQ: "Iraq",
6291
+ AZE: "Azerbaijan",
6292
+ CIV: "Cote d'Ivoire",
6293
+ PSE: "Palestine",
6294
+ MNE: "Montenegro",
6295
+ BIH: "Bosnia and Herzegovina",
6296
+ IMN: "Isle of Man",
6297
+ PNG: "Papua New Guinea",
6298
+ VCT: "Saint Vincent and the Grenadines",
6299
+ VGB: "British Virgin Islands",
6300
+ };
6301
+
6302
+ const regionMapping = {
6303
+ Africa: [
6304
+ "Algeria",
6305
+ "Angola",
6306
+ "Benin",
6307
+ "Botswana",
6308
+ "Burkina Faso",
6309
+ "Burundi",
6310
+ "Cabo Verde",
6311
+ "Cameroon",
6312
+ "Central African Republic",
6313
+ "Chad",
6314
+ "Comoros",
6315
+ "Congo",
6316
+ "Congo, the Democratic Republic of the",
6317
+ "Cote d'Ivoire",
6318
+ "Djibouti",
6319
+ "Egypt",
6320
+ "Equatorial Guinea",
6321
+ "Eritrea",
6322
+ "Eswatini",
6323
+ "Ethiopia",
6324
+ "Gabon",
6325
+ "Gambia",
6326
+ "Ghana",
6327
+ "Guinea",
6328
+ "Guinea-Bissau",
6329
+ "Kenya",
6330
+ "Lesotho",
6331
+ "Liberia",
6332
+ "Libya",
6333
+ "Madagascar",
6334
+ "Malawi",
6335
+ "Mali",
6336
+ "Mauritania",
6337
+ "Mauritius",
6338
+ "Morocco",
6339
+ "Mozambique",
6340
+ "Namibia",
6341
+ "Niger",
6342
+ "Nigeria",
6343
+ "Rwanda",
6344
+ "Sao Tome and Principe",
6345
+ "Senegal",
6346
+ "Seychelles",
6347
+ "Sierra Leone",
6348
+ "Somalia",
6349
+ "South Africa",
6350
+ "South Sudan",
6351
+ "Sudan",
6352
+ "Tanzania",
6353
+ "Togo",
6354
+ "Tunisia",
6355
+ "Uganda",
6356
+ "Zambia",
6357
+ "Zimbabwe",
6358
+ ],
6359
+ Americas: [
6360
+ "Anguilla",
6361
+ "Antigua and Barbuda",
6362
+ "Argentina",
6363
+ "Aruba",
6364
+ "Bahamas",
6365
+ "Barbados",
6366
+ "Belize",
6367
+ "Bermuda",
6368
+ "Bolivia",
6369
+ "Brazil",
6370
+ "British Virgin Islands",
6371
+ "Canada",
6372
+ "Cayman Islands",
6373
+ "Chile",
6374
+ "Colombia",
6375
+ "Costa Rica",
6376
+ "Cuba",
6377
+ "Curacao",
6378
+ "Dominica",
6379
+ "Dominican Republic",
6380
+ "Ecuador",
6381
+ "El Salvador",
6382
+ "Falkland Islands",
6383
+ "French Guiana",
6384
+ "Grenada",
6385
+ "Guadeloupe",
6386
+ "Guatemala",
6387
+ "Guyana",
6388
+ "Haiti",
6389
+ "Honduras",
6390
+ "Jamaica",
6391
+ "Martinique",
6392
+ "Mexico",
6393
+ "Montserrat",
6394
+ "Nicaragua",
6395
+ "Panama",
6396
+ "Paraguay",
6397
+ "Peru",
6398
+ "Puerto Rico",
6399
+ "Saint Kitts and Nevis",
6400
+ "Saint Lucia",
6401
+ "Saint Vincent and the Grenadines",
6402
+ "Suriname",
6403
+ "Trinidad and Tobago",
6404
+ "Turks and Caicos Islands",
6405
+ "United States",
6406
+ "United States Virgin Islands",
6407
+ "Uruguay",
6408
+ "Venezuela",
6409
+ ],
6410
+ Antarctica: ["French Southern And Antarctic Lands"],
6411
+ Asia: [
6412
+ "Afghanistan",
6413
+ "Armenia",
6414
+ "Azerbaijan",
6415
+ "Bahrain",
6416
+ "Bangladesh",
6417
+ "Bhutan",
6418
+ "Brunei Darussalam",
6419
+ "Cambodia",
6420
+ "China",
6421
+ "East Timor",
6422
+ "Georgia",
6423
+ "Hong Kong",
6424
+ "India",
6425
+ "Indonesia",
6426
+ "Iran",
6427
+ "Iraq",
6428
+ "Israel",
6429
+ "Japan",
6430
+ "Jordan",
6431
+ "Kazakhstan",
6432
+ "Kuwait",
6433
+ "Kyrgyzstan",
6434
+ "Laos",
6435
+ "Lebanon",
6436
+ "Macao",
6437
+ "Malaysia",
6438
+ "Maldives",
6439
+ "Mongolia",
6440
+ "Myanmar",
6441
+ "Nepal",
6442
+ "Palestine",
6443
+ "Oman",
6444
+ "Pakistan",
6445
+ "Palestinian Territories",
6446
+ "Philippines",
6447
+ "Qatar",
6448
+ "Russia",
6449
+ "Saudi Arabia",
6450
+ "Singapore",
6451
+ "South Korea",
6452
+ "Sri Lanka",
6453
+ "Syria",
6454
+ "Taiwan",
6455
+ "Tajikistan",
6456
+ "Turkey",
6457
+ "Thailand",
6458
+ "Turkmenistan",
6459
+ "United Arab Emirates",
6460
+ "Uzbekistan",
6461
+ "Vietnam",
6462
+ "Yemen",
6463
+ ],
6464
+ Europe: [
6465
+ "Albania",
6466
+ "Andorra",
6467
+ "Austria",
6468
+ "Belarus",
6469
+ "Belgium",
6470
+ "Bosnia and Herzegovina",
6471
+ "Bulgaria",
6472
+ "Croatia",
6473
+ "Cyprus",
6474
+ "Czech Republic",
6475
+ "Denmark",
6476
+ "Estonia",
6477
+ "Faroe Islands",
6478
+ "Finland",
6479
+ "France",
6480
+ "Germany",
6481
+ "Gibraltar",
6482
+ "Greece",
6483
+ "Guernsey",
6484
+ "Hungary",
6485
+ "Iceland",
6486
+ "Ireland",
6487
+ "Isle of Man",
6488
+ "Italy",
6489
+ "Jersey",
6490
+ "Latvia",
6491
+ "Liechtenstein",
6492
+ "Lithuania",
6493
+ "Luxembourg",
6494
+ "Malta",
6495
+ "Moldova",
6496
+ "Monaco",
6497
+ "Montenegro",
6498
+ "Netherlands",
6499
+ "Macedonia",
6500
+ "Norway",
6501
+ "Poland",
6502
+ "Portugal",
6503
+ "Romania",
6504
+ "San Marino",
6505
+ "Serbia",
6506
+ "Slovakia",
6507
+ "Slovenia",
6508
+ "Spain",
6509
+ "Sweden",
6510
+ "Switzerland",
6511
+ "Ukraine",
6512
+ "United Kingdom",
6513
+ "Vatican City",
6514
+ ],
6515
+ Oceania: [
6516
+ "American Samoa",
6517
+ "Australia",
6518
+ "Cook Islands",
6519
+ "Fiji",
6520
+ "French Polynesia",
6521
+ "Guam",
6522
+ "Kiribati",
6523
+ "Marshall Islands",
6524
+ "Micronesia",
6525
+ "Nauru",
6526
+ "New Caledonia",
6527
+ "New Zealand",
6528
+ "Niue",
6529
+ "Northern Mariana Islands",
6530
+ "Palau",
6531
+ "Papua New Guinea",
6532
+ "Samoa",
6533
+ "Solomon Islands",
6534
+ "Tokelau",
6535
+ "Tonga",
6536
+ "Tuvalu",
6537
+ "Vanuatu",
6538
+ "Wallis and Futuna",
6539
+ ],
6540
+ };
6541
+
6542
+ const accountStatusSchema = z.enum([
6543
+ 'pending_credentials_verification',
6544
+ 'valid_credentials',
6545
+ 'invalid_credentials',
6546
+ ]);
6404
6547
 
6405
6548
  const proxyCountryEnum = z.enum([
6406
6549
  'US',
@@ -8943,133 +9086,6 @@ const syncProposalsStatusRequestPayloadSchema = z.object({
8943
9086
  bidderAccountId: z.string(),
8944
9087
  });
8945
9088
 
8946
- const roomNoteSchema = z.object({
8947
- note: z.string().nullable(),
8948
- createdAt: z.number(),
8949
- updatedAt: z.number(),
8950
- });
8951
- const roomCrmStatusEnum = z.enum([
8952
- 'new',
8953
- 'follow_up',
8954
- 'qualified',
8955
- 'won',
8956
- 'archived',
8957
- ]);
8958
- const roomCrmArchivedReasonEnum = z.enum([
8959
- 'completed',
8960
- 'not_fit',
8961
- 'lost',
8962
- 'no_response',
8963
- 'other',
8964
- ]);
8965
- const roomJobClientHistorySchema = z.object({
8966
- jobUrl: z.string().nullable(),
8967
- title: z.string().nullable(),
8968
- clientInfo: clientInfoSchema.nullable(),
8969
- });
8970
- const roomSchema = z.object({
8971
- id: z.string(),
8972
- roomId: z.string(),
8973
- roomName: z.string(),
8974
- topic: z.string(),
8975
- organizationUid: z.string(),
8976
- organizationType: z.string(),
8977
- recentTimestamp: z.number(),
8978
- organizationName: z.string(),
8979
- context: z.object({
8980
- freelancerId: z.string(),
8981
- freelancerOrgId: z.string(),
8982
- freelancerName: z.string().optional(),
8983
- clientId: z.string().optional(),
8984
- clientName: z.string().optional(),
8985
- jobTitle: z.string().optional(),
8986
- currentStatus: z.string().optional(),
8987
- associatedAgencyOrgId: z.string().optional(),
8988
- }),
8989
- numUnread: z.number(),
8990
- latestStory: z
8991
- .object({
8992
- message: z.string(),
8993
- created: z.number(),
8994
- messageId: z.string().optional(),
8995
- senderName: z.string().optional(),
8996
- })
8997
- .optional(),
8998
- lastChecked: z.number().optional(),
8999
- hasNewMessages: z.boolean().optional(),
9000
- updatedAt: z.number().optional(),
9001
- lastFetchedAt: z.number().optional(),
9002
- roomTypeExtended: z.string().optional(),
9003
- roomNote: roomNoteSchema.optional(),
9004
- crmStatus: roomCrmStatusEnum.optional(),
9005
- crmStatusUpdatedAt: z.number().optional(),
9006
- crmArchivedReason: roomCrmArchivedReasonEnum.optional().nullable(),
9007
- jobClientHistory: roomJobClientHistorySchema.optional(),
9008
- });
9009
- const roomsMetadataSchema = z.object({
9010
- accountId: z.string(),
9011
- lastUpdated: z.number(),
9012
- totalRooms: z.number(),
9013
- });
9014
- const roomMessageSchema = z
9015
- .object({
9016
- messageId: z.string(),
9017
- userId: z.string(),
9018
- message: z.string(),
9019
- created: z.number(),
9020
- userName: z.string().optional(),
9021
- orgId: z.string().optional(),
9022
- senderName: z.string().optional(),
9023
- attachmentUrl: z.string().optional(),
9024
- startedPreparingDownloadAt: z.number().optional(),
9025
- })
9026
- .passthrough();
9027
- const getRoomsResponseSchema = z.object({
9028
- data: z.array(roomSchema),
9029
- pagination: z.object({
9030
- hasMore: z.boolean(),
9031
- nextCursor: z.string().nullable(),
9032
- limit: z.number(),
9033
- total: z.number(),
9034
- }),
9035
- });
9036
- const roomTagSchema = z.object({
9037
- id: z.string(),
9038
- name: z.string(),
9039
- color: z.string().optional(),
9040
- createdAt: z.number(),
9041
- updatedAt: z.number().optional(),
9042
- });
9043
- const createRoomTagRequestBodySchema = z.object({
9044
- name: z.string(),
9045
- color: z.string().optional(),
9046
- });
9047
- const assignRoomTagsRequestBodySchema = z.object({
9048
- tagIds: z.array(z.string()),
9049
- });
9050
- const updateRoomNotesRequestBodySchema = z.object({
9051
- note: z.string(),
9052
- });
9053
- const updateRoomCrmStatusRequestBodySchema = z.object({
9054
- status: roomCrmStatusEnum,
9055
- archivedReason: roomCrmArchivedReasonEnum.optional(),
9056
- });
9057
- const sendMessageRequestSchema = z.object({
9058
- message: z.string(),
9059
- file: z.instanceof(File).optional(),
9060
- });
9061
- const freeSlotsRequestBodySchema = z.object({
9062
- userId: z.string(),
9063
- durationMinutes: z.number(),
9064
- });
9065
- const bookSlotRequestBodySchema = z.object({
9066
- ownerUid: z.string(),
9067
- duration: z.number(),
9068
- platform: z.string(),
9069
- startTime: z.number(),
9070
- endTime: z.number(),
9071
- });
9072
-
9073
9089
  const campaignStatsSchema = z.object({
9074
9090
  contacted: z.number(),
9075
9091
  viewed: z.number(),
@@ -15838,6 +15854,7 @@ const ROUTES = {
15838
15854
  JOBS: {
15839
15855
  BASE: 'jobs',
15840
15856
  BY_ID: (id) => `jobs/${id}`,
15857
+ BY_UID: (uid) => `jobs/by-uid/${uid}`,
15841
15858
  UPDATE_ACTIVITY: `jobs/update-activity`,
15842
15859
  IMPORT: 'jobs/import',
15843
15860
  FILTER_OPTIONS: 'jobs/filter-options',
@@ -15931,7 +15948,18 @@ const ROUTES = {
15931
15948
  TEST_SUITABILITY: 'admin/agent/test-suitability',
15932
15949
  TEST_PROPOSAL: 'admin/agent/test-proposal',
15933
15950
  },
15951
+ UPWORK_INVITATIONS_CONFIG: {
15952
+ BASE: 'admin/upwork-invitation-bucket-account',
15953
+ },
15954
+ BIDDER_INSTANCES: {
15955
+ BASE: 'admin/bidder-instances',
15956
+ BY_ID: (id) => `admin/bidder-instances/${id}`,
15957
+ ASSIGN_ACCOUNTS: (id) => `admin/bidder-instances/${id}/assign-accounts`,
15958
+ UNASSIGN_ACCOUNTS: (id) => `admin/bidder-instances/${id}/unassign-accounts`,
15959
+ SET_DEFAULT: (id) => `admin/bidder-instances/${id}/set-default`,
15960
+ },
15934
15961
  BILLING: {
15962
+ BASE: 'admin/billing',
15935
15963
  PLANS: {
15936
15964
  BASE: 'admin/billing/plans',
15937
15965
  BY_ID: (id) => `admin/billing/plans/${id}`,
@@ -15945,16 +15973,6 @@ const ROUTES = {
15945
15973
  BY_ID: (id) => `admin/billing/features/${id}`,
15946
15974
  },
15947
15975
  },
15948
- UPWORK_INVITATIONS_CONFIG: {
15949
- BASE: 'admin/upwork-invitation-bucket-account',
15950
- },
15951
- BIDDER_INSTANCES: {
15952
- BASE: 'admin/bidder-instances',
15953
- BY_ID: (id) => `admin/bidder-instances/${id}`,
15954
- ASSIGN_ACCOUNTS: (id) => `admin/bidder-instances/${id}/assign-accounts`,
15955
- UNASSIGN_ACCOUNTS: (id) => `admin/bidder-instances/${id}/unassign-accounts`,
15956
- SET_DEFAULT: (id) => `admin/bidder-instances/${id}/set-default`,
15957
- },
15958
15976
  },
15959
15977
  BID: {
15960
15978
  BASE: 'bid',
@@ -16018,9 +16036,13 @@ const ROUTES = {
16018
16036
  ROOM_TAG: (organizationId, bidderAccountId, roomId) => `organizations/${organizationId}/bidder-accounts/${bidderAccountId}/rooms/${roomId}/tags`,
16019
16037
  ROOM_NOTES: (organizationId, bidderAccountId, roomId) => `organizations/${organizationId}/bidder-accounts/${bidderAccountId}/rooms/${roomId}/notes`,
16020
16038
  ROOM_CRM_STATUS: (organizationId, bidderAccountId, roomId) => `organizations/${organizationId}/bidder-accounts/${bidderAccountId}/rooms/${roomId}/crm-status`,
16039
+ ROOM_DEAL_VALUE: (organizationId, bidderAccountId, roomId) => `organizations/${organizationId}/bidder-accounts/${bidderAccountId}/rooms/${roomId}/deal-value`,
16040
+ ROOM_TASKS: (organizationId, bidderAccountId, roomId) => `organizations/${organizationId}/bidder-accounts/${bidderAccountId}/rooms/${roomId}/tasks`,
16041
+ ROOM_TASK_BY_ID: (organizationId, bidderAccountId, roomId, taskId) => `organizations/${organizationId}/bidder-accounts/${bidderAccountId}/rooms/${roomId}/tasks/${taskId}`,
16021
16042
  CONNECT_ACCOUNT: (organizationId, bidderAccountId) => `organizations/${organizationId}/bidder-accounts/${bidderAccountId}/chat/connect-account`,
16022
16043
  ROOMS: (id, bidderAccountId) => `organizations/${id}/bidder-accounts/${bidderAccountId}/rooms`,
16023
16044
  ROOM: (id, bidderAccountId, roomId) => `organizations/${id}/bidder-accounts/${bidderAccountId}/rooms/${roomId}`,
16045
+ ROOM_METADATA: (id, bidderAccountId, roomId) => `organizations/${id}/bidder-accounts/${bidderAccountId}/rooms/${roomId}/metadata`,
16024
16046
  REFRESH_ROOM: (id, bidderAccountId, roomId) => `organizations/${id}/bidder-accounts/${bidderAccountId}/rooms/${roomId}/refresh`,
16025
16047
  SEND_MESSAGE: (id, bidderAccountId, roomId) => `organizations/${id}/bidder-accounts/${bidderAccountId}/rooms/${roomId}/send-message`,
16026
16048
  REFRESH_ROOMS: (organizationId, bidderAccountId) => `organizations/${organizationId}/bidder-accounts/${bidderAccountId}/chat/refresh-rooms`,
@@ -16032,6 +16054,7 @@ const ROUTES = {
16032
16054
  GET_FREE_SLOTS: (organizationId, bidderAccountId, roomId) => `organizations/${organizationId}/bidder-accounts/${bidderAccountId}/rooms/${roomId}/free-slots`,
16033
16055
  BOOK_SLOT: (organizationId, bidderAccountId, roomId) => `organizations/${organizationId}/bidder-accounts/${bidderAccountId}/rooms/${roomId}/book-slot`,
16034
16056
  ATTACHMENT_REDIRECT: (organizationId, bidderAccountId, roomId) => `organizations/${organizationId}/bidder-accounts/${bidderAccountId}/rooms/${roomId}/attachment-redirect`,
16057
+ PIPELINE_LIST_ROOMS: (organizationId) => `organizations/${organizationId}/chat/pipeline-list-rooms`,
16035
16058
  },
16036
16059
  },
16037
16060
  LEADS_BY_JOB_ID: (organizationId, jobId) => `organizations/${organizationId}/leads/${jobId}`,
@@ -16045,6 +16068,7 @@ const ROUTES = {
16045
16068
  CONNECTS_SAVED: (organizationId, campaignId) => `organizations/${organizationId}/campaigns/${campaignId}/connects-saved`,
16046
16069
  LAST_MONTH_LEAD_COUNTS: (organizationId) => `organizations/${organizationId}/campaigns/last-month-leads-count`,
16047
16070
  TOP_KEYWORDS: (organizationId, campaignId) => `organizations/${organizationId}/campaigns/${campaignId}/top-keywords`,
16071
+ TOP_SKILLS: (organizationId, campaignId) => `organizations/${organizationId}/campaigns/${campaignId}/top-skills`,
16048
16072
  BIDDER_ACCOUNTS: {
16049
16073
  BASE: (organizationId, campaignId) => `organizations/${organizationId}/campaigns/${campaignId}/bidder-account`,
16050
16074
  CONNECT: (organizationId, campaignId) => `organizations/${organizationId}/campaigns/${campaignId}/bidder-account/connect`,
@@ -16112,6 +16136,9 @@ const ROUTES = {
16112
16136
  BASE: (id) => `organizations/${id}/users`,
16113
16137
  BY_ID: (organizationId, userId) => `organizations/${organizationId}/users/${userId}`,
16114
16138
  },
16139
+ ALL_TASKS: (organizationId) => `organizations/${organizationId}/tasks`,
16140
+ PIPELINE_TOTALS: (organizationId) => `organizations/${organizationId}/pipeline/totals`,
16141
+ PIPELINE_COLUMNS: (organizationId) => `organizations/${organizationId}/pipeline/columns`,
16115
16142
  INVOICE_PREVIEW: (id) => `organizations/${id}/invoice-preview`,
16116
16143
  },
16117
16144
  TRANSACTIONS: {
@@ -24808,5 +24835,5 @@ async function tryCatch(promise) {
24808
24835
  }
24809
24836
  }
24810
24837
 
24811
- export { BidderAccountAlreadyConnectedException, BoostAboveMaxConnectsException, CAMPAIGN_NOTIFICATION_SETTINGS, CAMPAIGN_NOTIFICATION_TYPES, CLIENT_SIZE_TO_NUMBER, CloudflareChallengeFailedException, DEFAULT_ROOM_CRM_STATUS, DeleteMultiloginProfileException, DropdownOptionNotPresentException, ElementNotClickableException, EvaluateElementException, EvaluateFunctionException, FEED_JOB_TO_JOB_DETAILS_FIELD_MAPPING, FailedToParseNuxtJobException, FeedJobEnrichException, FeedScrapeException, GOAT_COUNTRIES, GetMultiloginBrowserException, GoToUrlException, HIERARCHICAL_CATEGORIES_TO_CHILDREN, INFINITY, IncorrectSecurityQuestionAnswerException, InitBrowserException, InsufficientConnectsException, InvalidCredentialsException, InvalidGoogleOAuthTokenException, InvalidJobUrlException, JOB_FILTER_OPTIONS, JobAlreadyBiddedOnException, JobAlreadyHiredException, JobAlreadyProcessedInAnotherCampaignException, JobIsPrivateException, JobNoLongerAvailableException, LogEventTypeEnum, LoginFailedException, MultiloginAuthenticationException, NavigationTimeoutException, NetworkRestrictionsException, NewBrowserPageException, NewPageException, NoBidderAccountsAvailableException, NoGoogleOAuthTokensFoundException, NoScraperAccountAvailableException, OpenPageException, PageClosedException, PageContentException, ParseConnectsException, ParseJobListingsException, PrivateJobException, ProposalErrorAlertException, ProposalFormWarningAlertException, ProposalGenerationFailedException, ProposalSubmitFailedException, ProxyNotReachableException, PuppeteerConnectionErrorException, QuestionPairNotMatchingException, ROOM_CRM_ARCHIVED_REASON_LABELS, ROOM_CRM_ARCHIVED_REASON_ORDER, ROOM_CRM_KANBAN_STATUS_ORDER, ROOM_CRM_STATUS_BY_ID, ROOM_CRM_STATUS_IDS, ROOM_CRM_STATUS_LABELS, ROOM_CRM_STATUS_ORDER, ROOM_EXTENDED_TYPE_MAP, ROOM_TYPES_MATCHING_EMPTY_EXTENDED_TYPE, ROUTES, ScraperAccountProxyNotFoundException, SearchFieldsSchema, SearchQueryBuilder, SelectAgencyException, SelectContractorException, SelectorNotFoundError, TRACKED_BID_FAILURE_MONITORING_CODES, TwoFactorPresentException, TypedValueInFieldNotMatchingException, TypingInputFieldException, USER_FACING_CREDENTIAL_ERROR_CODES, WaitForFunctionTimeoutError, acceptUpworkInvitationResponseSchema, acceptUpworkInvitationSchema, accountStatusDisplayMap, accountStatusOrder, accountStatusSchema, addFromClientHireRateNodeFormSchema, addFromClientRatingNodeFormSchema, addFromClientSizeNodeFormSchema, addFromClientSpentNodeFormSchema, addFromHourlyRateNodeFormSchema, addFromSuitabilityNodeFormSchema, agencyBidPayloadSchema, agencyBidProposalDataSchema, agentCalculateSuitabilityRequestSchema, agentGenerateProposalRequestSchema, agentGenerateProposalResponseSchema, agentPickSpecialisedProfileRequestSchema, agentPickSpecialisedProfileResponseSchema, agentStatusSchema, agentTaskResponseSchema, aiConfigSchema, alreadyHiredActionEnum, assignDecodoProxyToBidderAccountSchema, assignRoomTagsRequestBodySchema, bidAsEnum, bidConfigSchema, bidDtoSchema, bidFailedSchema, bidPayloadProposalDataSchema, bidPayloadSchema, bidRangeSchema, bidSuccessSchema, bidWithWarningEnum, bidderAccountAgencyContractorSchema, bidderAccountAgencySchema, bidderAccountAlreadyConnectedException, bidderAccountPortfolioSchema, bidderAccountProvider, bidderAccountProviderDisplayMap, bidderAccountSchema, bidderAccountStatusEnum, bidderFailureDashboardResponseSchema, bidderInstanceSchema, bidderInstanceStatusEnum, bidderMonitoringRowSchema, biddingCompletedEventMetadata, biddingFailedEventMetadata, biddingHourlyRateStrategyEnum, biddingProcessingEventMetadata, biddingRejectedWithFeedbackEventMetadata, billingConfigSchema, billingIntervalEnum, bookSlotRequestBodySchema, booleanSchema, boostAboveMaxConnectsException, boostFormSchema, buildRoute, campaignAIMetricsSchema, campaignActivityCreateSchema, campaignActivitySchema, campaignActivityTypeSchema, campaignAnalyticsResponseSchema, campaignAnalyticsSchema, campaignAnalyticsStatsSchema, campaignCountByStatusSchema, campaignExpensesSchema, campaignInsightsSchema, campaignNotificationType, campaignSchema, campaignStatusActivitySchema, campaignStatusSchema, capitalize, caseStudySchema, categoryEnum, chatbotChannelSchema, chatbotPlatforms, chatbotSchema, checkLeadStatusPayloadSchema, clientIndustryEnum, clientInfoSchema, clientReviewSchema, clientSizeEnum, cloudflareProtectionFailure, connectUpworkAccountSchema, convertToUtc, countryMapping, coverLetterTemplateSchema, createBidderAccountSchema, createBidderInstanceSchema, createCampaignSchema, createChatbotSchema, createClientHireRateFormSchema, createClientRatingFormSchema, createClientSizeFormSchema, createClientSpentFormSchema, createCoverLetterTemplateSchema, createHourlyRateFormSchema, createOrganizationProfileSchema, createOrganizationSchema, createRoomTagRequestBodySchema, createSampleSchema, createScraperAccountSchema, createSuitabilityFormSchema, dailyUsageSchema, dateSchema, defaultQuestions, deleteMultiloginProfileException, dropdownOptionNotPresentException, elementNotClickableException, employmentHistorySchema, engagementTypeEnum, englishLevelEnum, evaluateElementException, evaluateFunctionException, eventLoggerPayloadSchema, experienceLevelEnum, externalProxySchema, failedToParseNuxtJobException, featureSchema, feedChunkEnrichCompletedEventMetadata, feedChunkEnrichFailedEventMetadata, feedChunkEnrichStartedEventMetadata, feedEnrichCompletedEventMetadata, feedEnrichFailedEventMetadata, feedEnrichStartedEventMetadata, feedJobEnrichCompletedEventMetadata, feedJobEnrichFailedEventMetadata, feedJobEnrichFailedException, feedJobEnrichStartedEventMetadata, feedJobSchema, feedScrapeCompletedEventMetadata, feedScrapeException, feedScrapeFailedEventMetadata, feedScrapeResultSchema, feedScrapeStartedEventMetadata, filterOptionItemSchema, filterOptionsResponseSchema, findLeadsRequestSchema, findLeadsResponseSchema, forgotPasswordSchema, formatCurrency, formatDuration, freeSlotsRequestBodySchema, freelancerBidPayloadSchema, freelancerBidProposalDataSchema, generateLeadCountsRequestSchema, generateSlug, getAverageClientHireRateResponseSchema, getAverageClientTotalSpentResponseSchema, getAverageFixedPriceBudgetResponseSchema, getAverageHourlyRateBudgetResponseSchema, getAverageHourlyRatePaidByCountryResponseSchema, getAveragePaidPerProjectResponseSchema, getBiddingProcessingEventFromAnotherCampaignsPayloadSchema, getBiddingProcessingEventFromAnotherCampaignsResponseSchema, getCampaignLeadsRequestQuerySchema, getCampaignLeadsResponseSchema, getCampaignLeadsStatusEnum, getJobsByClientTotalSpentResponseSchema, getJobsByCountryResponseSchema, getJobsByDayOfWeekResponseSchema, getJobsByHourPostedResponseSchema, getJobsCountLast3MonthsResponseSchema, getJobsPostedResponseSchema, getMultiloginBrowserException, getNextStatus, getOrganizationLeadsRequestQuerySchema, getOrganizationLeadsStatusEnum, getPreviousStatus, getRoomsResponseSchema, getRouteWithoutAdminPrefix, getSamplesRequestSchema, getTop10CategoriesByAvgHourlyBudgetResponseSchema, getTop10CategoriesByAvgPaidPerProjectResponseSchema, getTop10CategoriesByClientHireRateResponseSchema, getTop10CategoriesByClientTotalSpentResponseSchema, getTop10CategoriesByJobsPostedResponseSchema, getTop10CountriesByAvgHourlyBudgetResponseSchema, getTop10CountriesByAvgPaidPerProjectResponseSchema, getTop10CountriesByClientHireRateResponseSchema, getTop10CountriesByClientTotalSpentResponseSchema, getTop10CountriesByJobsPostedResponseSchema, getTop10SkillsResponseSchema, getTop20CategoriesByAvgHourlyRatePaidResponseSchema, goToUrlException, hasQuestionsEnum, incorrectSecurityQuestionAnswerException, initBrowserException, insufficeintBoostConnectsActionEnum, insufficientConnectsActionEnum, insufficientConnectsException, invalidCredentialsException, invalidGoogleOAuthTokenSchema, invalidJobUrlException, invoiceLineItemSchema, invoiceSchema, invoiceStatusEnum, invoiceStatusNames, invoiceStripeMetadataLineSchema, invoiceStripeMetadataSchema, isNumeric, isPaymentVerifiedEnum, isPhoneVerifiedEnum, isRoomCrmStatus, isTrackedBidFailureMonitoringCode, isUserFacingCredentialErrorCode, isWorkTime, jobActivityDeltaSchema, jobActivityOffsetEnum, jobActivityOffsetHourSchema, jobActivityOffsetHours, jobActivitySchema, jobActivityScrapeFailedEventMetadata, jobActivityScrapedEventMetadata, jobActivitySnapshotSchema, jobActivityUpdateSchema, jobAlreadyBiddedOnException, jobAlreadyHiredException, jobAlreadyProcessedInAnotherCampaignException, jobDetailsStateSchema, jobFiltersSchema, jobIsPrivateException, jobListingSchema, jobNoLongerAvailableException, jobQualityScoreSchema, jobSkillsSchema, jobStatusOrder, labelEnum, lancerBiddingExceptionEventMetadata, largeCountries, leadAnalysisActivitySchema, leadBiddingConfigSchema, leadResponseSchema, leadSchema, leadStatusActivitySchema, leadStatusEnum, leadStatusEventMetadata, limitsSchema, logEventSchema, loginFailedException, loginSchema, metadataSchema, monitoringBidFailureRecordSchema, multiloginAuthenticationException, navigationTimeoutException, networkRestrictionsException, newBrowserPageException, newPageException, noBidderAccountsAvailableException, noGoogleOAuthTokensFoundException, noScraperAccountAvailableException, nodeEnums, normalizeRoomCrmStatus, normalizeRoomCrmStatuses, notificationConfigSchema, nuxtStateJobDetailsSchema, nuxtStateJobSchema, nuxtStateJobsSearchSchema, onboardingSectionSchema, openPageException, organizationCampaignStatsSchema, organizationMemberRoleEnum, organizationMemberSchema, organizationProfileSchema, organizationSchema, organizationSettingsSchema, organizationTierEnum, organizationTypeSchema, organizationUpdateSchema, pageClosedException, pageContentException, parseConnectsException, parseJobListingsException, passwordSchema, paymentTypeEnum, periodTypeSchema, periodUsageSchema, pickProfileRequestSchema, pickProfileResponseSchema, planFeatureSchema, planPricingIntervalSchema, planPricingSchema, planSchema, planSlugEnum, planSlugToNameMap, planStripeMetadataSchema, pluralize, portfolioSchema, privateJobException, processFeedPayloadSchema, projectDurationEnum, proposalCompleteEventMetadataSchema, proposalErrorAlertException, proposalFormWarningAlertException, proposalGenerationFailed, proposalSchema, proposalSentActivitySchema, proposalSubmitFailedException, proxyAvailableReplacementsSchema, proxyCountryCodeToName, proxyCountryEnum, proxyNotReachableException, proxyProtocolSchema, proxyProviderSchema, proxySchema, proxyStatusSchema, proxyTypeSchema, puppeteerConnectionErrorException, questionAnswerPairSchema, questionPairNotMatchingException, questionRulesSchema, reconnectBidderAccountRequestBodySchema, reconnectBidderAccountResponseSchema, refreshRoomsFailedEventMetadataSchema, refreshRotatingProxiesRequestBodySchema, regionEnum, regionMapping, regionNames, regionSchema, registerSchema, requiredEarningsEnum, requiredJSSEnum, roomCrmArchivedReasonEnum, roomCrmStatusEnum, roomJobClientHistorySchema, roomMessageSchema, roomNoteSchema, roomSchema, roomTagSchema, roomsMetadataSchema, sampleSchema, savedSearchSchema, scheduleBiddingEventMetadataSchema, scrapeJobActivityPayloadSchema, scrapeJobPayloadSchema, scrapeJobsCompletedEventMetadata, scrapePayloadSchema, scrapeResultSchema, scrapeUserProfileRequestSchema, scraperAccountErrorEventMetadata, scraperAccountProxyNotFoundException, scraperAccountRegionEnum, scraperAccountSchema, scraperAccountSwapCompletedEventMetadata, scraperAccountSwapFailedEventMetadata, scraperAccountSwapStartedEventMetadata, scraperAccountTypeEnum, searchQueryModeEnum, selectAgencyException, selectContractorException, selectorNotFoundError, sendAlertPayloadSchema, sendDiscordMessageRequestBodySchema, sendMessageRequestSchema, sendNotificationRequestSchema, specialisedProfileSchema, stringify, subscribePayloadSchema, subscriptionSchema, subscriptionSourceEnum, subscriptionStatusEnum, subscriptionStripeMetadataItemSchema, subscriptionStripeMetadataSchema, suitabilityCompleteEventMetadataSchema, suitabilityFailedEventMetadataSchema, suitabilityPendingEventMetadataSchema, suitabilityRatingSchema, syncProposalsStatusCompletedEventMetadata, syncProposalsStatusFailedEventMetadata, syncProposalsStatusRequestPayloadSchema, systemPromptSchema, systemSchema, talentTypeEnum, timeBlockSchema, trackUsageEventTypeEnum, trackUsagePayloadSchema, transactionSchema, transactionStatusEnum, transactionStripeMetadataSchema, transactionTypeEnum, tryCatch, twoFactorPresentException, typedValueInFieldNotMatchingException, typingInputFieldException, unauthenticatedSessionDetectedEventMetadataSchema, updateBidderAccountSchema, updateCampaignAnalyticsSchema, updateCampaignSchema, updateChatbotSchema, updateLeadStatusSchema, updateOrganizationLeadsStatusPayloadSchema, updateOrganizationProfileSchema, updateRoomCrmStatusRequestBodySchema, updateRoomNotesRequestBodySchema, updateSampleSchema, updateScraperAccountSchema, updateSuitableLeadNotificationBodySchema, updateSuitableLeadNotificationType, upworkAccountConnectSchema, upworkAccountConnectStatusSchema, upworkJobSchema, upworkOrganizationSchema, upworkOrganizationTypeEnum, upworkProfileSchema, upworkTalentCountrySchema, upworkTalentSchema, upworkTalentSearchRequestSchema, upworkTalentSearchResponseSchema, upworkTalentSkillWithRankSchema, upworkTalentSkillsResponseSchema, upworkTalentSkillsSchema, usageEventMetadataSchema, usageEventSchema, usageEventTypeEnum, userAccountBiddingExceptionEventMetadata, userSchema, vendorQualificationSchema, vendorTypeEnum, verifyBidderAccountCredentialsResponseSchema, verifyBidderAccountCredentialsSchema, verifyCredentialsFailedEventMetadataSchema, verifyCredentialsSucceededEventMetadataSchema, waitForFunctionTimeoutError, weekDaysEnum, workTimeSchema };
24838
+ export { BidderAccountAlreadyConnectedException, BoostAboveMaxConnectsException, CAMPAIGN_NOTIFICATION_SETTINGS, CAMPAIGN_NOTIFICATION_TYPES, CLIENT_SIZE_TO_NUMBER, CloudflareChallengeFailedException, DEFAULT_PIPELINE_COLUMNS, DEFAULT_PIPELINE_COLUMN_ID, DEFAULT_ROOM_CRM_STATUS, DeleteMultiloginProfileException, DropdownOptionNotPresentException, ElementNotClickableException, EvaluateElementException, EvaluateFunctionException, FEED_JOB_TO_JOB_DETAILS_FIELD_MAPPING, FailedToParseNuxtJobException, FeedJobEnrichException, FeedScrapeException, GOAT_COUNTRIES, GetMultiloginBrowserException, GoToUrlException, HIERARCHICAL_CATEGORIES_TO_CHILDREN, INFINITY, IncorrectSecurityQuestionAnswerException, InitBrowserException, InsufficientConnectsException, InvalidCredentialsException, InvalidGoogleOAuthTokenException, InvalidJobUrlException, JOB_FILTER_OPTIONS, JobAlreadyBiddedOnException, JobAlreadyHiredException, JobAlreadyProcessedInAnotherCampaignException, JobIsPrivateException, JobNoLongerAvailableException, LogEventTypeEnum, LoginFailedException, MultiloginAuthenticationException, NavigationTimeoutException, NetworkRestrictionsException, NewBrowserPageException, NewPageException, NoBidderAccountsAvailableException, NoGoogleOAuthTokensFoundException, NoScraperAccountAvailableException, OpenPageException, PIPELINE_COLUMN_COLORS, PIPELINE_DEAL_VALUE_EXCLUDED_COLUMN_IDS, PIPELINE_LIST_SORT_FIELDS, PageClosedException, PageContentException, ParseConnectsException, ParseJobListingsException, PrivateJobException, ProposalErrorAlertException, ProposalFormWarningAlertException, ProposalGenerationFailedException, ProposalSubmitFailedException, ProxyNotReachableException, PuppeteerConnectionErrorException, QuestionPairNotMatchingException, ROOM_CRM_ARCHIVED_REASON_ORDER, ROOM_EXTENDED_TYPE_MAP, ROOM_TYPES_MATCHING_EMPTY_EXTENDED_TYPE, ROUTES, ScraperAccountProxyNotFoundException, SearchFieldsSchema, SearchQueryBuilder, SelectAgencyException, SelectContractorException, SelectorNotFoundError, TRACKED_BID_FAILURE_MONITORING_CODES, TwoFactorPresentException, TypedValueInFieldNotMatchingException, TypingInputFieldException, USER_FACING_CREDENTIAL_ERROR_CODES, WaitForFunctionTimeoutError, acceptUpworkInvitationResponseSchema, acceptUpworkInvitationSchema, accountStatusDisplayMap, accountStatusOrder, accountStatusSchema, addFromClientHireRateNodeFormSchema, addFromClientRatingNodeFormSchema, addFromClientSizeNodeFormSchema, addFromClientSpentNodeFormSchema, addFromHourlyRateNodeFormSchema, addFromSuitabilityNodeFormSchema, agencyBidPayloadSchema, agencyBidProposalDataSchema, agentCalculateSuitabilityRequestSchema, agentGenerateProposalRequestSchema, agentGenerateProposalResponseSchema, agentPickSpecialisedProfileRequestSchema, agentPickSpecialisedProfileResponseSchema, agentStatusSchema, agentTaskResponseSchema, aiConfigSchema, alreadyHiredActionEnum, assignDecodoProxyToBidderAccountSchema, assignRoomTagsRequestBodySchema, bidAsEnum, bidConfigSchema, bidDtoSchema, bidFailedSchema, bidPayloadProposalDataSchema, bidPayloadSchema, bidRangeSchema, bidSuccessSchema, bidWithWarningEnum, bidderAccountAgencyContractorSchema, bidderAccountAgencySchema, bidderAccountAlreadyConnectedException, bidderAccountPortfolioSchema, bidderAccountProvider, bidderAccountProviderDisplayMap, bidderAccountSchema, bidderAccountStatusEnum, bidderFailureDashboardResponseSchema, bidderInstanceSchema, bidderInstanceStatusEnum, bidderMonitoringRowSchema, biddingCompletedEventMetadata, biddingFailedEventMetadata, biddingHourlyRateStrategyEnum, biddingProcessingEventMetadata, biddingRejectedWithFeedbackEventMetadata, billingConfigSchema, billingIntervalEnum, bookSlotRequestBodySchema, booleanSchema, boostAboveMaxConnectsException, boostFormSchema, buildRoute, campaignAIMetricsSchema, campaignActivityCreateSchema, campaignActivitySchema, campaignActivityTypeSchema, campaignAnalyticsResponseSchema, campaignAnalyticsSchema, campaignAnalyticsStatsSchema, campaignCountByStatusSchema, campaignExpensesSchema, campaignInsightsSchema, campaignNotificationType, campaignSchema, campaignStatusActivitySchema, campaignStatusSchema, capitalize, caseStudySchema, categoryEnum, chatbotChannelSchema, chatbotPlatforms, chatbotSchema, checkLeadStatusPayloadSchema, clientIndustryEnum, clientInfoSchema, clientReviewSchema, clientSizeEnum, cloudflareProtectionFailure, connectUpworkAccountSchema, convertToUtc, countryMapping, coverLetterTemplateSchema, createBidderAccountSchema, createBidderInstanceSchema, createCampaignSchema, createChatbotSchema, createClientHireRateFormSchema, createClientRatingFormSchema, createClientSizeFormSchema, createClientSpentFormSchema, createCoverLetterTemplateSchema, createHourlyRateFormSchema, createOrganizationProfileSchema, createOrganizationSchema, createRoomTagRequestBodySchema, createRoomTaskRequestBodySchema, createSampleSchema, createScraperAccountSchema, createSuitabilityFormSchema, dailyUsageSchema, dateSchema, defaultQuestions, deleteMultiloginProfileException, dropdownOptionNotPresentException, elementNotClickableException, employmentHistorySchema, engagementTypeEnum, englishLevelEnum, evaluateElementException, evaluateFunctionException, eventLoggerPayloadSchema, experienceLevelEnum, externalProxySchema, failedToParseNuxtJobException, featureSchema, feedChunkEnrichCompletedEventMetadata, feedChunkEnrichFailedEventMetadata, feedChunkEnrichStartedEventMetadata, feedEnrichCompletedEventMetadata, feedEnrichFailedEventMetadata, feedEnrichStartedEventMetadata, feedJobEnrichCompletedEventMetadata, feedJobEnrichFailedEventMetadata, feedJobEnrichFailedException, feedJobEnrichStartedEventMetadata, feedJobSchema, feedScrapeCompletedEventMetadata, feedScrapeException, feedScrapeFailedEventMetadata, feedScrapeResultSchema, feedScrapeStartedEventMetadata, filterOptionItemSchema, filterOptionsResponseSchema, findLeadsRequestSchema, findLeadsResponseSchema, forgotPasswordSchema, formatCurrency, formatDuration, freeSlotsRequestBodySchema, freelancerBidPayloadSchema, freelancerBidProposalDataSchema, generateLeadCountsRequestSchema, generateSlug, getAverageClientHireRateResponseSchema, getAverageClientTotalSpentResponseSchema, getAverageFixedPriceBudgetResponseSchema, getAverageHourlyRateBudgetResponseSchema, getAverageHourlyRatePaidByCountryResponseSchema, getAveragePaidPerProjectResponseSchema, getBiddingProcessingEventFromAnotherCampaignsPayloadSchema, getBiddingProcessingEventFromAnotherCampaignsResponseSchema, getCampaignLeadsRequestQuerySchema, getCampaignLeadsResponseSchema, getCampaignLeadsStatusEnum, getJobsByClientTotalSpentResponseSchema, getJobsByCountryResponseSchema, getJobsByDayOfWeekResponseSchema, getJobsByHourPostedResponseSchema, getJobsCountLast3MonthsResponseSchema, getJobsPostedResponseSchema, getMultiloginBrowserException, getNextStatus, getOrganizationLeadsRequestQuerySchema, getOrganizationLeadsStatusEnum, getPipelineListRoomsResponseSchema, getPreviousStatus, getRoomsResponseSchema, getRouteWithoutAdminPrefix, getSamplesRequestSchema, getTop10CategoriesByAvgHourlyBudgetResponseSchema, getTop10CategoriesByAvgPaidPerProjectResponseSchema, getTop10CategoriesByClientHireRateResponseSchema, getTop10CategoriesByClientTotalSpentResponseSchema, getTop10CategoriesByJobsPostedResponseSchema, getTop10CountriesByAvgHourlyBudgetResponseSchema, getTop10CountriesByAvgPaidPerProjectResponseSchema, getTop10CountriesByClientHireRateResponseSchema, getTop10CountriesByClientTotalSpentResponseSchema, getTop10CountriesByJobsPostedResponseSchema, getTop10SkillsResponseSchema, getTop20CategoriesByAvgHourlyRatePaidResponseSchema, goToUrlException, hasQuestionsEnum, incorrectSecurityQuestionAnswerException, initBrowserException, insufficeintBoostConnectsActionEnum, insufficientConnectsActionEnum, insufficientConnectsException, invalidCredentialsException, invalidGoogleOAuthTokenSchema, invalidJobUrlException, invoiceLineItemSchema, invoiceSchema, invoiceStatusEnum, invoiceStatusNames, invoiceStripeMetadataLineSchema, invoiceStripeMetadataSchema, isNumeric, isPaymentVerifiedEnum, isPhoneVerifiedEnum, isTrackedBidFailureMonitoringCode, isUserFacingCredentialErrorCode, isWorkTime, jobActivityDeltaSchema, jobActivityOffsetEnum, jobActivityOffsetHourSchema, jobActivityOffsetHours, jobActivitySchema, jobActivityScrapeFailedEventMetadata, jobActivityScrapedEventMetadata, jobActivitySnapshotSchema, jobActivityUpdateSchema, jobAlreadyBiddedOnException, jobAlreadyHiredException, jobAlreadyProcessedInAnotherCampaignException, jobDetailsStateSchema, jobFiltersSchema, jobIsPrivateException, jobListingSchema, jobNoLongerAvailableException, jobQualityScoreSchema, jobSkillsSchema, jobStatusOrder, labelEnum, lancerBiddingExceptionEventMetadata, largeCountries, leadAnalysisActivitySchema, leadBiddingConfigSchema, leadResponseSchema, leadSchema, leadStatusActivitySchema, leadStatusEnum, leadStatusEventMetadata, limitsSchema, logEventSchema, loginFailedException, loginSchema, metadataSchema, monitoringBidFailureRecordSchema, multiloginAuthenticationException, navigationTimeoutException, networkRestrictionsException, newBrowserPageException, newPageException, noBidderAccountsAvailableException, noGoogleOAuthTokensFoundException, noScraperAccountAvailableException, nodeEnums, normalizeRoomCrmStatus, normalizeRoomCrmStatuses, notificationConfigSchema, nuxtStateJobDetailsSchema, nuxtStateJobSchema, nuxtStateJobsSearchSchema, onboardingSectionSchema, openPageException, organizationCampaignStatsSchema, organizationMemberRoleEnum, organizationMemberSchema, organizationProfileSchema, organizationSchema, organizationSettingsSchema, organizationTierEnum, organizationTypeSchema, organizationUpdateSchema, pageClosedException, pageContentException, parseConnectsException, parseJobListingsException, passwordSchema, paymentTypeEnum, periodTypeSchema, periodUsageSchema, pickProfileRequestSchema, pickProfileResponseSchema, pipelineColumnSchema, planFeatureSchema, planPricingIntervalSchema, planPricingSchema, planSchema, planSlugEnum, planSlugToNameMap, planStripeMetadataSchema, pluralize, portfolioSchema, privateJobException, processFeedPayloadSchema, projectDurationEnum, proposalCompleteEventMetadataSchema, proposalErrorAlertException, proposalFormWarningAlertException, proposalGenerationFailed, proposalSchema, proposalSentActivitySchema, proposalSubmitFailedException, proxyAvailableReplacementsSchema, proxyCountryCodeToName, proxyCountryEnum, proxyNotReachableException, proxyProtocolSchema, proxyProviderSchema, proxySchema, proxyStatusSchema, proxyTypeSchema, puppeteerConnectionErrorException, questionAnswerPairSchema, questionPairNotMatchingException, questionRulesSchema, reconnectBidderAccountRequestBodySchema, reconnectBidderAccountResponseSchema, refreshRoomsFailedEventMetadataSchema, refreshRotatingProxiesRequestBodySchema, regionEnum, regionMapping, regionNames, regionSchema, registerSchema, requiredEarningsEnum, requiredJSSEnum, roomCrmArchivedReasonEnum, roomCrmStatusEnum, roomJobClientHistorySchema, roomMessageSchema, roomNoteSchema, roomSchema, roomTagSchema, roomTaskSchema, roomsMetadataSchema, sampleSchema, savedSearchSchema, scheduleBiddingEventMetadataSchema, scrapeJobActivityPayloadSchema, scrapeJobPayloadSchema, scrapeJobsCompletedEventMetadata, scrapePayloadSchema, scrapeResultSchema, scrapeUserProfileRequestSchema, scraperAccountErrorEventMetadata, scraperAccountProxyNotFoundException, scraperAccountRegionEnum, scraperAccountSchema, scraperAccountSwapCompletedEventMetadata, scraperAccountSwapFailedEventMetadata, scraperAccountSwapStartedEventMetadata, scraperAccountTypeEnum, searchQueryModeEnum, selectAgencyException, selectContractorException, selectorNotFoundError, sendAlertPayloadSchema, sendDiscordMessageRequestBodySchema, sendMessageRequestSchema, sendNotificationRequestSchema, specialisedProfileSchema, stringify, subscribePayloadSchema, subscriptionSchema, subscriptionSourceEnum, subscriptionStatusEnum, subscriptionStripeMetadataItemSchema, subscriptionStripeMetadataSchema, suitabilityCompleteEventMetadataSchema, suitabilityFailedEventMetadataSchema, suitabilityPendingEventMetadataSchema, suitabilityRatingSchema, syncProposalsStatusCompletedEventMetadata, syncProposalsStatusFailedEventMetadata, syncProposalsStatusRequestPayloadSchema, systemPromptSchema, systemSchema, talentTypeEnum, timeBlockSchema, trackUsageEventTypeEnum, trackUsagePayloadSchema, transactionSchema, transactionStatusEnum, transactionStripeMetadataSchema, transactionTypeEnum, tryCatch, twoFactorPresentException, typedValueInFieldNotMatchingException, typingInputFieldException, unauthenticatedSessionDetectedEventMetadataSchema, updateBidderAccountSchema, updateCampaignAnalyticsSchema, updateCampaignSchema, updateChatbotSchema, updateLeadStatusSchema, updateOrganizationLeadsStatusPayloadSchema, updateOrganizationProfileSchema, updatePipelineColumnsRequestBodySchema, updateRoomCrmStatusRequestBodySchema, updateRoomDealValueRequestBodySchema, updateRoomNotesRequestBodySchema, updateRoomTaskRequestBodySchema, updateSampleSchema, updateScraperAccountSchema, updateSuitableLeadNotificationBodySchema, updateSuitableLeadNotificationType, upworkAccountConnectSchema, upworkAccountConnectStatusSchema, upworkJobSchema, upworkOrganizationSchema, upworkOrganizationTypeEnum, upworkProfileSchema, upworkTalentCountrySchema, upworkTalentSchema, upworkTalentSearchRequestSchema, upworkTalentSearchResponseSchema, upworkTalentSkillWithRankSchema, upworkTalentSkillsResponseSchema, upworkTalentSkillsSchema, usageEventMetadataSchema, usageEventSchema, usageEventTypeEnum, userAccountBiddingExceptionEventMetadata, userSchema, vendorQualificationSchema, vendorTypeEnum, verifyBidderAccountCredentialsResponseSchema, verifyBidderAccountCredentialsSchema, verifyCredentialsFailedEventMetadataSchema, verifyCredentialsSucceededEventMetadataSchema, waitForFunctionTimeoutError, weekDaysEnum, workTimeSchema };
24812
24839
  //# sourceMappingURL=bundle.esm.js.map