lancer-shared 1.2.138 → 1.2.139
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
CHANGED
|
@@ -6581,9 +6581,11 @@ const ROUTES = {
|
|
|
6581
6581
|
BASE: (organizationId, campaignId) => `organizations/${organizationId}/campaigns/${campaignId}/chat-bots`,
|
|
6582
6582
|
BY_PLATFORM: (organizationId, campaignId, platform) => `organizations/${organizationId}/campaigns/${campaignId}/chat-bots/${platform}`,
|
|
6583
6583
|
OAUTH_URL: (organizationId, campaignId, platform) => `organizations/${organizationId}/campaigns/${campaignId}/chat-bots/${platform}/oauth-url`,
|
|
6584
|
+
UPDATE_SUITABLE_LEAD_NOTIFICATION: (organizationId, campaignId, leadId) => `organizations/${organizationId}/campaigns/${campaignId}/chat-bots/update-lead-message-state/${leadId}`,
|
|
6584
6585
|
CALLBACK: (platform) => `chat-bots/${platform}/callback`,
|
|
6585
6586
|
SEND_NOTIFICATION: () => 'chat-bots/send-notification',
|
|
6586
6587
|
REMOVE_SUITABLE_LEAD_MESSAGE_BUTTONS: () => 'chat-bots/remove-suitable-lead-message-buttons',
|
|
6588
|
+
SLACK_INTERACTIONS: () => 'chat-bots/slack/interactions',
|
|
6587
6589
|
},
|
|
6588
6590
|
ACTIVITIES: {
|
|
6589
6591
|
BASE: (organizationId, campaignId) => `organizations/${organizationId}/campaigns/${campaignId}/activities`,
|
|
@@ -13453,9 +13455,11 @@ const chatbotChannelSchema = z.object({
|
|
|
13453
13455
|
id: z.string(),
|
|
13454
13456
|
name: z.string(),
|
|
13455
13457
|
});
|
|
13456
|
-
const chatbotPlatforms = z.enum(['discord']);
|
|
13458
|
+
const chatbotPlatforms = z.enum(['discord', 'slack']);
|
|
13457
13459
|
const chatbotSchema = z.object({
|
|
13458
|
-
|
|
13460
|
+
accessToken: z.string().optional(),
|
|
13461
|
+
refreshToken: z.string().optional(),
|
|
13462
|
+
workspaceId: z.string(),
|
|
13459
13463
|
channels: z.array(chatbotChannelSchema),
|
|
13460
13464
|
selectedChannelId: z.string().nullable(),
|
|
13461
13465
|
notificationsEnabled: z.boolean().default(true),
|
|
@@ -13466,7 +13470,9 @@ const chatbotSchema = z.object({
|
|
|
13466
13470
|
updatedAt: z.number(),
|
|
13467
13471
|
});
|
|
13468
13472
|
const createChatbotSchema = chatbotSchema.pick({
|
|
13469
|
-
|
|
13473
|
+
workspaceId: true,
|
|
13474
|
+
accessToken: true,
|
|
13475
|
+
refreshToken: true,
|
|
13470
13476
|
channels: true,
|
|
13471
13477
|
organizationId: true,
|
|
13472
13478
|
campaignId: true,
|
|
@@ -13483,6 +13489,13 @@ const sendNotificationRequestSchema = z.object({
|
|
|
13483
13489
|
notificationType: campaignNotificationType,
|
|
13484
13490
|
message: z.string().optional(),
|
|
13485
13491
|
});
|
|
13492
|
+
const updateSuitableLeadNotificationType = z.enum([
|
|
13493
|
+
'proceeded',
|
|
13494
|
+
'feedback-provided',
|
|
13495
|
+
]);
|
|
13496
|
+
const updateSuitableLeadNotificationBodySchema = z.object({
|
|
13497
|
+
type: updateSuitableLeadNotificationType,
|
|
13498
|
+
});
|
|
13486
13499
|
const CAMPAIGN_NOTIFICATION_TYPES = {
|
|
13487
13500
|
suitableLead: 'Suitable Lead',
|
|
13488
13501
|
proposalSent: 'Proposal Sent',
|
|
@@ -14859,6 +14872,8 @@ exports.updateCampaignSchema = updateCampaignSchema;
|
|
|
14859
14872
|
exports.updateChatbotSchema = updateChatbotSchema;
|
|
14860
14873
|
exports.updateLeadStatusSchema = updateLeadStatusSchema;
|
|
14861
14874
|
exports.updateScraperAccountSchema = updateScraperAccountSchema;
|
|
14875
|
+
exports.updateSuitableLeadNotificationBodySchema = updateSuitableLeadNotificationBodySchema;
|
|
14876
|
+
exports.updateSuitableLeadNotificationType = updateSuitableLeadNotificationType;
|
|
14862
14877
|
exports.upworkAccountConnectSchema = upworkAccountConnectSchema;
|
|
14863
14878
|
exports.upworkAccountConnectStatusSchema = upworkAccountConnectStatusSchema;
|
|
14864
14879
|
exports.upworkJobSchema = upworkJobSchema;
|
|
@@ -162,9 +162,11 @@ export declare const ROUTES: {
|
|
|
162
162
|
readonly BASE: (organizationId: string, campaignId: string) => string;
|
|
163
163
|
readonly BY_PLATFORM: (organizationId: string, campaignId: string, platform: ChatbotPlatform) => string;
|
|
164
164
|
readonly OAUTH_URL: (organizationId: string, campaignId: string, platform: string) => string;
|
|
165
|
+
readonly UPDATE_SUITABLE_LEAD_NOTIFICATION: (organizationId: string, campaignId: string, leadId: string) => string;
|
|
165
166
|
readonly CALLBACK: (platform: string) => string;
|
|
166
167
|
readonly SEND_NOTIFICATION: () => string;
|
|
167
168
|
readonly REMOVE_SUITABLE_LEAD_MESSAGE_BUTTONS: () => string;
|
|
169
|
+
readonly SLACK_INTERACTIONS: () => string;
|
|
168
170
|
};
|
|
169
171
|
readonly ACTIVITIES: {
|
|
170
172
|
readonly BASE: (organizationId: string, campaignId: string) => string;
|
|
@@ -10,9 +10,11 @@ export declare const chatbotChannelSchema: z.ZodObject<{
|
|
|
10
10
|
id: string;
|
|
11
11
|
name: string;
|
|
12
12
|
}>;
|
|
13
|
-
export declare const chatbotPlatforms: z.ZodEnum<["discord"]>;
|
|
13
|
+
export declare const chatbotPlatforms: z.ZodEnum<["discord", "slack"]>;
|
|
14
14
|
export declare const chatbotSchema: z.ZodObject<{
|
|
15
|
-
|
|
15
|
+
accessToken: z.ZodOptional<z.ZodString>;
|
|
16
|
+
refreshToken: z.ZodOptional<z.ZodString>;
|
|
17
|
+
workspaceId: z.ZodString;
|
|
16
18
|
channels: z.ZodArray<z.ZodObject<{
|
|
17
19
|
id: z.ZodString;
|
|
18
20
|
name: z.ZodString;
|
|
@@ -31,7 +33,7 @@ export declare const chatbotSchema: z.ZodObject<{
|
|
|
31
33
|
createdAt: z.ZodNumber;
|
|
32
34
|
updatedAt: z.ZodNumber;
|
|
33
35
|
}, "strip", z.ZodTypeAny, {
|
|
34
|
-
|
|
36
|
+
workspaceId: string;
|
|
35
37
|
channels: {
|
|
36
38
|
id: string;
|
|
37
39
|
name: string;
|
|
@@ -43,8 +45,10 @@ export declare const chatbotSchema: z.ZodObject<{
|
|
|
43
45
|
campaignId: string;
|
|
44
46
|
createdAt: number;
|
|
45
47
|
updatedAt: number;
|
|
48
|
+
accessToken?: string | undefined;
|
|
49
|
+
refreshToken?: string | undefined;
|
|
46
50
|
}, {
|
|
47
|
-
|
|
51
|
+
workspaceId: string;
|
|
48
52
|
channels: {
|
|
49
53
|
id: string;
|
|
50
54
|
name: string;
|
|
@@ -55,10 +59,14 @@ export declare const chatbotSchema: z.ZodObject<{
|
|
|
55
59
|
campaignId: string;
|
|
56
60
|
createdAt: number;
|
|
57
61
|
updatedAt: number;
|
|
62
|
+
accessToken?: string | undefined;
|
|
63
|
+
refreshToken?: string | undefined;
|
|
58
64
|
notificationsEnabled?: boolean | undefined;
|
|
59
65
|
}>;
|
|
60
66
|
export declare const createChatbotSchema: z.ZodObject<Pick<{
|
|
61
|
-
|
|
67
|
+
accessToken: z.ZodOptional<z.ZodString>;
|
|
68
|
+
refreshToken: z.ZodOptional<z.ZodString>;
|
|
69
|
+
workspaceId: z.ZodString;
|
|
62
70
|
channels: z.ZodArray<z.ZodObject<{
|
|
63
71
|
id: z.ZodString;
|
|
64
72
|
name: z.ZodString;
|
|
@@ -76,25 +84,31 @@ export declare const createChatbotSchema: z.ZodObject<Pick<{
|
|
|
76
84
|
campaignId: z.ZodString;
|
|
77
85
|
createdAt: z.ZodNumber;
|
|
78
86
|
updatedAt: z.ZodNumber;
|
|
79
|
-
}, "
|
|
80
|
-
|
|
87
|
+
}, "accessToken" | "refreshToken" | "workspaceId" | "channels" | "organizationId" | "campaignId">, "strip", z.ZodTypeAny, {
|
|
88
|
+
workspaceId: string;
|
|
81
89
|
channels: {
|
|
82
90
|
id: string;
|
|
83
91
|
name: string;
|
|
84
92
|
}[];
|
|
85
93
|
organizationId: string;
|
|
86
94
|
campaignId: string;
|
|
95
|
+
accessToken?: string | undefined;
|
|
96
|
+
refreshToken?: string | undefined;
|
|
87
97
|
}, {
|
|
88
|
-
|
|
98
|
+
workspaceId: string;
|
|
89
99
|
channels: {
|
|
90
100
|
id: string;
|
|
91
101
|
name: string;
|
|
92
102
|
}[];
|
|
93
103
|
organizationId: string;
|
|
94
104
|
campaignId: string;
|
|
105
|
+
accessToken?: string | undefined;
|
|
106
|
+
refreshToken?: string | undefined;
|
|
95
107
|
}>;
|
|
96
108
|
export declare const updateChatbotSchema: z.ZodObject<Pick<{
|
|
97
|
-
|
|
109
|
+
accessToken: z.ZodOptional<z.ZodString>;
|
|
110
|
+
refreshToken: z.ZodOptional<z.ZodString>;
|
|
111
|
+
workspaceId: z.ZodString;
|
|
98
112
|
channels: z.ZodArray<z.ZodObject<{
|
|
99
113
|
id: z.ZodString;
|
|
100
114
|
name: z.ZodString;
|
|
@@ -140,6 +154,18 @@ export declare const sendNotificationRequestSchema: z.ZodObject<{
|
|
|
140
154
|
notificationType: "suitableLead" | "proposalSent" | "proposalViewed" | "proposalReplied" | "noConnects" | "accountDisconnected" | "biddingWarning";
|
|
141
155
|
message?: string | undefined;
|
|
142
156
|
}>;
|
|
157
|
+
export declare const updateSuitableLeadNotificationType: z.ZodEnum<["proceeded", "feedback-provided"]>;
|
|
158
|
+
export declare const updateSuitableLeadNotificationBodySchema: z.ZodObject<{
|
|
159
|
+
type: z.ZodEnum<["proceeded", "feedback-provided"]>;
|
|
160
|
+
}, "strip", z.ZodTypeAny, {
|
|
161
|
+
type: "proceeded" | "feedback-provided";
|
|
162
|
+
}, {
|
|
163
|
+
type: "proceeded" | "feedback-provided";
|
|
164
|
+
}>;
|
|
165
|
+
export type UpdateSuitableLeadNotificationType = z.infer<typeof updateSuitableLeadNotificationType>;
|
|
166
|
+
export interface UpdateSuitableLeadNotificationBody extends z.infer<typeof updateSuitableLeadNotificationBodySchema> {
|
|
167
|
+
type: UpdateSuitableLeadNotificationType;
|
|
168
|
+
}
|
|
143
169
|
export type CampaignNotificationType = z.infer<typeof campaignNotificationType>;
|
|
144
170
|
export interface SendNotificationRequest extends z.infer<typeof sendNotificationRequestSchema> {
|
|
145
171
|
notificationType: CampaignNotificationType;
|