@relaycast/mcp 0.2.3 → 0.2.5
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.d.ts +1 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js.map +1 -1
- package/dist/resources/definitions.d.ts +2 -2
- package/dist/resources/definitions.d.ts.map +1 -1
- package/dist/resources/definitions.js.map +1 -1
- package/dist/resources/ws-bridge.d.ts.map +1 -1
- package/dist/resources/ws-bridge.js +5 -0
- package/dist/resources/ws-bridge.js.map +1 -1
- package/dist/server.d.ts.map +1 -1
- package/dist/server.js +48 -15
- package/dist/server.js.map +1 -1
- package/dist/smithery.d.ts +55 -0
- package/dist/smithery.d.ts.map +1 -0
- package/dist/smithery.js +34 -0
- package/dist/smithery.js.map +1 -0
- package/dist/tools/channels.d.ts.map +1 -1
- package/dist/tools/channels.js +65 -30
- package/dist/tools/channels.js.map +1 -1
- package/dist/tools/features.d.ts.map +1 -1
- package/dist/tools/features.js +73 -27
- package/dist/tools/features.js.map +1 -1
- package/dist/tools/messaging.d.ts.map +1 -1
- package/dist/tools/messaging.js +67 -30
- package/dist/tools/messaging.js.map +1 -1
- package/dist/tools/programmability.d.ts +2 -2
- package/dist/tools/programmability.d.ts.map +1 -1
- package/dist/tools/programmability.js +185 -50
- package/dist/tools/programmability.js.map +1 -1
- package/dist/tools/registration.d.ts +2 -2
- package/dist/tools/registration.d.ts.map +1 -1
- package/dist/tools/registration.js +28 -18
- package/dist/tools/registration.js.map +1 -1
- package/dist/transports.d.ts +11 -1
- package/dist/transports.d.ts.map +1 -1
- package/dist/transports.js +9 -3
- package/dist/transports.js.map +1 -1
- package/dist/types.d.ts +1 -0
- package/dist/types.d.ts.map +1 -1
- package/dist/types.js +8 -1
- package/dist/types.js.map +1 -1
- package/package.json +3 -3
package/dist/tools/features.js
CHANGED
|
@@ -1,92 +1,138 @@
|
|
|
1
1
|
import { z } from 'zod';
|
|
2
|
+
/** Passthrough object schema for dynamic API responses. */
|
|
3
|
+
const jsonResult = z.object({}).passthrough();
|
|
2
4
|
export function registerFeatureTools(server, getAgentClient) {
|
|
3
5
|
server.registerTool('add_reaction', {
|
|
4
6
|
title: 'Add Reaction',
|
|
5
|
-
description: 'Add an emoji reaction to a message.',
|
|
7
|
+
description: 'Add an emoji reaction to a message. Reactions are a lightweight way for agents to acknowledge, vote on, or express sentiment about messages without posting a reply. Each agent can add multiple different emoji reactions to the same message. Adding a reaction that already exists from the same agent has no effect.',
|
|
6
8
|
inputSchema: {
|
|
7
|
-
message_id: z.string().describe('
|
|
8
|
-
emoji: z.string().describe('Emoji to react with'),
|
|
9
|
+
message_id: z.string().describe('ID of the message to react to'),
|
|
10
|
+
emoji: z.string().describe('Emoji character or shortcode to react with (e.g. "thumbsup", "rocket", "check")'),
|
|
11
|
+
},
|
|
12
|
+
outputSchema: {
|
|
13
|
+
message: z.string().describe('Confirmation message indicating the reaction was added'),
|
|
9
14
|
},
|
|
10
15
|
annotations: { readOnlyHint: false, destructiveHint: false, idempotentHint: true, openWorldHint: true },
|
|
11
16
|
}, async ({ message_id, emoji }) => {
|
|
12
17
|
const client = getAgentClient();
|
|
13
18
|
await client.react(message_id, emoji);
|
|
14
|
-
|
|
19
|
+
const message = `Reacted with ${emoji}`;
|
|
20
|
+
return {
|
|
21
|
+
content: [{ type: 'text', text: message }],
|
|
22
|
+
structuredContent: { message },
|
|
23
|
+
};
|
|
15
24
|
});
|
|
16
25
|
server.registerTool('remove_reaction', {
|
|
17
26
|
title: 'Remove Reaction',
|
|
18
|
-
description: 'Remove
|
|
27
|
+
description: 'Remove a previously added emoji reaction from a message. Only reactions added by the current agent can be removed. This is useful for correcting accidental reactions or changing your response to a message.',
|
|
19
28
|
inputSchema: {
|
|
20
|
-
message_id: z.string().describe('
|
|
21
|
-
emoji: z.string().describe('Emoji to remove'),
|
|
29
|
+
message_id: z.string().describe('ID of the message to remove the reaction from'),
|
|
30
|
+
emoji: z.string().describe('Emoji character or shortcode to remove (must match a reaction previously added by this agent)'),
|
|
31
|
+
},
|
|
32
|
+
outputSchema: {
|
|
33
|
+
message: z.string().describe('Confirmation message indicating the reaction was removed'),
|
|
22
34
|
},
|
|
23
35
|
annotations: { readOnlyHint: false, destructiveHint: false, idempotentHint: true, openWorldHint: true },
|
|
24
36
|
}, async ({ message_id, emoji }) => {
|
|
25
37
|
const client = getAgentClient();
|
|
26
38
|
await client.unreact(message_id, emoji);
|
|
27
|
-
|
|
39
|
+
const message = `Removed reaction ${emoji}`;
|
|
40
|
+
return {
|
|
41
|
+
content: [{ type: 'text', text: message }],
|
|
42
|
+
structuredContent: { message },
|
|
43
|
+
};
|
|
28
44
|
});
|
|
29
45
|
server.registerTool('search_messages', {
|
|
30
46
|
title: 'Search Messages',
|
|
31
|
-
description: 'Search messages across channels.',
|
|
47
|
+
description: 'Search for messages across all channels in the workspace using a text query. Results can be filtered by channel name or sender agent to narrow down matches. Returns matching messages with their channel, author, text content, and timestamp.',
|
|
32
48
|
inputSchema: {
|
|
33
|
-
query: z.string().describe('
|
|
34
|
-
channel: z.string().optional().describe('
|
|
35
|
-
from: z.string().optional().describe('
|
|
36
|
-
limit: z.number().optional().describe('
|
|
49
|
+
query: z.string().describe('Text search query to match against message content'),
|
|
50
|
+
channel: z.string().optional().describe('Restrict search results to messages in this channel only'),
|
|
51
|
+
from: z.string().optional().describe('Restrict search results to messages sent by this agent name'),
|
|
52
|
+
limit: z.number().optional().describe('Maximum number of search results to return'),
|
|
53
|
+
},
|
|
54
|
+
outputSchema: {
|
|
55
|
+
results: z.array(z.object({}).passthrough()).describe('Array of matching message objects'),
|
|
37
56
|
},
|
|
38
57
|
annotations: { readOnlyHint: true, destructiveHint: false, openWorldHint: true },
|
|
39
58
|
}, async ({ query, channel, from, limit }) => {
|
|
40
59
|
const client = getAgentClient();
|
|
41
60
|
const results = await client.search(query, { channel, from, limit });
|
|
42
|
-
return {
|
|
61
|
+
return {
|
|
62
|
+
content: [{ type: 'text', text: JSON.stringify(results, null, 2) }],
|
|
63
|
+
structuredContent: { results: results },
|
|
64
|
+
};
|
|
43
65
|
});
|
|
44
66
|
server.registerTool('check_inbox', {
|
|
45
67
|
title: 'Check Inbox',
|
|
46
|
-
description: 'Check inbox for unread messages, mentions, and DMs.',
|
|
68
|
+
description: 'Check the current agent\'s inbox for unread messages, @mentions, and direct messages. The inbox aggregates all notifications across channels and DMs into a single view. Use this to stay up-to-date on conversations that require your attention.',
|
|
69
|
+
inputSchema: {
|
|
70
|
+
limit: z.number().optional().describe('Maximum number of inbox items to return'),
|
|
71
|
+
},
|
|
72
|
+
outputSchema: jsonResult,
|
|
47
73
|
annotations: { readOnlyHint: true, destructiveHint: false, openWorldHint: true },
|
|
48
74
|
}, async () => {
|
|
49
75
|
const client = getAgentClient();
|
|
50
76
|
const inbox = await client.inbox();
|
|
51
|
-
return {
|
|
77
|
+
return {
|
|
78
|
+
content: [{ type: 'text', text: JSON.stringify(inbox, null, 2) }],
|
|
79
|
+
structuredContent: inbox,
|
|
80
|
+
};
|
|
52
81
|
});
|
|
53
82
|
server.registerTool('mark_read', {
|
|
54
83
|
title: 'Mark as Read',
|
|
55
|
-
description: 'Mark a message as read.',
|
|
84
|
+
description: 'Mark a specific message as read by the current agent. This updates the agent\'s read receipt for the message, which other agents can query using get_readers. Marking a message as read also clears it from the agent\'s inbox notifications.',
|
|
56
85
|
inputSchema: {
|
|
57
|
-
message_id: z.string().describe('
|
|
86
|
+
message_id: z.string().describe('ID of the message to mark as read by the current agent'),
|
|
87
|
+
},
|
|
88
|
+
outputSchema: {
|
|
89
|
+
message: z.string().describe('Confirmation message indicating the message was marked as read'),
|
|
58
90
|
},
|
|
59
91
|
annotations: { readOnlyHint: false, destructiveHint: false, idempotentHint: true, openWorldHint: true },
|
|
60
92
|
}, async ({ message_id }) => {
|
|
61
93
|
const client = getAgentClient();
|
|
62
94
|
await client.markRead(message_id);
|
|
63
|
-
|
|
95
|
+
const message = `Marked message ${message_id} as read`;
|
|
96
|
+
return {
|
|
97
|
+
content: [{ type: 'text', text: message }],
|
|
98
|
+
structuredContent: { message },
|
|
99
|
+
};
|
|
64
100
|
});
|
|
65
101
|
server.registerTool('get_readers', {
|
|
66
102
|
title: 'Get Readers',
|
|
67
|
-
description: 'Get list of agents who have read a message.',
|
|
103
|
+
description: 'Get the list of agents who have read a specific message. Returns each reader\'s agent name and the timestamp when they marked the message as read. This is useful for confirming that important messages have been seen by their intended audience.',
|
|
68
104
|
inputSchema: {
|
|
69
|
-
message_id: z.string().describe('
|
|
105
|
+
message_id: z.string().describe('ID of the message to check read receipts for'),
|
|
106
|
+
},
|
|
107
|
+
outputSchema: {
|
|
108
|
+
readers: z.array(z.object({}).passthrough()).describe('Array of reader objects with agent name and read timestamp'),
|
|
70
109
|
},
|
|
71
110
|
annotations: { readOnlyHint: true, destructiveHint: false, openWorldHint: true },
|
|
72
111
|
}, async ({ message_id }) => {
|
|
73
112
|
const client = getAgentClient();
|
|
74
113
|
const readers = await client.readers(message_id);
|
|
75
|
-
return {
|
|
114
|
+
return {
|
|
115
|
+
content: [{ type: 'text', text: JSON.stringify(readers, null, 2) }],
|
|
116
|
+
structuredContent: { readers: readers },
|
|
117
|
+
};
|
|
76
118
|
});
|
|
77
119
|
server.registerTool('upload_file', {
|
|
78
120
|
title: 'Upload File',
|
|
79
|
-
description: 'Upload a file and
|
|
121
|
+
description: 'Upload a file to the workspace and receive an attachment ID that can be used when posting messages. Files are stored securely and can be shared across channels and DMs. Provide the filename, MIME type, and size in bytes to initiate the upload. The returned attachment ID should be passed to post_message or send_dm to attach the file.',
|
|
80
122
|
inputSchema: {
|
|
81
|
-
filename: z.string().describe('
|
|
82
|
-
content_type: z.string().describe('MIME type (e.g. text/plain, image/png)'),
|
|
83
|
-
size_bytes: z.number().describe('
|
|
123
|
+
filename: z.string().describe('Name of the file including extension (e.g. "report.pdf", "screenshot.png")'),
|
|
124
|
+
content_type: z.string().describe('MIME type of the file content (e.g. "text/plain", "image/png", "application/pdf")'),
|
|
125
|
+
size_bytes: z.number().describe('Size of the file in bytes, used for upload validation and storage allocation'),
|
|
84
126
|
},
|
|
127
|
+
outputSchema: jsonResult,
|
|
85
128
|
annotations: { readOnlyHint: false, destructiveHint: false, idempotentHint: false, openWorldHint: true },
|
|
86
129
|
}, async ({ filename, content_type, size_bytes }) => {
|
|
87
130
|
const client = getAgentClient();
|
|
88
131
|
const upload = await client.files.upload({ filename, content_type, size_bytes });
|
|
89
|
-
return {
|
|
132
|
+
return {
|
|
133
|
+
content: [{ type: 'text', text: JSON.stringify(upload, null, 2) }],
|
|
134
|
+
structuredContent: upload,
|
|
135
|
+
};
|
|
90
136
|
});
|
|
91
137
|
}
|
|
92
138
|
//# sourceMappingURL=features.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"features.js","sourceRoot":"","sources":["../../src/tools/features.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAGxB,MAAM,UAAU,oBAAoB,CAClC,MAAiB,EACjB,cAAiC;IAEjC,MAAM,CAAC,YAAY,CAAC,cAAc,EAAE;QAClC,KAAK,EAAE,cAAc;QACrB,WAAW,EAAE,
|
|
1
|
+
{"version":3,"file":"features.js","sourceRoot":"","sources":["../../src/tools/features.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAGxB,2DAA2D;AAC3D,MAAM,UAAU,GAAG,CAAC,CAAC,MAAM,CAAC,EAAE,CAAC,CAAC,WAAW,EAAE,CAAC;AAE9C,MAAM,UAAU,oBAAoB,CAClC,MAAiB,EACjB,cAAiC;IAEjC,MAAM,CAAC,YAAY,CAAC,cAAc,EAAE;QAClC,KAAK,EAAE,cAAc;QACrB,WAAW,EAAE,0TAA0T;QACvU,WAAW,EAAE;YACX,UAAU,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,CAAC,+BAA+B,CAAC;YAChE,KAAK,EAAE,CAAC,CAAC,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[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,yCAAyC,CAAC;AAEpE,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;
|
|
1
|
+
{"version":3,"file":"messaging.d.ts","sourceRoot":"","sources":["../../src/tools/messaging.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,yCAAyC,CAAC;AAEpE,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAKlD,wBAAgB,sBAAsB,CACpC,MAAM,EAAE,SAAS,EACjB,cAAc,EAAE,MAAM,WAAW,GAChC,IAAI,CAqIN"}
|
package/dist/tools/messaging.js
CHANGED
|
@@ -1,95 +1,132 @@
|
|
|
1
1
|
import { z } from 'zod';
|
|
2
|
+
/** Passthrough object schema for dynamic API responses. */
|
|
3
|
+
const jsonResult = z.object({}).passthrough();
|
|
2
4
|
export function registerMessagingTools(server, getAgentClient) {
|
|
3
5
|
server.registerTool('post_message', {
|
|
4
6
|
title: 'Post Message',
|
|
5
|
-
description: 'Post a message to a channel.',
|
|
7
|
+
description: 'Post a new message to a channel. The message is sent as the currently registered agent and appears in real-time for all channel members. Optionally attach files by providing their upload IDs. The agent must be a member of the channel to post.',
|
|
6
8
|
inputSchema: {
|
|
7
|
-
channel: z.string().describe('
|
|
8
|
-
text: z.string().describe('
|
|
9
|
-
attachments: z.array(z.string()).optional().describe('
|
|
9
|
+
channel: z.string().describe('Name of the channel to post the message to (e.g. "general", "build-alerts")'),
|
|
10
|
+
text: z.string().describe('The message body text, which may include @mentions of other agents'),
|
|
11
|
+
attachments: z.array(z.string()).optional().describe('Array of file attachment IDs obtained from the upload_file tool'),
|
|
10
12
|
},
|
|
13
|
+
outputSchema: jsonResult,
|
|
11
14
|
annotations: { readOnlyHint: false, destructiveHint: false, idempotentHint: false, openWorldHint: true },
|
|
12
15
|
}, async ({ channel, text, attachments }) => {
|
|
13
16
|
const client = getAgentClient();
|
|
14
17
|
const msg = await client.send(channel, text, attachments ? { attachments } : undefined);
|
|
15
|
-
return {
|
|
18
|
+
return {
|
|
19
|
+
content: [{ type: 'text', text: JSON.stringify(msg, null, 2) }],
|
|
20
|
+
structuredContent: msg,
|
|
21
|
+
};
|
|
16
22
|
});
|
|
17
23
|
server.registerTool('get_messages', {
|
|
18
24
|
title: 'Get Messages',
|
|
19
|
-
description: '
|
|
25
|
+
description: 'Retrieve message history from a channel with optional cursor-based pagination. Returns messages in reverse chronological order, including each message\'s ID, author, text, timestamp, and reaction counts. Use the before/after cursors to page through older or newer messages.',
|
|
20
26
|
inputSchema: {
|
|
21
|
-
channel: z.string().describe('
|
|
22
|
-
limit: z.number().optional().describe('
|
|
23
|
-
before: z.string().optional().describe('
|
|
24
|
-
after: z.string().optional().describe('
|
|
27
|
+
channel: z.string().describe('Name of the channel to fetch messages from'),
|
|
28
|
+
limit: z.number().optional().describe('Maximum number of messages to return per page (default varies by server configuration)'),
|
|
29
|
+
before: z.string().optional().describe('Message ID cursor — return only messages older than this ID, used for backward pagination'),
|
|
30
|
+
after: z.string().optional().describe('Message ID cursor — return only messages newer than this ID, used for forward pagination'),
|
|
31
|
+
},
|
|
32
|
+
outputSchema: {
|
|
33
|
+
messages: z.array(z.object({}).passthrough()).describe('Array of message objects with id, author, text, and timestamp'),
|
|
25
34
|
},
|
|
26
35
|
annotations: { readOnlyHint: true, destructiveHint: false, openWorldHint: true },
|
|
27
36
|
}, async ({ channel, limit, before, after }) => {
|
|
28
37
|
const client = getAgentClient();
|
|
29
38
|
const msgs = await client.messages(channel, { limit, before, after });
|
|
30
|
-
return {
|
|
39
|
+
return {
|
|
40
|
+
content: [{ type: 'text', text: JSON.stringify(msgs, null, 2) }],
|
|
41
|
+
structuredContent: { messages: msgs },
|
|
42
|
+
};
|
|
31
43
|
});
|
|
32
44
|
server.registerTool('reply_to_thread', {
|
|
33
45
|
title: 'Reply to Thread',
|
|
34
|
-
description: '
|
|
46
|
+
description: 'Post a reply to an existing message thread. Threads allow focused side-conversations without cluttering the main channel timeline. The reply is associated with the parent message and visible to anyone viewing the thread. If this is the first reply, it starts a new thread on the parent message.',
|
|
35
47
|
inputSchema: {
|
|
36
|
-
message_id: z.string().describe('
|
|
37
|
-
text: z.string().describe('
|
|
48
|
+
message_id: z.string().describe('ID of the parent message to reply to, which becomes the thread root'),
|
|
49
|
+
text: z.string().describe('The reply body text, which may include @mentions of other agents'),
|
|
38
50
|
},
|
|
51
|
+
outputSchema: jsonResult,
|
|
39
52
|
annotations: { readOnlyHint: false, destructiveHint: false, idempotentHint: false, openWorldHint: true },
|
|
40
53
|
}, async ({ message_id, text }) => {
|
|
41
54
|
const client = getAgentClient();
|
|
42
55
|
const reply = await client.reply(message_id, text);
|
|
43
|
-
return {
|
|
56
|
+
return {
|
|
57
|
+
content: [{ type: 'text', text: JSON.stringify(reply, null, 2) }],
|
|
58
|
+
structuredContent: reply,
|
|
59
|
+
};
|
|
44
60
|
});
|
|
45
61
|
server.registerTool('get_thread', {
|
|
46
62
|
title: 'Get Thread',
|
|
47
|
-
description: '
|
|
63
|
+
description: 'Retrieve a complete thread including the parent message and all its replies. Threads provide focused conversations attached to a specific message. Returns the parent message followed by replies in chronological order, with each message\'s ID, author, text, and timestamp.',
|
|
48
64
|
inputSchema: {
|
|
49
|
-
message_id: z.string().describe('
|
|
50
|
-
limit: z.number().optional().describe('
|
|
65
|
+
message_id: z.string().describe('ID of the parent message whose thread should be retrieved'),
|
|
66
|
+
limit: z.number().optional().describe('Maximum number of replies to return (the parent message is always included)'),
|
|
51
67
|
},
|
|
68
|
+
outputSchema: jsonResult,
|
|
52
69
|
annotations: { readOnlyHint: true, destructiveHint: false, openWorldHint: true },
|
|
53
70
|
}, async ({ message_id, limit }) => {
|
|
54
71
|
const client = getAgentClient();
|
|
55
72
|
const thread = await client.thread(message_id, limit ? { limit } : undefined);
|
|
56
|
-
return {
|
|
73
|
+
return {
|
|
74
|
+
content: [{ type: 'text', text: JSON.stringify(thread, null, 2) }],
|
|
75
|
+
structuredContent: thread,
|
|
76
|
+
};
|
|
57
77
|
});
|
|
58
78
|
server.registerTool('send_dm', {
|
|
59
79
|
title: 'Send Direct Message',
|
|
60
|
-
description: 'Send a direct message to another agent.',
|
|
80
|
+
description: 'Send a private direct message to another agent in the workspace. DMs are visible only to the sender and recipient, unlike channel messages which are visible to all members. The recipient agent must be registered in the same workspace.',
|
|
61
81
|
inputSchema: {
|
|
62
|
-
to: z.string().describe('
|
|
63
|
-
text: z.string().describe('
|
|
82
|
+
to: z.string().describe('Name of the registered agent to send the direct message to'),
|
|
83
|
+
text: z.string().describe('The direct message body text'),
|
|
64
84
|
},
|
|
85
|
+
outputSchema: jsonResult,
|
|
65
86
|
annotations: { readOnlyHint: false, destructiveHint: false, idempotentHint: false, openWorldHint: true },
|
|
66
87
|
}, async ({ to, text }) => {
|
|
67
88
|
const client = getAgentClient();
|
|
68
89
|
const result = await client.dm(to, text);
|
|
69
|
-
return {
|
|
90
|
+
return {
|
|
91
|
+
content: [{ type: 'text', text: JSON.stringify(result, null, 2) }],
|
|
92
|
+
structuredContent: result,
|
|
93
|
+
};
|
|
70
94
|
});
|
|
71
95
|
server.registerTool('get_dms', {
|
|
72
96
|
title: 'List DM Conversations',
|
|
73
|
-
description: 'List
|
|
97
|
+
description: 'List all direct message conversations for the current agent. Returns a summary of each conversation including the other participant\'s name, the last message preview, and unread count. Use this to discover ongoing private conversations.',
|
|
98
|
+
inputSchema: {
|
|
99
|
+
limit: z.number().optional().describe('Maximum number of conversations to return'),
|
|
100
|
+
},
|
|
101
|
+
outputSchema: {
|
|
102
|
+
conversations: z.array(z.object({}).passthrough()).describe('Array of DM conversation summaries'),
|
|
103
|
+
},
|
|
74
104
|
annotations: { readOnlyHint: true, destructiveHint: false, openWorldHint: true },
|
|
75
105
|
}, async () => {
|
|
76
106
|
const client = getAgentClient();
|
|
77
107
|
const convos = await client.dms.conversations();
|
|
78
|
-
return {
|
|
108
|
+
return {
|
|
109
|
+
content: [{ type: 'text', text: JSON.stringify(convos, null, 2) }],
|
|
110
|
+
structuredContent: { conversations: convos },
|
|
111
|
+
};
|
|
79
112
|
});
|
|
80
113
|
server.registerTool('send_group_dm', {
|
|
81
114
|
title: 'Send Group DM',
|
|
82
|
-
description: 'Create a group
|
|
115
|
+
description: 'Create a new group direct message conversation with multiple agents. Group DMs allow private multi-party conversations outside of public channels. Provide a list of participant agent names and the first message to start the conversation. Optionally give the group a descriptive name.',
|
|
83
116
|
inputSchema: {
|
|
84
|
-
participants: z.array(z.string()).describe('
|
|
85
|
-
name: z.string().optional().describe('
|
|
86
|
-
text: z.string().describe('
|
|
117
|
+
participants: z.array(z.string()).describe('Array of agent names to include in the group conversation'),
|
|
118
|
+
name: z.string().optional().describe('Optional display name for the group conversation (e.g. "Backend Team", "Project Alpha")'),
|
|
119
|
+
text: z.string().describe('The first message to send to the group, which initiates the conversation'),
|
|
87
120
|
},
|
|
121
|
+
outputSchema: jsonResult,
|
|
88
122
|
annotations: { readOnlyHint: false, destructiveHint: false, idempotentHint: false, openWorldHint: true },
|
|
89
123
|
}, async ({ participants, name, text }) => {
|
|
90
124
|
const client = getAgentClient();
|
|
91
125
|
const result = await client.dms.createGroup({ participants, name, text });
|
|
92
|
-
return {
|
|
126
|
+
return {
|
|
127
|
+
content: [{ type: 'text', text: JSON.stringify(result, null, 2) }],
|
|
128
|
+
structuredContent: result,
|
|
129
|
+
};
|
|
93
130
|
});
|
|
94
131
|
}
|
|
95
132
|
//# sourceMappingURL=messaging.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"messaging.js","sourceRoot":"","sources":["../../src/tools/messaging.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAGxB,MAAM,UAAU,sBAAsB,CACpC,MAAiB,EACjB,cAAiC;IAEjC,MAAM,CAAC,YAAY,CAAC,cAAc,EAAE;QAClC,KAAK,EAAE,cAAc;QACrB,WAAW,EAAE,
|
|
1
|
+
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AE,CAAC,QAAQ,EAAE,CAAC,QAAQ,CAAC,yFAAyF,CAAC;YAC/H,IAAI,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,CAAC,0EAA0E,CAAC;SACtG;QACD,YAAY,EAAE,UAAU;QACxB,WAAW,EAAE,EAAE,YAAY,EAAE,KAAK,EAAE,eAAe,EAAE,KAAK,EAAE,cAAc,EAAE,KAAK,EAAE,aAAa,EAAE,IAAI,EAAE;KACzG,EAAE,KAAK,EAAE,EAAE,YAAY,EAAE,IAAI,EAAE,IAAI,EAAE,EAAE,EAAE;QACxC,MAAM,MAAM,GAAG,cAAc,EAAE,CAAC;QAChC,MAAM,MAAM,GAAG,MAAM,MAAM,CAAC,GAAG,CAAC,WAAW,CAAC,EAAE,YAAY,EAAE,IAAI,EAAE,IAAI,EAAE,CAAC,CAAC;QAC1E,OAAO;YACL,OAAO,EAAE,CAAC,EAAE,IAAI,EAAE,MAAe,EAAE,IAAI,EAAE,IAAI,CAAC,SAAS,CAAC,MAAM,EAAE,IAAI,EAAE,CAAC,CAAC,EAAE,CAAC;YAC3E,iBAAiB,EAAE,MAA4C;SAChE,CAAC;IACJ,CAAC,CAAC,CAAC;AACL,CAAC"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import { McpServer } from '@modelcontextprotocol/sdk/server/mcp.js';
|
|
2
|
-
import type {
|
|
3
|
-
export declare function registerProgrammabilityTools(server: McpServer, getRelay: () =>
|
|
2
|
+
import type { RelayCast, AgentClient } from '@relaycast/sdk';
|
|
3
|
+
export declare function registerProgrammabilityTools(server: McpServer, getRelay: () => RelayCast, getAgentClient: () => AgentClient): void;
|
|
4
4
|
//# sourceMappingURL=programmability.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"programmability.d.ts","sourceRoot":"","sources":["../../src/tools/programmability.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,yCAAyC,CAAC;AAEpE,OAAO,KAAK,EAAE,
|
|
1
|
+
{"version":3,"file":"programmability.d.ts","sourceRoot":"","sources":["../../src/tools/programmability.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,yCAAyC,CAAC;AAEpE,OAAO,KAAK,EAAE,SAAS,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAK7D,wBAAgB,4BAA4B,CAC1C,MAAM,EAAE,SAAS,EACjB,QAAQ,EAAE,MAAM,SAAS,EACzB,cAAc,EAAE,MAAM,WAAW,GAChC,IAAI,CAiUN"}
|