lancer-shared 1.0.6 → 1.0.7

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.
@@ -111,7 +111,7 @@ export declare const metadataSchema: z.ZodObject<{
111
111
  paymentType: string | null;
112
112
  fixedPrice: number | null;
113
113
  }>;
114
- export declare const upworkJobSchema: z.ZodObject<{
114
+ export declare const jobSchema: z.ZodObject<{
115
115
  id: z.ZodNullable<z.ZodString>;
116
116
  createdAt: z.ZodNullable<z.ZodNumber>;
117
117
  title: z.ZodNullable<z.ZodString>;
@@ -342,7 +342,7 @@ export declare const upworkJobSchema: z.ZodObject<{
342
342
  } | null;
343
343
  processed: boolean | null;
344
344
  }>;
345
- export declare const jobSchema: z.ZodObject<z.objectUtil.extendShape<{
345
+ export declare const leadSchema: z.ZodObject<z.objectUtil.extendShape<{
346
346
  id: z.ZodNullable<z.ZodString>;
347
347
  createdAt: z.ZodNullable<z.ZodNumber>;
348
348
  title: z.ZodNullable<z.ZodString>;
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.jobResponseSchema = exports.jobListItemSchema = exports.jobSchema = exports.upworkJobSchema = exports.metadataSchema = exports.clientInfoSchema = exports.vendorQualificationSchema = exports.jobSkillsSchema = void 0;
3
+ exports.jobResponseSchema = exports.jobListItemSchema = exports.leadSchema = exports.jobSchema = exports.metadataSchema = exports.clientInfoSchema = exports.vendorQualificationSchema = exports.jobSkillsSchema = void 0;
4
4
  const zod_1 = require("zod");
5
5
  const job_note_1 = require("./job-note");
6
6
  const job_status_1 = require("./job-status");
@@ -45,7 +45,7 @@ exports.metadataSchema = zod_1.z.object({
45
45
  paymentType: zod_1.z.string().nullable(),
46
46
  fixedPrice: zod_1.z.number().nullable(),
47
47
  });
48
- exports.upworkJobSchema = zod_1.z.object({
48
+ exports.jobSchema = zod_1.z.object({
49
49
  id: zod_1.z.string().nullable(),
50
50
  createdAt: zod_1.z.number().nullable(),
51
51
  title: zod_1.z.string().nullable(),
@@ -64,7 +64,7 @@ exports.upworkJobSchema = zod_1.z.object({
64
64
  vendorQualifications: exports.vendorQualificationSchema.nullable(),
65
65
  processed: (0, zod_1.boolean)().nullable(),
66
66
  });
67
- exports.jobSchema = exports.upworkJobSchema.extend({
67
+ exports.leadSchema = exports.jobSchema.extend({
68
68
  jobId: zod_1.z.string(),
69
69
  updatedAt: zod_1.z.number().nullable(),
70
70
  suitabilityRating: zod_1.z.number().nullable(),
@@ -84,7 +84,7 @@ exports.jobListItemSchema = zod_1.z.object({
84
84
  datetime: zod_1.z.string().nullable(),
85
85
  });
86
86
  exports.jobResponseSchema = zod_1.z.object({
87
- jobs: zod_1.z.array(exports.jobSchema),
87
+ jobs: zod_1.z.array(exports.leadSchema),
88
88
  nextCursor: zod_1.z.string().nullable(),
89
89
  hasMore: zod_1.z.boolean(),
90
90
  jobCounts: zod_1.z.number().nullable(),
@@ -1,4 +1,4 @@
1
- import { z } from 'zod';
1
+ import { z } from "zod";
2
2
  export declare const scrapeResultSchema: z.ZodObject<{
3
3
  jobs: z.ZodArray<z.ZodObject<{
4
4
  id: z.ZodNullable<z.ZodString>;
@@ -4,6 +4,6 @@ exports.scrapeResultSchema = void 0;
4
4
  const zod_1 = require("zod");
5
5
  const job_1 = require("../job");
6
6
  exports.scrapeResultSchema = zod_1.z.object({
7
- jobs: zod_1.z.array(job_1.upworkJobSchema),
7
+ jobs: zod_1.z.array(job_1.jobSchema),
8
8
  cookies: zod_1.z.array(zod_1.z.any()),
9
9
  });
@@ -3,14 +3,14 @@ import { SavedSearch } from "../saved-search";
3
3
  import { JobNote } from "./job-note";
4
4
  import { JobStatus } from "./job-status";
5
5
  import { QuestionAnswerPair } from "../ai";
6
- import { clientInfoSchema, jobListItemSchema, jobResponseSchema, jobSchema, jobSkillsSchema, metadataSchema, upworkJobSchema, vendorQualificationSchema } from "../../schemas/job/job";
7
- export interface UpworkJob extends z.infer<typeof upworkJobSchema> {
6
+ import { clientInfoSchema, jobListItemSchema, jobResponseSchema, leadSchema, jobSkillsSchema, metadataSchema, jobSchema, vendorQualificationSchema } from "../../schemas/job/job";
7
+ export interface Job extends z.infer<typeof jobSchema> {
8
8
  clientInfo: ClientInfo | null;
9
9
  metadata: JobMetadata | null;
10
10
  skills: JobSkill[] | null;
11
11
  vendorQualifications: VendorQualifications | null;
12
12
  }
13
- export interface Job extends z.infer<typeof jobSchema> {
13
+ export interface Lead extends z.infer<typeof leadSchema> {
14
14
  clientInfo: ClientInfo | null;
15
15
  metadata: JobMetadata | null;
16
16
  skills: JobSkill[] | null;
@@ -20,9 +20,9 @@ export interface Job extends z.infer<typeof jobSchema> {
20
20
  status: JobStatus;
21
21
  }
22
22
  export interface JobResponse extends z.infer<typeof jobResponseSchema> {
23
- jobs: Job[];
23
+ jobs: Lead[];
24
24
  }
25
- export type JobWithSavedSearch = Job & {
25
+ export type JobWithSavedSearch = Lead & {
26
26
  savedSearch?: SavedSearch | null;
27
27
  };
28
28
  export type JobListItem = z.infer<typeof jobListItemSchema>;
@@ -1,6 +1,6 @@
1
1
  import { z } from "zod";
2
2
  import { savedSearchSchema } from "../../schemas";
3
- import { Job } from "../job";
3
+ import { Lead } from "../job";
4
4
  export interface SavedSearch extends z.infer<typeof savedSearchSchema> {
5
- jobs: Job[];
5
+ jobs: Lead[];
6
6
  }
@@ -1,9 +1,9 @@
1
1
  import { z } from "zod";
2
2
  import { loginSchema, registerSchema, userSchema } from "../../schemas";
3
- import { Job } from "../job";
3
+ import { Lead } from "../job";
4
4
  import { SavedSearch } from "../saved-search";
5
5
  export interface User extends z.infer<typeof userSchema> {
6
- jobs?: Job[];
6
+ jobs?: Lead[];
7
7
  savedSearches?: SavedSearch[];
8
8
  }
9
9
  export interface RegisterSchema extends z.infer<typeof registerSchema> {
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "type": "commonjs",
3
3
  "name": "lancer-shared",
4
- "version": "1.0.6",
4
+ "version": "1.0.7",
5
5
  "description": "This package contains shared stuff.",
6
6
  "types": "./dist/index.d.ts",
7
7
  "main": "./dist/index.js",