lancer-shared 1.2.335 → 1.2.337
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 +75 -0
- package/dist/bundle.cjs.js.map +1 -1
- package/dist/bundle.esm.js +69 -1
- package/dist/bundle.esm.js.map +1 -1
- package/dist/constants/routes.d.ts +3 -0
- package/dist/schemas/bidder/exceptions/index.d.ts +3 -0
- package/dist/schemas/dashboard/index.d.ts +195 -0
- package/dist/schemas/logger/log-event.d.ts +33 -10
- package/dist/schemas/proxy/proxy.d.ts +8 -0
- package/package.json +1 -1
package/dist/bundle.cjs.js
CHANGED
|
@@ -6677,6 +6677,7 @@ const proxyProviderSchema = z.enum([
|
|
|
6677
6677
|
'mars',
|
|
6678
6678
|
]);
|
|
6679
6679
|
const proxyTypeSchema = z.enum(['rotating', 'static']);
|
|
6680
|
+
const proxyProtocolSchema = z.enum(['socks5', 'http']);
|
|
6680
6681
|
const proxySchema = z.object({
|
|
6681
6682
|
id: z.string(),
|
|
6682
6683
|
externalId: z.string(),
|
|
@@ -6694,6 +6695,7 @@ const proxySchema = z.object({
|
|
|
6694
6695
|
region: z.string().nullable(),
|
|
6695
6696
|
accountId: z.string().nullable(),
|
|
6696
6697
|
type: proxyTypeSchema,
|
|
6698
|
+
protocol: proxyProtocolSchema.nullable().optional(),
|
|
6697
6699
|
});
|
|
6698
6700
|
const externalProxySchema = proxySchema.omit({
|
|
6699
6701
|
id: true,
|
|
@@ -8897,6 +8899,20 @@ class WaitForFunctionTimeoutError extends Error {
|
|
|
8897
8899
|
}
|
|
8898
8900
|
const waitForFunctionTimeoutError = (fn, timeout) => new WaitForFunctionTimeoutError(fn, timeout);
|
|
8899
8901
|
|
|
8902
|
+
const TRACKED_BID_FAILURE_MONITORING_CODES = [
|
|
8903
|
+
'CLOUDFLARE_CHALLENGE_FAILED_EXCEPTION',
|
|
8904
|
+
'GO_TO_URL_EXCEPTION',
|
|
8905
|
+
'SELECTOR_NOT_FOUND_ERROR',
|
|
8906
|
+
'PROPOSAL_SUBMIT_FAILED',
|
|
8907
|
+
'PROXY_NOT_REACHABLE_EXCEPTION',
|
|
8908
|
+
'ELEMENT_NOT_CLICKABLE_EXCEPTION',
|
|
8909
|
+
'LOGIN_FAILED_EXCEPTION',
|
|
8910
|
+
'INVALID_CREDENTIALS_EXCEPTION',
|
|
8911
|
+
'NETWORK_RESTRICTIONS_EXCEPTION',
|
|
8912
|
+
];
|
|
8913
|
+
const TRACKED_BID_FAILURE_MONITORING_CODES_SET = new Set(TRACKED_BID_FAILURE_MONITORING_CODES);
|
|
8914
|
+
const isTrackedBidFailureMonitoringCode = (code) => !!code && TRACKED_BID_FAILURE_MONITORING_CODES_SET.has(code);
|
|
8915
|
+
|
|
8900
8916
|
const syncProposalsStatusRequestPayloadSchema = z.object({
|
|
8901
8917
|
organizationId: z.string(),
|
|
8902
8918
|
bidderAccountId: z.string(),
|
|
@@ -9067,6 +9083,46 @@ const organizationCampaignStatsSchema = z.object({
|
|
|
9067
9083
|
totalStats: campaignStatsSchema,
|
|
9068
9084
|
campaigns: z.array(campaignDetailsSchema),
|
|
9069
9085
|
});
|
|
9086
|
+
const monitoringBidFailureRecordSchema = z.object({
|
|
9087
|
+
id: z.string(),
|
|
9088
|
+
eventId: z.string(),
|
|
9089
|
+
timestamp: z.number(),
|
|
9090
|
+
organizationId: z.string().nullable(),
|
|
9091
|
+
organizationName: z.string().nullable(),
|
|
9092
|
+
campaignId: z.string().nullable(),
|
|
9093
|
+
leadId: z.string().nullable(),
|
|
9094
|
+
reason: z.string().nullable(),
|
|
9095
|
+
errorCode: z.string().nullable(),
|
|
9096
|
+
errorMessage: z.string().nullable(),
|
|
9097
|
+
});
|
|
9098
|
+
const bidderMonitoringRowSchema = z.object({
|
|
9099
|
+
eventType: z.enum([
|
|
9100
|
+
'biddingFailed',
|
|
9101
|
+
'syncProposalsStatusFailed',
|
|
9102
|
+
'refreshRoomsFailed',
|
|
9103
|
+
]),
|
|
9104
|
+
eventId: z.string(),
|
|
9105
|
+
bidderAccountId: z.string().nullable(),
|
|
9106
|
+
email: z.string().nullable(),
|
|
9107
|
+
proxyString: z.string().nullable(),
|
|
9108
|
+
timestamp: z.number(),
|
|
9109
|
+
organizationId: z.string().nullable(),
|
|
9110
|
+
organizationName: z.string().nullable(),
|
|
9111
|
+
campaignId: z.string().nullable(),
|
|
9112
|
+
leadId: z.string().nullable(),
|
|
9113
|
+
reason: z.string().nullable(),
|
|
9114
|
+
errorCode: z.string().nullable(),
|
|
9115
|
+
errorMessage: z.string().nullable(),
|
|
9116
|
+
screenshotUrl: z.string().nullable(),
|
|
9117
|
+
attempt: z.number().nullable(),
|
|
9118
|
+
viewed: z.boolean(),
|
|
9119
|
+
viewedAt: z.number().nullable(),
|
|
9120
|
+
});
|
|
9121
|
+
const bidderFailureDashboardResponseSchema = z.object({
|
|
9122
|
+
items: z.array(bidderMonitoringRowSchema),
|
|
9123
|
+
totalFailures: z.number(),
|
|
9124
|
+
unviewedCount: z.number(),
|
|
9125
|
+
});
|
|
9070
9126
|
|
|
9071
9127
|
const labelEnum = z.enum(['suitable', 'unsuitable']);
|
|
9072
9128
|
const sampleSchema = z.object({
|
|
@@ -9339,6 +9395,7 @@ const LogEventTypeEnum = z.enum([
|
|
|
9339
9395
|
// Bidder Account Events
|
|
9340
9396
|
'verifyCredentialsSucceeded',
|
|
9341
9397
|
'verifyCredentialsFailed',
|
|
9398
|
+
'refreshRoomsFailed',
|
|
9342
9399
|
]);
|
|
9343
9400
|
const logEventSchema = z.object({
|
|
9344
9401
|
// The type of event (use a z.enum if possible)
|
|
@@ -9371,6 +9428,7 @@ const biddingCompletedEventMetadata = objectType({
|
|
|
9371
9428
|
});
|
|
9372
9429
|
const biddingFailedEventMetadata = objectType({
|
|
9373
9430
|
error: z.any(),
|
|
9431
|
+
screenshotUrl: z.string().url().optional(),
|
|
9374
9432
|
});
|
|
9375
9433
|
const biddingProcessingEventMetadata = objectType({
|
|
9376
9434
|
jobUrl: z.string(),
|
|
@@ -9383,6 +9441,7 @@ const syncProposalsStatusCompletedEventMetadata = objectType({
|
|
|
9383
9441
|
});
|
|
9384
9442
|
const syncProposalsStatusFailedEventMetadata = objectType({
|
|
9385
9443
|
error: z.any(),
|
|
9444
|
+
bidderAccountId: z.string().optional(),
|
|
9386
9445
|
});
|
|
9387
9446
|
const userAccountBiddingExceptionEventMetadata = objectType({
|
|
9388
9447
|
errorType: z.enum(['insufficientConnects', 'proposalFormWarningAlert']),
|
|
@@ -9428,6 +9487,12 @@ const verifyCredentialsFailedEventMetadataSchema = objectType({
|
|
|
9428
9487
|
bidderAccountId: z.string(),
|
|
9429
9488
|
errorMessage: z.string(),
|
|
9430
9489
|
});
|
|
9490
|
+
const refreshRoomsFailedEventMetadataSchema = objectType({
|
|
9491
|
+
bidderAccountId: z.string().optional(),
|
|
9492
|
+
errorMessage: z.string().optional(),
|
|
9493
|
+
errorCode: z.string().optional(),
|
|
9494
|
+
context: z.string().optional(),
|
|
9495
|
+
});
|
|
9431
9496
|
const suitabilityPendingEventMetadataSchema = objectType({
|
|
9432
9497
|
jobId: z.string(),
|
|
9433
9498
|
jobUrl: z.string(),
|
|
@@ -15781,6 +15846,9 @@ const ROUTES = {
|
|
|
15781
15846
|
},
|
|
15782
15847
|
DASHBOARD: {
|
|
15783
15848
|
CAMPAIGN_STATS: 'admin/dashboard/campaign-stats',
|
|
15849
|
+
BIDDER_FAILURES: 'admin/dashboard/bidder-failures',
|
|
15850
|
+
MARK_BIDDER_FAILURE_VIEWED: (eventId) => `admin/dashboard/bidder-failures/${eventId}/viewed`,
|
|
15851
|
+
BIDDER_FAILURE_VIEWS: 'admin/dashboard/bidder-failure-views',
|
|
15784
15852
|
},
|
|
15785
15853
|
ALERTS: {
|
|
15786
15854
|
BASE: 'admin/alerts',
|
|
@@ -24722,6 +24790,7 @@ exports.SearchQueryBuilder = SearchQueryBuilder;
|
|
|
24722
24790
|
exports.SelectAgencyException = SelectAgencyException;
|
|
24723
24791
|
exports.SelectContractorException = SelectContractorException;
|
|
24724
24792
|
exports.SelectorNotFoundError = SelectorNotFoundError;
|
|
24793
|
+
exports.TRACKED_BID_FAILURE_MONITORING_CODES = TRACKED_BID_FAILURE_MONITORING_CODES;
|
|
24725
24794
|
exports.TwoFactorPresentException = TwoFactorPresentException;
|
|
24726
24795
|
exports.TypedValueInFieldNotMatchingException = TypedValueInFieldNotMatchingException;
|
|
24727
24796
|
exports.TypingInputFieldException = TypingInputFieldException;
|
|
@@ -24766,8 +24835,10 @@ exports.bidderAccountProvider = bidderAccountProvider;
|
|
|
24766
24835
|
exports.bidderAccountProviderDisplayMap = bidderAccountProviderDisplayMap;
|
|
24767
24836
|
exports.bidderAccountSchema = bidderAccountSchema;
|
|
24768
24837
|
exports.bidderAccountStatusEnum = bidderAccountStatusEnum;
|
|
24838
|
+
exports.bidderFailureDashboardResponseSchema = bidderFailureDashboardResponseSchema;
|
|
24769
24839
|
exports.bidderInstanceSchema = bidderInstanceSchema;
|
|
24770
24840
|
exports.bidderInstanceStatusEnum = bidderInstanceStatusEnum;
|
|
24841
|
+
exports.bidderMonitoringRowSchema = bidderMonitoringRowSchema;
|
|
24771
24842
|
exports.biddingCompletedEventMetadata = biddingCompletedEventMetadata;
|
|
24772
24843
|
exports.biddingFailedEventMetadata = biddingFailedEventMetadata;
|
|
24773
24844
|
exports.biddingHourlyRateStrategyEnum = biddingHourlyRateStrategyEnum;
|
|
@@ -24924,6 +24995,7 @@ exports.isNumeric = isNumeric;
|
|
|
24924
24995
|
exports.isPaymentVerifiedEnum = isPaymentVerifiedEnum;
|
|
24925
24996
|
exports.isPhoneVerifiedEnum = isPhoneVerifiedEnum;
|
|
24926
24997
|
exports.isRoomCrmStatus = isRoomCrmStatus;
|
|
24998
|
+
exports.isTrackedBidFailureMonitoringCode = isTrackedBidFailureMonitoringCode;
|
|
24927
24999
|
exports.isWorkTime = isWorkTime;
|
|
24928
25000
|
exports.jobActivityDeltaSchema = jobActivityDeltaSchema;
|
|
24929
25001
|
exports.jobActivityOffsetEnum = jobActivityOffsetEnum;
|
|
@@ -24960,6 +25032,7 @@ exports.logEventSchema = logEventSchema;
|
|
|
24960
25032
|
exports.loginFailedException = loginFailedException;
|
|
24961
25033
|
exports.loginSchema = loginSchema;
|
|
24962
25034
|
exports.metadataSchema = metadataSchema;
|
|
25035
|
+
exports.monitoringBidFailureRecordSchema = monitoringBidFailureRecordSchema;
|
|
24963
25036
|
exports.multiloginAuthenticationException = multiloginAuthenticationException;
|
|
24964
25037
|
exports.navigationTimeoutException = navigationTimeoutException;
|
|
24965
25038
|
exports.networkRestrictionsException = networkRestrictionsException;
|
|
@@ -25019,6 +25092,7 @@ exports.proxyAvailableReplacementsSchema = proxyAvailableReplacementsSchema;
|
|
|
25019
25092
|
exports.proxyCountryCodeToName = proxyCountryCodeToName;
|
|
25020
25093
|
exports.proxyCountryEnum = proxyCountryEnum;
|
|
25021
25094
|
exports.proxyNotReachableException = proxyNotReachableException;
|
|
25095
|
+
exports.proxyProtocolSchema = proxyProtocolSchema;
|
|
25022
25096
|
exports.proxyProviderSchema = proxyProviderSchema;
|
|
25023
25097
|
exports.proxySchema = proxySchema;
|
|
25024
25098
|
exports.proxyStatusSchema = proxyStatusSchema;
|
|
@@ -25029,6 +25103,7 @@ exports.questionPairNotMatchingException = questionPairNotMatchingException;
|
|
|
25029
25103
|
exports.questionRulesSchema = questionRulesSchema;
|
|
25030
25104
|
exports.reconnectBidderAccountRequestBodySchema = reconnectBidderAccountRequestBodySchema;
|
|
25031
25105
|
exports.reconnectBidderAccountResponseSchema = reconnectBidderAccountResponseSchema;
|
|
25106
|
+
exports.refreshRoomsFailedEventMetadataSchema = refreshRoomsFailedEventMetadataSchema;
|
|
25032
25107
|
exports.refreshRotatingProxiesRequestBodySchema = refreshRotatingProxiesRequestBodySchema;
|
|
25033
25108
|
exports.regionEnum = regionEnum;
|
|
25034
25109
|
exports.regionMapping = regionMapping;
|