@exileum/meta-mcp 5.0.0 → 7.0.0

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.
Files changed (86) hide show
  1. package/README.md +83 -12
  2. package/dist/config.d.ts +10 -8
  3. package/dist/config.d.ts.map +1 -1
  4. package/dist/config.js +65 -8
  5. package/dist/config.js.map +1 -1
  6. package/dist/index.d.ts.map +1 -1
  7. package/dist/index.js +11 -59
  8. package/dist/index.js.map +1 -1
  9. package/dist/register-all.d.ts +4 -0
  10. package/dist/register-all.d.ts.map +1 -0
  11. package/dist/register-all.js +41 -0
  12. package/dist/register-all.js.map +1 -0
  13. package/dist/resources/instagram.d.ts.map +1 -1
  14. package/dist/resources/instagram.js +18 -12
  15. package/dist/resources/instagram.js.map +1 -1
  16. package/dist/resources/threads.d.ts.map +1 -1
  17. package/dist/resources/threads.js +18 -12
  18. package/dist/resources/threads.js.map +1 -1
  19. package/dist/schemas.d.ts +14 -0
  20. package/dist/schemas.d.ts.map +1 -1
  21. package/dist/schemas.js +14 -0
  22. package/dist/schemas.js.map +1 -1
  23. package/dist/services/meta-client.d.ts +101 -5
  24. package/dist/services/meta-client.d.ts.map +1 -1
  25. package/dist/services/meta-client.js +273 -69
  26. package/dist/services/meta-client.js.map +1 -1
  27. package/dist/tools/annotations.d.ts +6 -0
  28. package/dist/tools/annotations.d.ts.map +1 -0
  29. package/dist/tools/annotations.js +27 -0
  30. package/dist/tools/annotations.js.map +1 -0
  31. package/dist/tools/instagram/comments.d.ts.map +1 -1
  32. package/dist/tools/instagram/comments.js +64 -33
  33. package/dist/tools/instagram/comments.js.map +1 -1
  34. package/dist/tools/instagram/hashtags.d.ts.map +1 -1
  35. package/dist/tools/instagram/hashtags.js +37 -18
  36. package/dist/tools/instagram/hashtags.js.map +1 -1
  37. package/dist/tools/instagram/media.d.ts.map +1 -1
  38. package/dist/tools/instagram/media.js +47 -24
  39. package/dist/tools/instagram/media.js.map +1 -1
  40. package/dist/tools/instagram/mentions.d.ts.map +1 -1
  41. package/dist/tools/instagram/mentions.js +21 -10
  42. package/dist/tools/instagram/mentions.js.map +1 -1
  43. package/dist/tools/instagram/messaging.d.ts.map +1 -1
  44. package/dist/tools/instagram/messaging.js +64 -27
  45. package/dist/tools/instagram/messaging.js.map +1 -1
  46. package/dist/tools/instagram/profile.d.ts.map +1 -1
  47. package/dist/tools/instagram/profile.js +54 -31
  48. package/dist/tools/instagram/profile.js.map +1 -1
  49. package/dist/tools/instagram/publishing.d.ts.map +1 -1
  50. package/dist/tools/instagram/publishing.js +83 -57
  51. package/dist/tools/instagram/publishing.js.map +1 -1
  52. package/dist/tools/meta/auth.d.ts.map +1 -1
  53. package/dist/tools/meta/auth.js +47 -21
  54. package/dist/tools/meta/auth.js.map +1 -1
  55. package/dist/tools/threads/insights.d.ts.map +1 -1
  56. package/dist/tools/threads/insights.js +21 -10
  57. package/dist/tools/threads/insights.js.map +1 -1
  58. package/dist/tools/threads/media.d.ts.map +1 -1
  59. package/dist/tools/threads/media.js +38 -23
  60. package/dist/tools/threads/media.js.map +1 -1
  61. package/dist/tools/threads/mentions.d.ts.map +1 -1
  62. package/dist/tools/threads/mentions.js +12 -6
  63. package/dist/tools/threads/mentions.js.map +1 -1
  64. package/dist/tools/threads/profile.d.ts.map +1 -1
  65. package/dist/tools/threads/profile.js +8 -2
  66. package/dist/tools/threads/profile.js.map +1 -1
  67. package/dist/tools/threads/publishing.d.ts +7 -0
  68. package/dist/tools/threads/publishing.d.ts.map +1 -1
  69. package/dist/tools/threads/publishing.js +168 -76
  70. package/dist/tools/threads/publishing.js.map +1 -1
  71. package/dist/tools/threads/replies.d.ts.map +1 -1
  72. package/dist/tools/threads/replies.js +48 -27
  73. package/dist/tools/threads/replies.js.map +1 -1
  74. package/dist/utils/container.d.ts +4 -2
  75. package/dist/utils/container.d.ts.map +1 -1
  76. package/dist/utils/container.js +8 -3
  77. package/dist/utils/container.js.map +1 -1
  78. package/dist/utils/errors.d.ts +2 -0
  79. package/dist/utils/errors.d.ts.map +1 -1
  80. package/dist/utils/errors.js +27 -10
  81. package/dist/utils/errors.js.map +1 -1
  82. package/dist/utils/response.d.ts +11 -0
  83. package/dist/utils/response.d.ts.map +1 -0
  84. package/dist/utils/response.js +6 -0
  85. package/dist/utils/response.js.map +1 -0
  86. package/package.json +10 -1
package/README.md CHANGED
@@ -64,11 +64,15 @@ npm run build
64
64
  | Variable | Required | Description |
65
65
  |----------|----------|-------------|
66
66
  | `INSTAGRAM_ACCESS_TOKEN` | For Instagram | Instagram Graph API access token |
67
- | `INSTAGRAM_USER_ID` | For Instagram | Instagram Business/Creator account ID |
67
+ | `INSTAGRAM_USER_ID` | For Instagram | Instagram Business/Creator account ID (numeric string, or `"me"` for the authenticated user) |
68
68
  | `THREADS_ACCESS_TOKEN` | For Threads | Threads API access token |
69
- | `THREADS_USER_ID` | For Threads | Threads user ID |
70
- | `META_APP_ID` | For token/webhook tools | Meta App ID |
69
+ | `THREADS_USER_ID` | For Threads | Threads user ID (numeric string, or `"me"` for the authenticated user) |
70
+ | `META_APP_ID` | For token/webhook tools | Meta App ID (numeric string) |
71
71
  | `META_APP_SECRET` | For token/webhook tools | Meta App Secret |
