@velaro/mcp-server 0.6.76 → 0.6.78
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/package.json +1 -1
- package/server.js +21 -2
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@velaro/mcp-server",
|
|
3
|
-
"version": "0.6.
|
|
3
|
+
"version": "0.6.78",
|
|
4
4
|
"description": "Velaro MCP server — connect Claude and other AI agents directly to your Velaro account: KB, workflows, bots, conversations, contacts, routing, and more.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"bin": {
|
package/server.js
CHANGED
|
@@ -4151,6 +4151,7 @@ For multiSelect dynamic options: the variable named in dynamicOptionsVariable mu
|
|
|
4151
4151
|
description: { type: 'string', description: 'New description' },
|
|
4152
4152
|
contactSales: { type: 'boolean', description: 'Set true to hide price and show "Contact sales"' },
|
|
4153
4153
|
isActive: { type: 'boolean', description: 'Set false to deactivate (hide from catalog)' },
|
|
4154
|
+
limits: { type: 'object', description: 'Plan limit keys merged into MetadataJson (numbers): aiTokensPerMonth, includedMcpCalls, apiCallsPerMonth, webhookInvocationsPerMonth, httpActionsPerMonth, emailSendsPerMonth, blobUploadMbPerMonth. Other keys are preserved.' },
|
|
4154
4155
|
},
|
|
4155
4156
|
required: ['packageKey'],
|
|
4156
4157
|
},
|
|
@@ -5302,7 +5303,7 @@ async function handleTool(name, args) {
|
|
|
5302
5303
|
}
|
|
5303
5304
|
|
|
5304
5305
|
case 'kb_update_article': {
|
|
5305
|
-
await api('PUT', `/api/kb/articles?id=${args.id}`, {
|
|
5306
|
+
const updateResult = await api('PUT', `/api/kb/articles?id=${args.id}`, {
|
|
5306
5307
|
title: args.title,
|
|
5307
5308
|
slug: args.slug,
|
|
5308
5309
|
topicId: args.topicId,
|
|
@@ -5316,7 +5317,8 @@ async function handleTool(name, args) {
|
|
|
5316
5317
|
botSummary: args.botSummary || '',
|
|
5317
5318
|
isFeatured: false,
|
|
5318
5319
|
});
|
|
5319
|
-
|
|
5320
|
+
// Server reports the real transition (published / unpublished / saved) since 2026-10-07.
|
|
5321
|
+
return `${updateResult?.message || 'Updated article'} [${args.id}] "${args.title}".`;
|
|
5320
5322
|
}
|
|
5321
5323
|
|
|
5322
5324
|
case 'kb_get_settings': {
|
|
@@ -9281,6 +9283,13 @@ async function handleTool(name, args) {
|
|
|
9281
9283
|
for (const p of items) {
|
|
9282
9284
|
const price = p.contactSales ? 'Contact sales' : (p.monthlyPriceCents ? `$${(p.monthlyPriceCents/100).toFixed(0)}${p.unitLabel||'/mo'}` : 'Free');
|
|
9283
9285
|
lines.push(` ${p.packageKey.padEnd(40)} ${price.padEnd(18)} v${p.version} ${p.displayName}`);
|
|
9286
|
+
if (p.packageType === 'plan' && p.metadataJson) {
|
|
9287
|
+
try {
|
|
9288
|
+
const m = JSON.parse(p.metadataJson);
|
|
9289
|
+
const lim = ['aiTokensPerMonth','includedMcpCalls','apiCallsPerMonth','webhookInvocationsPerMonth','httpActionsPerMonth','emailSendsPerMonth','blobUploadMbPerMonth'].filter(k => m[k] != null).map(k => `${k}=${m[k]}`);
|
|
9290
|
+
if (lim.length) lines.push(` limits: ${lim.join(' ')}`);
|
|
9291
|
+
} catch { /* ignore bad metadata */ }
|
|
9292
|
+
}
|
|
9284
9293
|
}
|
|
9285
9294
|
}
|
|
9286
9295
|
return lines.join('\n');
|
|
@@ -9295,6 +9304,16 @@ async function handleTool(name, args) {
|
|
|
9295
9304
|
if (args.description) payload.description = args.description;
|
|
9296
9305
|
if (args.contactSales != null) payload.contactSales = args.contactSales;
|
|
9297
9306
|
if (args.isActive != null) payload.isActive = args.isActive;
|
|
9307
|
+
if (args.limits && typeof args.limits === 'object') {
|
|
9308
|
+
const LIMIT_KEYS = ['aiTokensPerMonth','includedMcpCalls','apiCallsPerMonth','webhookInvocationsPerMonth','httpActionsPerMonth','emailSendsPerMonth','blobUploadMbPerMonth'];
|
|
9309
|
+
const bad = Object.keys(args.limits).filter(k => !LIMIT_KEYS.includes(k));
|
|
9310
|
+
if (bad.length) throw new Error(`Unknown limit keys: ${bad.join(', ')}`);
|
|
9311
|
+
const all = await api('GET', '/Pricing/catalog');
|
|
9312
|
+
const cur = (Array.isArray(all) ? all : []).find(p => p.packageKey === args.packageKey);
|
|
9313
|
+
let meta = {};
|
|
9314
|
+
try { meta = cur?.metadataJson ? JSON.parse(cur.metadataJson) : {}; } catch { meta = {}; }
|
|
9315
|
+
payload.metadataJson = JSON.stringify({ ...meta, ...args.limits });
|
|
9316
|
+
}
|
|
9298
9317
|
const result = await api('PUT', `/Pricing/catalog/${args.packageKey}`, payload);
|
|
9299
9318
|
return `✅ Package '${result.packageKey}' updated to v${result.version}.`;
|
|
9300
9319
|
}
|