lancer-shared 1.2.20 → 1.2.21
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/bundle.cjs.js +112 -15
- package/dist/constants/account-status.d.ts +3 -0
- package/dist/constants/account-status.js +17 -0
- package/dist/constants/collections.js +13 -11
- package/dist/constants/common-questions.js +4 -1
- package/dist/constants/index.js +32 -10
- package/dist/constants/job-filter-options.js +4 -1
- package/dist/constants/job-status.js +12 -7
- package/dist/constants/mappings/countryMapping.js +3 -1
- package/dist/constants/mappings/regionMapping.js +3 -1
- package/dist/constants/routes.js +35 -43
- package/dist/constants/upwork-accounts.js +6 -3
- package/dist/index.js +20 -4
- package/dist/schemas/account/account-status.js +5 -2
- package/dist/schemas/account/bidder-account.js +24 -22
- package/dist/schemas/account/index.js +19 -3
- package/dist/schemas/account/manager-account.d.ts +116 -0
- package/dist/schemas/account/manager-account.js +38 -0
- package/dist/schemas/account/scraper-account.js +24 -21
- package/dist/schemas/ai/ai-config.js +11 -8
- package/dist/schemas/ai/index.js +19 -3
- package/dist/schemas/ai/proposal.js +13 -10
- package/dist/schemas/ai/suitability.js +11 -8
- package/dist/schemas/bid/bid-result.js +13 -9
- package/dist/schemas/bid/bid.js +30 -29
- package/dist/schemas/bid/index.js +18 -2
- package/dist/schemas/bidding/index.d.ts +1 -0
- package/dist/schemas/bidding/index.js +17 -0
- package/dist/schemas/bidding/proposal-bidding-status.d.ts +26 -0
- package/dist/schemas/bidding/proposal-bidding-status.js +18 -0
- package/dist/schemas/campaign/campaign-ai-metrics.js +8 -5
- package/dist/schemas/campaign/campaign-analytics.d.ts +2621 -38
- package/dist/schemas/campaign/campaign-analytics.js +31 -32
- package/dist/schemas/campaign/campaign-expenses.js +8 -5
- package/dist/schemas/campaign/campaign-insights.js +30 -30
- package/dist/schemas/campaign/campaign-integrations.js +13 -10
- package/dist/schemas/campaign/campaign-job-count.js +6 -3
- package/dist/schemas/campaign/campaign.js +35 -32
- package/dist/schemas/campaign/index.js +23 -7
- package/dist/schemas/chat-message/chat-message.js +10 -7
- package/dist/schemas/chat-message/index.js +17 -1
- package/dist/schemas/config/agency-config.js +9 -6
- package/dist/schemas/config/index.js +17 -1
- package/dist/schemas/index.js +32 -17
- package/dist/schemas/job/index.js +19 -0
- package/dist/schemas/job/job-details.d.ts +335 -0
- package/dist/schemas/job/job-details.js +29 -0
- package/dist/schemas/job/job-note.d.ts +83 -0
- package/dist/schemas/job/job-note.js +30 -0
- package/dist/schemas/job/job-status.d.ts +3 -0
- package/dist/schemas/job/job-status.js +27 -0
- package/dist/schemas/job/job.d.ts +1160 -0
- package/dist/schemas/job/job.js +90 -0
- package/dist/schemas/job/pipeline-job.d.ts +602 -0
- package/dist/schemas/job/pipeline-job.js +42 -0
- package/dist/schemas/job/upwork-job.d.ts +334 -0
- package/dist/schemas/job/upwork-job.js +60 -0
- package/dist/schemas/job-filters/index.js +17 -1
- package/dist/schemas/job-filters/job-filters.js +65 -62
- package/dist/schemas/lead/index.js +19 -173
- package/dist/schemas/lead/lead-note.js +16 -13
- package/dist/schemas/lead/lead-status.d.ts +23 -0
- package/dist/schemas/lead/lead-status.js +6 -3
- package/dist/schemas/lead/lead.d.ts +1897 -0
- package/dist/schemas/lead/lead.js +143 -0
- package/dist/schemas/logger/index.js +17 -1
- package/dist/schemas/logger/log-event.d.ts +13 -10
- package/dist/schemas/logger/log-event.js +49 -100
- package/dist/schemas/organization/index.js +17 -70
- package/dist/schemas/organization/organization.d.ts +7 -177
- package/dist/schemas/organization/organization.js +17 -14
- package/dist/schemas/proxy/index.js +17 -3
- package/dist/schemas/proxy/proxy.js +17 -25
- package/dist/schemas/saved-search/index.js +11 -8
- package/dist/schemas/scraper/index.js +18 -2
- package/dist/schemas/scraper/scrape-payload.js +14 -19
- package/dist/schemas/scraper/scrape-result.js +21 -21
- package/dist/schemas/shared.js +9 -12
- package/dist/schemas/time-filter/index.js +8 -5
- package/dist/schemas/upwork-account/index.d.ts +3 -0
- package/dist/schemas/upwork-account/index.js +19 -0
- package/dist/schemas/upwork-account/upwork-account-status.d.ts +2 -0
- package/dist/schemas/upwork-account/upwork-account-status.js +11 -0
- package/dist/schemas/upwork-account/upwork-business-manager-account.d.ts +95 -0
- package/dist/schemas/upwork-account/upwork-business-manager-account.js +35 -0
- package/dist/schemas/upwork-account/upwork-scraping-account.d.ts +90 -0
- package/dist/schemas/upwork-account/upwork-scraping-account.js +29 -0
- package/dist/schemas/user/index.js +41 -38
- package/dist/types/account/account-status.js +2 -1
- package/dist/types/account/bidder-account.js +2 -1
- package/dist/types/account/index.js +19 -3
- package/dist/types/account/manager-account.d.ts +7 -0
- package/dist/types/account/manager-account.js +2 -0
- package/dist/types/account/scraper-account.js +2 -1
- package/dist/types/ai/ai-config.js +2 -1
- package/dist/types/ai/index.js +19 -3
- package/dist/types/ai/proposal.js +2 -1
- package/dist/types/ai/suitability.js +2 -1
- package/dist/types/bid/bid-result.js +2 -1
- package/dist/types/bid/bid.js +2 -1
- package/dist/types/bid/index.js +18 -2
- package/dist/types/bidding/index.d.ts +1 -0
- package/dist/types/bidding/index.js +17 -0
- package/dist/types/bidding/proposal-bidding-status.d.ts +3 -0
- package/dist/types/bidding/proposal-bidding-status.js +2 -0
- package/dist/types/campaign/campaign-analytics.js +2 -1
- package/dist/types/campaign/campaign-expenses.js +2 -1
- package/dist/types/campaign/campaign-insights.js +2 -1
- package/dist/types/campaign/campaign-integrations.js +2 -1
- package/dist/types/campaign/campaign-job-count.js +2 -1
- package/dist/types/campaign/campaign.js +2 -1
- package/dist/types/campaign/index.js +22 -6
- package/dist/types/chat-message/chat-message.js +2 -1
- package/dist/types/chat-message/index.js +17 -1
- package/dist/types/config/agency-config.js +2 -1
- package/dist/types/config/index.js +17 -1
- package/dist/types/index.js +29 -15
- package/dist/types/job/index.js +19 -3
- package/dist/types/job/job-details.d.ts +36 -0
- package/dist/types/job/job-details.js +2 -0
- package/dist/types/job/job-note.js +2 -1
- package/dist/types/job/job-status.js +4 -1
- package/dist/types/job/job.d.ts +36 -0
- package/dist/types/job/job.js +2 -0
- package/dist/types/job-filters/index.js +17 -1
- package/dist/types/job-filters/job-filters.js +2 -1
- package/dist/types/logger/index.js +17 -1
- package/dist/types/logger/log-event.js +2 -1
- package/dist/types/saved-search/index.js +2 -1
- package/dist/types/scraper/index.js +18 -2
- package/dist/types/scraper/scrape-payload.js +2 -1
- package/dist/types/scraper/scrape-result.js +2 -1
- package/dist/types/time-filter/index.js +2 -1
- package/dist/types/upwork-account/index.d.ts +3 -0
- package/dist/types/upwork-account/index.js +19 -0
- package/dist/types/upwork-account/upwork-account-status.d.ts +3 -0
- package/dist/types/upwork-account/upwork-account-status.js +2 -0
- package/dist/types/upwork-account/upwork-business-manager-account.d.ts +7 -0
- package/dist/types/upwork-account/upwork-business-manager-account.js +2 -0
- package/dist/types/upwork-account/upwork-scraping-account.d.ts +5 -0
- package/dist/types/upwork-account/upwork-scraping-account.js +2 -0
- package/dist/types/user/index.js +2 -1
- package/dist/utils/index.js +17 -1
- package/dist/utils/try-catch.js +23 -8
- package/package.json +1 -1
- package/dist/schemas/event/index.d.ts +0 -58
- package/dist/schemas/lead/nuxt.js +0 -287
- package/dist/schemas/organization/member.js +0 -7
- package/dist/schemas/organization/subscription.js +0 -17
- package/dist/schemas/proxy/proxy-available-replacements.js +0 -3
- package/dist/schemas/proxy/proxy-country.js +0 -249
- package/dist/schemas/tier/index.d.ts +0 -119
- package/dist/schemas/transaction/index.js +0 -17
- package/dist/schemas/usage/index.js +0 -18
- package/dist/types/job/nuxt.js +0 -1
- package/dist/types/shared.js +0 -1
- package/dist/types/transaction/index.js +0 -1
- package/dist/types/usage/index.js +0 -1
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
import { z } from "zod";
|
|
2
|
+
import { SavedSearch } from "../saved-search";
|
|
3
|
+
import { LeadNote } from "./job-note";
|
|
4
|
+
import { LeadAgentStatus, LeadStatus } from "./job-status";
|
|
5
|
+
import { QuestionAnswerPair } from "../ai";
|
|
6
|
+
import { clientInfoSchema, jobListItemSchema, leadResponseSchema, leadSchema, jobSkillsSchema, metadataSchema, upworkJobSchema, vendorQualificationSchema, clientReviewSchema, bidRangeSchema, jobActivitySchema } from "../../schemas/lead/lead";
|
|
7
|
+
export interface Job extends z.infer<typeof upworkJobSchema> {
|
|
8
|
+
clientInfo: ClientInfo | null;
|
|
9
|
+
metadata: JobMetadata | null;
|
|
10
|
+
skills: JobSkill[] | null;
|
|
11
|
+
vendorQualifications: VendorQualifications | null;
|
|
12
|
+
}
|
|
13
|
+
export interface Lead extends z.infer<typeof leadSchema> {
|
|
14
|
+
clientInfo: ClientInfo | null;
|
|
15
|
+
metadata: JobMetadata | null;
|
|
16
|
+
skills: JobSkill[] | null;
|
|
17
|
+
vendorQualifications: VendorQualifications | null;
|
|
18
|
+
notes: LeadNote[] | null;
|
|
19
|
+
questionAnswerPairs: QuestionAnswerPair[] | null;
|
|
20
|
+
agentStatus: LeadAgentStatus;
|
|
21
|
+
leadStatus: LeadStatus;
|
|
22
|
+
}
|
|
23
|
+
export interface LeadResponse extends z.infer<typeof leadResponseSchema> {
|
|
24
|
+
leads: Lead[];
|
|
25
|
+
}
|
|
26
|
+
export type JobWithSavedSearch = Lead & {
|
|
27
|
+
savedSearch?: SavedSearch | null;
|
|
28
|
+
};
|
|
29
|
+
export type JobListItem = z.infer<typeof jobListItemSchema>;
|
|
30
|
+
export type JobSkill = z.infer<typeof jobSkillsSchema>;
|
|
31
|
+
export type VendorQualifications = z.infer<typeof vendorQualificationSchema>;
|
|
32
|
+
export type ClientInfo = z.infer<typeof clientInfoSchema>;
|
|
33
|
+
export type JobMetadata = z.infer<typeof metadataSchema>;
|
|
34
|
+
export type ClientReview = z.infer<typeof clientReviewSchema>;
|
|
35
|
+
export type JobBidRange = z.infer<typeof bidRangeSchema>;
|
|
36
|
+
export type JobActivity = z.infer<typeof jobActivitySchema>;
|
|
@@ -1 +1,17 @@
|
|
|
1
|
-
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("./job-filters"), exports);
|
|
@@ -1 +1,2 @@
|
|
|
1
|
-
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
@@ -1 +1,17 @@
|
|
|
1
|
-
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("./log-event"), exports);
|
|
@@ -1 +1,2 @@
|
|
|
1
|
-
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
@@ -1 +1,2 @@
|
|
|
1
|
-
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
@@ -1,2 +1,18 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("./scrape-payload"), exports);
|
|
18
|
+
__exportStar(require("./scrape-result"), exports);
|
|
@@ -1 +1,2 @@
|
|
|
1
|
-
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
@@ -1 +1,2 @@
|
|
|
1
|
-
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
@@ -1 +1,2 @@
|
|
|
1
|
-
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("./upwork-account-status"), exports);
|
|
18
|
+
__exportStar(require("./upwork-business-manager-account"), exports);
|
|
19
|
+
__exportStar(require("./upwork-scraping-account"), exports);
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
import { createUpworkBusinessManagerAccountSchema, updateUpworkBusinessManagerAccountSchema, upworkBusinessManagerAccountProvider, upworkBusinessManagerAccountSchema } from '../../schemas';
|
|
3
|
+
export interface UpworkBusinessManagerAccount extends z.infer<typeof upworkBusinessManagerAccountSchema> {
|
|
4
|
+
}
|
|
5
|
+
export type UpworkBusinessManagerAccountProvider = z.infer<typeof upworkBusinessManagerAccountProvider>;
|
|
6
|
+
export type CreateUpworkBusinessManagerAccount = z.infer<typeof createUpworkBusinessManagerAccountSchema>;
|
|
7
|
+
export type UpdateUpworkBusinessManagerAccount = z.infer<typeof updateUpworkBusinessManagerAccountSchema>;
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
import { createUpworkScraperAccountSchema, updateUpworkScraperAccountSchema, upworkScrapingAccountSchema } from '../../schemas';
|
|
3
|
+
export type UpworkScrapingAccount = z.infer<typeof upworkScrapingAccountSchema>;
|
|
4
|
+
export type CreateUpworkScraperAccount = z.infer<typeof createUpworkScraperAccountSchema>;
|
|
5
|
+
export type UpdateUpworkScraperAccount = z.infer<typeof updateUpworkScraperAccountSchema>;
|
package/dist/types/user/index.js
CHANGED
|
@@ -1 +1,2 @@
|
|
|
1
|
-
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
package/dist/utils/index.js
CHANGED
|
@@ -1 +1,17 @@
|
|
|
1
|
-
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("./try-catch"), exports);
|
package/dist/utils/try-catch.js
CHANGED
|
@@ -1,10 +1,25 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
3
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
4
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
5
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
6
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
7
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
8
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
9
|
+
});
|
|
10
|
+
};
|
|
11
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
+
exports.tryCatch = void 0;
|
|
1
13
|
// Main wrapper function
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
14
|
+
function tryCatch(promise) {
|
|
15
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
16
|
+
try {
|
|
17
|
+
const data = yield promise;
|
|
18
|
+
return { data, error: null };
|
|
19
|
+
}
|
|
20
|
+
catch (error) {
|
|
21
|
+
return { data: null, error: error };
|
|
22
|
+
}
|
|
23
|
+
});
|
|
10
24
|
}
|
|
25
|
+
exports.tryCatch = tryCatch;
|
package/package.json
CHANGED
|
@@ -1,58 +0,0 @@
|
|
|
1
|
-
export declare const logEventSchemaWithMetadata: import("zod").ZodIntersection<import("zod").ZodIntersection<import("zod").ZodObject<{
|
|
2
|
-
type: import("zod").ZodEnum<["scraperStarted", "scraperCompleted", "jobScraped", "jobScrapeFailed", "jobsIndexed", "jobDuplicateSkipped", "scraperFailed", "jobActivityScraped", "jobActivityScrapeFailed", "feedScrapeStarted", "feedScrapeCompleted", "feedScrapeFailed", "jobListingScraped", "jobSyncPublished", "jobSyncReceived", "leadsCreatedAndSynced", "suitabilityPending", "suitabilityProcessing", "suitabilityComplete", "suitabilityFailed", "manualSuitabilityAnalyzed", "proposalProcessing", "proposalComplete", "proposalFailed", "manualProposalGenerated", "biddingProcessing", "biddingComplete", "biddingFailed", "biddingSkipped", "biddingPending", "errorLogged", "cloudTaskRetry", "manualLeadEdited", "leadArchived", "auditTrailLogged"]>;
|
|
3
|
-
source: import("zod").ZodString;
|
|
4
|
-
resourceType: import("zod").ZodDefault<import("zod").ZodString>;
|
|
5
|
-
resourceId: import("zod").ZodNullable<import("zod").ZodString>;
|
|
6
|
-
leadId: import("zod").ZodNullable<import("zod").ZodString>;
|
|
7
|
-
campaignId: import("zod").ZodNullable<import("zod").ZodString>;
|
|
8
|
-
userId: import("zod").ZodNullable<import("zod").ZodString>;
|
|
9
|
-
reason: import("zod").ZodNullable<import("zod").ZodString>;
|
|
10
|
-
timestamp: import("zod").ZodNumber;
|
|
11
|
-
}, "strip", import("zod").ZodTypeAny, {
|
|
12
|
-
type: "scraperStarted" | "scraperCompleted" | "jobScraped" | "jobScrapeFailed" | "jobsIndexed" | "jobDuplicateSkipped" | "scraperFailed" | "jobActivityScraped" | "jobActivityScrapeFailed" | "feedScrapeStarted" | "feedScrapeCompleted" | "feedScrapeFailed" | "jobListingScraped" | "jobSyncPublished" | "jobSyncReceived" | "leadsCreatedAndSynced" | "suitabilityPending" | "suitabilityProcessing" | "suitabilityComplete" | "suitabilityFailed" | "manualSuitabilityAnalyzed" | "proposalProcessing" | "proposalComplete" | "proposalFailed" | "manualProposalGenerated" | "biddingProcessing" | "biddingComplete" | "biddingFailed" | "biddingSkipped" | "biddingPending" | "errorLogged" | "cloudTaskRetry" | "manualLeadEdited" | "leadArchived" | "auditTrailLogged";
|
|
13
|
-
source: string;
|
|
14
|
-
resourceType: string;
|
|
15
|
-
resourceId: string | null;
|
|
16
|
-
leadId: string | null;
|
|
17
|
-
campaignId: string | null;
|
|
18
|
-
userId: string | null;
|
|
19
|
-
reason: string | null;
|
|
20
|
-
timestamp: number;
|
|
21
|
-
}, {
|
|
22
|
-
type: "scraperStarted" | "scraperCompleted" | "jobScraped" | "jobScrapeFailed" | "jobsIndexed" | "jobDuplicateSkipped" | "scraperFailed" | "jobActivityScraped" | "jobActivityScrapeFailed" | "feedScrapeStarted" | "feedScrapeCompleted" | "feedScrapeFailed" | "jobListingScraped" | "jobSyncPublished" | "jobSyncReceived" | "leadsCreatedAndSynced" | "suitabilityPending" | "suitabilityProcessing" | "suitabilityComplete" | "suitabilityFailed" | "manualSuitabilityAnalyzed" | "proposalProcessing" | "proposalComplete" | "proposalFailed" | "manualProposalGenerated" | "biddingProcessing" | "biddingComplete" | "biddingFailed" | "biddingSkipped" | "biddingPending" | "errorLogged" | "cloudTaskRetry" | "manualLeadEdited" | "leadArchived" | "auditTrailLogged";
|
|
23
|
-
source: string;
|
|
24
|
-
resourceId: string | null;
|
|
25
|
-
leadId: string | null;
|
|
26
|
-
campaignId: string | null;
|
|
27
|
-
userId: string | null;
|
|
28
|
-
reason: string | null;
|
|
29
|
-
timestamp: number;
|
|
30
|
-
resourceType?: string | undefined;
|
|
31
|
-
}>, import("zod").ZodDiscriminatedUnion<"type", [import("zod").ZodObject<{
|
|
32
|
-
type: import("zod").ZodEnum<["jobActivityScraped"]>;
|
|
33
|
-
}, "strip", import("zod").ZodTypeAny, {
|
|
34
|
-
type: "jobActivityScraped";
|
|
35
|
-
}, {
|
|
36
|
-
type: "jobActivityScraped";
|
|
37
|
-
}>, import("zod").ZodObject<{
|
|
38
|
-
type: import("zod").ZodEnum<["scraperStarted", "scraperCompleted", "jobScraped", "jobScrapeFailed", "jobsIndexed", "jobDuplicateSkipped", "scraperFailed", "jobActivityScrapeFailed", "feedScrapeStarted", "feedScrapeCompleted", "feedScrapeFailed", "jobListingScraped", "jobSyncPublished", "jobSyncReceived", "leadsCreatedAndSynced", "suitabilityPending", "suitabilityProcessing", "suitabilityComplete", "suitabilityFailed", "manualSuitabilityAnalyzed", "proposalProcessing", "proposalComplete", "proposalFailed", "manualProposalGenerated", "biddingProcessing", "biddingComplete", "biddingFailed", "biddingSkipped", "biddingPending", "errorLogged", "cloudTaskRetry", "manualLeadEdited", "leadArchived", "auditTrailLogged"]>;
|
|
39
|
-
metadata: import("zod").ZodNullable<import("zod").ZodRecord<import("zod").ZodString, import("zod").ZodUnknown>>;
|
|
40
|
-
}, "strip", import("zod").ZodTypeAny, {
|
|
41
|
-
type: "scraperStarted" | "scraperCompleted" | "jobScraped" | "jobScrapeFailed" | "jobsIndexed" | "jobDuplicateSkipped" | "scraperFailed" | "jobActivityScrapeFailed" | "feedScrapeStarted" | "feedScrapeCompleted" | "feedScrapeFailed" | "jobListingScraped" | "jobSyncPublished" | "jobSyncReceived" | "leadsCreatedAndSynced" | "suitabilityPending" | "suitabilityProcessing" | "suitabilityComplete" | "suitabilityFailed" | "manualSuitabilityAnalyzed" | "proposalProcessing" | "proposalComplete" | "proposalFailed" | "manualProposalGenerated" | "biddingProcessing" | "biddingComplete" | "biddingFailed" | "biddingSkipped" | "biddingPending" | "errorLogged" | "cloudTaskRetry" | "manualLeadEdited" | "leadArchived" | "auditTrailLogged";
|
|
42
|
-
metadata: Record<string, unknown> | null;
|
|
43
|
-
}, {
|
|
44
|
-
type: "scraperStarted" | "scraperCompleted" | "jobScraped" | "jobScrapeFailed" | "jobsIndexed" | "jobDuplicateSkipped" | "scraperFailed" | "jobActivityScrapeFailed" | "feedScrapeStarted" | "feedScrapeCompleted" | "feedScrapeFailed" | "jobListingScraped" | "jobSyncPublished" | "jobSyncReceived" | "leadsCreatedAndSynced" | "suitabilityPending" | "suitabilityProcessing" | "suitabilityComplete" | "suitabilityFailed" | "manualSuitabilityAnalyzed" | "proposalProcessing" | "proposalComplete" | "proposalFailed" | "manualProposalGenerated" | "biddingProcessing" | "biddingComplete" | "biddingFailed" | "biddingSkipped" | "biddingPending" | "errorLogged" | "cloudTaskRetry" | "manualLeadEdited" | "leadArchived" | "auditTrailLogged";
|
|
45
|
-
metadata: Record<string, unknown> | null;
|
|
46
|
-
}>]>>, import("zod").ZodDiscriminatedUnion<"type", [import("zod").ZodObject<{
|
|
47
|
-
type: import("zod").ZodEnum<["jobActivityScraped"]>;
|
|
48
|
-
}, "strip", import("zod").ZodTypeAny, {
|
|
49
|
-
type: "jobActivityScraped";
|
|
50
|
-
}, {
|
|
51
|
-
type: "jobActivityScraped";
|
|
52
|
-
}>, import("zod").ZodObject<{
|
|
53
|
-
type: import("zod").ZodEnum<["jobActivityScraped"]>;
|
|
54
|
-
}, "strip", import("zod").ZodTypeAny, {
|
|
55
|
-
type: "jobActivityScraped";
|
|
56
|
-
}, {
|
|
57
|
-
type: "jobActivityScraped";
|
|
58
|
-
}>]>>;
|
|
@@ -1,287 +0,0 @@
|
|
|
1
|
-
import { any, array, boolean, number, object, record, string } from "zod";
|
|
2
|
-
const segmentationDataSchema = object({
|
|
3
|
-
customValue: string().nullable(),
|
|
4
|
-
label: string(),
|
|
5
|
-
name: string(),
|
|
6
|
-
sortOrder: number(),
|
|
7
|
-
type: string(),
|
|
8
|
-
value: string(),
|
|
9
|
-
skill: any().nullable(),
|
|
10
|
-
});
|
|
11
|
-
const clientActivitySchema = object({
|
|
12
|
-
lastBuyerActivity: string(),
|
|
13
|
-
totalApplicants: number(),
|
|
14
|
-
totalHired: number(),
|
|
15
|
-
totalInvitedToInterview: number(),
|
|
16
|
-
unansweredInvites: number(),
|
|
17
|
-
invitationsSent: number(),
|
|
18
|
-
numberOfPositionsToHire: number(),
|
|
19
|
-
});
|
|
20
|
-
const annotationsSchema = object({
|
|
21
|
-
tags: array(string()),
|
|
22
|
-
});
|
|
23
|
-
const budgetSchema = object({
|
|
24
|
-
amount: number(),
|
|
25
|
-
currencyCode: string(),
|
|
26
|
-
});
|
|
27
|
-
const engagementDurationSchema = object({
|
|
28
|
-
label: string(),
|
|
29
|
-
weeks: number(),
|
|
30
|
-
});
|
|
31
|
-
const extendedBudgetInfoSchema = object({
|
|
32
|
-
hourlyBudgetMin: number().nullable(),
|
|
33
|
-
hourlyBudgetMax: number().nullable(),
|
|
34
|
-
hourlyBudgetType: string().nullable(),
|
|
35
|
-
});
|
|
36
|
-
const qualificationsSchema = object({
|
|
37
|
-
countries: any().nullable(),
|
|
38
|
-
earnings: any().nullable(),
|
|
39
|
-
groupRecno: any().nullable(),
|
|
40
|
-
languages: any().nullable(),
|
|
41
|
-
localDescription: any().nullable(),
|
|
42
|
-
localFlexibilityDescription: any().nullable(),
|
|
43
|
-
localMarket: boolean(),
|
|
44
|
-
minJobSuccessScore: number(),
|
|
45
|
-
minOdeskHours: number(),
|
|
46
|
-
onSiteType: any().nullable(),
|
|
47
|
-
prefEnglishSkill: number(),
|
|
48
|
-
regions: any().nullable(),
|
|
49
|
-
risingTalent: boolean(),
|
|
50
|
-
shouldHavePortfolio: boolean(),
|
|
51
|
-
states: any().nullable(),
|
|
52
|
-
tests: any().nullable(),
|
|
53
|
-
timezones: any().nullable(),
|
|
54
|
-
type: number(),
|
|
55
|
-
locationCheckRequired: boolean(),
|
|
56
|
-
group: any().nullable(),
|
|
57
|
-
location: any().nullable(),
|
|
58
|
-
locations: any().nullable(),
|
|
59
|
-
});
|
|
60
|
-
const jobSchema = object({
|
|
61
|
-
status: number(),
|
|
62
|
-
category: object({
|
|
63
|
-
name: string(),
|
|
64
|
-
urlSlug: string(),
|
|
65
|
-
}),
|
|
66
|
-
categoryGroup: object({
|
|
67
|
-
name: string(),
|
|
68
|
-
urlSlug: string(),
|
|
69
|
-
}),
|
|
70
|
-
budget: budgetSchema,
|
|
71
|
-
postedOn: string(),
|
|
72
|
-
publishTime: string(),
|
|
73
|
-
wasRenewed: boolean(),
|
|
74
|
-
startDate: string().nullable(),
|
|
75
|
-
deliveryDate: string().nullable(),
|
|
76
|
-
workload: string().nullable(),
|
|
77
|
-
engagementDuration: engagementDurationSchema,
|
|
78
|
-
extendedBudgetInfo: extendedBudgetInfoSchema,
|
|
79
|
-
contractorTier: number(),
|
|
80
|
-
description: string(),
|
|
81
|
-
segmentationData: array(segmentationDataSchema),
|
|
82
|
-
clientActivity: clientActivitySchema,
|
|
83
|
-
annotations: annotationsSchema,
|
|
84
|
-
uid: string(),
|
|
85
|
-
title: string(),
|
|
86
|
-
type: number(),
|
|
87
|
-
ciphertext: string(),
|
|
88
|
-
access: number(),
|
|
89
|
-
createdOn: string(),
|
|
90
|
-
hideBudget: boolean(),
|
|
91
|
-
notSureProjectDuration: boolean(),
|
|
92
|
-
notSureFreelancersToHire: boolean(),
|
|
93
|
-
notSureExperienceLevel: boolean(),
|
|
94
|
-
numberOfPositionsToHire: number(),
|
|
95
|
-
isContractToHire: boolean(),
|
|
96
|
-
attachments: array(any()),
|
|
97
|
-
isPremium: boolean(),
|
|
98
|
-
qualifications: qualificationsSchema,
|
|
99
|
-
questions: array(object({ question: string(), position: number() })),
|
|
100
|
-
durationIdV3: number(),
|
|
101
|
-
durationLabel: string(),
|
|
102
|
-
});
|
|
103
|
-
const buyerSchema = object({
|
|
104
|
-
isEnterprise: boolean(),
|
|
105
|
-
isPaymentMethodVerified: boolean(),
|
|
106
|
-
stats: object({
|
|
107
|
-
totalAssignments: number(),
|
|
108
|
-
activeAssignmentsCount: number(),
|
|
109
|
-
hoursCount: number(),
|
|
110
|
-
feedbackCount: number(),
|
|
111
|
-
score: number(),
|
|
112
|
-
totalJobsWithHires: number(),
|
|
113
|
-
totalCharges: object({
|
|
114
|
-
amount: number(),
|
|
115
|
-
}),
|
|
116
|
-
}),
|
|
117
|
-
location: object({
|
|
118
|
-
offsetFromUtcMillis: number(),
|
|
119
|
-
countryTimezone: string(),
|
|
120
|
-
city: string(),
|
|
121
|
-
country: string(),
|
|
122
|
-
}),
|
|
123
|
-
company: object({
|
|
124
|
-
isEDCReplicated: any().nullable(),
|
|
125
|
-
contractDate: string(),
|
|
126
|
-
profile: object({
|
|
127
|
-
industry: string(),
|
|
128
|
-
size: number(),
|
|
129
|
-
}),
|
|
130
|
-
name: string().nullable(),
|
|
131
|
-
}),
|
|
132
|
-
jobs: object({
|
|
133
|
-
postedCount: number(),
|
|
134
|
-
openCount: number(),
|
|
135
|
-
}),
|
|
136
|
-
avgHourlyJobsRate: object({
|
|
137
|
-
amount: number(),
|
|
138
|
-
}).nullable(),
|
|
139
|
-
});
|
|
140
|
-
const currentUserInfoSchema = object({
|
|
141
|
-
owner: boolean(),
|
|
142
|
-
freelancerInfo: object({
|
|
143
|
-
profileState: string(),
|
|
144
|
-
applied: any().nullable(),
|
|
145
|
-
devProfileCiphertext: string(),
|
|
146
|
-
hired: any().nullable(),
|
|
147
|
-
application: record(any()),
|
|
148
|
-
pendingInvite: record(any()),
|
|
149
|
-
contract: any().nullable(),
|
|
150
|
-
hourlyRate: object({
|
|
151
|
-
amount: number(),
|
|
152
|
-
}),
|
|
153
|
-
qualificationsMatches: object({
|
|
154
|
-
matches: array(object({
|
|
155
|
-
clientPreferred: string(),
|
|
156
|
-
clientPreferredLabel: string().nullable(),
|
|
157
|
-
freelancerValue: string(),
|
|
158
|
-
freelancerValueLabel: string(),
|
|
159
|
-
qualification: number(),
|
|
160
|
-
qualified: boolean(),
|
|
161
|
-
})),
|
|
162
|
-
}),
|
|
163
|
-
}),
|
|
164
|
-
});
|
|
165
|
-
const workHistorySchema = array(object({
|
|
166
|
-
isPtcJob: any().nullable(),
|
|
167
|
-
status: any().nullable(),
|
|
168
|
-
isEDCReplicated: any().nullable(),
|
|
169
|
-
startDate: string(),
|
|
170
|
-
endDate: string(),
|
|
171
|
-
totalCharge: number(),
|
|
172
|
-
totalHours: number(),
|
|
173
|
-
jobInfo: object({
|
|
174
|
-
title: string(),
|
|
175
|
-
id: any().nullable(),
|
|
176
|
-
uid: any().nullable(),
|
|
177
|
-
access: number(),
|
|
178
|
-
type: number(),
|
|
179
|
-
ciphertext: any().nullable(),
|
|
180
|
-
}),
|
|
181
|
-
contractorInfo: object({
|
|
182
|
-
contractorName: string(),
|
|
183
|
-
accessType: string(),
|
|
184
|
-
ciphertext: string(),
|
|
185
|
-
}),
|
|
186
|
-
rate: object({
|
|
187
|
-
amount: number(),
|
|
188
|
-
}).nullable(),
|
|
189
|
-
feedback: object({
|
|
190
|
-
feedbackSuppressed: boolean(),
|
|
191
|
-
score: number(),
|
|
192
|
-
comment: string(),
|
|
193
|
-
feedback_suppressed: boolean(),
|
|
194
|
-
}),
|
|
195
|
-
feedbackToClient: object({
|
|
196
|
-
feedbackSuppressed: boolean(),
|
|
197
|
-
score: number(),
|
|
198
|
-
comment: string(),
|
|
199
|
-
feedback_suppressed: boolean(),
|
|
200
|
-
}),
|
|
201
|
-
isEDCPublic: boolean(),
|
|
202
|
-
}));
|
|
203
|
-
const sandsSchema = object({
|
|
204
|
-
occupation: object({
|
|
205
|
-
freeText: string().nullable(),
|
|
206
|
-
ontologyId: string(),
|
|
207
|
-
prefLabel: string(),
|
|
208
|
-
id: string(),
|
|
209
|
-
uid: string(),
|
|
210
|
-
}),
|
|
211
|
-
ontologySkills: array(any()),
|
|
212
|
-
additionalSkills: array(object({
|
|
213
|
-
uid: string(),
|
|
214
|
-
name: string(),
|
|
215
|
-
isFreeText: boolean(),
|
|
216
|
-
})),
|
|
217
|
-
});
|
|
218
|
-
const connectsSchema = object({
|
|
219
|
-
pricing: object({
|
|
220
|
-
price: number(),
|
|
221
|
-
context: string(),
|
|
222
|
-
auctionPrice: number(),
|
|
223
|
-
}),
|
|
224
|
-
requiredConnects: number(),
|
|
225
|
-
availableConnects: number(),
|
|
226
|
-
chooseConnectsStatus: object({
|
|
227
|
-
isExplainerModalShown: boolean().nullable(),
|
|
228
|
-
}),
|
|
229
|
-
canSeeApplicantsRates: boolean(),
|
|
230
|
-
});
|
|
231
|
-
const authSchema = object({
|
|
232
|
-
canFlagOpening: boolean(),
|
|
233
|
-
canPostJob: boolean(),
|
|
234
|
-
domestic: object({
|
|
235
|
-
country: string().nullable(),
|
|
236
|
-
isInfographicTooltipAvailable: boolean(),
|
|
237
|
-
}),
|
|
238
|
-
});
|
|
239
|
-
const applicationContextSchema = object({
|
|
240
|
-
freelancerAllowed: boolean(),
|
|
241
|
-
clientAllowed: boolean(),
|
|
242
|
-
userIntentEvaluation: object({
|
|
243
|
-
isDeclined: boolean(),
|
|
244
|
-
reason: string().nullable(),
|
|
245
|
-
}),
|
|
246
|
-
canApplyOnBehalfOfAgencyFreelancers: boolean(),
|
|
247
|
-
canSubmitMoreProposals: boolean(),
|
|
248
|
-
submittedProposals: any().nullable(),
|
|
249
|
-
});
|
|
250
|
-
export const nuxtStateJobSchema = object({
|
|
251
|
-
cache: boolean(),
|
|
252
|
-
job: jobSchema,
|
|
253
|
-
buyer: buyerSchema,
|
|
254
|
-
currentUserInfo: currentUserInfoSchema,
|
|
255
|
-
isVisitor: boolean(),
|
|
256
|
-
openJobs: array(any()),
|
|
257
|
-
workHistory: workHistorySchema,
|
|
258
|
-
similarJobs: array(any()),
|
|
259
|
-
sands: sandsSchema,
|
|
260
|
-
auth: authSchema,
|
|
261
|
-
applicants: object({
|
|
262
|
-
applicantsBidsStats: any().nullable(),
|
|
263
|
-
}),
|
|
264
|
-
connects: connectsSchema.nullish(),
|
|
265
|
-
enterpriseJobAdditionalInfo: record(any()),
|
|
266
|
-
applicationContext: applicationContextSchema,
|
|
267
|
-
profileMatchServiceUid: string(),
|
|
268
|
-
seo: object({
|
|
269
|
-
title: string(),
|
|
270
|
-
description: string(),
|
|
271
|
-
url: string(),
|
|
272
|
-
}),
|
|
273
|
-
teamUid: any().nullable(),
|
|
274
|
-
proposalPermissions: object({
|
|
275
|
-
freelancerAllowed: boolean(),
|
|
276
|
-
clientAllowed: boolean(),
|
|
277
|
-
}),
|
|
278
|
-
jobSlug: any().nullable(),
|
|
279
|
-
prefillWith: any().nullable(),
|
|
280
|
-
isGroupOpportunity: boolean(),
|
|
281
|
-
workLocation: any().nullable(),
|
|
282
|
-
isPhoneVerified: boolean(),
|
|
283
|
-
errorResponse: any().nullable(),
|
|
284
|
-
isApplyBlocked: boolean(),
|
|
285
|
-
hasAiInterview: boolean(),
|
|
286
|
-
talentFeePromotion: boolean().nullish(),
|
|
287
|
-
});
|
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
import { number, object, string, z } from "zod";
|
|
2
|
-
export const subscriptionStatusEnum = z.enum([
|
|
3
|
-
"active",
|
|
4
|
-
"trialing",
|
|
5
|
-
"cancelled",
|
|
6
|
-
"paused",
|
|
7
|
-
]);
|
|
8
|
-
export const subscriptionSourceEnum = z.enum(["stripe", "manual"]);
|
|
9
|
-
export const organizationSubscriptionSchema = object({
|
|
10
|
-
tierId: string(),
|
|
11
|
-
status: subscriptionStatusEnum,
|
|
12
|
-
creditsRemaining: number(),
|
|
13
|
-
startedAt: number(),
|
|
14
|
-
currentPeriodEnd: number(),
|
|
15
|
-
stripeSubscriptionId: string(),
|
|
16
|
-
source: subscriptionSourceEnum,
|
|
17
|
-
});
|