72
+ | `META_API_VERSION` | Optional | Meta Graph API version for Instagram and Facebook endpoints — defaults to `v25.0` (verified 2026-05-06). Override only when Meta deprecates a version before meta-mcp ships a new release. Format: `vMAJOR.MINOR` (e.g., `v26.0`); malformed values fall back to the default with a stderr warning. OAuth token endpoints are unversioned and unaffected by this setting |
73
+ | `THREADS_API_VERSION` | Optional | Threads API version — defaults to `v1.0` (verified 2026-05-06). Threads runs a separate single-major-version track and is not bumped in lockstep with the Graph API. Same `vMAJOR.MINOR` format and fallback behavior as `META_API_VERSION` |
74
+
75
+ The server validates these at startup. Malformed values for `INSTAGRAM_USER_ID`, `THREADS_USER_ID`, or `META_APP_ID` cause the process to exit with `Invalid meta-mcp configuration: …`. Setting only one half of a credential pair (e.g., `INSTAGRAM_ACCESS_TOKEN` without `INSTAGRAM_USER_ID`) prints a stderr warning and continues; related tool invocations still fail at call time.
72
76
 
73
77
  ## Account Requirements
74
78
 
@@ -86,7 +90,8 @@ npm run build
86
90
  - **Meta**: Token exchange/refresh/debug, webhook management
87
91
  - **2 resources**: Instagram profile, Threads profile
88
92
  - **2 prompts**: Cross-platform content publishing, analytics report
89
- - Rate limit tracking via `x-app-usage` header
93
+ - Rate limit tracking via `x-app-usage` header — and **automatic client-side throttling** at 80% (1s slowdown) / 90% (5s backoff) so a burst of tool calls stays under Meta's per-app quota
94
+ - **Automatic retry** for transient Meta API failures (HTTP `429`/`500`/`502`/`503`/`504`, network errors, `fetch` timeouts) with exponential backoff and `Retry-After` honoring; tunable via `MetaClient`'s `maxRetries` option (default 3, set to 0 to disable)
90
95
  - **Structured error responses** with `error_type` (`auth`, `validation`, `rate_limit`, `server`, `network`, `internal`), HTTP status, Meta API code/subcode/type, and a `remediation` hint where actionable — see [`CHANGELOG.md`](./CHANGELOG.md) for the JSON shape
91
96
 
92
97
  ## Tools
@@ -143,7 +148,7 @@ npm run build
143
148
  | `ig_get_account_insights` | Get account-level analytics (views, reach, follower_count). Optional `metric_type` (`total_value` or `time_series`) controls aggregation shape |
144
149
  | `ig_business_discovery` | Look up another business account |
145
150
  | `ig_get_collaboration_invites` | Get pending collaboration invites |
146
- | `ig_respond_collaboration_invite` | Accept or decline collaboration invites |
151
+ | `ig_respond_collaboration_invite` | Accept/decline a collaboration invite by media_id |
147
152
 
148
153
  ### Instagram — Hashtags (4)
149
154
 
@@ -167,21 +172,22 @@ npm run build
167
172
  |------|-------------|
168
173
  | `ig_get_conversations` | List DM conversations |
169
174
  | `ig_get_messages` | Get messages in a conversation |
170
- | `ig_send_message` | Send a DM |
175
+ | `ig_send_message` | Send a DM (optional `messaging_type` = `RESPONSE`/`UPDATE`/`MESSAGE_TAG` and `tag` = `HUMAN_AGENT` for the 7-day human-agent window) |
171
176
  | `ig_get_message` | Get message details |
172
177
 
173
- ### Threads — Publishing (8)
178
+ ### Threads — Publishing (9)
174
179
 
175
180
  | Tool | Description |
176
181
  |------|-------------|
177
- | `threads_publish_text` | Publish a text post in a single API call (`auto_publish_text=true`, default; set `auto_publish=false` for the legacy two-step flow). Supports polls, GIFs, link attachments, topic tags, quote posts, spoiler flag, cross-share to IG Stories, geo-gating via `allowlisted_country_codes`, text attachments up to 10K chars with styling |
178
- | `threads_publish_image` | Publish an image post (supports alt_text, topic tags, spoiler flag, cross-share to IG Stories, geo-gating via `allowlisted_country_codes`) |
179
- | `threads_publish_video` | Publish a video post (supports alt_text, topic tags, spoiler flag, cross-share to IG Stories, geo-gating via `allowlisted_country_codes`) |
180
- | `threads_publish_carousel` | Publish a carousel (2-20 items, supports alt_text per item, cross-share to IG Stories, geo-gating via `allowlisted_country_codes` on the parent container) |
182
+ | `threads_publish_text` | Publish a text post in a single API call (`auto_publish_text=true`, default; set `auto_publish=false` for the legacy two-step flow). Supports polls, GIFs, link attachments, topic tags, quote posts, spoiler flag, cross-share to IG Stories, geo-gating via `allowlisted_country_codes`, location tagging via `location_id`, text attachments up to 10K chars with styling |
183
+ | `threads_publish_image` | Publish an image post (supports alt_text, topic tags, spoiler flag, cross-share to IG Stories, geo-gating via `allowlisted_country_codes`, location tagging via `location_id`) |
184
+ | `threads_publish_video` | Publish a video post (supports alt_text, topic tags, spoiler flag, cross-share to IG Stories, geo-gating via `allowlisted_country_codes`, location tagging via `location_id`) |
185
+ | `threads_publish_carousel` | Publish a carousel (2-20 items, supports alt_text per item, cross-share to IG Stories, geo-gating via `allowlisted_country_codes` and location tagging via `location_id` on the parent container) |
181
186
  | `threads_delete_post` | Delete a post (max 100/day) |
182
187
  | `threads_get_container_status` | Check container processing status (unpublished containers only) |
183
188
  | `threads_get_publishing_limit` | Check remaining publishing quota (250 posts/day) |
184
189
  | `threads_repost` | Repost an existing thread to your profile (requires `threads_content_publish`) |
190
+ | `threads_search_locations` | Search Threads-supported locations by query (`q`) or coordinates (`latitude`+`longitude`) to obtain a `location_id` for the four `threads_publish_*` tools (requires `threads_location_tagging` permission) |
185
191
 
186
192
  ### Threads — Media & Search (3)
187
193
 
@@ -282,7 +288,7 @@ Your **`META_APP_ID`** and **`META_APP_SECRET`** are in **App Settings -> Basic*
282
288
  https://threads.net/oauth/authorize
283
289
  ?client_id=YOUR_APP_ID
