@aithr-ai/mcp-server 1.0.3 → 1.0.4
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/index.js +5 -5
- package/package.json +1 -1
package/index.js
CHANGED
|
@@ -1146,12 +1146,12 @@ class MCPServer {
|
|
|
1146
1146
|
};
|
|
1147
1147
|
|
|
1148
1148
|
try {
|
|
1149
|
-
const result = await this.
|
|
1150
|
-
`/
|
|
1149
|
+
const result = await this.mcpApiCall(
|
|
1150
|
+
`/mcp/projects/${projectId}/canvas/nodes`,
|
|
1151
1151
|
'POST',
|
|
1152
1152
|
nodeData
|
|
1153
1153
|
);
|
|
1154
|
-
return { success: true, nodeId: result.id, message: `Added ${agentType} agent`, node: result };
|
|
1154
|
+
return { success: true, nodeId: result.nodeId || result.node?.id, message: `Added ${agentType} agent`, node: result.node };
|
|
1155
1155
|
} catch (e) {
|
|
1156
1156
|
// Check if it's a tier restriction
|
|
1157
1157
|
if (e.message.includes('403') || e.message.includes('Pro tier')) {
|
|
@@ -1170,8 +1170,8 @@ class MCPServer {
|
|
|
1170
1170
|
const projectId = config.projectId;
|
|
1171
1171
|
|
|
1172
1172
|
try {
|
|
1173
|
-
await this.
|
|
1174
|
-
`/
|
|
1173
|
+
await this.mcpApiCall(
|
|
1174
|
+
`/mcp/projects/${projectId}/canvas/nodes/${nodeId}`,
|
|
1175
1175
|
'DELETE'
|
|
1176
1176
|
);
|
|
1177
1177
|
return { success: true, message: `Removed node ${nodeId}` };
|