@chirpie/mcp 1.0.8 → 1.0.10
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 +134 -3
- package/package.json +21 -3
package/dist/index.js
CHANGED
|
@@ -27,9 +27,10 @@ function formatError(err) {
|
|
|
27
27
|
isError: true
|
|
28
28
|
};
|
|
29
29
|
}
|
|
30
|
+
var SERVER_VERSION = true ? "1.0.10" : "dev";
|
|
30
31
|
var server = new McpServer({
|
|
31
32
|
name: "chirpie",
|
|
32
|
-
version:
|
|
33
|
+
version: SERVER_VERSION
|
|
33
34
|
});
|
|
34
35
|
server.tool(
|
|
35
36
|
"chirpie_post",
|
|
@@ -37,7 +38,7 @@ server.tool(
|
|
|
37
38
|
{
|
|
38
39
|
account_id: z.string().describe("Account ID to post from (X, Bluesky, LinkedIn, Threads, Mastodon, Instagram, Facebook, Telegram, Reddit, Pinterest, TikTok, YouTube, Google Business Profile, or Snapchat)"),
|
|
39
40
|
text: z.string().max(63206).describe("Post text (max 280 chars for standard X, 25,000 for X Premium, 300 for Bluesky, 3,000 for LinkedIn, 500 for Threads, 500 for Mastodon, 2,200 for Instagram, 63,206 for Facebook, 4,096 for Telegram, 40,000 for Reddit, 500 for Pinterest, 2,200 for TikTok, 5,000 for YouTube, 1,500 for Google Business Profile, 160 for Snapchat)"),
|
|
40
|
-
media_urls: z.array(z.string()).max(10).optional().describe("Public image URLs. X supports images + video (max 4); Bluesky supports images only (~1MB each, max 4); LinkedIn supports images (JPEG, PNG, GIF up to 8MB each, max 4). Threads supports one image per post
|
|
41
|
+
media_urls: z.array(z.string()).max(10).optional().describe("Public image URLs. X supports images + video (max 4); Bluesky supports images only (~1MB each, max 4); LinkedIn supports images (JPEG, PNG, GIF up to 8MB each, max 4). Threads supports one image per post. Mastodon supports images + video (max 4). Instagram REQUIRES at least 1 image (max 10 for carousel). Facebook supports images (max 4). Telegram supports images + video. Reddit supports images (max 1). Pinterest REQUIRES 1 image. TikTok REQUIRES video or photo. YouTube REQUIRES video. Google Business Profile supports images (max 1). Snapchat REQUIRES media (image or video)."),
|
|
41
42
|
schedule_at: z.string().optional().describe("ISO 8601 datetime to schedule the post")
|
|
42
43
|
},
|
|
43
44
|
async ({ account_id, text, media_urls, schedule_at }) => {
|
|
@@ -56,7 +57,7 @@ server.tool(
|
|
|
56
57
|
account_id: z.string().describe("Account ID to post from (X, Bluesky, LinkedIn, Threads, Mastodon, Instagram, Facebook, Telegram, Reddit, Pinterest, TikTok, YouTube, Google Business Profile, or Snapchat). Some platforms degrade to standalone posts."),
|
|
57
58
|
posts: z.array(z.object({
|
|
58
59
|
text: z.string().max(63206).describe("Post text (max 280 chars for standard X, 25,000 for X Premium, 300 for Bluesky, 3,000 for LinkedIn, 500 for Threads, 500 for Mastodon, 2,200 for Instagram, 63,206 for Facebook, 4,096 for Telegram, 40,000 for Reddit, 500 for Pinterest, 2,200 for TikTok, 5,000 for YouTube, 1,500 for Google Business Profile, 160 for Snapchat)"),
|
|
59
|
-
media_urls: z.array(z.string()).max(10).optional().describe("Public image URLs (Bluesky: images only, ~1MB each, max 4; X: images + video, max 4; LinkedIn: images up to 8MB each, max 4; Threads:
|
|
60
|
+
media_urls: z.array(z.string()).max(10).optional().describe("Public image URLs (Bluesky: images only, ~1MB each, max 4; X: images + video, max 4; LinkedIn: images up to 8MB each, max 4; Threads: 1 image per post; Mastodon: images + video, max 4; Instagram: requires images, max 10; Facebook: images, max 4; Telegram: images + video; Reddit: 1 image; Pinterest: requires 1 image; TikTok: requires video/photo; YouTube: requires video; Google Business Profile: 1 image; Snapchat: requires media)")
|
|
60
61
|
})).min(2).max(25).describe("Array of posts in the thread"),
|
|
61
62
|
schedule_at: z.string().optional().describe("ISO 8601 datetime to schedule")
|
|
62
63
|
},
|
|
@@ -144,6 +145,136 @@ server.tool(
|
|
|
144
145
|
}
|
|
145
146
|
}
|
|
146
147
|
);
|
|
148
|
+
server.tool(
|
|
149
|
+
"chirpie_create_key",
|
|
150
|
+
"Create a new Chirpie API key. Returns the full key once \u2014 store it securely. Keys are prefixed `chirpie_sk_` and never re-shown by the API.",
|
|
151
|
+
{
|
|
152
|
+
name: z.string().optional().describe("Friendly name for the key (default: 'Default')")
|
|
153
|
+
},
|
|
154
|
+
async ({ name }) => {
|
|
155
|
+
try {
|
|
156
|
+
const result = await requireClient().createKey(name);
|
|
157
|
+
return formatResult(result);
|
|
158
|
+
} catch (err) {
|
|
159
|
+
return formatError(err);
|
|
160
|
+
}
|
|
161
|
+
}
|
|
162
|
+
);
|
|
163
|
+
server.tool(
|
|
164
|
+
"chirpie_list_keys",
|
|
165
|
+
"List the user's Chirpie API keys (prefix + metadata; the full key is only shown on creation).",
|
|
166
|
+
{},
|
|
167
|
+
async () => {
|
|
168
|
+
try {
|
|
169
|
+
const result = await requireClient().listKeys();
|
|
170
|
+
return formatResult(result);
|
|
171
|
+
} catch (err) {
|
|
172
|
+
return formatError(err);
|
|
173
|
+
}
|
|
174
|
+
}
|
|
175
|
+
);
|
|
176
|
+
server.tool(
|
|
177
|
+
"chirpie_revoke_key",
|
|
178
|
+
"Revoke a Chirpie API key by its ID. Revocation is permanent and immediate.",
|
|
179
|
+
{
|
|
180
|
+
id: z.string().describe("API key ID to revoke")
|
|
181
|
+
},
|
|
182
|
+
async ({ id }) => {
|
|
183
|
+
try {
|
|
184
|
+
const result = await requireClient().revokeKey(id);
|
|
185
|
+
return formatResult(result);
|
|
186
|
+
} catch (err) {
|
|
187
|
+
return formatError(err);
|
|
188
|
+
}
|
|
189
|
+
}
|
|
190
|
+
);
|
|
191
|
+
var oauthConnectTools = [
|
|
192
|
+
{ name: "chirpie_connect_x", label: "X/Twitter", method: "connectXAccount" },
|
|
193
|
+
{ name: "chirpie_connect_linkedin", label: "LinkedIn", method: "connectLinkedInAccount" },
|
|
194
|
+
{ name: "chirpie_connect_threads", label: "Threads", method: "connectThreadsAccount" },
|
|
195
|
+
{ name: "chirpie_connect_instagram", label: "Instagram", method: "connectInstagramAccount" },
|
|
196
|
+
{ name: "chirpie_connect_facebook", label: "Facebook Pages", method: "connectFacebookAccount" }
|
|
197
|
+
// { name: "chirpie_connect_reddit", label: "Reddit", method: "connectRedditAccount" },
|
|
198
|
+
// { name: "chirpie_connect_pinterest", label: "Pinterest", method: "connectPinterestAccount" },
|
|
199
|
+
// { name: "chirpie_connect_tiktok", label: "TikTok", method: "connectTikTokAccount" },
|
|
200
|
+
// { name: "chirpie_connect_youtube", label: "YouTube", method: "connectYouTubeAccount" },
|
|
201
|
+
// { name: "chirpie_connect_google_business", label: "Google Business Profile", method: "connectGBPAccount" },
|
|
202
|
+
// { name: "chirpie_connect_snapchat", label: "Snapchat", method: "connectSnapchatAccount" },
|
|
203
|
+
];
|
|
204
|
+
for (const { name, label, method } of oauthConnectTools) {
|
|
205
|
+
server.tool(
|
|
206
|
+
name,
|
|
207
|
+
`Start the OAuth flow for a ${label} account. Returns an authorization_url the user must open in a browser to complete the connection.`,
|
|
208
|
+
{},
|
|
209
|
+
async () => {
|
|
210
|
+
try {
|
|
211
|
+
const fn = requireClient()[method];
|
|
212
|
+
const result = await fn.call(requireClient());
|
|
213
|
+
return formatResult(result);
|
|
214
|
+
} catch (err) {
|
|
215
|
+
return formatError(err);
|
|
216
|
+
}
|
|
217
|
+
}
|
|
218
|
+
);
|
|
219
|
+
}
|
|
220
|
+
server.tool(
|
|
221
|
+
"chirpie_connect_bluesky",
|
|
222
|
+
"Connect a Bluesky account using an app password (create one at https://bsky.app/settings/app-passwords).",
|
|
223
|
+
{
|
|
224
|
+
identifier: z.string().describe("Bluesky handle (e.g. user.bsky.social)"),
|
|
225
|
+
app_password: z.string().describe("Bluesky app password")
|
|
226
|
+
},
|
|
227
|
+
async ({ identifier, app_password }) => {
|
|
228
|
+
try {
|
|
229
|
+
const result = await requireClient().connectBlueskyAccount({
|
|
230
|
+
platform: "bluesky",
|
|
231
|
+
identifier,
|
|
232
|
+
app_password
|
|
233
|
+
});
|
|
234
|
+
return formatResult(result);
|
|
235
|
+
} catch (err) {
|
|
236
|
+
return formatError(err);
|
|
237
|
+
}
|
|
238
|
+
}
|
|
239
|
+
);
|
|
240
|
+
server.tool(
|
|
241
|
+
"chirpie_connect_mastodon",
|
|
242
|
+
"Start the OAuth flow for a Mastodon account on a specific instance.",
|
|
243
|
+
{
|
|
244
|
+
instance_url: z.string().describe("Mastodon instance URL (e.g. https://mastodon.social)")
|
|
245
|
+
},
|
|
246
|
+
async ({ instance_url }) => {
|
|
247
|
+
try {
|
|
248
|
+
const result = await requireClient().connectMastodonAccount({
|
|
249
|
+
platform: "mastodon",
|
|
250
|
+
instance_url
|
|
251
|
+
});
|
|
252
|
+
return formatResult(result);
|
|
253
|
+
} catch (err) {
|
|
254
|
+
return formatError(err);
|
|
255
|
+
}
|
|
256
|
+
}
|
|
257
|
+
);
|
|
258
|
+
server.tool(
|
|
259
|
+
"chirpie_connect_telegram",
|
|
260
|
+
"Connect a Telegram bot. Create a bot with @BotFather on Telegram, then pass the bot token and the chat ID (user, group, or channel).",
|
|
261
|
+
{
|
|
262
|
+
bot_token: z.string().describe("Bot token from @BotFather"),
|
|
263
|
+
chat_id: z.string().describe("Target chat ID (user, group, or channel)")
|
|
264
|
+
},
|
|
265
|
+
async ({ bot_token, chat_id }) => {
|
|
266
|
+
try {
|
|
267
|
+
const result = await requireClient().connectTelegramAccount({
|
|
268
|
+
platform: "telegram",
|
|
269
|
+
bot_token,
|
|
270
|
+
chat_id
|
|
271
|
+
});
|
|
272
|
+
return formatResult(result);
|
|
273
|
+
} catch (err) {
|
|
274
|
+
return formatError(err);
|
|
275
|
+
}
|
|
276
|
+
}
|
|
277
|
+
);
|
|
147
278
|
var transport = new StdioServerTransport();
|
|
148
279
|
server.connect(transport).catch((err) => {
|
|
149
280
|
console.error("Failed to start Chirpie MCP server:", err);
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@chirpie/mcp",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.10",
|
|
4
4
|
"description": "Chirpie MCP server — social media tools for AI agents",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -25,13 +25,31 @@
|
|
|
25
25
|
"keywords": [
|
|
26
26
|
"chirpie",
|
|
27
27
|
"mcp",
|
|
28
|
+
"model-context-protocol",
|
|
28
29
|
"ai",
|
|
30
|
+
"claude",
|
|
31
|
+
"cursor",
|
|
32
|
+
"agent",
|
|
29
33
|
"social-media",
|
|
30
|
-
"
|
|
34
|
+
"x",
|
|
35
|
+
"twitter",
|
|
36
|
+
"bluesky",
|
|
37
|
+
"linkedin",
|
|
38
|
+
"threads",
|
|
39
|
+
"mastodon",
|
|
40
|
+
"instagram",
|
|
41
|
+
"facebook",
|
|
42
|
+
"telegram",
|
|
43
|
+
"reddit",
|
|
44
|
+
"pinterest",
|
|
45
|
+
"tiktok",
|
|
46
|
+
"youtube",
|
|
47
|
+
"google-business",
|
|
48
|
+
"snapchat"
|
|
31
49
|
],
|
|
32
50
|
"license": "MIT",
|
|
33
51
|
"dependencies": {
|
|
34
|
-
"@chirpie/sdk": "^1.0.
|
|
52
|
+
"@chirpie/sdk": "^1.0.10",
|
|
35
53
|
"@modelcontextprotocol/sdk": "^1",
|
|
36
54
|
"zod": "^3.24.4"
|
|
37
55
|
},
|