@omnisocials/mcp-server 1.34.1 → 1.39.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.
- package/README.md +51 -6
- package/build/client.d.ts +15 -1
- package/build/client.js +24 -0
- package/build/index.js +1 -1
- package/build/metrics.d.ts +10 -2
- package/build/metrics.js +100 -2
- package/build/tools/analytics.js +1 -1
- package/build/tools/inbox.js +17 -8
- package/build/tools/media.js +39 -5
- package/build/tools/posts.js +251 -13
- package/build/tools/webhooks.js +3 -3
- package/build/types.d.ts +165 -6
- package/package.json +2 -2
package/build/types.d.ts
CHANGED
|
@@ -84,13 +84,23 @@ export interface InboxMessage {
|
|
|
84
84
|
}
|
|
85
85
|
/** What GET /inbox/next serves (and what `reply_to_inbox` returns as `next`
|
|
86
86
|
* when `include_next` is set). `message` is the unanswered incoming item: its
|
|
87
|
-
* `id` is what hide/delete take
|
|
87
|
+
* `id` is what hide/delete take and the `message_id` to pass to reply for a
|
|
88
|
+
* comment thread, its `conversation_id` is what reply takes as the path.
|
|
88
89
|
* `messages` is the thread oldest first (the most recent 50, plus the target
|
|
89
90
|
* and its parent when they fall outside that window). */
|
|
90
91
|
export interface InboxNextUnanswered {
|
|
91
92
|
conversation: InboxConversation;
|
|
92
93
|
message: InboxMessage;
|
|
93
94
|
messages: InboxMessage[];
|
|
95
|
+
/** Only Instagram and Facebook DMs have a reply window (Meta's 24 hours
|
|
96
|
+
* after the customer's last message): `closes_at` is that deadline and
|
|
97
|
+
* `open` is false once it has passed, in which case reply_to_inbox answers
|
|
98
|
+
* 422 outside_messaging_window. Every other item: open true, closes_at
|
|
99
|
+
* null. */
|
|
100
|
+
reply_window: {
|
|
101
|
+
open: boolean;
|
|
102
|
+
closes_at: string | null;
|
|
103
|
+
};
|
|
94
104
|
}
|
|
95
105
|
/** Response of DELETE /inbox/messages/:id. Replies under the comment are
|
|
96
106
|
* removed with it; their inbox ids are listed in `removed_reply_ids`. */
|
|
@@ -138,6 +148,21 @@ export interface ApiInstagramOptionsOut extends ApiPlatformOptionsOut {
|
|
|
138
148
|
thumb_offset?: number | string;
|
|
139
149
|
cover_url?: string;
|
|
140
150
|
}
|
|
151
|
+
/** One video-cover choice: a frame offset or a custom image. */
|
|
152
|
+
export interface ApiVideoCoverEntry {
|
|
153
|
+
type: "frame" | "custom";
|
|
154
|
+
/** Milliseconds into the video (type "frame"). */
|
|
155
|
+
thumb_offset?: number;
|
|
156
|
+
/** Public image URL (type "custom"). */
|
|
157
|
+
cover_url?: string;
|
|
158
|
+
}
|
|
159
|
+
/** Cross-platform video cover as stored on the post (`video_cover`). On
|
|
160
|
+
* input, a `null` override entry drops that platform's override; the API
|
|
161
|
+
* never echoes nulls back. */
|
|
162
|
+
export interface ApiVideoCover extends ApiVideoCoverEntry {
|
|
163
|
+
/** Per-platform overrides keyed by platform id; an override wins for that platform. */
|
|
164
|
+
overrides?: Record<string, ApiVideoCoverEntry | null>;
|
|
165
|
+
}
|
|
141
166
|
export interface ApiStorySlide {
|
|
142
167
|
/** Zero-based slide position. */
|
|
143
168
|
index?: number;
|
|
@@ -179,6 +204,8 @@ export interface ApiPost {
|
|
|
179
204
|
/** Stories only, after publishing: every slide per platform in publish
|
|
180
205
|
* order. `published_urls` keeps only the first slide's URL. */
|
|
181
206
|
story_slides?: Record<string, ApiStorySlide[]>;
|
|
207
|
+
/** Video thumbnail (base + per-platform overrides); null when none was chosen. */
|
|
208
|
+
video_cover?: ApiVideoCover | null;
|
|
182
209
|
/** Set on a retry post: the original failed post's id. */
|
|
183
210
|
retry_of?: string;
|
|
184
211
|
/** Set on the original post: ids of its retry posts. */
|
|
@@ -257,6 +284,68 @@ export interface RejectPostResult {
|
|
|
257
284
|
approval_status: "rejected";
|
|
258
285
|
message?: string;
|
|
259
286
|
}
|
|
287
|
+
/** One approver of a step in GET /posts/:id/approval. */
|
|
288
|
+
export interface PostApprovalApprover {
|
|
289
|
+
id: string;
|
|
290
|
+
name: string | null;
|
|
291
|
+
email: string | null;
|
|
292
|
+
status: "pending" | "approved" | "rejected";
|
|
293
|
+
decided_at: string | null;
|
|
294
|
+
/** The reason this approver gave with a rejection. */
|
|
295
|
+
comment: string | null;
|
|
296
|
+
}
|
|
297
|
+
export interface PostApprovalStep {
|
|
298
|
+
order: number;
|
|
299
|
+
name: string;
|
|
300
|
+
/** `all` = every approver of the step must approve. `any` = one approval is enough. */
|
|
301
|
+
require_mode: "all" | "any";
|
|
302
|
+
status: "pending" | "approved" | "rejected";
|
|
303
|
+
approvers: PostApprovalApprover[];
|
|
304
|
+
}
|
|
305
|
+
export interface PostApprovalComment {
|
|
306
|
+
id: string;
|
|
307
|
+
author: {
|
|
308
|
+
id: string;
|
|
309
|
+
name: string | null;
|
|
310
|
+
} | null;
|
|
311
|
+
message: string;
|
|
312
|
+
/** The channel the comment is about (`instagram`, `linkedin_page`, ...). Null = the whole post. */
|
|
313
|
+
account: string | null;
|
|
314
|
+
created_at: string;
|
|
315
|
+
}
|
|
316
|
+
/** `data` of GET /posts/:id/approval (backend/routes/api/v1/posts.js).
|
|
317
|
+
* `status: "none"` = the post has no approval workflow: `workflow`,
|
|
318
|
+
* `requested_by`, `requested_at`, `current_step` and `rejection` are null and
|
|
319
|
+
* `steps` and `comments` are empty. */
|
|
320
|
+
export interface PostApproval {
|
|
321
|
+
post_id: string;
|
|
322
|
+
status: "none" | "pending" | "approved" | "rejected";
|
|
323
|
+
/** `id` is null for a one-off approval that was not made from a saved workflow. */
|
|
324
|
+
workflow: {
|
|
325
|
+
id: string | null;
|
|
326
|
+
name: string;
|
|
327
|
+
} | null;
|
|
328
|
+
requested_by: {
|
|
329
|
+
id: string;
|
|
330
|
+
name: string | null;
|
|
331
|
+
} | null;
|
|
332
|
+
requested_at: string | null;
|
|
333
|
+
/** Order of the step the post waits on. Null when the review is finished. */
|
|
334
|
+
current_step: number | null;
|
|
335
|
+
steps: PostApprovalStep[];
|
|
336
|
+
rejection: {
|
|
337
|
+
by: {
|
|
338
|
+
id: string;
|
|
339
|
+
name: string | null;
|
|
340
|
+
};
|
|
341
|
+
reason: string | null;
|
|
342
|
+
at: string | null;
|
|
343
|
+
step: number | null;
|
|
344
|
+
} | null;
|
|
345
|
+
/** The review thread, oldest first. Includes the entries OmniSocials
|
|
346
|
+
* writes when a reviewer edits the post. */
|
|
347
|
+
comments: PostApprovalComment[];
|
|
348
|
+
}
|
|
260
349
|
/** One place from GET /locations/search
|
|
261
350
|
* (@openapi block in backend/routes/api/v1/locations.js). */
|
|
262
351
|
export interface LocationPlace {
|
|
@@ -297,6 +386,57 @@ export interface LocationSearchResult {
|
|
|
297
386
|
};
|
|
298
387
|
needsPermission?: boolean;
|
|
299
388
|
}
|
|
389
|
+
/** One product Pin from GET /pinterest/products
|
|
390
|
+
* (@openapi block in backend/routes/api/v1/pinterest.js). */
|
|
391
|
+
export interface PinterestProduct {
|
|
392
|
+
/** Use in `pinterest.product_tags`. */
|
|
393
|
+
pin_id: string;
|
|
394
|
+
title?: string | null;
|
|
395
|
+
description?: string | null;
|
|
396
|
+
link?: string | null;
|
|
397
|
+
image_url?: string | null;
|
|
398
|
+
/** Catalog source only. */
|
|
399
|
+
price?: number | null;
|
|
400
|
+
currency?: string | null;
|
|
401
|
+
availability?: string | null;
|
|
402
|
+
item_id?: string | null;
|
|
403
|
+
}
|
|
404
|
+
/** GET /pinterest/products envelope: NOT the standard data/error envelope.
|
|
405
|
+
* Success: `products` + `bookmark` + `source` + `catalog_access` (and, for
|
|
406
|
+
* the catalog source, `product_groups` + `product_group_id`). When the list
|
|
407
|
+
* could not be read, `error` is a { code, message } object with code one of
|
|
408
|
+
* pinterest_not_connected | pinterest_catalog_access_required |
|
|
409
|
+
* platform_error, and `products` is absent. */
|
|
410
|
+
export interface PinterestProductsResult {
|
|
411
|
+
products?: PinterestProduct[];
|
|
412
|
+
bookmark?: string | null;
|
|
413
|
+
source?: "catalog" | "pins";
|
|
414
|
+
catalog_access?: boolean;
|
|
415
|
+
product_groups?: Array<{
|
|
416
|
+
id: string;
|
|
417
|
+
name?: string | null;
|
|
418
|
+
}>;
|
|
419
|
+
product_group_id?: string | null;
|
|
420
|
+
error?: string | {
|
|
421
|
+
code: string;
|
|
422
|
+
message: string;
|
|
423
|
+
};
|
|
424
|
+
}
|
|
425
|
+
/** GET /pinterest/products/validate result. `unverified` = the check could
|
|
426
|
+
* not run; the publish step is then the final check. */
|
|
427
|
+
export interface PinterestProductCheck {
|
|
428
|
+
valid?: boolean;
|
|
429
|
+
pin_id?: string | null;
|
|
430
|
+
title?: string | null;
|
|
431
|
+
link?: string | null;
|
|
432
|
+
image_url?: string | null;
|
|
433
|
+
unverified?: boolean;
|
|
434
|
+
reason?: string;
|
|
435
|
+
error?: string | {
|
|
436
|
+
code: string;
|
|
437
|
+
message: string;
|
|
438
|
+
};
|
|
439
|
+
}
|
|
300
440
|
/** One track from GET /audio/search
|
|
301
441
|
* (@openapi block in backend/routes/api/v1/audio.js). */
|
|
302
442
|
export interface InstagramAudioTrack {
|
|
@@ -349,14 +489,29 @@ export interface MediaItem {
|
|
|
349
489
|
size: string;
|
|
350
490
|
status?: string;
|
|
351
491
|
created_at: string;
|
|
492
|
+
pdf?: {
|
|
493
|
+
id: string;
|
|
494
|
+
name: string;
|
|
495
|
+
url: string;
|
|
496
|
+
page?: number;
|
|
497
|
+
total_pages: number;
|
|
498
|
+
rendered_pages: number;
|
|
499
|
+
truncated?: boolean;
|
|
500
|
+
pages?: Array<{
|
|
501
|
+
url: string;
|
|
502
|
+
width?: number | null;
|
|
503
|
+
height?: number | null;
|
|
504
|
+
}>;
|
|
505
|
+
};
|
|
352
506
|
}
|
|
353
507
|
/**
|
|
354
508
|
* Extra top-level fields returned by /media/upload* when the uploaded file is a
|
|
355
|
-
* PDF. A PDF is rasterized into one image slide per page (max 20)
|
|
356
|
-
* mirrors the first slide (back-compat), while
|
|
357
|
-
* whole carousel in page order. Pass ALL of
|
|
358
|
-
* LinkedIn the slides post as a native
|
|
359
|
-
*
|
|
509
|
+
* PDF. A PDF is rasterized into one image slide per page (max 20) and the
|
|
510
|
+
* original file is kept: `data` mirrors the first slide (back-compat), while
|
|
511
|
+
* `slides` + `media_ids` carry the whole carousel in page order. Pass ALL of
|
|
512
|
+
* `media_ids` to create_post. On LinkedIn the slides post as a native
|
|
513
|
+
* swipeable document made from the original PDF (unless the post's
|
|
514
|
+
* linkedin.document_source is "slides"); elsewhere as an image carousel.
|
|
360
515
|
*/
|
|
361
516
|
export interface PdfUploadResult {
|
|
362
517
|
slides: MediaItem[];
|
|
@@ -365,6 +520,10 @@ export interface PdfUploadResult {
|
|
|
365
520
|
total_pages: number;
|
|
366
521
|
rendered_pages: number;
|
|
367
522
|
truncated: boolean;
|
|
523
|
+
id?: string;
|
|
524
|
+
name?: string;
|
|
525
|
+
url?: string;
|
|
526
|
+
size_bytes?: number;
|
|
368
527
|
};
|
|
369
528
|
}
|
|
370
529
|
export interface Account {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@omnisocials/mcp-server",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.39.0",
|
|
4
4
|
"mcpName": "io.github.omnisocials/mcp-server",
|
|
5
5
|
"description": "MCP server for OmniSocials API - manage social media posts, media, accounts, analytics, and webhooks",
|
|
6
6
|
"type": "module",
|
|
@@ -53,7 +53,7 @@
|
|
|
53
53
|
},
|
|
54
54
|
"overrides": {
|
|
55
55
|
"zod": "4.4.0",
|
|
56
|
-
"fast-uri": "^3.1.
|
|
56
|
+
"fast-uri": "^3.1.8",
|
|
57
57
|
"hono": "^4.13.7",
|
|
58
58
|
"qs": "^6.16.0"
|
|
59
59
|
}
|