@livechat/developer-studio-api 3.1.55 → 3.1.56-beta
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/index.d.mts +175 -946
- package/dist/index.d.ts +175 -946
- package/dist/index.js +50 -41
- package/dist/index.mjs +50 -41
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -2355,14 +2355,14 @@ var shopifyEventsZods = {
|
|
|
2355
2355
|
get unsubscribe() {
|
|
2356
2356
|
return this.source.and(
|
|
2357
2357
|
import_zod.z.object({
|
|
2358
|
-
event: this.
|
|
2358
|
+
event: this.eventName
|
|
2359
2359
|
})
|
|
2360
2360
|
);
|
|
2361
2361
|
},
|
|
2362
2362
|
get unsubscribeContent() {
|
|
2363
2363
|
return import_zod.z.object({
|
|
2364
2364
|
provider: this.provider,
|
|
2365
|
-
event: this.
|
|
2365
|
+
event: this.eventName
|
|
2366
2366
|
});
|
|
2367
2367
|
}
|
|
2368
2368
|
};
|
|
@@ -2383,11 +2383,9 @@ var mailchimpEventsZods = {
|
|
|
2383
2383
|
eventName: import_zod2.z.nativeEnum(MailchimpEventNames),
|
|
2384
2384
|
events: {
|
|
2385
2385
|
subscribed: import_zod2.z.object({
|
|
2386
|
-
listId: import_zod2.z.string(),
|
|
2387
2386
|
name: import_zod2.z.literal("subscribed" /* Subscribed */)
|
|
2388
2387
|
}),
|
|
2389
2388
|
unsubscribed: import_zod2.z.object({
|
|
2390
|
-
listId: import_zod2.z.string(),
|
|
2391
2389
|
name: import_zod2.z.literal("unsubscribed" /* Unsubscribed */)
|
|
2392
2390
|
})
|
|
2393
2391
|
},
|
|
@@ -2407,6 +2405,7 @@ var mailchimpEventsZods = {
|
|
|
2407
2405
|
return this.source.and(
|
|
2408
2406
|
import_zod2.z.object({
|
|
2409
2407
|
event: this.event,
|
|
2408
|
+
listId: import_zod2.z.string(),
|
|
2410
2409
|
callback: import_zod2.z.string()
|
|
2411
2410
|
})
|
|
2412
2411
|
);
|
|
@@ -2415,20 +2414,23 @@ var mailchimpEventsZods = {
|
|
|
2415
2414
|
return import_zod2.z.object({
|
|
2416
2415
|
provider: this.provider,
|
|
2417
2416
|
event: this.event,
|
|
2418
|
-
callback: import_zod2.z.string()
|
|
2417
|
+
callback: import_zod2.z.string(),
|
|
2418
|
+
listId: import_zod2.z.string()
|
|
2419
2419
|
});
|
|
2420
2420
|
},
|
|
2421
2421
|
get unsubscribe() {
|
|
2422
2422
|
return this.source.and(
|
|
2423
2423
|
import_zod2.z.object({
|
|
2424
|
-
event: this.
|
|
2424
|
+
event: this.eventName,
|
|
2425
|
+
listId: import_zod2.z.string()
|
|
2425
2426
|
})
|
|
2426
2427
|
);
|
|
2427
2428
|
},
|
|
2428
2429
|
get unsubscribeContent() {
|
|
2429
2430
|
return import_zod2.z.object({
|
|
2430
2431
|
provider: this.provider,
|
|
2431
|
-
event: this.
|
|
2432
|
+
event: this.eventName,
|
|
2433
|
+
listId: import_zod2.z.string()
|
|
2432
2434
|
});
|
|
2433
2435
|
}
|
|
2434
2436
|
};
|
|
@@ -2522,14 +2524,14 @@ var textLivechatEventsZods = {
|
|
|
2522
2524
|
get unsubscribe() {
|
|
2523
2525
|
return this.source.and(
|
|
2524
2526
|
import_zod3.z.object({
|
|
2525
|
-
event: this.
|
|
2527
|
+
event: this.eventName
|
|
2526
2528
|
})
|
|
2527
2529
|
);
|
|
2528
2530
|
},
|
|
2529
2531
|
get unsubscribeContent() {
|
|
2530
2532
|
return import_zod3.z.object({
|
|
2531
2533
|
provider: this.provider,
|
|
2532
|
-
event: this.
|
|
2534
|
+
event: this.eventName
|
|
2533
2535
|
});
|
|
2534
2536
|
}
|
|
2535
2537
|
};
|
|
@@ -2586,14 +2588,14 @@ var hubspotEventsZods = {
|
|
|
2586
2588
|
get unsubscribe() {
|
|
2587
2589
|
return this.source.and(
|
|
2588
2590
|
import_zod4.z.object({
|
|
2589
|
-
event: this.
|
|
2591
|
+
event: this.eventName
|
|
2590
2592
|
})
|
|
2591
2593
|
);
|
|
2592
2594
|
},
|
|
2593
2595
|
get unsubscribeContent() {
|
|
2594
2596
|
return import_zod4.z.object({
|
|
2595
2597
|
provider: this.provider,
|
|
2596
|
-
event: this.
|
|
2598
|
+
event: this.eventName
|
|
2597
2599
|
});
|
|
2598
2600
|
}
|
|
2599
2601
|
};
|
|
@@ -2670,14 +2672,14 @@ var bigcommerceEventsZods = {
|
|
|
2670
2672
|
get unsubscribe() {
|
|
2671
2673
|
return this.source.and(
|
|
2672
2674
|
import_zod5.z.object({
|
|
2673
|
-
event: this.
|
|
2675
|
+
event: this.eventName
|
|
2674
2676
|
})
|
|
2675
2677
|
);
|
|
2676
2678
|
},
|
|
2677
2679
|
get unsubscribeContent() {
|
|
2678
2680
|
return import_zod5.z.object({
|
|
2679
2681
|
provider: this.provider,
|
|
2680
|
-
event: this.
|
|
2682
|
+
event: this.eventName
|
|
2681
2683
|
});
|
|
2682
2684
|
}
|
|
2683
2685
|
};
|
|
@@ -3671,7 +3673,7 @@ var textPlatformWorkflowsApi = {
|
|
|
3671
3673
|
},
|
|
3672
3674
|
createWorkflow(payload, authorization) {
|
|
3673
3675
|
return __async(this, null, function* () {
|
|
3674
|
-
|
|
3676
|
+
return textClientInstance.post(
|
|
3675
3677
|
"/workflow_platform/workflows",
|
|
3676
3678
|
payload,
|
|
3677
3679
|
getTextClientConfig(__spreadProps(__spreadValues({}, authorization), {
|
|
@@ -3680,79 +3682,86 @@ var textPlatformWorkflowsApi = {
|
|
|
3680
3682
|
);
|
|
3681
3683
|
});
|
|
3682
3684
|
},
|
|
3683
|
-
updateWorkflow(payload, authorization) {
|
|
3685
|
+
updateWorkflow(workflowId, payload, authorization) {
|
|
3684
3686
|
return __async(this, null, function* () {
|
|
3685
|
-
|
|
3686
|
-
`/workflow_platform/workflows/${encodeURIComponent(
|
|
3687
|
+
return textClientInstance.put(
|
|
3688
|
+
`/workflow_platform/workflows/${encodeURIComponent(workflowId)}`,
|
|
3687
3689
|
payload,
|
|
3688
3690
|
getTextClientConfig(__spreadProps(__spreadValues({}, authorization), {
|
|
3689
3691
|
ensureAuthorizationToken: true
|
|
3690
3692
|
}))
|
|
3691
3693
|
);
|
|
3692
|
-
return workflow;
|
|
3693
3694
|
});
|
|
3694
3695
|
},
|
|
3695
|
-
deleteWorkflow(workflowId, authorization) {
|
|
3696
|
+
deleteWorkflow(workflowId, thirdPartyHeaders, authorization) {
|
|
3696
3697
|
return __async(this, null, function* () {
|
|
3697
|
-
|
|
3698
|
+
return textClientInstance.delete(
|
|
3698
3699
|
`/workflow_platform/workflows/${encodeURIComponent(workflowId)}`,
|
|
3699
|
-
__spreadValues({}, getTextClientConfig(__spreadProps(__spreadValues({}, authorization), {
|
|
3700
|
+
__spreadProps(__spreadValues({}, getTextClientConfig(__spreadProps(__spreadValues({}, authorization), {
|
|
3700
3701
|
ensureAuthorizationToken: true
|
|
3701
|
-
})))
|
|
3702
|
+
}))), {
|
|
3703
|
+
data: {
|
|
3704
|
+
third_party_headers: thirdPartyHeaders
|
|
3705
|
+
}
|
|
3706
|
+
})
|
|
3702
3707
|
);
|
|
3703
3708
|
});
|
|
3704
3709
|
},
|
|
3705
|
-
|
|
3710
|
+
toggleWorkflowActivation(workflowId, isActive, authorization) {
|
|
3706
3711
|
return __async(this, null, function* () {
|
|
3707
|
-
|
|
3712
|
+
return textClientInstance.put(
|
|
3708
3713
|
`/workflow_platform/workflows/${encodeURIComponent(
|
|
3709
|
-
|
|
3710
|
-
)}/
|
|
3711
|
-
|
|
3714
|
+
workflowId
|
|
3715
|
+
)}/activation`,
|
|
3716
|
+
{
|
|
3717
|
+
active: isActive
|
|
3718
|
+
},
|
|
3712
3719
|
getTextClientConfig(__spreadProps(__spreadValues({}, authorization), {
|
|
3713
3720
|
ensureAuthorizationToken: true
|
|
3714
3721
|
}))
|
|
3715
3722
|
);
|
|
3716
|
-
return execution;
|
|
3717
3723
|
});
|
|
3718
3724
|
},
|
|
3719
|
-
|
|
3725
|
+
executeWorkflow(workflowId, input, authorization) {
|
|
3720
3726
|
return __async(this, null, function* () {
|
|
3721
|
-
const { data:
|
|
3727
|
+
const { data: execution } = yield textClientInstance.post(
|
|
3722
3728
|
`/workflow_platform/workflows/${encodeURIComponent(
|
|
3723
3729
|
workflowId
|
|
3724
3730
|
)}/executions`,
|
|
3731
|
+
{
|
|
3732
|
+
input
|
|
3733
|
+
},
|
|
3725
3734
|
getTextClientConfig(__spreadProps(__spreadValues({}, authorization), {
|
|
3726
3735
|
ensureAuthorizationToken: true
|
|
3727
3736
|
}))
|
|
3728
3737
|
);
|
|
3729
|
-
return
|
|
3738
|
+
return execution;
|
|
3730
3739
|
});
|
|
3731
3740
|
},
|
|
3732
|
-
|
|
3741
|
+
getWorkflowExecutionsList(workflowId, authorization) {
|
|
3733
3742
|
return __async(this, null, function* () {
|
|
3734
|
-
const { data:
|
|
3743
|
+
const { data: executions } = yield textClientInstance.get(
|
|
3735
3744
|
`/workflow_platform/workflows/${encodeURIComponent(
|
|
3736
|
-
|
|
3737
|
-
)}/executions
|
|
3745
|
+
workflowId
|
|
3746
|
+
)}/executions`,
|
|
3738
3747
|
getTextClientConfig(__spreadProps(__spreadValues({}, authorization), {
|
|
3739
3748
|
ensureAuthorizationToken: true
|
|
3740
3749
|
}))
|
|
3741
3750
|
);
|
|
3742
|
-
return
|
|
3751
|
+
return executions;
|
|
3743
3752
|
});
|
|
3744
3753
|
},
|
|
3745
|
-
|
|
3754
|
+
getWorkflowExecutionDetails(workflowId, executionId, authorization) {
|
|
3746
3755
|
return __async(this, null, function* () {
|
|
3747
|
-
yield textClientInstance.
|
|
3756
|
+
const { data: execution } = yield textClientInstance.get(
|
|
3748
3757
|
`/workflow_platform/workflows/${encodeURIComponent(
|
|
3749
|
-
|
|
3750
|
-
)}/
|
|
3751
|
-
payload,
|
|
3758
|
+
workflowId
|
|
3759
|
+
)}/executions/${encodeURIComponent(executionId)}`,
|
|
3752
3760
|
getTextClientConfig(__spreadProps(__spreadValues({}, authorization), {
|
|
3753
3761
|
ensureAuthorizationToken: true
|
|
3754
3762
|
}))
|
|
3755
3763
|
);
|
|
3764
|
+
return execution;
|
|
3756
3765
|
});
|
|
3757
3766
|
},
|
|
3758
3767
|
validateWorkflowDefinition(payload, authorization) {
|
package/dist/index.mjs
CHANGED
|
@@ -2202,14 +2202,14 @@ var shopifyEventsZods = {
|
|
|
2202
2202
|
get unsubscribe() {
|
|
2203
2203
|
return this.source.and(
|
|
2204
2204
|
z.object({
|
|
2205
|
-
event: this.
|
|
2205
|
+
event: this.eventName
|
|
2206
2206
|
})
|
|
2207
2207
|
);
|
|
2208
2208
|
},
|
|
2209
2209
|
get unsubscribeContent() {
|
|
2210
2210
|
return z.object({
|
|
2211
2211
|
provider: this.provider,
|
|
2212
|
-
event: this.
|
|
2212
|
+
event: this.eventName
|
|
2213
2213
|
});
|
|
2214
2214
|
}
|
|
2215
2215
|
};
|
|
@@ -2230,11 +2230,9 @@ var mailchimpEventsZods = {
|
|
|
2230
2230
|
eventName: z2.nativeEnum(MailchimpEventNames),
|
|
2231
2231
|
events: {
|
|
2232
2232
|
subscribed: z2.object({
|
|
2233
|
-
listId: z2.string(),
|
|
2234
2233
|
name: z2.literal("subscribed" /* Subscribed */)
|
|
2235
2234
|
}),
|
|
2236
2235
|
unsubscribed: z2.object({
|
|
2237
|
-
listId: z2.string(),
|
|
2238
2236
|
name: z2.literal("unsubscribed" /* Unsubscribed */)
|
|
2239
2237
|
})
|
|
2240
2238
|
},
|
|
@@ -2254,6 +2252,7 @@ var mailchimpEventsZods = {
|
|
|
2254
2252
|
return this.source.and(
|
|
2255
2253
|
z2.object({
|
|
2256
2254
|
event: this.event,
|
|
2255
|
+
listId: z2.string(),
|
|
2257
2256
|
callback: z2.string()
|
|
2258
2257
|
})
|
|
2259
2258
|
);
|
|
@@ -2262,20 +2261,23 @@ var mailchimpEventsZods = {
|
|
|
2262
2261
|
return z2.object({
|
|
2263
2262
|
provider: this.provider,
|
|
2264
2263
|
event: this.event,
|
|
2265
|
-
callback: z2.string()
|
|
2264
|
+
callback: z2.string(),
|
|
2265
|
+
listId: z2.string()
|
|
2266
2266
|
});
|
|
2267
2267
|
},
|
|
2268
2268
|
get unsubscribe() {
|
|
2269
2269
|
return this.source.and(
|
|
2270
2270
|
z2.object({
|
|
2271
|
-
event: this.
|
|
2271
|
+
event: this.eventName,
|
|
2272
|
+
listId: z2.string()
|
|
2272
2273
|
})
|
|
2273
2274
|
);
|
|
2274
2275
|
},
|
|
2275
2276
|
get unsubscribeContent() {
|
|
2276
2277
|
return z2.object({
|
|
2277
2278
|
provider: this.provider,
|
|
2278
|
-
event: this.
|
|
2279
|
+
event: this.eventName,
|
|
2280
|
+
listId: z2.string()
|
|
2279
2281
|
});
|
|
2280
2282
|
}
|
|
2281
2283
|
};
|
|
@@ -2369,14 +2371,14 @@ var textLivechatEventsZods = {
|
|
|
2369
2371
|
get unsubscribe() {
|
|
2370
2372
|
return this.source.and(
|
|
2371
2373
|
z3.object({
|
|
2372
|
-
event: this.
|
|
2374
|
+
event: this.eventName
|
|
2373
2375
|
})
|
|
2374
2376
|
);
|
|
2375
2377
|
},
|
|
2376
2378
|
get unsubscribeContent() {
|
|
2377
2379
|
return z3.object({
|
|
2378
2380
|
provider: this.provider,
|
|
2379
|
-
event: this.
|
|
2381
|
+
event: this.eventName
|
|
2380
2382
|
});
|
|
2381
2383
|
}
|
|
2382
2384
|
};
|
|
@@ -2433,14 +2435,14 @@ var hubspotEventsZods = {
|
|
|
2433
2435
|
get unsubscribe() {
|
|
2434
2436
|
return this.source.and(
|
|
2435
2437
|
z4.object({
|
|
2436
|
-
event: this.
|
|
2438
|
+
event: this.eventName
|
|
2437
2439
|
})
|
|
2438
2440
|
);
|
|
2439
2441
|
},
|
|
2440
2442
|
get unsubscribeContent() {
|
|
2441
2443
|
return z4.object({
|
|
2442
2444
|
provider: this.provider,
|
|
2443
|
-
event: this.
|
|
2445
|
+
event: this.eventName
|
|
2444
2446
|
});
|
|
2445
2447
|
}
|
|
2446
2448
|
};
|
|
@@ -2517,14 +2519,14 @@ var bigcommerceEventsZods = {
|
|
|
2517
2519
|
get unsubscribe() {
|
|
2518
2520
|
return this.source.and(
|
|
2519
2521
|
z5.object({
|
|
2520
|
-
event: this.
|
|
2522
|
+
event: this.eventName
|
|
2521
2523
|
})
|
|
2522
2524
|
);
|
|
2523
2525
|
},
|
|
2524
2526
|
get unsubscribeContent() {
|
|
2525
2527
|
return z5.object({
|
|
2526
2528
|
provider: this.provider,
|
|
2527
|
-
event: this.
|
|
2529
|
+
event: this.eventName
|
|
2528
2530
|
});
|
|
2529
2531
|
}
|
|
2530
2532
|
};
|
|
@@ -3518,7 +3520,7 @@ var textPlatformWorkflowsApi = {
|
|
|
3518
3520
|
},
|
|
3519
3521
|
createWorkflow(payload, authorization) {
|
|
3520
3522
|
return __async(this, null, function* () {
|
|
3521
|
-
|
|
3523
|
+
return textClientInstance.post(
|
|
3522
3524
|
"/workflow_platform/workflows",
|
|
3523
3525
|
payload,
|
|
3524
3526
|
getTextClientConfig(__spreadProps(__spreadValues({}, authorization), {
|
|
@@ -3527,79 +3529,86 @@ var textPlatformWorkflowsApi = {
|
|
|
3527
3529
|
);
|
|
3528
3530
|
});
|
|
3529
3531
|
},
|
|
3530
|
-
updateWorkflow(payload, authorization) {
|
|
3532
|
+
updateWorkflow(workflowId, payload, authorization) {
|
|
3531
3533
|
return __async(this, null, function* () {
|
|
3532
|
-
|
|
3533
|
-
`/workflow_platform/workflows/${encodeURIComponent(
|
|
3534
|
+
return textClientInstance.put(
|
|
3535
|
+
`/workflow_platform/workflows/${encodeURIComponent(workflowId)}`,
|
|
3534
3536
|
payload,
|
|
3535
3537
|
getTextClientConfig(__spreadProps(__spreadValues({}, authorization), {
|
|
3536
3538
|
ensureAuthorizationToken: true
|
|
3537
3539
|
}))
|
|
3538
3540
|
);
|
|
3539
|
-
return workflow;
|
|
3540
3541
|
});
|
|
3541
3542
|
},
|
|
3542
|
-
deleteWorkflow(workflowId, authorization) {
|
|
3543
|
+
deleteWorkflow(workflowId, thirdPartyHeaders, authorization) {
|
|
3543
3544
|
return __async(this, null, function* () {
|
|
3544
|
-
|
|
3545
|
+
return textClientInstance.delete(
|
|
3545
3546
|
`/workflow_platform/workflows/${encodeURIComponent(workflowId)}`,
|
|
3546
|
-
__spreadValues({}, getTextClientConfig(__spreadProps(__spreadValues({}, authorization), {
|
|
3547
|
+
__spreadProps(__spreadValues({}, getTextClientConfig(__spreadProps(__spreadValues({}, authorization), {
|
|
3547
3548
|
ensureAuthorizationToken: true
|
|
3548
|
-
})))
|
|
3549
|
+
}))), {
|
|
3550
|
+
data: {
|
|
3551
|
+
third_party_headers: thirdPartyHeaders
|
|
3552
|
+
}
|
|
3553
|
+
})
|
|
3549
3554
|
);
|
|
3550
3555
|
});
|
|
3551
3556
|
},
|
|
3552
|
-
|
|
3557
|
+
toggleWorkflowActivation(workflowId, isActive, authorization) {
|
|
3553
3558
|
return __async(this, null, function* () {
|
|
3554
|
-
|
|
3559
|
+
return textClientInstance.put(
|
|
3555
3560
|
`/workflow_platform/workflows/${encodeURIComponent(
|
|
3556
|
-
|
|
3557
|
-
)}/
|
|
3558
|
-
|
|
3561
|
+
workflowId
|
|
3562
|
+
)}/activation`,
|
|
3563
|
+
{
|
|
3564
|
+
active: isActive
|
|
3565
|
+
},
|
|
3559
3566
|
getTextClientConfig(__spreadProps(__spreadValues({}, authorization), {
|
|
3560
3567
|
ensureAuthorizationToken: true
|
|
3561
3568
|
}))
|
|
3562
3569
|
);
|
|
3563
|
-
return execution;
|
|
3564
3570
|
});
|
|
3565
3571
|
},
|
|
3566
|
-
|
|
3572
|
+
executeWorkflow(workflowId, input, authorization) {
|
|
3567
3573
|
return __async(this, null, function* () {
|
|
3568
|
-
const { data:
|
|
3574
|
+
const { data: execution } = yield textClientInstance.post(
|
|
3569
3575
|
`/workflow_platform/workflows/${encodeURIComponent(
|
|
3570
3576
|
workflowId
|
|
3571
3577
|
)}/executions`,
|
|
3578
|
+
{
|
|
3579
|
+
input
|
|
3580
|
+
},
|
|
3572
3581
|
getTextClientConfig(__spreadProps(__spreadValues({}, authorization), {
|
|
3573
3582
|
ensureAuthorizationToken: true
|
|
3574
3583
|
}))
|
|
3575
3584
|
);
|
|
3576
|
-
return
|
|
3585
|
+
return execution;
|
|
3577
3586
|
});
|
|
3578
3587
|
},
|
|
3579
|
-
|
|
3588
|
+
getWorkflowExecutionsList(workflowId, authorization) {
|
|
3580
3589
|
return __async(this, null, function* () {
|
|
3581
|
-
const { data:
|
|
3590
|
+
const { data: executions } = yield textClientInstance.get(
|
|
3582
3591
|
`/workflow_platform/workflows/${encodeURIComponent(
|
|
3583
|
-
|
|
3584
|
-
)}/executions
|
|
3592
|
+
workflowId
|
|
3593
|
+
)}/executions`,
|
|
3585
3594
|
getTextClientConfig(__spreadProps(__spreadValues({}, authorization), {
|
|
3586
3595
|
ensureAuthorizationToken: true
|
|
3587
3596
|
}))
|
|
3588
3597
|
);
|
|
3589
|
-
return
|
|
3598
|
+
return executions;
|
|
3590
3599
|
});
|
|
3591
3600
|
},
|
|
3592
|
-
|
|
3601
|
+
getWorkflowExecutionDetails(workflowId, executionId, authorization) {
|
|
3593
3602
|
return __async(this, null, function* () {
|
|
3594
|
-
yield textClientInstance.
|
|
3603
|
+
const { data: execution } = yield textClientInstance.get(
|
|
3595
3604
|
`/workflow_platform/workflows/${encodeURIComponent(
|
|
3596
|
-
|
|
3597
|
-
)}/
|
|
3598
|
-
payload,
|
|
3605
|
+
workflowId
|
|
3606
|
+
)}/executions/${encodeURIComponent(executionId)}`,
|
|
3599
3607
|
getTextClientConfig(__spreadProps(__spreadValues({}, authorization), {
|
|
3600
3608
|
ensureAuthorizationToken: true
|
|
3601
3609
|
}))
|
|
3602
3610
|
);
|
|
3611
|
+
return execution;
|
|
3603
3612
|
});
|
|
3604
3613
|
},
|
|
3605
3614
|
validateWorkflowDefinition(payload, authorization) {
|