284
290
  &redirect_uri=YOUR_REDIRECT_URI
285
- &scope=threads_basic,threads_content_publish,threads_manage_insights,threads_manage_replies,threads_read_replies,threads_share_to_instagram,threads_manage_mentions
291
+ &scope=threads_basic,threads_content_publish,threads_manage_insights,threads_manage_replies,threads_read_replies,threads_share_to_instagram,threads_manage_mentions,threads_keyword_search
286
292
  &response_type=code
287
293
  ```
288
294
  For local testing, use `https://localhost/` as redirect URI (configure in App Settings -> Threads API -> Redirect URIs).
@@ -329,10 +335,75 @@ Access tokens expire after ~60 days. Refresh before expiration (token must be at
329
335
 
330
336
  Check token status anytime with `meta_debug_token`.
331
337
 
338
+ ## Troubleshooting
339
+
340
+ Tool failures return `isError: true` with a JSON body in `content[0].text` matching the envelope documented in [`CHANGELOG.md`](./CHANGELOG.md): `{ error: true, error_type, http_status, code, subcode, type, message, remediation, fbtrace_id, raw }`. The fastest path to a fix is to read `error_type` and the Meta API `code`, then jump to the matching subsection below. The full code reference is the [Meta Graph API error handling guide](https://developers.facebook.com/docs/graph-api/guides/error-handling/).
341
+
342
+ ### `error_type: "auth"` — expired, revoked, or under-scoped token
343
+
344
+ Triggered by Meta API codes `190`, `10`, `102`, HTTP `401`, or `type: "OAuthException"`. Common messages:
345
+
346
+ - `Error validating access token: Session has expired` — long-lived tokens expire ~60 days after issue.
347
+ - `Application does not have permission for this action` — the token is missing a scope, or the account is not eligible (e.g., a **Personal** Instagram account on Graph API endpoints).
348
+
349
+ What to do:
350
+
351
+ 1. Run `meta_debug_token` to inspect `expires_at`, `is_valid`, and `scopes`.
352
+ 2. If the token is **not yet expired** but at least 24h old, refresh in place with `meta_refresh_token` (`platform: "instagram"` or `"threads"`) — this extends the lifetime by another ~60 days. If the token is **already expired**, the refresh endpoint will reject it; regenerate a short-lived token from the Meta App dashboard and exchange it via `meta_exchange_token` (or run a full re-authorization for Threads).
353
+ 3. If scopes are missing, regenerate the token with the required permissions:
354
+ - **Instagram**: `instagram_business_basic` (always required) plus `instagram_business_content_publish`, `instagram_business_manage_comments`, `instagram_business_manage_messages` per feature.
355
+ - **Threads**: `threads_basic`, `threads_content_publish`, `threads_manage_insights`, `threads_manage_replies`, `threads_read_replies`, `threads_share_to_instagram`, `threads_manage_mentions`, `threads_keyword_search` per feature.
356
+ 4. If your Instagram account is **Personal**, switch to **Business** or **Creator** for free in the Instagram app (Settings → Account type and tools → Switch to professional account). The Graph API rejects Personal accounts.
357
+
358
+ ### `error_type: "rate_limit"` — application or user quota exhausted
359
+
360
+ Triggered by Meta API codes `4`, `17`, `32`, `341`, `613`, the business-use-case range `80001`–`80008`, or HTTP `429`. Includes any `OAuthException` with code `4` / `17` (these are surfaced as `error_type: "rate_limit"`, **not** `"auth"`, despite the type field). `MetaClient` automatically retries HTTP `429` up to 3 times with exponential backoff and honors any `Retry-After` header — a `rate_limit` error reaching the caller means the retry budget was exhausted.
361
+
362
+ What to do:
363
+
364
+ 1. Inspect the `_rateLimit` field on prior successful tool responses. `callCount`, `totalCpuTime`, and `totalTime` come from Meta's `x-app-usage` header; when any approaches `100` you are near the per-app threshold.
365
+ 2. meta-mcp already self-throttles once `max(callCount, totalCpuTime, totalTime)` crosses 80% (1s slowdown) or 90% (5s backoff) — see the `[meta-mcp] x-app-usage at N%…` lines on stderr. If you are still hitting `rate_limit` errors despite that, reduce request volume further and cache profile metadata between calls.
366
+ 3. Threads has hard daily quotas (250 publishes, 100 deletes) — query the remaining quota with `threads_get_publishing_limit` before bulk operations.
367
+
368
+ ### `error_type: "validation"` — bad parameter, wrong ID, or unsupported field
369
+
370
+ Triggered by Meta API codes `100`, `200`, `803`, or any unmapped 4xx HTTP status. Common pitfalls:
371
+
372
+ - **Wrong user ID format** — `INSTAGRAM_USER_ID` and `THREADS_USER_ID` must be the **numeric ID** returned by `GET /me?fields=user_id` (Instagram) or `GET /me?fields=id` (Threads), or the literal `"me"` for the authenticated user. The Instagram **username** is not accepted.
373
+ - **`(#100) Messaging is not supported`** on `ig_send_message` / `ig_get_conversations` / `ig_get_messages` — the account does not have the messaging API enabled. Grant `instagram_business_manage_messages` on your token and ensure DMs are enabled in the Instagram app (Settings → Privacy → Messages).
374
+ - **Deprecated publish endpoint** — `ig_publish_video` was retired by Meta on Nov 9, 2023; use `ig_publish_reel` for video posts. `ig_publish_story` is required for Stories.
375
+ - **Mutually exclusive Threads attachments** — a `threads_publish_text` post can carry only one of `text_attachment`, `poll_options`, `link_attachment`, or `gif_attachment`; combining them is rejected at the schema level.
376
+ - **Unsupported `metric` / `fields` for the resource** — see the per-tool Meta docs (`ig_get_media_insights` lists per-`media_type` valid metrics in its description).
377
+
378
+ ### Other categories
379
+
380
+ - `error_type: "server"` (codes `1`, `2`, HTTP 5xx) — transient Meta outage. `MetaClient` already retried `500`/`502`/`503`/`504` up to 3 times with exponential backoff before surfacing this; check [metastatus.com](https://metastatus.com/) if it persists.
381
+ - `error_type: "network"` — `fetch` timed out or failed before reaching Meta. `MetaClient` already retried thrown network errors up to 3 times; verify outbound connectivity if the error keeps reappearing.
382
+ - `error_type: "internal"` — unexpected condition that did not map to a Meta error code. The `raw` field carries the sanitized original message; `access_token`, `client_secret`, and `input_token` values are scrubbed to `***` before reporting.
383
+
384
+ ## API Stability
385
+
386
+ meta-mcp is consumed as an **MCP server runtime**, not as a library. The supported entry points are:
387
+
388
+ - `npx @exileum/meta-mcp` (recommended for end users)
389
+ - `node dist/index.js` (manual installation)
390
+
391
+ The single programmatic export from the package root, `createSandboxServer(): McpServer`, exists for the [Smithery](https://smithery.ai) sandbox runner and is the only stable JavaScript/TypeScript API.
392
+
393
+ **`zod` and other transitive runtime dependencies are internal** and not part of meta-mcp's public API. No `zod` symbols, types, or schemas flow through `dist/index.d.ts`, so `zod`'s version may change in any release — including major version bumps — without a corresponding meta-mcp major bump.
394
+
395
+ **`@modelcontextprotocol/sdk` is the one exception**: `McpServer` (the return type of `createSandboxServer()`) is imported from that package, so a breaking change to `McpServer`'s public interface would also be a breaking change for meta-mcp's programmatic API. In practice the MCP SDK follows semver, so consumers can treat `@modelcontextprotocol/sdk` as an implicit peer dependency of the `createSandboxServer` export.
396
+
397
+ Only the package root (`@exileum/meta-mcp`) is a supported import target. Deep imports into the published `dist/` tree (e.g. `@exileum/meta-mcp/dist/schemas.js`) are blocked by the `package.json` `exports` map for any spec-compliant resolver and are **not** part of the public API; they may be renamed, removed, or restructured in any release.
398
+
332
399
  ## Glama
333
400
 
334
401
  [![meta-mcp MCP server](https://glama.ai/mcp/servers/exileum/meta-mcp/badges/card.svg)](https://glama.ai/mcp/servers/exileum/meta-mcp)
335
402
 
403
+ ## Contributing
404
+
405
+ Contributions are welcome. See [CONTRIBUTING.md](CONTRIBUTING.md) for the dev setup, project layout, the tool-registration recipe, testing, commit conventions, the CHANGELOG flow, and the CI gates. Bug reports and feature requests use the [issue templates](.github/ISSUE_TEMPLATE); pull requests use the [PR template](.github/PULL_REQUEST_TEMPLATE.md).
406
+
336
407
  ## License
337
408
 
338
409
  [MIT](LICENSE)
package/dist/config.d.ts CHANGED
@@ -1,10 +1,12 @@
1
- export interface MetaConfig {
2
- appId: string;
3
- appSecret: string;
4
- instagramAccessToken: string;
5
- instagramUserId: string;
6
- threadsAccessToken: string;
7
- threadsUserId: string;
8
- }
1
+ import { z } from "zod";
2
+ export declare const MetaConfigSchema: z.ZodObject<{
3
+ appId: z.ZodDefault<z.ZodString>;
4
+ appSecret: z.ZodDefault<z.ZodString>;
5
+ instagramAccessToken: z.ZodDefault<z.ZodString>;
6
+ instagramUserId: z.ZodDefault<z.ZodString>;
7
+ threadsAccessToken: z.ZodDefault<z.ZodString>;
8
+ threadsUserId: z.ZodDefault<z.ZodString>;
9
+ }, z.core.$strip>;
10
+ export type MetaConfig = z.infer<typeof MetaConfigSchema>;
9
11
  export declare function loadConfig(): MetaConfig;
10
12
  //# sourceMappingURL=config.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"config.d.ts","sourceRoot":"","sources":["../src/config.ts"],"names":[],"mappings":"AAAA,MAAM,WAAW,UAAU;IACzB,KAAK,EAAE,MAAM,CAAC;IACd,SAAS,EAAE,MAAM,CAAC;IAClB,oBAAoB,EAAE,MAAM,CAAC;IAC7B,eAAe,EAAE,MAAM,CAAC;IACxB,kBAAkB,EAAE,MAAM,CAAC;IAC3B,aAAa,EAAE,MAAM,CAAC;CACvB;AAED,wBAAgB,UAAU,IAAI,UAAU,CASvC"}
1
+ {"version":3,"file":"config.d.ts","sourceRoot":"","sources":["../src/config.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAsBxB,eAAO,MAAM,gBAAgB;;;;;;;iBAO3B,CAAC;AAEH,MAAM,MAAM,UAAU,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,gBAAgB,CAAC,CAAC;AAE1D,wBAAgB,UAAU,IAAI,UAAU,CAiBvC"}
package/dist/config.js CHANGED
@@ -1,11 +1,68 @@
1
+ import { z } from "zod";
2
+ // Regex `*` (zero-or-more) is intentional so the Zod `.default("")` for unset
3
+ // vars passes validation; an empty string is treated as "absent" by warning
4
+ // logic and by the lazy "X is not configured" runtime checks in MetaClient.
5
+ const appIdSchema = z
6
+ .string()
7
+ .regex(/^\d*$/, "META_APP_ID must be a numeric string")
8
+ .default("");
9
+ // User IDs accept either a numeric string or the literal "me" — Meta's
10
+ // Graph/Threads APIs accept "me" as the authenticated-user alias on
11
+ // `/{user-id}/...` paths (e.g., GET https://graph.threads.net/v1.0/me).
12
+ const userIdSchema = (envName) => z
13
+ .string()
14
+ .regex(/^(me|\d*)$/, `${envName} must be a numeric string or "me"`)
15
+ .default("");
16
+ export const MetaConfigSchema = z.object({
17
+ appId: appIdSchema,
18
+ appSecret: z.string().default(""),
19
+ instagramAccessToken: z.string().default(""),
20
+ instagramUserId: userIdSchema("INSTAGRAM_USER_ID"),
21
+ threadsAccessToken: z.string().default(""),
22
+ threadsUserId: userIdSchema("THREADS_USER_ID"),
23
+ });
1
24
  export function loadConfig() {
2
- return {
3
- appId: process.env.META_APP_ID || "",
4
- appSecret: process.env.META_APP_SECRET || "",
5
- instagramAccessToken: process.env.INSTAGRAM_ACCESS_TOKEN || "",
6
- instagramUserId: process.env.INSTAGRAM_USER_ID || "",
7
- threadsAccessToken: process.env.THREADS_ACCESS_TOKEN || "",
8
- threadsUserId: process.env.THREADS_USER_ID || "",
9
- };
25
+ const result = MetaConfigSchema.safeParse({
26
+ appId: process.env.META_APP_ID,
27
+ appSecret: process.env.META_APP_SECRET,
28
+ instagramAccessToken: process.env.INSTAGRAM_ACCESS_TOKEN,
29
+ instagramUserId: process.env.INSTAGRAM_USER_ID,
30
+ threadsAccessToken: process.env.THREADS_ACCESS_TOKEN,
31
+ threadsUserId: process.env.THREADS_USER_ID,
32
+ });
33
+ if (!result.success) {
34
+ const issues = result.error.issues.map((i) => ` - ${i.message}`).join("\n");
35
+ throw new Error(`Invalid meta-mcp configuration:\n${issues}`);
36
+ }
37
+ warnIfMisconfigured(result.data);
38
+ return result.data;
39
+ }
40
+ function warnIfMisconfigured(config) {
41
+ const noCredentials = Object.values(config).every((v) => !v);
42
+ if (noCredentials) {
43
+ console.error("[meta-mcp] Warning: no credentials configured — every tool invocation will fail until you set INSTAGRAM_ACCESS_TOKEN, THREADS_ACCESS_TOKEN, or META_APP_ID/META_APP_SECRET.");
44
+ }
45
+ const pairs = [
46
+ [
47
+ !!config.instagramAccessToken,
48
+ !!config.instagramUserId,
49
+ "INSTAGRAM_ACCESS_TOKEN",
50
+ "INSTAGRAM_USER_ID",
51
+ ],
52
+ [
53
+ !!config.threadsAccessToken,
54
+ !!config.threadsUserId,
55
+ "THREADS_ACCESS_TOKEN",
56
+ "THREADS_USER_ID",
57
+ ],
58
+ [!!config.appId, !!config.appSecret, "META_APP_ID", "META_APP_SECRET"],
59
+ ];
60
+ for (const [hasA, hasB, aName, bName] of pairs) {
61
+ if (hasA === hasB)
62
+ continue;
63
+ const setName = hasA ? aName : bName;
64
+ const missingName = hasA ? bName : aName;
65
+ console.error(`[meta-mcp] Warning: ${setName} is set but ${missingName} is missing — related tools will fail at invocation time.`);
66
+ }
10
67
  }
11
68
  //# sourceMappingURL=config.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"config.js","sourceRoot":"","sources":["../src/config.ts"],"names":[],"mappings":"AASA,MAAM,UAAU,UAAU;IACxB,OAAO;QACL,KAAK,EAAE,OAAO,CAAC,GAAG,CAAC,WAAW,IAAI,EAAE;QACpC,SAAS,EAAE,OAAO,CAAC,GAAG,CAAC,eAAe,IAAI,EAAE;QAC5C,oBAAoB,EAAE,OAAO,CAAC,GAAG,CAAC,sBAAsB,IAAI,EAAE;QAC9D,eAAe,EAAE,OAAO,CAAC,GAAG,CAAC,iBAAiB,IAAI,EAAE;QACpD,kBAAkB,EAAE,OAAO,CAAC,GAAG,CAAC,oBAAoB,IAAI,EAAE;QAC1D,aAAa,EAAE,OAAO,CAAC,GAAG,CAAC,eAAe,IAAI,EAAE;KACjD,CAAC;AACJ,CAAC"}
1
+ {"version":3,"file":"config.js","sourceRoot":"","sources":["../src/config.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,8EAA8E;AAC9E,4EAA4E;AAC5E,4EAA4E;AAC5E,MAAM,WAAW,GAAG,CAAC;KAClB,MAAM,EAAE;KACR,KAAK,CAAC,OAAO,EAAE,sCAAsC,CAAC;KACtD,OAAO,CAAC,EAAE,CAAC,CAAC;AAEf,uEAAuE;AACvE,oEAAoE;AACpE,wEAAwE;AACxE,MAAM,YAAY,GAAG,CAAC,OAAe,EAAE,EAAE,CACvC,CAAC;KACE,MAAM,EAAE;KACR,KAAK,CACJ,YAAY,EACZ,GAAG,OAAO,mCAAm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
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";AAGA,OAAO,EAAE,SAAS,EAAE,MAAM,yCAAyC,CAAC;AAqCpE,wBAAgB,mBAAmB,cAmBlC"}
package/dist/index.js CHANGED
@@ -4,55 +4,23 @@ import { McpServer } from "@modelcontextprotocol/sdk/server/mcp.js";
4
4
  import { StdioServerTransport } from "@modelcontextprotocol/sdk/server/stdio.js";
5
5
  import { loadConfig } from "./config.js";
6
6
  import { MetaClient } from "./services/meta-client.js";
7
- // Meta platform tools
8
- import { registerMetaAuthTools } from "./tools/meta/auth.js";
9
- // Instagram tools
10
- import { registerIgPublishingTools } from "./tools/instagram/publishing.js";
11
- import { registerIgMediaTools } from "./tools/instagram/media.js";
12
- import { registerIgCommentTools } from "./tools/instagram/comments.js";
13
- import { registerIgProfileTools } from "./tools/instagram/profile.js";
14
- import { registerIgHashtagTools } from "./tools/instagram/hashtags.js";
15
- import { registerIgMentionTools } from "./tools/instagram/mentions.js";
16
- import { registerIgMessagingTools } from "./tools/instagram/messaging.js";
17
- // Threads tools
18
- import { registerThreadsPublishingTools } from "./tools/threads/publishing.js";
19
- import { registerThreadsMediaTools } from "./tools/threads/media.js";
20
- import { registerThreadsReplyTools } from "./tools/threads/replies.js";
21
- import { registerThreadsProfileTools } from "./tools/threads/profile.js";
22
- import { registerThreadsInsightTools } from "./tools/threads/insights.js";
23
- import { registerThreadsMentionsTools } from "./tools/threads/mentions.js";
24
- // Resources & Prompts
25
- import { registerInstagramResources } from "./resources/instagram.js";
26
- import { registerThreadsResources } from "./resources/threads.js";
27
- import { registerPrompts } from "./prompts/index.js";
7
+ import { registerAll } from "./register-all.js";
28
8
  const require = createRequire(import.meta.url);
29
9
  const { version: SERVER_VERSION } = require("../package.json");
30
10
  const server = new McpServer({
31
11
  name: "meta-mcp",
32
12
  version: SERVER_VERSION,
33
13
  });
34
- const config = loadConfig();
14
+ let config;
15
+ try {
16
+ config = loadConfig();
17
+ }
18
+ catch (err) {
19
+ console.error(err instanceof Error ? err.message : String(err));
20
+ process.exit(1);
21
+ }
35
22
  const client = new MetaClient(config);
36
- // Register tools
37
- registerMetaAuthTools(server, client);
38
- registerIgPublishingTools(server, client);
39
- registerIgMediaTools(server, client);
40
- registerIgCommentTools(server, client);
41
- registerIgProfileTools(server, client);
42
- registerIgHashtagTools(server, client);
43
- registerIgMentionTools(server, client);
44
- registerIgMessagingTools(server, client);
45
- registerThreadsPublishingTools(server, client);
46
- registerThreadsMediaTools(server, client);
47
- registerThreadsReplyTools(server, client);
48
- registerThreadsProfileTools(server, client);
49
- registerThreadsInsightTools(server, client);
50
- registerThreadsMentionsTools(server, client);
51
- // Register resources
52
- registerInstagramResources(server, client);
53
- registerThreadsResources(server, client);
54
- // Register prompts
55
- registerPrompts(server);
23
+ registerAll(server, client);
56
24
  async function main() {
57
25
  const transport = new StdioServerTransport();
58
26
  await server.connect(transport);
@@ -76,23 +44,7 @@ export function createSandboxServer() {
76
44
  threadsUserId: "",
77
45
  };
78
46
  const mockClient = new MetaClient(mockConfig);
79
- registerMetaAuthTools(sandbox, mockClient);
80
- registerIgPublishingTools(sandbox, mockClient);
81
- registerIgMediaTools(sandbox, mockClient);
82
- registerIgCommentTools(sandbox, mockClient);
83
- registerIgProfileTools(sandbox, mockClient);
84
- registerIgHashtagTools(sandbox, mockClient);
85
- registerIgMentionTools(sandbox, mockClient);
86
- registerIgMessagingTools(sandbox, mockClient);
87
- registerThreadsPublishingTools(sandbox, mockClient);
88
- registerThreadsMediaTools(sandbox, mockClient);
89
- registerThreadsReplyTools(sandbox, mockClient);
90
- registerThreadsProfileTools(sandbox, mockClient);
91
- registerThreadsInsightTools(sandbox, mockClient);
92
- registerThreadsMentionsTools(sandbox, mockClient);
93
- registerInstagramResources(sandbox, mockClient);
94
- registerThreadsResources(sandbox, mockClient);
95
- registerPrompts(sandbox);
47
+ registerAll(sandbox, mockClient);
96
48
  return sandbox;
97
49
  }
98
50
  //# sourceMappingURL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js";
2
+ import { MetaClient } from "./services/meta-client.js";
3
+ export declare function registerAll(server: McpServer, client: MetaClient): void;
4
+ //# sourceMappingURL=register-all.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"register-all.d.ts","sourceRoot":"","sources":["../src/register-all.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,yCAAyC,CAAC;AACpE,OAAO,EAAE,UAAU,EAAE,MAAM,2BAA2B,CAAC;AA2BvD,wBAAgB,WAAW,CAAC,MAAM,EAAE,SAAS,EAAE,MAAM,EAAE,UAAU,GAAG,IAAI,CAkBvE"}
@@ -0,0 +1,41 @@
1
+ // Meta platform tools
2
+ import { registerMetaAuthTools } from "./tools/meta/auth.js";
3
+ // Instagram tools
4
+ import { registerIgPublishingTools } from "./tools/instagram/publishing.js";
5
+ import { registerIgMediaTools } from "./tools/instagram/media.js";
6
+ import { registerIgCommentTools } from "./tools/instagram/comments.js";
7
+ import { registerIgProfileTools } from "./tools/instagram/profile.js";
8
+ import { registerIgHashtagTools } from "./tools/instagram/hashtags.js";
9
+ import { registerIgMentionTools } from "./tools/instagram/mentions.js";
10
+ import { registerIgMessagingTools } from "./tools/instagram/messaging.js";
11
+ // Threads tools
12
+ import { registerThreadsPublishingTools } from "./tools/threads/publishing.js";
13
+ import { registerThreadsMediaTools } from "./tools/threads/media.js";
14
+ import { registerThreadsReplyTools } from "./tools/threads/replies.js";
15
+ import { registerThreadsProfileTools } from "./tools/threads/profile.js";
16
+ import { registerThreadsInsightTools } from "./tools/threads/insights.js";
17
+ import { registerThreadsMentionsTools } from "./tools/threads/mentions.js";
18
+ // Resources & Prompts
19
+ import { registerInstagramResources } from "./resources/instagram.js";
20
+ import { registerThreadsResources } from "./resources/threads.js";
21
+ import { registerPrompts } from "./prompts/index.js";
22
+ export function registerAll(server, client) {
23
+ registerMetaAuthTools(server, client);
24
+ registerIgPublishingTools(server, client);
25
+ registerIgMediaTools(server, client);
26
+ registerIgCommentTools(server, client);
27
+ registerIgProfileTools(server, client);
28
+ registerIgHashtagTools(server, client);
29
+ registerIgMentionTools(server, client);
30
+ registerIgMessagingTools(server, client);
31
+ registerThreadsPublishingTools(server, client);
32
+ registerThreadsMediaTools(server, client);
33
+ registerThreadsReplyTools(server, client);
34
+ registerThreadsProfileTools(server, client);
35
+ registerThreadsInsightTools(server, client);
36
+ registerThreadsMentionsTools(server, client);
37
+ registerInstagramResources(server, client);
38
+ registerThreadsResources(server, client);
39
+ registerPrompts(server);
40
+ }
41
+ //# sourceMappingURL=register-all.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"register-all.js","sourceRoot":"","sources":["../src/register-all.ts"],"names":[],"mappings":"AAGA,sBAAsB;AACtB,OAAO,EAAE,qBAAqB,EAAE,MAAM,sBAAsB,CAAC;AAE7D,kBAAkB;AAClB,OAAO,EAAE,yBAAyB,EAAE,MAAM,iCAAiC,CAAC;AAC5E,OAAO,EAAE,oBAAoB,EAAE,MAAM,4BAA4B,CAAC;AAClE,OAAO,EAAE,sBAAsB,EAAE,MAAM,+BAA+B,CAAC;AACvE,OAAO,EAAE,sBAAsB,EAAE,MAAM,8BAA8B,CAAC;AACtE,OAAO,EAAE,sBAAsB,EAAE,MAAM,+BAA+B,CAAC;AACvE,OAAO,EAAE,sBAAsB,EAAE,MAAM,+BAA+B,CAAC;AACvE,OAAO,EAAE,wBAAwB,EAAE,MAAM,gCAAgC,CAAC;AAE1E,gBAAgB;AAChB,OAAO,EAAE,8BAA8B,EAAE,MAAM,+BAA+B,CAAC;AAC/E,OAAO,EAAE,yBAAyB,EAAE,MAAM,0BAA0B,CAAC;AACrE,OAAO,EAAE,yBAAyB,EAAE,MAAM,4BAA4B,CAAC;AACvE,OAAO,EAAE,2BAA2B,EAAE,MAAM,4BAA4B,CAAC;AACzE,OAAO,EAAE,2BAA2B,EAAE,MAAM,6BAA6B,CAAC;AAC1E,OAAO,EAAE,4BAA4B,EAAE,MAAM,6BAA6B,CAAC;AAE3E,sBAAsB;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E,UAAU,EAAE,MAAM,4BAA4B,CAAC;AAExD,wBAAgB,0BAA0B,CAAC,MAAM,EAAE,SAAS,EAAE,MAAM,EAAE,UAAU,QAoB/E"}
1
+ {"version":3,"file":"instagram.d.ts","sourceRoot":"","sources":["../../src/resources/instagram.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,yCAAyC,CAAC;AACpE,OAAO,EAAE,UAAU,EAAE,MAAM,4BAA4B,CAAC;AAGxD,wBAAgB,0BAA0B,CAAC,MAAM,EAAE,SAAS,EAAE,MAAM,EAAE,UAAU,QAwB/E"}
@@ -1,17 +1,23 @@
1
+ import { toMcpResourceError } from "../utils/errors.js";
1
2
  export function registerInstagramResources(server, client) {
2
3
  server.resource("instagram-profile", "meta-mcp://instagram/profile", { description: "Instagram Business/Creator account profile information", mimeType: "application/json" }, async () => {
3
- const { data } = await client.ig("GET", `/${client.igUserId}`, {
4
- fields: "id,name,username,biography,followers_count,follows_count,media_count,profile_picture_url,website",
5
- });
6
- return {
7
- contents: [
8
- {
9
- uri: "meta-mcp://instagram/profile",
10
- mimeType: "application/json",
11
- text: JSON.stringify(data, null, 2),
12
- },
13
- ],
14
- };
4
+ try {
5
+ const { data } = await client.ig("GET", `/${client.igUserId}`, {
6
+ fields: "id,name,username,biography,followers_count,follows_count,media_count,profile_picture_url,website",
7
+ });
8
+ return {
9
+ contents: [
10
+ {
11
+ uri: "meta-mcp://instagram/profile",
12
+ mimeType: "application/json",
13
+ text: JSON.stringify(data, null, 2),
14
+ },
15
+ ],
16
+ };
17
+ }
18
+ catch (error) {
19
+ throw toMcpResourceError(error, "Get Instagram profile");
20
+ }
15
21
  });
16
22
  }
17
23
  //# sourceMappingURL=instagram.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"instagram.js","sourceRoot":"","sources":["../../src/resources/instagram.ts"],"names":[],"mappings":"AAGA,MAAM,UAAU,0BAA0B,CAAC,MAAiB,EAAE,MAAkB;IAC9E,MAAM,CAAC,QAA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AAO,KAAK,EAAE,CAAC;YACf,MAAM,kBAAkB,CAAC,KAAK,EAAE,uBAAuB,CAAC,CAAC;QAC3D,CAAC;IACH,CAAC,CACF,CAAC;AACJ,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"threads.d.ts","sourceRoot":"","sources":["../../src/resources/threads.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,yCAAyC,CAAC;AACpE,OAAO,EAAE,UAAU,EAAE,MAAM,4BAA4B,CAAC;AAExD,wBAAgB,wBAAwB,CAAC,MAAM,EAAE,SAAS,EAAE,MAAM,EAAE,UAAU,QAoB7E"}
1
+ {"version":3,"file":"threads.d.ts","sourceRoot":"","sources":["../../src/resources/threads.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,yCAAyC,CAAC;AACpE,OAAO,EAAE,UAAU,EAAE,MAAM,4BAA4B,CAAC;AAGxD,wBAAgB,wBAAwB,CAAC,MAAM,EAAE,SAAS,EAAE,MAAM,EAAE,UAAU,QAwB7E"}
@@ -1,17 +1,23 @@
1
+ import { toMcpResourceError } from "../utils/errors.js";
1
2
  export function registerThreadsResources(server, client) {
2
3
  server.resource("threads-profile", "meta-mcp://threads/profile", { description: "Threads user profile information", mimeType: "application/json" }, async () => {
3
- const { data } = await client.threads("GET", `/${client.threadsUserId}`, {
4
- fields: "id,username,name,threads_profile_picture_url,threads_biography,is_verified",
5
- });
6
- return {
7
- contents: [
8
- {
9
- uri: "meta-mcp://threads/profile",
10
- mimeType: "application/json",
11
- text: JSON.stringify(data, null, 2),
12
- },
13
- ],
14
- };
4
+ try {
5
+ const { data } = await client.threads("GET", `/${client.threadsUserId}`, {
6
+ fields: "id,username,name,threads_profile_picture_url,threads_biography,is_verified",
7
+ });
8
+ return {
9
+ contents: [
10
+ {
11
+ uri: "meta-mcp://threads/profile",
12
+ mimeType: "application/json",
13
+ text: JSON.stringify(data, null, 2),
14
+ },
15
+ ],
16
+ };
17
+ }
18
+ catch (error) {
19
+ throw toMcpResourceError(error, "Get Threads profile");
20
+ }
15
21
  });
16
22
  }
17
23
  //# sourceMappingURL=threads.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"threads.js","sourceRoot":"","sources":["../../src/resources/threads.ts"],"names":[],"mappings":"AAGA,MAAM,UAAU,wBAAwB,CAAC,MAAiB,EAAE,MAAkB;IAC5E,MAAM,CAAC,QAAQ,CACb,iBAAiB,EACjB,4BAA4B,EAC5B,EAAE,WAAW,EAAE,kCAAkC,EAAE,QAAQ,EAAE,kBAAkB,EAAE,EACjF,KAAK,IAAI,EAAE;QACT,MAAM,EAAE,IAAI,EAAE,GAAG,MAAM,MAAM,CAAC,OAAO,CAAC,KAAK,EAAE,IAAI,MAAM,CAAC,aAAa,EAAE,EAAE;YACvE,MAAM,EAAE,4EAA4E;SACrF,CAAC,CAAC;QACH,OAAO;YACL,QAAQ,EAAE;gBACR;oBACE,GAAG,EAAE,4BAA4B;oBACjC,QAAQ,EAAE,kBAAkB;oBAC5B,IAAI,EAAE,IAAI,CAAC,SAAS,CAAC,IAAI,EAAE,IAAI,EAAE,CAAC,CAAC;iBACpC;aACF;SACF,CAAC;IACJ,CAAC,CACF,CAAC;AACJ,CAAC"}
1
+ {"version":3,"file":"threads.js","sourceRoot":"","sources":["../../src/resources/threads.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,kBAAkB,EAAE,MAAM,oBAAoB,CAAC;AAExD,MAAM,UAAU,wBAAwB,CAAC,MAAiB,EAAE,MAAkB;IAC5E,MAAM,CAAC,QAAQ,CACb,iBAAiB,EACjB,4BAA4B,EAC5B,EAAE,WAAW,EAAE,kCAAkC,EAAE,QAAQ,EAAE,kBAAkB,EAAE,EACjF,KAAK,IAAI,EAAE;QACT,IAAI,CAAC;YACH,MAAM,EAAE,IAAI,EAAE,GAAG,MAAM,MAAM,CAAC,OAAO,CAAC,KAAK,EAAE,IAAI,MAAM,CAAC,aAAa,EAAE,EAAE;gBACvE,MAAM,EAAE,4EAA4E;aACrF,CAAC,CAAC;YACH,OAAO;gBACL,QAAQ,EAAE;oBACR;wBACE,GAAG,EAAE,4BAA4B;wBACjC,QAAQ,EAAE,kBAAkB;wBAC5B,IAAI,EAAE,IAAI,CAAC,SAAS,CAAC,IAAI,EAAE,IAAI,EAAE,CAAC,CAAC;qBACpC;iBACF;aACF,CAAC;QACJ,CAAC;QAAC,OAAO,KAAK,EAAE,CAAC;YACf,MAAM,kBAAkB,CAAC,KAAK,EAAE,qBAAqB,CAAC,CAAC;QACzD,CAAC;IACH,CAAC,CACF,CAAC;AACJ,CAAC"}
package/dist/schemas.d.ts CHANGED
@@ -4,4 +4,18 @@ import { z } from "zod";
4
4
  * Use for all user-provided media and callback URLs to prevent SSRF and non-secure schemes.
5
5
  */
6
6
  export declare const httpsUrl: z.ZodString;
7
+ /**
8
+ * Zod schema for Meta-issued resource IDs (media, comment, container, post,
9
+ * reply, conversation, message, hashtag). Use for any ID that gets interpolated
10
+ * into a URL path segment in MetaClient calls — rejects path-altering characters
11
+ * (`/`, `.`, `?`, `&`, `=`, whitespace) at schema parse time so a crafted value
12
+ * cannot rewrite the request path or inject query params. The `+` quantifier
13
+ * also enforces non-empty (callers chaining `.min(1)` is redundant).
14
+ *
15
+ * Real Meta IDs are numeric (e.g. `17889615324123`) or numeric-with-underscore
16
+ * for compound containers (e.g. `17841405822304914_17889615324123`); the
17
+ * `[a-zA-Z0-9_-]` set is intentionally broader to absorb future format changes
18
+ * while keeping path-traversal characters out.
19
+ */
20
+ export declare const metaId: z.ZodString;
7
21
  //# sourceMappingURL=schemas.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"schemas.d.ts","sourceRoot":"","sources":["../src/schemas.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB;;;GAGG;AACH,eAAO,MAAM,QAAQ,aAGpB,CAAC"}
1
+ {"version":3,"file":"schemas.d.ts","sourceRoot":"","sources":["../src/schemas.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB;;;GAGG;AACH,eAAO,MAAM,QAAQ,aAGpB,CAAC;AAEF;;;;;;;;;;;;GAYG;AACH,eAAO,MAAM,MAAM,aAGlB,CAAC"}
package/dist/schemas.js CHANGED
@@ -4,4 +4,18 @@ import { z } from "zod";
4
4
  * Use for all user-provided media and callback URLs to prevent SSRF and non-secure schemes.
5
5
  */
6
6
  export const httpsUrl = z.string().url().refine((u) => u.toLowerCase().startsWith("https://"), { message: "URL must use HTTPS" });
7
+ /**
8
+ * Zod schema for Meta-issued resource IDs (media, comment, container, post,
9
+ * reply, conversation, message, hashtag). Use for any ID that gets interpolated
10
+ * into a URL path segment in MetaClient calls — rejects path-altering characters
11
+ * (`/`, `.`, `?`, `&`, `=`, whitespace) at schema parse time so a crafted value
12
+ * cannot rewrite the request path or inject query params. The `+` quantifier
13
+ * also enforces non-empty (callers chaining `.min(1)` is redundant).
14
+ *
15
+ * Real Meta IDs are numeric (e.g. `17889615324123`) or numeric-with-underscore
16
+ * for compound containers (e.g. `17841405822304914_17889615324123`); the
17
+ * `[a-zA-Z0-9_-]` set is intentionally broader to absorb future format changes
18
+ * while keeping path-traversal characters out.
19
+ */
20
+ export const metaId = z.string().regex(/^[a-zA-Z0-9_-]+$/, "ID must contain only letters, numbers, underscores, and hyphens");
7
21
  //# sourceMappingURL=schemas.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"schemas.js","sourceRoot":"","sources":["../src/schemas.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB;;;GAGG;AACH,MAAM,CAAC,MAAM,QAAQ,GAAG,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,EAAE,CAAC,MAAM,CAC7C,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,WAAW,EAAE,CAAC,UAAU,CAAC,UAAU,CAAC,EAC7C,EAAE,OAAO,EAAE,oBAAoB,EAAE,CAClC,CAAC"}
1
+ {"version":3,"file":"schemas.js","sourceRoot":"","sources":["../src/schemas.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB;;;GAGG;AACH,MAAM,CAAC,MAAM,QAAQ,GAAG,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,EAAE,CAAC,MAAM,CAC7C,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,WAAW,EAAE,CAAC,UAAU,CAAC,UAAU,CAAC,EAC7C,EAAE,OAAO,EAAE,oBAAoB,EAAE,CAClC,CAAC;AAEF;;;;;;;;;;;;GAYG;AACH,MAAM,CAAC,MAAM,MAAM,GAAG,CAAC,CAAC,MAAM,EAAE,CAAC,KAAK,CACpC,kBAAkB,EAClB,iEAAiE,CAClE,CAAC"}