lancer-shared 1.2.0 → 1.2.1
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 +1 -0
- package/dist/schemas/organization/index.d.ts +8 -0
- package/dist/schemas/organization/organization.d.ts +22 -118
- package/package.json +1 -1
- package/dist/constants/collections.js +0 -14
- package/dist/constants/common-questions.js +0 -57
- package/dist/constants/index.js +0 -18
- package/dist/constants/job-filter-options.js +0 -265
- package/dist/constants/job-status.js +0 -21
- package/dist/constants/mappings/countryMapping.js +0 -120
- package/dist/constants/mappings/regionMapping.js +0 -240
- package/dist/constants/routes.js +0 -116
- package/dist/constants/upwork-accounts.js +0 -18
- package/dist/index.js +0 -4
- package/dist/schemas/account/account-status.js +0 -8
- package/dist/schemas/account/bidder-account.js +0 -35
- package/dist/schemas/account/index.js +0 -3
- package/dist/schemas/account/scraper-account.js +0 -34
- package/dist/schemas/ai/ai-config.d.ts +0 -36
- package/dist/schemas/ai/ai-config.js +0 -9
- package/dist/schemas/ai/index.d.ts +0 -3
- package/dist/schemas/ai/index.js +0 -3
- package/dist/schemas/ai/proposal.d.ts +0 -82
- package/dist/schemas/ai/proposal.js +0 -13
- package/dist/schemas/ai/suitability.d.ts +0 -37
- package/dist/schemas/ai/suitability.js +0 -14
- package/dist/schemas/bid/bid-result.js +0 -11
- package/dist/schemas/bid/bid.js +0 -35
- package/dist/schemas/bid/index.js +0 -2
- package/dist/schemas/campaign/campaign-ai-metrics.js +0 -6
- package/dist/schemas/campaign/campaign-analytics.js +0 -42
- package/dist/schemas/campaign/campaign-expenses.js +0 -6
- package/dist/schemas/campaign/campaign-insights.js +0 -31
- package/dist/schemas/campaign/campaign-integrations.js +0 -13
- package/dist/schemas/campaign/campaign-job-count.js +0 -3
- package/dist/schemas/campaign/campaign.js +0 -41
- package/dist/schemas/campaign/index.js +0 -7
- package/dist/schemas/chat-message/chat-message.js +0 -10
- package/dist/schemas/chat-message/index.js +0 -1
- package/dist/schemas/config/agency-config.js +0 -7
- package/dist/schemas/config/index.js +0 -1
- package/dist/schemas/event/index.d.ts +0 -58
- package/dist/schemas/index.js +0 -17
- package/dist/schemas/job/index.d.ts +0 -95
- package/dist/schemas/job-filters/index.js +0 -1
- package/dist/schemas/job-filters/job-filters.js +0 -84
- package/dist/schemas/lead/index.js +0 -173
- package/dist/schemas/lead/lead-note.js +0 -27
- package/dist/schemas/lead/lead-status.js +0 -23
- package/dist/schemas/lead/nuxt.js +0 -287
- package/dist/schemas/logger/index.js +0 -1
- package/dist/schemas/logger/log-event.js +0 -117
- package/dist/schemas/organization/index.js +0 -70
- package/dist/schemas/organization/member.js +0 -7
- package/dist/schemas/organization/organization.js +0 -16
- package/dist/schemas/organization/subscription.js +0 -17
- package/dist/schemas/proxy/index.js +0 -3
- package/dist/schemas/proxy/proxy-available-replacements.js +0 -3
- package/dist/schemas/proxy/proxy-country.js +0 -249
- package/dist/schemas/proxy/proxy.js +0 -29
- package/dist/schemas/saved-search/index.js +0 -9
- package/dist/schemas/scraper/index.js +0 -2
- package/dist/schemas/scraper/scrape-payload.js +0 -21
- package/dist/schemas/scraper/scrape-result.js +0 -23
- package/dist/schemas/shared.js +0 -19
- package/dist/schemas/time-filter/index.js +0 -6
- package/dist/schemas/transaction/index.js +0 -17
- package/dist/schemas/usage/index.js +0 -18
- package/dist/schemas/user/index.js +0 -52
- package/dist/types/account/account-status.js +0 -1
- package/dist/types/account/bidder-account.js +0 -1
- package/dist/types/account/index.js +0 -3
- package/dist/types/account/scraper-account.js +0 -1
- package/dist/types/ai/ai-config.d.ts +0 -6
- package/dist/types/ai/ai-config.js +0 -1
- package/dist/types/ai/index.d.ts +0 -3
- package/dist/types/ai/index.js +0 -3
- package/dist/types/ai/proposal.d.ts +0 -10
- package/dist/types/ai/proposal.js +0 -1
- package/dist/types/ai/suitability.d.ts +0 -6
- package/dist/types/ai/suitability.js +0 -1
- package/dist/types/bid/bid-result.js +0 -1
- package/dist/types/bid/bid.js +0 -1
- package/dist/types/bid/index.js +0 -2
- package/dist/types/campaign/campaign-analytics.js +0 -1
- package/dist/types/campaign/campaign-expenses.js +0 -1
- package/dist/types/campaign/campaign-insights.js +0 -1
- package/dist/types/campaign/campaign-integrations.js +0 -1
- package/dist/types/campaign/campaign-job-count.js +0 -1
- package/dist/types/campaign/campaign.js +0 -1
- package/dist/types/campaign/index.js +0 -6
- package/dist/types/chat-message/chat-message.js +0 -1
- package/dist/types/chat-message/index.js +0 -1
- package/dist/types/config/agency-config.js +0 -1
- package/dist/types/config/index.js +0 -1
- package/dist/types/index.js +0 -15
- package/dist/types/job/index.js +0 -3
- package/dist/types/job/job-note.js +0 -1
- package/dist/types/job/job-status.js +0 -9
- package/dist/types/job/nuxt.js +0 -1
- package/dist/types/job-filters/index.js +0 -1
- package/dist/types/job-filters/job-filters.js +0 -1
- package/dist/types/logger/index.js +0 -1
- package/dist/types/logger/log-event.js +0 -1
- package/dist/types/saved-search/index.js +0 -1
- package/dist/types/scraper/index.js +0 -2
- package/dist/types/scraper/scrape-payload.js +0 -1
- package/dist/types/scraper/scrape-result.js +0 -1
- package/dist/types/shared.js +0 -1
- package/dist/types/time-filter/index.js +0 -1
- package/dist/types/transaction/index.js +0 -1
- package/dist/types/usage/index.js +0 -1
- package/dist/types/user/index.js +0 -1
- package/dist/utils/index.js +0 -1
- package/dist/utils/try-catch.js +0 -10
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
import { z } from 'zod';
|
|
2
|
-
export const bidConfigSchema = z.object({
|
|
3
|
-
agencyName: z.string().nullable(),
|
|
4
|
-
bidderId: z.string().nullable(),
|
|
5
|
-
contractorName: z.string().nullable(),
|
|
6
|
-
specialisedProfile: z.string().nullable(),
|
|
7
|
-
});
|
|
8
|
-
export const organizationTypeSchema = z.enum(['agency', 'freelancer']);
|
|
9
|
-
export const organizationSchema = z.object({
|
|
10
|
-
id: z.string(),
|
|
11
|
-
name: z.string(),
|
|
12
|
-
type: organizationTypeSchema,
|
|
13
|
-
bidConfig: bidConfigSchema,
|
|
14
|
-
createdAt: z.date(),
|
|
15
|
-
updatedAt: z.date(),
|
|
16
|
-
});
|
|
@@ -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
|
-
});
|
|
@@ -1,249 +0,0 @@
|
|
|
1
|
-
import { z } from 'zod';
|
|
2
|
-
export const proxyCountrySchema = z.enum([
|
|
3
|
-
'US',
|
|
4
|
-
'CA',
|
|
5
|
-
'GB',
|
|
6
|
-
'AF',
|
|
7
|
-
'AX',
|
|
8
|
-
'AL',
|
|
9
|
-
'DZ',
|
|
10
|
-
'AS',
|
|
11
|
-
'AD',
|
|
12
|
-
'AO',
|
|
13
|
-
'AI',
|
|
14
|
-
'AQ',
|
|
15
|
-
'AG',
|
|
16
|
-
'AR',
|
|
17
|
-
'AM',
|
|
18
|
-
'AW',
|
|
19
|
-
'AU',
|
|
20
|
-
'AT',
|
|
21
|
-
'AZ',
|
|
22
|
-
'BS',
|
|
23
|
-
'BH',
|
|
24
|
-
'BD',
|
|
25
|
-
'BB',
|
|
26
|
-
'BY',
|
|
27
|
-
'BE',
|
|
28
|
-
'BZ',
|
|
29
|
-
'BJ',
|
|
30
|
-
'BM',
|
|
31
|
-
'BT',
|
|
32
|
-
'BO',
|
|
33
|
-
'BA',
|
|
34
|
-
'BW',
|
|
35
|
-
'BV',
|
|
36
|
-
'BR',
|
|
37
|
-
'IO',
|
|
38
|
-
'BN',
|
|
39
|
-
'BG',
|
|
40
|
-
'BF',
|
|
41
|
-
'BI',
|
|
42
|
-
'KH',
|
|
43
|
-
'CM',
|
|
44
|
-
'CV',
|
|
45
|
-
'KY',
|
|
46
|
-
'CF',
|
|
47
|
-
'TD',
|
|
48
|
-
'CL',
|
|
49
|
-
'CN',
|
|
50
|
-
'CX',
|
|
51
|
-
'CC',
|
|
52
|
-
'CO',
|
|
53
|
-
'KM',
|
|
54
|
-
'CG',
|
|
55
|
-
'CD',
|
|
56
|
-
'CK',
|
|
57
|
-
'CR',
|
|
58
|
-
'CI',
|
|
59
|
-
'HR',
|
|
60
|
-
'CU',
|
|
61
|
-
'CY',
|
|
62
|
-
'CZ',
|
|
63
|
-
'DK',
|
|
64
|
-
'DJ',
|
|
65
|
-
'DM',
|
|
66
|
-
'DO',
|
|
67
|
-
'EC',
|
|
68
|
-
'EG',
|
|
69
|
-
'SV',
|
|
70
|
-
'GQ',
|
|
71
|
-
'ER',
|
|
72
|
-
'EE',
|
|
73
|
-
'ET',
|
|
74
|
-
'FK',
|
|
75
|
-
'FO',
|
|
76
|
-
'FJ',
|
|
77
|
-
'FI',
|
|
78
|
-
'FR',
|
|
79
|
-
'GF',
|
|
80
|
-
'PF',
|
|
81
|
-
'TF',
|
|
82
|
-
'GA',
|
|
83
|
-
'GM',
|
|
84
|
-
'GE',
|
|
85
|
-
'DE',
|
|
86
|
-
'GH',
|
|
87
|
-
'GI',
|
|
88
|
-
'GR',
|
|
89
|
-
'GL',
|
|
90
|
-
'GD',
|
|
91
|
-
'GP',
|
|
92
|
-
'GU',
|
|
93
|
-
'GT',
|
|
94
|
-
'GG',
|
|
95
|
-
'GN',
|
|
96
|
-
'GW',
|
|
97
|
-
'GY',
|
|
98
|
-
'HT',
|
|
99
|
-
'HM',
|
|
100
|
-
'VA',
|
|
101
|
-
'HN',
|
|
102
|
-
'HK',
|
|
103
|
-
'HU',
|
|
104
|
-
'IS',
|
|
105
|
-
'IN',
|
|
106
|
-
'ID',
|
|
107
|
-
'IR',
|
|
108
|
-
'IQ',
|
|
109
|
-
'IE',
|
|
110
|
-
'IM',
|
|
111
|
-
'IL',
|
|
112
|
-
'IT',
|
|
113
|
-
'JM',
|
|
114
|
-
'JP',
|
|
115
|
-
'JE',
|
|
116
|
-
'JO',
|
|
117
|
-
'KZ',
|
|
118
|
-
'KE',
|
|
119
|
-
'KI',
|
|
120
|
-
'KP',
|
|
121
|
-
'KR',
|
|
122
|
-
'KW',
|
|
123
|
-
'KG',
|
|
124
|
-
'LA',
|
|
125
|
-
'LV',
|
|
126
|
-
'LB',
|
|
127
|
-
'LS',
|
|
128
|
-
'LR',
|
|
129
|
-
'LY',
|
|
130
|
-
'LI',
|
|
131
|
-
'LT',
|
|
132
|
-
'LU',
|
|
133
|
-
'MO',
|
|
134
|
-
'MK',
|
|
135
|
-
'MG',
|
|
136
|
-
'MW',
|
|
137
|
-
'MY',
|
|
138
|
-
'MV',
|
|
139
|
-
'ML',
|
|
140
|
-
'MT',
|
|
141
|
-
'MH',
|
|
142
|
-
'MQ',
|
|
143
|
-
'MR',
|
|
144
|
-
'MU',
|
|
145
|
-
'YT',
|
|
146
|
-
'MX',
|
|
147
|
-
'FM',
|
|
148
|
-
'MD',
|
|
149
|
-
'MC',
|
|
150
|
-
'MN',
|
|
151
|
-
'ME',
|
|
152
|
-
'MS',
|
|
153
|
-
'MA',
|
|
154
|
-
'MZ',
|
|
155
|
-
'MM',
|
|
156
|
-
'NA',
|
|
157
|
-
'NR',
|
|
158
|
-
'NP',
|
|
159
|
-
'NL',
|
|
160
|
-
'AN',
|
|
161
|
-
'NC',
|
|
162
|
-
'NZ',
|
|
163
|
-
'NI',
|
|
164
|
-
'NE',
|
|
165
|
-
'NG',
|
|
166
|
-
'NU',
|
|
167
|
-
'NF',
|
|
168
|
-
'MP',
|
|
169
|
-
'NO',
|
|
170
|
-
'OM',
|
|
171
|
-
'PK',
|
|
172
|
-
'PW',
|
|
173
|
-
'PS',
|
|
174
|
-
'PA',
|
|
175
|
-
'PG',
|
|
176
|
-
'PY',
|
|
177
|
-
'PE',
|
|
178
|
-
'PH',
|
|
179
|
-
'PN',
|
|
180
|
-
'PL',
|
|
181
|
-
'PT',
|
|
182
|
-
'PR',
|
|
183
|
-
'QA',
|
|
184
|
-
'RE',
|
|
185
|
-
'RO',
|
|
186
|
-
'RU',
|
|
187
|
-
'RW',
|
|
188
|
-
'BL',
|
|
189
|
-
'SH',
|
|
190
|
-
'KN',
|
|
191
|
-
'LC',
|
|
192
|
-
'MF',
|
|
193
|
-
'PM',
|
|
194
|
-
'VC',
|
|
195
|
-
'WS',
|
|
196
|
-
'SM',
|
|
197
|
-
'ST',
|
|
198
|
-
'SA',
|
|
199
|
-
'SN',
|
|
200
|
-
'RS',
|
|
201
|
-
'SC',
|
|
202
|
-
'SL',
|
|
203
|
-
'SG',
|
|
204
|
-
'SK',
|
|
205
|
-
'SI',
|
|
206
|
-
'SB',
|
|
207
|
-
'SO',
|
|
208
|
-
'ZA',
|
|
209
|
-
'GS',
|
|
210
|
-
'ES',
|
|
211
|
-
'LK',
|
|
212
|
-
'SD',
|
|
213
|
-
'SR',
|
|
214
|
-
'SJ',
|
|
215
|
-
'SZ',
|
|
216
|
-
'SE',
|
|
217
|
-
'CH',
|
|
218
|
-
'SY',
|
|
219
|
-
'TW',
|
|
220
|
-
'TJ',
|
|
221
|
-
'TZ',
|
|
222
|
-
'TH',
|
|
223
|
-
'TL',
|
|
224
|
-
'TG',
|
|
225
|
-
'TK',
|
|
226
|
-
'TO',
|
|
227
|
-
'TT',
|
|
228
|
-
'TN',
|
|
229
|
-
'TR',
|
|
230
|
-
'TM',
|
|
231
|
-
'TC',
|
|
232
|
-
'TV',
|
|
233
|
-
'UG',
|
|
234
|
-
'UA',
|
|
235
|
-
'AE',
|
|
236
|
-
'UM',
|
|
237
|
-
'UY',
|
|
238
|
-
'UZ',
|
|
239
|
-
'VU',
|
|
240
|
-
'VE',
|
|
241
|
-
'VN',
|
|
242
|
-
'VG',
|
|
243
|
-
'VI',
|
|
244
|
-
'WF',
|
|
245
|
-
'EH',
|
|
246
|
-
'YE',
|
|
247
|
-
'ZM',
|
|
248
|
-
'ZW',
|
|
249
|
-
]);
|
|
@@ -1,29 +0,0 @@
|
|
|
1
|
-
import { z } from 'zod';
|
|
2
|
-
import { proxyCountrySchema } from './proxy-country';
|
|
3
|
-
export const proxyStatusSchema = z.enum([
|
|
4
|
-
'invalid',
|
|
5
|
-
'valid',
|
|
6
|
-
'pending_validation',
|
|
7
|
-
]);
|
|
8
|
-
export const proxyProviderSchema = z.enum(['webshare']);
|
|
9
|
-
export const proxySchema = z.object({
|
|
10
|
-
id: z.string(),
|
|
11
|
-
externalId: z.string(),
|
|
12
|
-
host: z.string(),
|
|
13
|
-
port: z.number(),
|
|
14
|
-
username: z.string(),
|
|
15
|
-
password: z.string(),
|
|
16
|
-
provider: proxyProviderSchema,
|
|
17
|
-
fraudScore: z.number().nullable(),
|
|
18
|
-
claimedCountry: proxyCountrySchema,
|
|
19
|
-
status: proxyStatusSchema.nullable(),
|
|
20
|
-
country: proxyCountrySchema.nullable(),
|
|
21
|
-
bidderId: z.string().nullable(),
|
|
22
|
-
});
|
|
23
|
-
export const externalProxySchema = proxySchema.omit({
|
|
24
|
-
id: true,
|
|
25
|
-
bidderId: true,
|
|
26
|
-
status: true,
|
|
27
|
-
country: true,
|
|
28
|
-
fraudScore: true,
|
|
29
|
-
});
|
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
import { any, array, object, string } from "zod";
|
|
2
|
-
import { jobActivityOffsetHourSchema, jobListingSchema } from "../lead";
|
|
3
|
-
export const scrapePayloadSchema = object({
|
|
4
|
-
latestJobsUrls: array(string()),
|
|
5
|
-
cookies: array(any()),
|
|
6
|
-
username: string(),
|
|
7
|
-
password: string(),
|
|
8
|
-
});
|
|
9
|
-
export const scrapeUserProfilePayloadSchema = object({
|
|
10
|
-
profileUrl: string(),
|
|
11
|
-
cookies: array(any()),
|
|
12
|
-
username: string(),
|
|
13
|
-
password: string(),
|
|
14
|
-
});
|
|
15
|
-
export const scrapeJobPayloadSchema = object({
|
|
16
|
-
listing: jobListingSchema,
|
|
17
|
-
});
|
|
18
|
-
export const scrapeJobActivityPayloadSchema = object({
|
|
19
|
-
listing: jobListingSchema,
|
|
20
|
-
offsetHour: jobActivityOffsetHourSchema,
|
|
21
|
-
});
|
|
@@ -1,23 +0,0 @@
|
|
|
1
|
-
import { any, array, boolean, object, string } from "zod";
|
|
2
|
-
import { jobListingSchema, upworkJobSchema } from "../lead";
|
|
3
|
-
import { regionSchema } from "../shared";
|
|
4
|
-
import { upworkProfileSchema } from "../user";
|
|
5
|
-
export const scrapeResultSchema = object({
|
|
6
|
-
jobs: array(upworkJobSchema),
|
|
7
|
-
cookies: array(any()),
|
|
8
|
-
region: regionSchema,
|
|
9
|
-
usAccountCookies: array(any()).optional(),
|
|
10
|
-
ukAccountCookies: array(any()).optional(),
|
|
11
|
-
});
|
|
12
|
-
export const scrapeUserProfileResultSchema = object({
|
|
13
|
-
success: boolean(),
|
|
14
|
-
message: string(),
|
|
15
|
-
data: upworkProfileSchema,
|
|
16
|
-
});
|
|
17
|
-
export const scrapeFeedResultSchema = object({
|
|
18
|
-
listings: array(jobListingSchema),
|
|
19
|
-
cookies: array(any()),
|
|
20
|
-
region: regionSchema,
|
|
21
|
-
usAccountCookies: array(any()).optional(),
|
|
22
|
-
ukAccountCookies: array(any()).optional(),
|
|
23
|
-
});
|
package/dist/schemas/shared.js
DELETED
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
import { coerce, string, z } from "zod";
|
|
2
|
-
export const booleanSchema = z
|
|
3
|
-
.union([z.boolean(), z.literal("true"), z.literal("false")])
|
|
4
|
-
.transform((value) => value === true || value === "true");
|
|
5
|
-
export const dateSchema = (params = {}) => coerce.date({
|
|
6
|
-
...params,
|
|
7
|
-
});
|
|
8
|
-
export const passwordSchema = string()
|
|
9
|
-
.min(8, "Password must be at least 8 characters long.")
|
|
10
|
-
.max(255, "Password must be at most 255 characters long.")
|
|
11
|
-
.refine((password) => /[a-z]/.test(password), "Password must contain at least one lowercase letter.")
|
|
12
|
-
.refine((password) => /[A-Z]/.test(password), "Password must contain at least one uppercase letter.")
|
|
13
|
-
.refine((password) => /\d/.test(password), "Password must contain at least one number.")
|
|
14
|
-
.refine((password) => /[\W_]/.test(password), "Password must contain at least one symbol.");
|
|
15
|
-
export const regionSchema = z.union([
|
|
16
|
-
z.literal("USOnly"),
|
|
17
|
-
z.literal("UKOnly"),
|
|
18
|
-
z.literal("Worldwide"),
|
|
19
|
-
]);
|
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
import { number, object, string, z } from "zod";
|
|
2
|
-
export const transactionTypeEnum = z.enum(["subscription", "add-on", "refund"]);
|
|
3
|
-
export const transactionStatusEnum = z.enum([
|
|
4
|
-
"succeeded",
|
|
5
|
-
"failed",
|
|
6
|
-
"refunded",
|
|
7
|
-
]);
|
|
8
|
-
export const transactionSchema = object({
|
|
9
|
-
orgId: string(),
|
|
10
|
-
type: transactionTypeEnum,
|
|
11
|
-
creditsPurchased: number(),
|
|
12
|
-
creditsGranted: number().nullable(),
|
|
13
|
-
amountUsd: number(),
|
|
14
|
-
stripeInvoiceId: string(),
|
|
15
|
-
status: transactionStatusEnum,
|
|
16
|
-
timestamp: number(),
|
|
17
|
-
});
|
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
import { number, object, string } from "zod";
|
|
2
|
-
const breakdownSchema = object({
|
|
3
|
-
suitability: number(),
|
|
4
|
-
proposal: number(),
|
|
5
|
-
bidding: number(),
|
|
6
|
-
});
|
|
7
|
-
export const dailyUsageSchema = object({
|
|
8
|
-
breakdown: breakdownSchema,
|
|
9
|
-
tokensUsed: number().optional(),
|
|
10
|
-
campaignId: string().optional(),
|
|
11
|
-
model: string(),
|
|
12
|
-
timestamp: number(),
|
|
13
|
-
});
|
|
14
|
-
export const periodUsageSchema = object({
|
|
15
|
-
usedCredits: number(),
|
|
16
|
-
breakdown: breakdownSchema,
|
|
17
|
-
lastUpdated: number(),
|
|
18
|
-
});
|
|
@@ -1,52 +0,0 @@
|
|
|
1
|
-
import { number, object, string, z } from "zod";
|
|
2
|
-
import { passwordSchema } from "../shared";
|
|
3
|
-
export const userSchema = object({
|
|
4
|
-
id: string(),
|
|
5
|
-
firstName: string(),
|
|
6
|
-
lastName: string(),
|
|
7
|
-
displayName: string(),
|
|
8
|
-
email: string(),
|
|
9
|
-
organizationIds: z.array(string()),
|
|
10
|
-
createdAt: number(),
|
|
11
|
-
updatedAt: number(),
|
|
12
|
-
});
|
|
13
|
-
export const loginSchema = object({
|
|
14
|
-
email: string().email(),
|
|
15
|
-
password: passwordSchema,
|
|
16
|
-
});
|
|
17
|
-
export const registerSchema = object({
|
|
18
|
-
firstName: string().min(1, "First name is required").max(255),
|
|
19
|
-
lastName: string().min(1, "Last name is required").max(255),
|
|
20
|
-
email: string()
|
|
21
|
-
.email("Must be a valid email address")
|
|
22
|
-
.max(255)
|
|
23
|
-
.min(1, "Email address is required"),
|
|
24
|
-
password: passwordSchema,
|
|
25
|
-
confirmPassword: passwordSchema,
|
|
26
|
-
}).refine(({ password, confirmPassword }) => password === confirmPassword, {
|
|
27
|
-
message: `Passwords don't match.`,
|
|
28
|
-
path: ["confirmPassword"],
|
|
29
|
-
});
|
|
30
|
-
export const upworkProfileSchema = object({
|
|
31
|
-
name: string().nullable(),
|
|
32
|
-
country: string().nullable(),
|
|
33
|
-
bio: string().nullable(),
|
|
34
|
-
skills: z.array(string()).nullable(),
|
|
35
|
-
certifications: z.array(string()).nullable(),
|
|
36
|
-
employmentHistory: z
|
|
37
|
-
.array(z.object({
|
|
38
|
-
jobTitle: string(),
|
|
39
|
-
period: string(),
|
|
40
|
-
description: string(),
|
|
41
|
-
}))
|
|
42
|
-
.nullable(),
|
|
43
|
-
languages: z.record(string(), string()).nullable(),
|
|
44
|
-
portfolio: z
|
|
45
|
-
.array(z.object({
|
|
46
|
-
title: string(),
|
|
47
|
-
description: string(),
|
|
48
|
-
skills: z.array(string()),
|
|
49
|
-
publishedDate: string(),
|
|
50
|
-
}))
|
|
51
|
-
.nullable(),
|
|
52
|
-
});
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export {};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export {};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export {};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export {};
|
package/dist/types/ai/index.d.ts
DELETED
package/dist/types/ai/index.js
DELETED
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
import { proposalResponseSchema } from '../../schemas/ai/proposal';
|
|
2
|
-
import { proposalSchema } from '../../schemas/ai/proposal';
|
|
3
|
-
import { z } from 'zod';
|
|
4
|
-
import { questionAnswerPairSchema } from '../../schemas/ai/proposal';
|
|
5
|
-
export interface QuestionAnswerPair extends z.infer<typeof questionAnswerPairSchema> {
|
|
6
|
-
}
|
|
7
|
-
export interface Proposal extends z.infer<typeof proposalSchema> {
|
|
8
|
-
}
|
|
9
|
-
export interface ProposalResponse extends z.infer<typeof proposalResponseSchema> {
|
|
10
|
-
}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export {};
|
|
@@ -1,6 +0,0 @@
|
|
|
1
|
-
import { z } from 'zod';
|
|
2
|
-
import { suitabilitySchema, suitabilityResponseSchema } from '../../schemas';
|
|
3
|
-
export interface Suitability extends z.infer<typeof suitabilitySchema> {
|
|
4
|
-
}
|
|
5
|
-
export interface SuitabilityResponse extends z.infer<typeof suitabilityResponseSchema> {
|
|
6
|
-
}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export {};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export {};
|
package/dist/types/bid/bid.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export {};
|
package/dist/types/bid/index.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export {};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export {};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export {};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export {};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export {};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export {};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export {};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export * from './chat-message';
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export {};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export * from './agency-config';
|
package/dist/types/index.js
DELETED
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
export * from "./chat-message";
|
|
2
|
-
export * from "./job";
|
|
3
|
-
export * from "./saved-search";
|
|
4
|
-
export * from "./user";
|
|
5
|
-
export * from "./job-filters";
|
|
6
|
-
export * from "./campaign";
|
|
7
|
-
export * from "./scraper";
|
|
8
|
-
export * from "./config";
|
|
9
|
-
export * from "./logger";
|
|
10
|
-
export * from "./account";
|
|
11
|
-
export * from "./bid";
|
|
12
|
-
export * from "./time-filter";
|
|
13
|
-
export * from "./shared";
|
|
14
|
-
export * from "./usage";
|
|
15
|
-
export * from "./transaction";
|
package/dist/types/job/index.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export {};
|
package/dist/types/job/nuxt.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export {};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export * from './job-filters';
|