@avallon-labs/mcp 43.3.0 → 44.1.0-staging.1036
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.js
CHANGED
|
@@ -1796,11 +1796,24 @@ var createWorkerWebhook = async (workerId, createWorkerWebhookBody, options) =>
|
|
|
1796
1796
|
headers: res.headers
|
|
1797
1797
|
};
|
|
1798
1798
|
};
|
|
1799
|
-
var getListWorkerWebhooksUrl = (workerId) => {
|
|
1800
|
-
|
|
1799
|
+
var getListWorkerWebhooksUrl = (workerId, params) => {
|
|
1800
|
+
const normalizedParams = new URLSearchParams();
|
|
1801
|
+
Object.entries(params || {}).forEach(([key, value]) => {
|
|
1802
|
+
if (value !== void 0) {
|
|
1803
|
+
if (typeof value === "object" && value !== null && !Array.isArray(value)) {
|
|
1804
|
+
for (const [sk, sv] of Object.entries(value)) {
|
|
1805
|
+
if (sv !== void 0) normalizedParams.append(`${key}[${sk}]`, String(sv));
|
|
1806
|
+
}
|
|
1807
|
+
} else {
|
|
1808
|
+
normalizedParams.append(key, value === null ? "null" : String(value));
|
|
1809
|
+
}
|
|
1810
|
+
}
|
|
1811
|
+
});
|
|
1812
|
+
const stringifiedParams = normalizedParams.toString();
|
|
1813
|
+
return stringifiedParams.length > 0 ? `/v1/workers/${workerId}/webhooks?${stringifiedParams}` : `/v1/workers/${workerId}/webhooks`;
|
|
1801
1814
|
};
|
|
1802
|
-
var listWorkerWebhooks = async (workerId, options) => {
|
|
1803
|
-
const res = await fetch(getListWorkerWebhooksUrl(workerId), {
|
|
1815
|
+
var listWorkerWebhooks = async (workerId, params, options) => {
|
|
1816
|
+
const res = await fetch(getListWorkerWebhooksUrl(workerId, params), {
|
|
1804
1817
|
...options,
|
|
1805
1818
|
method: "GET"
|
|
1806
1819
|
});
|
|
@@ -2876,11 +2889,24 @@ var createAgentWebhook = async (voiceAgentId, createAgentWebhookBody, options) =
|
|
|
2876
2889
|
headers: res.headers
|
|
2877
2890
|
};
|
|
2878
2891
|
};
|
|
2879
|
-
var getListAgentWebhooksUrl = (voiceAgentId) => {
|
|
2880
|
-
|
|
2892
|
+
var getListAgentWebhooksUrl = (voiceAgentId, params) => {
|
|
2893
|
+
const normalizedParams = new URLSearchParams();
|
|
2894
|
+
Object.entries(params || {}).forEach(([key, value]) => {
|
|
2895
|
+
if (value !== void 0) {
|
|
2896
|
+
if (typeof value === "object" && value !== null && !Array.isArray(value)) {
|
|
2897
|
+
for (const [sk, sv] of Object.entries(value)) {
|
|
2898
|
+
if (sv !== void 0) normalizedParams.append(`${key}[${sk}]`, String(sv));
|
|
2899
|
+
}
|
|
2900
|
+
} else {
|
|
2901
|
+
normalizedParams.append(key, value === null ? "null" : String(value));
|
|
2902
|
+
}
|
|
2903
|
+
}
|
|
2904
|
+
});
|
|
2905
|
+
const stringifiedParams = normalizedParams.toString();
|
|
2906
|
+
return stringifiedParams.length > 0 ? `/v1/voice-agents/${voiceAgentId}/webhooks?${stringifiedParams}` : `/v1/voice-agents/${voiceAgentId}/webhooks`;
|
|
2881
2907
|
};
|
|
2882
|
-
var listAgentWebhooks = async (voiceAgentId, options) => {
|
|
2883
|
-
const res = await fetch(getListAgentWebhooksUrl(voiceAgentId), {
|
|
2908
|
+
var listAgentWebhooks = async (voiceAgentId, params, options) => {
|
|
2909
|
+
const res = await fetch(getListAgentWebhooksUrl(voiceAgentId, params), {
|
|
2884
2910
|
...options,
|
|
2885
2911
|
method: "GET"
|
|
2886
2912
|
});
|
|
@@ -2910,11 +2936,24 @@ var createInboxWebhook = async (inboxId, createInboxWebhookBody, options) => {
|
|
|
2910
2936
|
headers: res.headers
|
|
2911
2937
|
};
|
|
2912
2938
|
};
|
|
2913
|
-
var getListInboxWebhooksUrl = (inboxId) => {
|
|
2914
|
-
|
|
2939
|
+
var getListInboxWebhooksUrl = (inboxId, params) => {
|
|
2940
|
+
const normalizedParams = new URLSearchParams();
|
|
2941
|
+
Object.entries(params || {}).forEach(([key, value]) => {
|
|
2942
|
+
if (value !== void 0) {
|
|
2943
|
+
if (typeof value === "object" && value !== null && !Array.isArray(value)) {
|
|
2944
|
+
for (const [sk, sv] of Object.entries(value)) {
|
|
2945
|
+
if (sv !== void 0) normalizedParams.append(`${key}[${sk}]`, String(sv));
|
|
2946
|
+
}
|
|
2947
|
+
} else {
|
|
2948
|
+
normalizedParams.append(key, value === null ? "null" : String(value));
|
|
2949
|
+
}
|
|
2950
|
+
}
|
|
2951
|
+
});
|
|
2952
|
+
const stringifiedParams = normalizedParams.toString();
|
|
2953
|
+
return stringifiedParams.length > 0 ? `/v1/inboxes/${inboxId}/webhooks?${stringifiedParams}` : `/v1/inboxes/${inboxId}/webhooks`;
|
|
2915
2954
|
};
|
|
2916
|
-
var listInboxWebhooks = async (inboxId, options) => {
|
|
2917
|
-
const res = await fetch(getListInboxWebhooksUrl(inboxId), {
|
|
2955
|
+
var listInboxWebhooks = async (inboxId, params, options) => {
|
|
2956
|
+
const res = await fetch(getListInboxWebhooksUrl(inboxId, params), {
|
|
2918
2957
|
...options,
|
|
2919
2958
|
method: "GET"
|
|
2920
2959
|
});
|
|
@@ -2944,11 +2983,24 @@ var createExtractorWebhook = async (id, createExtractorWebhookBody, options) =>
|
|
|
2944
2983
|
headers: res.headers
|
|
2945
2984
|
};
|
|
2946
2985
|
};
|
|
2947
|
-
var getListWebhooksUrl = (id) => {
|
|
2948
|
-
|
|
2986
|
+
var getListWebhooksUrl = (id, params) => {
|
|
2987
|
+
const normalizedParams = new URLSearchParams();
|
|
2988
|
+
Object.entries(params || {}).forEach(([key, value]) => {
|
|
2989
|
+
if (value !== void 0) {
|
|
2990
|
+
if (typeof value === "object" && value !== null && !Array.isArray(value)) {
|
|
2991
|
+
for (const [sk, sv] of Object.entries(value)) {
|
|
2992
|
+
if (sv !== void 0) normalizedParams.append(`${key}[${sk}]`, String(sv));
|
|
2993
|
+
}
|
|
2994
|
+
} else {
|
|
2995
|
+
normalizedParams.append(key, value === null ? "null" : String(value));
|
|
2996
|
+
}
|
|
2997
|
+
}
|
|
2998
|
+
});
|
|
2999
|
+
const stringifiedParams = normalizedParams.toString();
|
|
3000
|
+
return stringifiedParams.length > 0 ? `/v1/extractors/${id}/webhooks?${stringifiedParams}` : `/v1/extractors/${id}/webhooks`;
|
|
2949
3001
|
};
|
|
2950
|
-
var listWebhooks = async (id, options) => {
|
|
2951
|
-
const res = await fetch(getListWebhooksUrl(id), {
|
|
3002
|
+
var listWebhooks = async (id, params, options) => {
|
|
3003
|
+
const res = await fetch(getListWebhooksUrl(id, params), {
|
|
2952
3004
|
...options,
|
|
2953
3005
|
method: "GET"
|
|
2954
3006
|
});
|
|
@@ -3024,10 +3076,12 @@ var listWebhookDeliveries = async (id, params, options) => {
|
|
|
3024
3076
|
var getTestWebhookUrl = (id) => {
|
|
3025
3077
|
return `/v1/webhooks/${id}/test`;
|
|
3026
3078
|
};
|
|
3027
|
-
var testWebhook = async (id, options) => {
|
|
3079
|
+
var testWebhook = async (id, testWebhookBody, options) => {
|
|
3028
3080
|
const res = await fetch(getTestWebhookUrl(id), {
|
|
3029
3081
|
...options,
|
|
3030
|
-
method: "POST"
|
|
3082
|
+
method: "POST",
|
|
3083
|
+
headers: { "Content-Type": "application/json", ...options?.headers },
|
|
3084
|
+
body: JSON.stringify(testWebhookBody)
|
|
3031
3085
|
});
|
|
3032
3086
|
const body = [204, 205, 304].includes(res.status) ? null : await res.text();
|
|
3033
3087
|
const data = body ? JSON.parse(body) : {};
|
|
@@ -4059,7 +4113,10 @@ var createWorkerWebhookHandler = async (args) => {
|
|
|
4059
4113
|
};
|
|
4060
4114
|
};
|
|
4061
4115
|
var listWorkerWebhooksHandler = async (args) => {
|
|
4062
|
-
const res = await listWorkerWebhooks(
|
|
4116
|
+
const res = await listWorkerWebhooks(
|
|
4117
|
+
args.pathParams.workerId,
|
|
4118
|
+
args.queryParams
|
|
4119
|
+
);
|
|
4063
4120
|
return {
|
|
4064
4121
|
content: [
|
|
4065
4122
|
{
|
|
@@ -4688,7 +4745,10 @@ var createAgentWebhookHandler = async (args) => {
|
|
|
4688
4745
|
};
|
|
4689
4746
|
};
|
|
4690
4747
|
var listAgentWebhooksHandler = async (args) => {
|
|
4691
|
-
const res = await listAgentWebhooks(
|
|
4748
|
+
const res = await listAgentWebhooks(
|
|
4749
|
+
args.pathParams.voiceAgentId,
|
|
4750
|
+
args.queryParams
|
|
4751
|
+
);
|
|
4692
4752
|
return {
|
|
4693
4753
|
content: [
|
|
4694
4754
|
{
|
|
@@ -4713,7 +4773,10 @@ var createInboxWebhookHandler = async (args) => {
|
|
|
4713
4773
|
};
|
|
4714
4774
|
};
|
|
4715
4775
|
var listInboxWebhooksHandler = async (args) => {
|
|
4716
|
-
const res = await listInboxWebhooks(
|
|
4776
|
+
const res = await listInboxWebhooks(
|
|
4777
|
+
args.pathParams.inboxId,
|
|
4778
|
+
args.queryParams
|
|
4779
|
+
);
|
|
4717
4780
|
return {
|
|
4718
4781
|
content: [
|
|
4719
4782
|
{
|
|
@@ -4735,7 +4798,7 @@ var createExtractorWebhookHandler = async (args) => {
|
|
|
4735
4798
|
};
|
|
4736
4799
|
};
|
|
4737
4800
|
var listWebhooksHandler = async (args) => {
|
|
4738
|
-
const res = await listWebhooks(args.pathParams.id);
|
|
4801
|
+
const res = await listWebhooks(args.pathParams.id, args.queryParams);
|
|
4739
4802
|
return {
|
|
4740
4803
|
content: [
|
|
4741
4804
|
{
|
|
@@ -4779,7 +4842,7 @@ var listWebhookDeliveriesHandler = async (args) => {
|
|
|
4779
4842
|
};
|
|
4780
4843
|
};
|
|
4781
4844
|
var testWebhookHandler = async (args) => {
|
|
4782
|
-
const res = await testWebhook(args.pathParams.id);
|
|
4845
|
+
const res = await testWebhook(args.pathParams.id, args.bodyParams);
|
|
4783
4846
|
return {
|
|
4784
4847
|
content: [
|
|
4785
4848
|
{
|
|
@@ -4838,7 +4901,7 @@ var ListVoiceAgentsResponse = zod.object({
|
|
|
4838
4901
|
"eleven_turbo_v2_5",
|
|
4839
4902
|
"sonic-3",
|
|
4840
4903
|
"sonic-3.5",
|
|
4841
|
-
"sonic-
|
|
4904
|
+
"sonic-3.6",
|
|
4842
4905
|
"chirp_3",
|
|
4843
4906
|
"polly-neural"
|
|
4844
4907
|
]),
|
|
@@ -4894,7 +4957,7 @@ var ListVoiceAgentsResponse = zod.object({
|
|
|
4894
4957
|
"eleven_turbo_v2_5",
|
|
4895
4958
|
"sonic-3",
|
|
4896
4959
|
"sonic-3.5",
|
|
4897
|
-
"sonic-
|
|
4960
|
+
"sonic-3.6",
|
|
4898
4961
|
"chirp_3",
|
|
4899
4962
|
"polly-neural"
|
|
4900
4963
|
]),
|
|
@@ -4956,7 +5019,7 @@ var CreateVoiceAgentBody = zod.object({
|
|
|
4956
5019
|
"eleven_turbo_v2_5",
|
|
4957
5020
|
"sonic-3",
|
|
4958
5021
|
"sonic-3.5",
|
|
4959
|
-
"sonic-
|
|
5022
|
+
"sonic-3.6",
|
|
4960
5023
|
"chirp_3",
|
|
4961
5024
|
"polly-neural"
|
|
4962
5025
|
]).describe("Text-to-speech model"),
|
|
@@ -5045,7 +5108,7 @@ var GetVoiceAgentResponse = zod.object({
|
|
|
5045
5108
|
"eleven_turbo_v2_5",
|
|
5046
5109
|
"sonic-3",
|
|
5047
5110
|
"sonic-3.5",
|
|
5048
|
-
"sonic-
|
|
5111
|
+
"sonic-3.6",
|
|
5049
5112
|
"chirp_3",
|
|
5050
5113
|
"polly-neural"
|
|
5051
5114
|
]),
|
|
@@ -5101,7 +5164,7 @@ var GetVoiceAgentResponse = zod.object({
|
|
|
5101
5164
|
"eleven_turbo_v2_5",
|
|
5102
5165
|
"sonic-3",
|
|
5103
5166
|
"sonic-3.5",
|
|
5104
|
-
"sonic-
|
|
5167
|
+
"sonic-3.6",
|
|
5105
5168
|
"chirp_3",
|
|
5106
5169
|
"polly-neural"
|
|
5107
5170
|
]),
|
|
@@ -5185,7 +5248,7 @@ var UpdateVoiceAgentResponse = zod.object({
|
|
|
5185
5248
|
"eleven_turbo_v2_5",
|
|
5186
5249
|
"sonic-3",
|
|
5187
5250
|
"sonic-3.5",
|
|
5188
|
-
"sonic-
|
|
5251
|
+
"sonic-3.6",
|
|
5189
5252
|
"chirp_3",
|
|
5190
5253
|
"polly-neural"
|
|
5191
5254
|
]),
|
|
@@ -5241,7 +5304,7 @@ var UpdateVoiceAgentResponse = zod.object({
|
|
|
5241
5304
|
"eleven_turbo_v2_5",
|
|
5242
5305
|
"sonic-3",
|
|
5243
5306
|
"sonic-3.5",
|
|
5244
|
-
"sonic-
|
|
5307
|
+
"sonic-3.6",
|
|
5245
5308
|
"chirp_3",
|
|
5246
5309
|
"polly-neural"
|
|
5247
5310
|
]),
|
|
@@ -5357,7 +5420,7 @@ var GetVoiceAgentVersionResponse = zod.object({
|
|
|
5357
5420
|
"eleven_turbo_v2_5",
|
|
5358
5421
|
"sonic-3",
|
|
5359
5422
|
"sonic-3.5",
|
|
5360
|
-
"sonic-
|
|
5423
|
+
"sonic-3.6",
|
|
5361
5424
|
"chirp_3",
|
|
5362
5425
|
"polly-neural"
|
|
5363
5426
|
]),
|
|
@@ -5413,7 +5476,7 @@ var GetVoiceAgentVersionResponse = zod.object({
|
|
|
5413
5476
|
"eleven_turbo_v2_5",
|
|
5414
5477
|
"sonic-3",
|
|
5415
5478
|
"sonic-3.5",
|
|
5416
|
-
"sonic-
|
|
5479
|
+
"sonic-3.6",
|
|
5417
5480
|
"chirp_3",
|
|
5418
5481
|
"polly-neural"
|
|
5419
5482
|
]),
|
|
@@ -5514,7 +5577,7 @@ var AddToolsToVoiceAgentResponse = zod.object({
|
|
|
5514
5577
|
"eleven_turbo_v2_5",
|
|
5515
5578
|
"sonic-3",
|
|
5516
5579
|
"sonic-3.5",
|
|
5517
|
-
"sonic-
|
|
5580
|
+
"sonic-3.6",
|
|
5518
5581
|
"chirp_3",
|
|
5519
5582
|
"polly-neural"
|
|
5520
5583
|
]),
|
|
@@ -5570,7 +5633,7 @@ var AddToolsToVoiceAgentResponse = zod.object({
|
|
|
5570
5633
|
"eleven_turbo_v2_5",
|
|
5571
5634
|
"sonic-3",
|
|
5572
5635
|
"sonic-3.5",
|
|
5573
|
-
"sonic-
|
|
5636
|
+
"sonic-3.6",
|
|
5574
5637
|
"chirp_3",
|
|
5575
5638
|
"polly-neural"
|
|
5576
5639
|
]),
|
|
@@ -5641,7 +5704,7 @@ var DeleteToolsFromVoiceAgentResponse = zod.object({
|
|
|
5641
5704
|
"eleven_turbo_v2_5",
|
|
5642
5705
|
"sonic-3",
|
|
5643
5706
|
"sonic-3.5",
|
|
5644
|
-
"sonic-
|
|
5707
|
+
"sonic-3.6",
|
|
5645
5708
|
"chirp_3",
|
|
5646
5709
|
"polly-neural"
|
|
5647
5710
|
]),
|
|
@@ -5697,7 +5760,7 @@ var DeleteToolsFromVoiceAgentResponse = zod.object({
|
|
|
5697
5760
|
"eleven_turbo_v2_5",
|
|
5698
5761
|
"sonic-3",
|
|
5699
5762
|
"sonic-3.5",
|
|
5700
|
-
"sonic-
|
|
5763
|
+
"sonic-3.6",
|
|
5701
5764
|
"chirp_3",
|
|
5702
5765
|
"polly-neural"
|
|
5703
5766
|
]),
|
|
@@ -5790,7 +5853,7 @@ var UpdateVoiceAgentModelsBody = zod.object({
|
|
|
5790
5853
|
"eleven_turbo_v2_5",
|
|
5791
5854
|
"sonic-3",
|
|
5792
5855
|
"sonic-3.5",
|
|
5793
|
-
"sonic-
|
|
5856
|
+
"sonic-3.6",
|
|
5794
5857
|
"chirp_3",
|
|
5795
5858
|
"polly-neural"
|
|
5796
5859
|
]),
|
|
@@ -5858,7 +5921,7 @@ var UpdateVoiceAgentModelsBody = zod.object({
|
|
|
5858
5921
|
"eleven_turbo_v2_5",
|
|
5859
5922
|
"sonic-3",
|
|
5860
5923
|
"sonic-3.5",
|
|
5861
|
-
"sonic-
|
|
5924
|
+
"sonic-3.6",
|
|
5862
5925
|
"chirp_3",
|
|
5863
5926
|
"polly-neural"
|
|
5864
5927
|
]),
|
|
@@ -5939,7 +6002,7 @@ var UpdateVoiceAgentModelsResponse = zod.object({
|
|
|
5939
6002
|
"eleven_turbo_v2_5",
|
|
5940
6003
|
"sonic-3",
|
|
5941
6004
|
"sonic-3.5",
|
|
5942
|
-
"sonic-
|
|
6005
|
+
"sonic-3.6",
|
|
5943
6006
|
"chirp_3",
|
|
5944
6007
|
"polly-neural"
|
|
5945
6008
|
]),
|
|
@@ -5995,7 +6058,7 @@ var UpdateVoiceAgentModelsResponse = zod.object({
|
|
|
5995
6058
|
"eleven_turbo_v2_5",
|
|
5996
6059
|
"sonic-3",
|
|
5997
6060
|
"sonic-3.5",
|
|
5998
|
-
"sonic-
|
|
6061
|
+
"sonic-3.6",
|
|
5999
6062
|
"chirp_3",
|
|
6000
6063
|
"polly-neural"
|
|
6001
6064
|
]),
|
|
@@ -6068,7 +6131,7 @@ var UpdateCallControlsResponse = zod.object({
|
|
|
6068
6131
|
"eleven_turbo_v2_5",
|
|
6069
6132
|
"sonic-3",
|
|
6070
6133
|
"sonic-3.5",
|
|
6071
|
-
"sonic-
|
|
6134
|
+
"sonic-3.6",
|
|
6072
6135
|
"chirp_3",
|
|
6073
6136
|
"polly-neural"
|
|
6074
6137
|
]),
|
|
@@ -6124,7 +6187,7 @@ var UpdateCallControlsResponse = zod.object({
|
|
|
6124
6187
|
"eleven_turbo_v2_5",
|
|
6125
6188
|
"sonic-3",
|
|
6126
6189
|
"sonic-3.5",
|
|
6127
|
-
"sonic-
|
|
6190
|
+
"sonic-3.6",
|
|
6128
6191
|
"chirp_3",
|
|
6129
6192
|
"polly-neural"
|
|
6130
6193
|
]),
|
|
@@ -8180,6 +8243,7 @@ var createWorkerWebhookBodyAuthHeaderValueOneMax = 2048;
|
|
|
8180
8243
|
var CreateWorkerWebhookBody = zod.object({
|
|
8181
8244
|
name: zod.string().min(1).max(createWorkerWebhookBodyNameMax),
|
|
8182
8245
|
url: zod.string().url().max(createWorkerWebhookBodyUrlMax),
|
|
8246
|
+
environments: zod.array(zod.enum(["live", "test"])).min(1).default([`live`]),
|
|
8183
8247
|
auth_header_name: zod.union([
|
|
8184
8248
|
zod.string().max(createWorkerWebhookBodyAuthHeaderNameOneMax),
|
|
8185
8249
|
zod.null()
|
|
@@ -8212,6 +8276,7 @@ var CreateWorkerWebhookResponse = zod.object({
|
|
|
8212
8276
|
auth_header_name: zod.union([zod.string(), zod.null()]),
|
|
8213
8277
|
has_auth: zod.boolean(),
|
|
8214
8278
|
enabled: zod.boolean(),
|
|
8279
|
+
environments: zod.array(zod.enum(["live", "test"])),
|
|
8215
8280
|
created_at: zod.string().datetime({}),
|
|
8216
8281
|
updated_at: zod.string().datetime({})
|
|
8217
8282
|
}),
|
|
@@ -8220,6 +8285,11 @@ var CreateWorkerWebhookResponse = zod.object({
|
|
|
8220
8285
|
var ListWorkerWebhooksParams = zod.object({
|
|
8221
8286
|
workerId: zod.string().min(1)
|
|
8222
8287
|
});
|
|
8288
|
+
var ListWorkerWebhooksQueryParams = zod.object({
|
|
8289
|
+
environment: zod.enum(["live", "test"]).optional().describe(
|
|
8290
|
+
"Only return webhooks that receive events from this environment. Webhooks configured for both environments match either value."
|
|
8291
|
+
)
|
|
8292
|
+
});
|
|
8223
8293
|
var ListWorkerWebhooksResponse = zod.object({
|
|
8224
8294
|
data: zod.array(
|
|
8225
8295
|
zod.object({
|
|
@@ -8243,6 +8313,7 @@ var ListWorkerWebhooksResponse = zod.object({
|
|
|
8243
8313
|
auth_header_name: zod.union([zod.string(), zod.null()]),
|
|
8244
8314
|
has_auth: zod.boolean(),
|
|
8245
8315
|
enabled: zod.boolean(),
|
|
8316
|
+
environments: zod.array(zod.enum(["live", "test"])),
|
|
8246
8317
|
created_at: zod.string().datetime({}),
|
|
8247
8318
|
updated_at: zod.string().datetime({})
|
|
8248
8319
|
})
|
|
@@ -9681,6 +9752,7 @@ var createAgentWebhookBodyAuthHeaderValueOneMax = 2048;
|
|
|
9681
9752
|
var CreateAgentWebhookBody = zod.object({
|
|
9682
9753
|
name: zod.string().min(1).max(createAgentWebhookBodyNameMax),
|
|
9683
9754
|
url: zod.string().url().max(createAgentWebhookBodyUrlMax),
|
|
9755
|
+
environments: zod.array(zod.enum(["live", "test"])).min(1).default([`live`]),
|
|
9684
9756
|
auth_header_name: zod.union([
|
|
9685
9757
|
zod.string().max(createAgentWebhookBodyAuthHeaderNameOneMax),
|
|
9686
9758
|
zod.null()
|
|
@@ -9713,6 +9785,7 @@ var CreateAgentWebhookResponse = zod.object({
|
|
|
9713
9785
|
auth_header_name: zod.union([zod.string(), zod.null()]),
|
|
9714
9786
|
has_auth: zod.boolean(),
|
|
9715
9787
|
enabled: zod.boolean(),
|
|
9788
|
+
environments: zod.array(zod.enum(["live", "test"])),
|
|
9716
9789
|
created_at: zod.string().datetime({}),
|
|
9717
9790
|
updated_at: zod.string().datetime({})
|
|
9718
9791
|
}),
|
|
@@ -9721,6 +9794,11 @@ var CreateAgentWebhookResponse = zod.object({
|
|
|
9721
9794
|
var ListAgentWebhooksParams = zod.object({
|
|
9722
9795
|
voiceAgentId: zod.string().min(1)
|
|
9723
9796
|
});
|
|
9797
|
+
var ListAgentWebhooksQueryParams = zod.object({
|
|
9798
|
+
environment: zod.enum(["live", "test"]).optional().describe(
|
|
9799
|
+
"Only return webhooks that receive events from this environment. Webhooks configured for both environments match either value."
|
|
9800
|
+
)
|
|
9801
|
+
});
|
|
9724
9802
|
var ListAgentWebhooksResponse = zod.object({
|
|
9725
9803
|
data: zod.array(
|
|
9726
9804
|
zod.object({
|
|
@@ -9744,6 +9822,7 @@ var ListAgentWebhooksResponse = zod.object({
|
|
|
9744
9822
|
auth_header_name: zod.union([zod.string(), zod.null()]),
|
|
9745
9823
|
has_auth: zod.boolean(),
|
|
9746
9824
|
enabled: zod.boolean(),
|
|
9825
|
+
environments: zod.array(zod.enum(["live", "test"])),
|
|
9747
9826
|
created_at: zod.string().datetime({}),
|
|
9748
9827
|
updated_at: zod.string().datetime({})
|
|
9749
9828
|
})
|
|
@@ -9760,6 +9839,7 @@ var createInboxWebhookBodyAuthHeaderValueOneMax = 2048;
|
|
|
9760
9839
|
var CreateInboxWebhookBody = zod.object({
|
|
9761
9840
|
name: zod.string().min(1).max(createInboxWebhookBodyNameMax),
|
|
9762
9841
|
url: zod.string().url().max(createInboxWebhookBodyUrlMax),
|
|
9842
|
+
environments: zod.array(zod.enum(["live", "test"])).min(1).default([`live`]),
|
|
9763
9843
|
auth_header_name: zod.union([
|
|
9764
9844
|
zod.string().max(createInboxWebhookBodyAuthHeaderNameOneMax),
|
|
9765
9845
|
zod.null()
|
|
@@ -9792,6 +9872,7 @@ var CreateInboxWebhookResponse = zod.object({
|
|
|
9792
9872
|
auth_header_name: zod.union([zod.string(), zod.null()]),
|
|
9793
9873
|
has_auth: zod.boolean(),
|
|
9794
9874
|
enabled: zod.boolean(),
|
|
9875
|
+
environments: zod.array(zod.enum(["live", "test"])),
|
|
9795
9876
|
created_at: zod.string().datetime({}),
|
|
9796
9877
|
updated_at: zod.string().datetime({})
|
|
9797
9878
|
}),
|
|
@@ -9800,6 +9881,11 @@ var CreateInboxWebhookResponse = zod.object({
|
|
|
9800
9881
|
var ListInboxWebhooksParams = zod.object({
|
|
9801
9882
|
inboxId: zod.string().min(1)
|
|
9802
9883
|
});
|
|
9884
|
+
var ListInboxWebhooksQueryParams = zod.object({
|
|
9885
|
+
environment: zod.enum(["live", "test"]).optional().describe(
|
|
9886
|
+
"Only return webhooks that receive events from this environment. Webhooks configured for both environments match either value."
|
|
9887
|
+
)
|
|
9888
|
+
});
|
|
9803
9889
|
var ListInboxWebhooksResponse = zod.object({
|
|
9804
9890
|
data: zod.array(
|
|
9805
9891
|
zod.object({
|
|
@@ -9823,6 +9909,7 @@ var ListInboxWebhooksResponse = zod.object({
|
|
|
9823
9909
|
auth_header_name: zod.union([zod.string(), zod.null()]),
|
|
9824
9910
|
has_auth: zod.boolean(),
|
|
9825
9911
|
enabled: zod.boolean(),
|
|
9912
|
+
environments: zod.array(zod.enum(["live", "test"])),
|
|
9826
9913
|
created_at: zod.string().datetime({}),
|
|
9827
9914
|
updated_at: zod.string().datetime({})
|
|
9828
9915
|
})
|
|
@@ -9839,6 +9926,7 @@ var createExtractorWebhookBodyAuthHeaderValueOneMax = 2048;
|
|
|
9839
9926
|
var CreateExtractorWebhookBody = zod.object({
|
|
9840
9927
|
name: zod.string().min(1).max(createExtractorWebhookBodyNameMax),
|
|
9841
9928
|
url: zod.string().url().max(createExtractorWebhookBodyUrlMax),
|
|
9929
|
+
environments: zod.array(zod.enum(["live", "test"])).min(1).default([`live`]),
|
|
9842
9930
|
auth_header_name: zod.union([
|
|
9843
9931
|
zod.string().max(createExtractorWebhookBodyAuthHeaderNameOneMax),
|
|
9844
9932
|
zod.null()
|
|
@@ -9871,6 +9959,7 @@ var CreateExtractorWebhookResponse = zod.object({
|
|
|
9871
9959
|
auth_header_name: zod.union([zod.string(), zod.null()]),
|
|
9872
9960
|
has_auth: zod.boolean(),
|
|
9873
9961
|
enabled: zod.boolean(),
|
|
9962
|
+
environments: zod.array(zod.enum(["live", "test"])),
|
|
9874
9963
|
created_at: zod.string().datetime({}),
|
|
9875
9964
|
updated_at: zod.string().datetime({})
|
|
9876
9965
|
}),
|
|
@@ -9879,6 +9968,11 @@ var CreateExtractorWebhookResponse = zod.object({
|
|
|
9879
9968
|
var ListWebhooksParams = zod.object({
|
|
9880
9969
|
id: zod.string().min(1)
|
|
9881
9970
|
});
|
|
9971
|
+
var ListWebhooksQueryParams = zod.object({
|
|
9972
|
+
environment: zod.enum(["live", "test"]).optional().describe(
|
|
9973
|
+
"Only return webhooks that receive events from this environment. Webhooks configured for both environments match either value."
|
|
9974
|
+
)
|
|
9975
|
+
});
|
|
9882
9976
|
var ListWebhooksResponse = zod.object({
|
|
9883
9977
|
data: zod.array(
|
|
9884
9978
|
zod.object({
|
|
@@ -9902,6 +9996,7 @@ var ListWebhooksResponse = zod.object({
|
|
|
9902
9996
|
auth_header_name: zod.union([zod.string(), zod.null()]),
|
|
9903
9997
|
has_auth: zod.boolean(),
|
|
9904
9998
|
enabled: zod.boolean(),
|
|
9999
|
+
environments: zod.array(zod.enum(["live", "test"])),
|
|
9905
10000
|
created_at: zod.string().datetime({}),
|
|
9906
10001
|
updated_at: zod.string().datetime({})
|
|
9907
10002
|
})
|
|
@@ -9940,6 +10035,7 @@ var GetWebhookResponse = zod.object({
|
|
|
9940
10035
|
auth_header_name: zod.union([zod.string(), zod.null()]),
|
|
9941
10036
|
has_auth: zod.boolean(),
|
|
9942
10037
|
enabled: zod.boolean(),
|
|
10038
|
+
environments: zod.array(zod.enum(["live", "test"])),
|
|
9943
10039
|
created_at: zod.string().datetime({}),
|
|
9944
10040
|
updated_at: zod.string().datetime({})
|
|
9945
10041
|
}),
|
|
@@ -9979,6 +10075,10 @@ var ListWebhookDeliveriesResponse = zod.object({
|
|
|
9979
10075
|
var TestWebhookParams = zod.object({
|
|
9980
10076
|
id: zod.string().min(1)
|
|
9981
10077
|
});
|
|
10078
|
+
var testWebhookBodyEnvironmentDefault = `live`;
|
|
10079
|
+
var TestWebhookBody = zod.object({
|
|
10080
|
+
environment: zod.enum(["live", "test"]).default(testWebhookBodyEnvironmentDefault).describe("The environment to stamp on the test payload.")
|
|
10081
|
+
});
|
|
9982
10082
|
var TestWebhookResponse = zod.object({
|
|
9983
10083
|
data: zod.object({
|
|
9984
10084
|
success: zod.boolean(),
|
|
@@ -10718,7 +10818,8 @@ server.tool(
|
|
|
10718
10818
|
"listWorkerWebhooks",
|
|
10719
10819
|
"List worker webhooks",
|
|
10720
10820
|
{
|
|
10721
|
-
pathParams: ListWorkerWebhooksParams
|
|
10821
|
+
pathParams: ListWorkerWebhooksParams,
|
|
10822
|
+
queryParams: ListWorkerWebhooksQueryParams
|
|
10722
10823
|
},
|
|
10723
10824
|
listWorkerWebhooksHandler
|
|
10724
10825
|
);
|
|
@@ -11155,7 +11256,8 @@ server.tool(
|
|
|
11155
11256
|
"listAgentWebhooks",
|
|
11156
11257
|
"List voice agent webhooks",
|
|
11157
11258
|
{
|
|
11158
|
-
pathParams: ListAgentWebhooksParams
|
|
11259
|
+
pathParams: ListAgentWebhooksParams,
|
|
11260
|
+
queryParams: ListAgentWebhooksQueryParams
|
|
11159
11261
|
},
|
|
11160
11262
|
listAgentWebhooksHandler
|
|
11161
11263
|
);
|
|
@@ -11172,7 +11274,8 @@ server.tool(
|
|
|
11172
11274
|
"listInboxWebhooks",
|
|
11173
11275
|
"List inbox webhooks",
|
|
11174
11276
|
{
|
|
11175
|
-
pathParams: ListInboxWebhooksParams
|
|
11277
|
+
pathParams: ListInboxWebhooksParams,
|
|
11278
|
+
queryParams: ListInboxWebhooksQueryParams
|
|
11176
11279
|
},
|
|
11177
11280
|
listInboxWebhooksHandler
|
|
11178
11281
|
);
|
|
@@ -11189,7 +11292,8 @@ server.tool(
|
|
|
11189
11292
|
"listWebhooks",
|
|
11190
11293
|
"List extractor webhooks",
|
|
11191
11294
|
{
|
|
11192
|
-
pathParams: ListWebhooksParams
|
|
11295
|
+
pathParams: ListWebhooksParams,
|
|
11296
|
+
queryParams: ListWebhooksQueryParams
|
|
11193
11297
|
},
|
|
11194
11298
|
listWebhooksHandler
|
|
11195
11299
|
);
|
|
@@ -11222,7 +11326,8 @@ server.tool(
|
|
|
11222
11326
|
"testWebhook",
|
|
11223
11327
|
"Test webhook",
|
|
11224
11328
|
{
|
|
11225
|
-
pathParams: TestWebhookParams
|
|
11329
|
+
pathParams: TestWebhookParams,
|
|
11330
|
+
bodyParams: TestWebhookBody
|
|
11226
11331
|
},
|
|
11227
11332
|
testWebhookHandler
|
|
11228
11333
|
);
|
|
@@ -11230,4 +11335,4 @@ var transport = new StdioServerTransport();
|
|
|
11230
11335
|
server.connect(transport).then(() => {
|
|
11231
11336
|
console.error("MCP server running on stdio");
|
|
11232
11337
|
}).catch(console.error);
|
|
11233
|
-
//# sourceMappingURL=server-
|
|
11338
|
+
//# sourceMappingURL=server-UWR4VDLZ.js.map
|