@flowrelay/mcp-server 1.0.0 → 1.0.1
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/README.md +1 -1
- package/dist/api.d.ts +7 -1
- package/dist/api.js +2 -2
- package/dist/index.js +15 -5
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -29,7 +29,7 @@ The server currently exposes these tools:
|
|
|
29
29
|
- list_events
|
|
30
30
|
- list_untracked_resources (lists event-producing resources not scoped to any project – useful for discovering untracked activity)
|
|
31
31
|
- discord_list_channels
|
|
32
|
-
- discord_send_message
|
|
32
|
+
- discord_send_message (plain text, or a handoff/insight by id or `last_*` rendered to Markdown and attached as a `.md` file)
|
|
33
33
|
|
|
34
34
|
## Environment Variables
|
|
35
35
|
|
package/dist/api.d.ts
CHANGED
|
@@ -180,7 +180,13 @@ export declare class FlowRelayAPI {
|
|
|
180
180
|
topic: string;
|
|
181
181
|
}>;
|
|
182
182
|
}>;
|
|
183
|
-
discordSendMessage(channelId: string,
|
|
183
|
+
discordSendMessage(channelId: string, payload: {
|
|
184
|
+
content?: string;
|
|
185
|
+
handoff_id?: string;
|
|
186
|
+
insight_id?: string;
|
|
187
|
+
artifact?: 'last_handoff' | 'last_correlation' | 'last_onboarding' | 'last_architecture';
|
|
188
|
+
project_id?: string;
|
|
189
|
+
}): Promise<{
|
|
184
190
|
ok: boolean;
|
|
185
191
|
message_id: string;
|
|
186
192
|
}>;
|
package/dist/api.js
CHANGED
|
@@ -109,10 +109,10 @@ export class FlowRelayAPI {
|
|
|
109
109
|
async discordListChannels() {
|
|
110
110
|
return this.request('/discord/channels');
|
|
111
111
|
}
|
|
112
|
-
async discordSendMessage(channelId,
|
|
112
|
+
async discordSendMessage(channelId, payload) {
|
|
113
113
|
return this.request('/discord/send', {
|
|
114
114
|
method: 'POST',
|
|
115
|
-
body: JSON.stringify({ channel_id: channelId,
|
|
115
|
+
body: JSON.stringify({ channel_id: channelId, ...payload }),
|
|
116
116
|
});
|
|
117
117
|
}
|
|
118
118
|
async listUntrackedResources() {
|
package/dist/index.js
CHANGED
|
@@ -326,12 +326,22 @@ server.tool('discord_list_channels', 'List text channels in your connected Disco
|
|
|
326
326
|
}
|
|
327
327
|
});
|
|
328
328
|
// ── Tool: discord send message ──────────────────────────────────────
|
|
329
|
-
server.tool('discord_send_message', 'Send
|
|
330
|
-
channel_id: z.string().describe('The Discord channel ID to send
|
|
331
|
-
content: z.string().describe('
|
|
332
|
-
|
|
329
|
+
server.tool('discord_send_message', 'Send to a Discord channel in your connected server. Provide exactly one of: content (inline text); handoff_id or insight_id (sends that artifact, rendered to Markdown, as a .md file attachment); or artifact (last_handoff / last_correlation / last_onboarding / last_architecture, with project_id) to send the latest active artifact of that kind.', {
|
|
330
|
+
channel_id: z.string().describe('The Discord channel ID to send to'),
|
|
331
|
+
content: z.string().optional().describe('Inline message text. Mutually exclusive with handoff_id / insight_id / artifact'),
|
|
332
|
+
handoff_id: z.string().optional().describe('UUID of a handoff to render and attach as a .md file'),
|
|
333
|
+
insight_id: z.string().optional().describe('UUID of an insight to render and attach as a .md file'),
|
|
334
|
+
artifact: z
|
|
335
|
+
.enum(['last_handoff', 'last_correlation', 'last_onboarding', 'last_architecture'])
|
|
336
|
+
.optional()
|
|
337
|
+
.describe('Send the latest active artifact of this kind. Requires project_id'),
|
|
338
|
+
project_id: z.string().optional().describe('Project UUID. Required only when artifact is set'),
|
|
339
|
+
}, async ({ channel_id, content, handoff_id, insight_id, artifact, project_id, }) => {
|
|
340
|
+
if (!content && !handoff_id && !insight_id && !artifact) {
|
|
341
|
+
return { content: [{ type: 'text', text: 'Provide content, handoff_id, insight_id, or artifact.' }] };
|
|
342
|
+
}
|
|
333
343
|
try {
|
|
334
|
-
const result = await api.discordSendMessage(channel_id, content);
|
|
344
|
+
const result = await api.discordSendMessage(channel_id, { content, handoff_id, insight_id, artifact, project_id });
|
|
335
345
|
return { content: [{ type: 'text', text: `Message sent (ID: ${result.message_id})` }] };
|
|
336
346
|
}
|
|
337
347
|
catch (err) {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@flowrelay/mcp-server",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.1",
|
|
4
4
|
"description": "Flow Relay MCP Server for Claude Desktop and Claude Code – handoffs, integrations, and context events via natural conversation.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"license": "MIT",
|