@speakai/mcp-server 1.12.1 → 1.12.3
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 +27 -4
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -2390,6 +2390,27 @@ var recorder_exports = {};
|
|
|
2390
2390
|
__export(recorder_exports, {
|
|
2391
2391
|
register: () => register5
|
|
2392
2392
|
});
|
|
2393
|
+
function optionsFromMetaType(metaType) {
|
|
2394
|
+
const bool = (v, fallback) => typeof v === "boolean" ? v : fallback;
|
|
2395
|
+
const upload = metaType?.upload ?? {};
|
|
2396
|
+
return {
|
|
2397
|
+
audio: bool(metaType?.audio, true),
|
|
2398
|
+
video: bool(metaType?.video, true),
|
|
2399
|
+
screenShare: bool(metaType?.screenShare, false),
|
|
2400
|
+
upload: {
|
|
2401
|
+
file: bool(upload.file, true),
|
|
2402
|
+
multiple: bool(upload.multiple, false),
|
|
2403
|
+
url: bool(upload.url, false)
|
|
2404
|
+
},
|
|
2405
|
+
liveTranscription: bool(metaType?.liveTranscription, false)
|
|
2406
|
+
};
|
|
2407
|
+
}
|
|
2408
|
+
function addRecorderOptions(recorder) {
|
|
2409
|
+
if (recorder && typeof recorder === "object") {
|
|
2410
|
+
recorder.options = optionsFromMetaType(recorder.meta?.type);
|
|
2411
|
+
}
|
|
2412
|
+
return recorder;
|
|
2413
|
+
}
|
|
2393
2414
|
function register5(server, client) {
|
|
2394
2415
|
const api = client ?? speakClient;
|
|
2395
2416
|
registerSpeakTool(
|
|
@@ -2441,6 +2462,7 @@ function register5(server, client) {
|
|
|
2441
2462
|
async (body) => {
|
|
2442
2463
|
try {
|
|
2443
2464
|
const result = await api.post("/v1/recorder/create", body);
|
|
2465
|
+
addRecorderOptions(result.data?.data?.recorderData);
|
|
2444
2466
|
return {
|
|
2445
2467
|
content: [{ type: "text", text: JSON.stringify(result.data, null, 2) }]
|
|
2446
2468
|
};
|
|
@@ -2471,6 +2493,7 @@ function register5(server, client) {
|
|
|
2471
2493
|
async (params) => {
|
|
2472
2494
|
try {
|
|
2473
2495
|
const result = await api.get("/v1/recorder", { params });
|
|
2496
|
+
result.data?.data?.recorderList?.forEach?.(addRecorderOptions);
|
|
2474
2497
|
return {
|
|
2475
2498
|
content: [{ type: "text", text: JSON.stringify(result.data, null, 2) }]
|
|
2476
2499
|
};
|
|
@@ -2530,6 +2553,7 @@ function register5(server, client) {
|
|
|
2530
2553
|
async ({ recorderId }) => {
|
|
2531
2554
|
try {
|
|
2532
2555
|
const result = await api.get(`/v1/recorder/${recorderId}`);
|
|
2556
|
+
addRecorderOptions(result.data?.data);
|
|
2533
2557
|
return {
|
|
2534
2558
|
content: [{ type: "text", text: JSON.stringify(result.data, null, 2) }]
|
|
2535
2559
|
};
|
|
@@ -2616,6 +2640,7 @@ function register5(server, client) {
|
|
|
2616
2640
|
async ({ recorderId, ...body }) => {
|
|
2617
2641
|
try {
|
|
2618
2642
|
const result = await api.put(`/v1/recorder/settings/${recorderId}`, body);
|
|
2643
|
+
addRecorderOptions(result.data?.data?.recorderData);
|
|
2619
2644
|
return {
|
|
2620
2645
|
content: [{ type: "text", text: JSON.stringify(result.data, null, 2) }]
|
|
2621
2646
|
};
|
|
@@ -4312,8 +4337,7 @@ ${JSON.stringify(uploadRes.data, null, 2)}` }],
|
|
|
4312
4337
|
params: { isVideo, filename, mimeType }
|
|
4313
4338
|
});
|
|
4314
4339
|
const signedData = signedRes.data?.data;
|
|
4315
|
-
const uploadUrl = signedData?.signedUrl ?? signedData?.url;
|
|
4316
|
-
const s3Key = signedData?.key ?? signedData?.s3Key;
|
|
4340
|
+
const uploadUrl = signedData?.preSignedUrl ?? signedData?.signedUrl ?? signedData?.url;
|
|
4317
4341
|
if (!uploadUrl) {
|
|
4318
4342
|
return {
|
|
4319
4343
|
content: [{ type: "text", text: `Error: Could not get signed upload URL.
|
|
@@ -4333,10 +4357,9 @@ ${JSON.stringify(signedRes.data, null, 2)}` }],
|
|
|
4333
4357
|
const createBody = {
|
|
4334
4358
|
name: params.name ?? filename,
|
|
4335
4359
|
url: uploadUrl.split("?")[0],
|
|
4336
|
-
// S3 URL without query params
|
|
4360
|
+
// S3 URL without query params; server re-signs via CloudFront
|
|
4337
4361
|
mediaType
|
|
4338
4362
|
};
|
|
4339
|
-
if (s3Key) createBody.s3Key = s3Key;
|
|
4340
4363
|
if (params.sourceLanguage) createBody.sourceLanguage = params.sourceLanguage;
|
|
4341
4364
|
if (params.folderId) createBody.folderId = params.folderId;
|
|
4342
4365
|
if (params.tags) createBody.tags = params.tags;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@speakai/mcp-server",
|
|
3
|
-
"version": "1.12.
|
|
3
|
+
"version": "1.12.3",
|
|
4
4
|
"mcpName": "io.github.speakai/mcp-server",
|
|
5
5
|
"description": "Official Speak AI MCP Server — capture meetings, search thousands of recordings, run async voice and video surveys, create clips, and automate workflows from your AI assistant.",
|
|
6
6
|
"homepage": "https://mcp.speakai.co",
|