posterly-mcp-server 0.34.0 → 0.35.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 CHANGED
@@ -122,7 +122,7 @@ Add the same server definition to your Cursor MCP settings:
122
122
 
123
123
  ## Available tools
124
124
 
125
- `posterly-mcp-server@0.34.0` exposes 78 tools.
125
+ `posterly-mcp-server@0.35.0` exposes 78 tools.
126
126
 
127
127
  Public setup tools work before `POSTERLY_API_KEY` exists:
128
128
 
@@ -812,6 +812,7 @@ export interface PublicSignupSessionResponse {
812
812
  export interface VideoJob {
813
813
  id: string;
814
814
  status: string;
815
+ provider: 'google' | 'xai';
815
816
  prompt: string;
816
817
  model: string;
817
818
  duration_seconds: number;
@@ -1015,8 +1016,10 @@ export declare class PosterlyClient {
1015
1016
  aspect_ratio?: string;
1016
1017
  style?: string;
1017
1018
  variations?: number;
1019
+ provider?: 'google' | 'xai';
1018
1020
  model?: 'lite' | 'flash' | 'pro';
1019
1021
  resolution?: '512' | '1K' | '2K' | '4K';
1022
+ quality?: 'low' | 'medium';
1020
1023
  }): Promise<{
1021
1024
  urls: string[];
1022
1025
  images: Array<{
@@ -1025,6 +1028,7 @@ export declare class PosterlyClient {
1025
1028
  path: string;
1026
1029
  }>;
1027
1030
  model: string;
1031
+ provider: 'google' | 'xai';
1028
1032
  credits_used: number;
1029
1033
  warnings?: string[];
1030
1034
  usage: {
@@ -1042,11 +1046,12 @@ export declare class PosterlyClient {
1042
1046
  params?: Record<string, unknown>;
1043
1047
  }): Promise<Record<string, any>>;
1044
1048
  generateVideo(data: {
1049
+ provider?: 'google' | 'xai';
1045
1050
  prompt: string;
1046
1051
  negative_prompt?: string;
1047
- aspect_ratio?: '16:9' | '9:16';
1048
- duration_seconds?: 4 | 6 | 8;
1049
- resolution?: '720p' | '1080p';
1052
+ aspect_ratio?: '1:1' | '16:9' | '9:16' | '4:3' | '3:4' | '3:2' | '2:3';
1053
+ duration_seconds?: number;
1054
+ resolution?: '480p' | '720p' | '1080p';
1050
1055
  model?: 'lite' | 'fast' | 'standard';
1051
1056
  image_url?: string;
1052
1057
  end_image_url?: string;
@@ -1 +1 @@
1
- export declare const POSTERLY_MCP_VERSION = "0.34.0";
1
+ export declare const POSTERLY_MCP_VERSION = "0.35.0";
@@ -5,4 +5,4 @@
5
5
  // tool set (minus the intentional pre-auth signup tools that only this stdio
6
6
  // package exposes). `npm run check:mcp-parity` enforces both the version match
7
7
  // and the tool-list match, and runs in the pre-commit hook.
8
- export const POSTERLY_MCP_VERSION = '0.34.0';
8
+ export const POSTERLY_MCP_VERSION = '0.35.0';
@@ -9,12 +9,12 @@ export declare const createConnectSessionTool: {
9
9
  auto_start: z.ZodOptional<z.ZodBoolean>;
10
10
  debug: z.ZodOptional<z.ZodBoolean>;
11
11
  }, "strip", z.ZodTypeAny, {
12
- platform: "meta" | "instagram_direct" | "instagram" | "instagram-standalone" | "facebook" | "tiktok" | "twitter" | "threads" | "linkedin" | "youtube" | "pinterest" | "google_business" | "x" | "telegram" | "bluesky" | "discord" | "slack" | "mastodon" | "devto" | "hashnode" | "wordpress" | "lemmy" | "reddit" | "medium" | "skool" | "whop" | "gmb" | "google-business" | "google_business_profile" | "linkedin_page" | "facebook_instagram" | "facebook_pages" | "linkedin-company" | "linkedin-page" | "linkedin_company" | "linkedin_personal" | "meta_business" | "x_twitter";
12
+ platform: "meta" | "instagram_direct" | "instagram" | "instagram-standalone" | "facebook" | "tiktok" | "twitter" | "threads" | "linkedin" | "youtube" | "pinterest" | "google_business" | "medium" | "x" | "telegram" | "bluesky" | "discord" | "slack" | "mastodon" | "devto" | "hashnode" | "wordpress" | "lemmy" | "reddit" | "skool" | "whop" | "gmb" | "google-business" | "google_business_profile" | "linkedin_page" | "facebook_instagram" | "facebook_pages" | "linkedin-company" | "linkedin-page" | "linkedin_company" | "linkedin_personal" | "meta_business" | "x_twitter";
13
13
  workspace_id?: string | undefined;
14
14
  auto_start?: boolean | undefined;
15
15
  debug?: boolean | undefined;
16
16
  }, {
17
- platform: "meta" | "instagram_direct" | "instagram" | "instagram-standalone" | "facebook" | "tiktok" | "twitter" | "threads" | "linkedin" | "youtube" | "pinterest" | "google_business" | "x" | "telegram" | "bluesky" | "discord" | "slack" | "mastodon" | "devto" | "hashnode" | "wordpress" | "lemmy" | "reddit" | "medium" | "skool" | "whop" | "gmb" | "google-business" | "google_business_profile" | "linkedin_page" | "facebook_instagram" | "facebook_pages" | "linkedin-company" | "linkedin-page" | "linkedin_company" | "linkedin_personal" | "meta_business" | "x_twitter";
17
+ platform: "meta" | "instagram_direct" | "instagram" | "instagram-standalone" | "facebook" | "tiktok" | "twitter" | "threads" | "linkedin" | "youtube" | "pinterest" | "google_business" | "medium" | "x" | "telegram" | "bluesky" | "discord" | "slack" | "mastodon" | "devto" | "hashnode" | "wordpress" | "lemmy" | "reddit" | "skool" | "whop" | "gmb" | "google-business" | "google_business_profile" | "linkedin_page" | "facebook_instagram" | "facebook_pages" | "linkedin-company" | "linkedin-page" | "linkedin_company" | "linkedin_personal" | "meta_business" | "x_twitter";
18
18
  workspace_id?: string | undefined;
19
19
  auto_start?: boolean | undefined;
20
20
  debug?: boolean | undefined;
@@ -8,33 +8,41 @@ export declare const generateImageTool: {
8
8
  aspect_ratio: z.ZodOptional<z.ZodEnum<["1:1", "9:16", "4:5", "3:4", "2:3", "1:4", "1:8", "21:9", "16:9", "4:3", "3:2", "4:1", "8:1", "5:4"]>>;
9
9
  style: z.ZodOptional<z.ZodEnum<["photographic", "illustration", "minimal", "vibrant", "professional", "youtube_thumbnail", "reel_cover", "review_background"]>>;
10
10
  variations: z.ZodOptional<z.ZodNumber>;
11
+ provider: z.ZodOptional<z.ZodEnum<["google", "xai"]>>;
11
12
  model: z.ZodOptional<z.ZodEnum<["lite", "flash", "pro"]>>;
12
13
  resolution: z.ZodOptional<z.ZodEnum<["512", "1K", "2K", "4K"]>>;
14
+ quality: z.ZodOptional<z.ZodEnum<["low", "medium"]>>;
13
15
  confirm: z.ZodLiteral<true>;
14
16
  }, "strip", z.ZodTypeAny, {
15
17
  confirm: true;
16
18
  prompt: string;
17
- aspect_ratio?: "16:9" | "9:16" | "1:1" | "4:5" | "3:4" | "2:3" | "1:4" | "1:8" | "21:9" | "4:3" | "3:2" | "4:1" | "8:1" | "5:4" | undefined;
19
+ aspect_ratio?: "1:1" | "16:9" | "9:16" | "4:3" | "3:4" | "3:2" | "2:3" | "4:5" | "1:4" | "1:8" | "21:9" | "4:1" | "8:1" | "5:4" | undefined;
18
20
  style?: "minimal" | "professional" | "photographic" | "illustration" | "vibrant" | "youtube_thumbnail" | "reel_cover" | "review_background" | undefined;
19
21
  variations?: number | undefined;
22
+ provider?: "google" | "xai" | undefined;
20
23
  model?: "pro" | "lite" | "flash" | undefined;
21
24
  resolution?: "512" | "1K" | "2K" | "4K" | undefined;
25
+ quality?: "low" | "medium" | undefined;
22
26
  }, {
23
27
  confirm: true;
24
28
  prompt: string;
25
- aspect_ratio?: "16:9" | "9:16" | "1:1" | "4:5" | "3:4" | "2:3" | "1:4" | "1:8" | "21:9" | "4:3" | "3:2" | "4:1" | "8:1" | "5:4" | undefined;
29
+ aspect_ratio?: "1:1" | "16:9" | "9:16" | "4:3" | "3:4" | "3:2" | "2:3" | "4:5" | "1:4" | "1:8" | "21:9" | "4:1" | "8:1" | "5:4" | undefined;
26
30
  style?: "minimal" | "professional" | "photographic" | "illustration" | "vibrant" | "youtube_thumbnail" | "reel_cover" | "review_background" | undefined;
27
31
  variations?: number | undefined;
32
+ provider?: "google" | "xai" | undefined;
28
33
  model?: "pro" | "lite" | "flash" | undefined;
29
34
  resolution?: "512" | "1K" | "2K" | "4K" | undefined;
35
+ quality?: "low" | "medium" | undefined;
30
36
  }>;
31
37
  execute(client: PosterlyClient, input: {
32
38
  prompt: string;
33
39
  aspect_ratio?: string;
34
40
  style?: string;
35
41
  variations?: number;
42
+ provider?: "google" | "xai";
36
43
  model?: "lite" | "flash" | "pro";
37
44
  resolution?: "512" | "1K" | "2K" | "4K";
45
+ quality?: "low" | "medium";
38
46
  confirm: true;
39
47
  }): Promise<string>;
40
48
  };
@@ -2,7 +2,7 @@ import { z } from 'zod';
2
2
  import { mdBullets, mdKeyValue, mdSection, mdTable, mdTitle } from '../lib/format.js';
3
3
  export const generateImageTool = {
4
4
  name: 'generate_image',
5
- description: 'Generate an AI image via Posterly\'s Nano Banana (Gemini) integration. The image is saved to the user\'s media storage and the returned URL can be passed to `create_post` as `media_url`.\n\n' +
5
+ description: 'Generate an AI image via Posterly using Nano Banana (Gemini) or Grok Imagine Image 2.0 (xAI). The image is saved to the user\'s media storage and the returned URL can be passed to `create_post` as `media_url`.\n\n' +
6
6
  'COSTS CREDITS. Every call consumes part of the user\'s monthly AI image quota (or purchased credits once the quota is exhausted). Do NOT call speculatively - always describe the image you\'re about to generate (subject, style, aspect ratio) to the user and get confirmation before calling.\n\n' +
7
7
  'If the user is over their plan limit and has no credits, this tool returns a 402 with upgrade info. Surface that message verbatim - do not retry.\n\n' +
8
8
  'Common aspect ratios by platform:\n' +
@@ -37,14 +37,22 @@ export const generateImageTool = {
37
37
  .max(4)
38
38
  .optional()
39
39
  .describe('How many variations to generate. Default 1. Each variation costs credits separately - prefer 1 unless the user explicitly wants options.'),
40
+ provider: z
41
+ .enum(['google', 'xai'])
42
+ .optional()
43
+ .describe('Image provider. Default google. Use xai for Grok Imagine Image 2.0.'),
40
44
  model: z
41
45
  .enum(['lite', 'flash', 'pro'])
42
46
  .optional()
43
- .describe('lite (8 credits, 1K only) is the cheapest and suits drafts and exploration. flash (default, 15 credits at 1K) balances quality and cost. pro (30 credits at 1K) is highest quality for hero imagery. Start with lite or flash unless quality is critical.'),
47
+ .describe('Google-only. lite (8 credits, 1K only) suits drafts; flash (default, 15 at 1K) balances quality and cost; pro (30 at 1K) is highest quality. Ignored for xAI.'),
44
48
  resolution: z
45
49
  .enum(['512', '1K', '2K', '4K'])
46
50
  .optional()
47
- .describe('Output resolution. Default 1K. Higher resolutions cost more credits (flash: 10/15/23/35 for 512/1K/2K/4K; pro: 30 at 1K-2K, 55 at 4K). 512 is flash-only and lite supports 1K only.'),
51
+ .describe('Output resolution. Default 1K. xAI supports 1K/2K only. Google flash: 10/15/23/35 credits at 512/1K/2K/4K; pro: 30 at 1K-2K, 55 at 4K.'),
52
+ quality: z
53
+ .enum(['low', 'medium'])
54
+ .optional()
55
+ .describe('xAI only. Low costs 9/14 credits at 1K/2K; medium (default) costs 14/18 credits and gives better quality.'),
48
56
  confirm: z.literal(true).describe('Must be true after explicit user confirmation of subject, style, aspect ratio, and credit use.'),
49
57
  }),
50
58
  async execute(client, input) {
@@ -4,11 +4,12 @@ export declare const generateVideoTool: {
4
4
  name: string;
5
5
  description: string;
6
6
  inputSchema: z.ZodObject<{
7
+ provider: z.ZodOptional<z.ZodDefault<z.ZodEnum<["google", "xai"]>>>;
7
8
  prompt: z.ZodString;
8
9
  negative_prompt: z.ZodOptional<z.ZodString>;
9
- aspect_ratio: z.ZodOptional<z.ZodDefault<z.ZodEnum<["16:9", "9:16"]>>>;
10
- duration_seconds: z.ZodOptional<z.ZodDefault<z.ZodUnion<[z.ZodLiteral<4>, z.ZodLiteral<6>, z.ZodLiteral<8>]>>>;
11
- resolution: z.ZodOptional<z.ZodDefault<z.ZodEnum<["720p", "1080p"]>>>;
10
+ aspect_ratio: z.ZodOptional<z.ZodDefault<z.ZodEnum<["1:1", "16:9", "9:16", "4:3", "3:4", "3:2", "2:3"]>>>;
11
+ duration_seconds: z.ZodOptional<z.ZodDefault<z.ZodNumber>>;
12
+ resolution: z.ZodOptional<z.ZodDefault<z.ZodEnum<["480p", "720p", "1080p"]>>>;
12
13
  model: z.ZodOptional<z.ZodDefault<z.ZodEnum<["lite", "fast", "standard"]>>>;
13
14
  image_url: z.ZodOptional<z.ZodString>;
14
15
  end_image_url: z.ZodOptional<z.ZodString>;
@@ -28,11 +29,12 @@ export declare const generateVideoTool: {
28
29
  }, "strip", z.ZodTypeAny, {
29
30
  confirm: true;
30
31
  prompt: string;
31
- aspect_ratio?: "16:9" | "9:16" | undefined;
32
+ aspect_ratio?: "1:1" | "16:9" | "9:16" | "4:3" | "3:4" | "3:2" | "2:3" | undefined;
33
+ provider?: "google" | "xai" | undefined;
32
34
  model?: "lite" | "fast" | "standard" | undefined;
33
- resolution?: "720p" | "1080p" | undefined;
35
+ resolution?: "480p" | "720p" | "1080p" | undefined;
34
36
  negative_prompt?: string | undefined;
35
- duration_seconds?: 4 | 6 | 8 | undefined;
37
+ duration_seconds?: number | undefined;
36
38
  image_url?: string | undefined;
37
39
  end_image_url?: string | undefined;
38
40
  reference_images?: {
@@ -44,11 +46,12 @@ export declare const generateVideoTool: {
44
46
  }, {
45
47
  confirm: true;
46
48
  prompt: string;
47
- aspect_ratio?: "16:9" | "9:16" | undefined;
49
+ aspect_ratio?: "1:1" | "16:9" | "9:16" | "4:3" | "3:4" | "3:2" | "2:3" | undefined;
50
+ provider?: "google" | "xai" | undefined;
48
51
  model?: "lite" | "fast" | "standard" | undefined;
49
- resolution?: "720p" | "1080p" | undefined;
52
+ resolution?: "480p" | "720p" | "1080p" | undefined;
50
53
  negative_prompt?: string | undefined;
51
- duration_seconds?: 4 | 6 | 8 | undefined;
54
+ duration_seconds?: number | undefined;
52
55
  image_url?: string | undefined;
53
56
  end_image_url?: string | undefined;
54
57
  reference_images?: {
@@ -1,13 +1,14 @@
1
1
  import { z } from 'zod';
2
2
  export const generateVideoTool = {
3
3
  name: 'generate_video',
4
- description: 'Queue a Veo AI video generation job. COSTS VEO CREDITS: confirm prompt, model, duration, resolution, aspect ratio, audio choice, and credit cost with the user before calling. Models cost 12 (lite), 35 (fast) or 90 (standard) credits per second; lite supports text-to-video and image-to-video only, not reference_images or source_video_url. Poll get_video_job for status and final video_url.',
4
+ description: 'Queue an AI video generation job with Google Veo 3.1 or xAI Grok Imagine Video 1.5. COSTS CREDITS: confirm provider, prompt, duration, resolution, aspect ratio, audio choice, and credit cost with the user before calling. Grok supports 1–15 seconds and 480p–1080p; reference-to-video is capped at 720p. Poll get_video_job for status and final video_url.',
5
5
  inputSchema: z.object({
6
+ provider: z.enum(['google', 'xai']).default('google').optional(),
6
7
  prompt: z.string().min(5).max(1024),
7
8
  negative_prompt: z.string().max(500).optional(),
8
- aspect_ratio: z.enum(['16:9', '9:16']).default('16:9').optional(),
9
- duration_seconds: z.union([z.literal(4), z.literal(6), z.literal(8)]).default(8).optional(),
10
- resolution: z.enum(['720p', '1080p']).default('720p').optional(),
9
+ aspect_ratio: z.enum(['1:1', '16:9', '9:16', '4:3', '3:4', '3:2', '2:3']).default('16:9').optional(),
10
+ duration_seconds: z.number().int().min(1).max(15).default(8).optional(),
11
+ resolution: z.enum(['480p', '720p', '1080p']).default('720p').optional(),
11
12
  model: z.enum(['lite', 'fast', 'standard']).default('fast').optional(),
12
13
  image_url: z.string().url().optional(),
13
14
  end_image_url: z.string().url().optional(),
@@ -15,7 +16,7 @@ export const generateVideoTool = {
15
16
  url: z.string().url(),
16
17
  type: z.enum(['character', 'object', 'scene']),
17
18
  })).max(3).optional(),
18
- generate_audio: z.boolean().default(true).optional(),
19
+ generate_audio: z.boolean().default(true).optional().describe('Google can disable generated audio. xAI Grok includes audio and requires this to remain true.'),
19
20
  source_video_url: z.string().url().optional(),
20
21
  confirm: z.literal(true).describe('Must be true after explicit user confirmation of prompt, model, duration, resolution, and credit cost.'),
21
22
  }),
@@ -9,12 +9,12 @@ export declare const getConnectLinkTool: {
9
9
  include_planned: z.ZodOptional<z.ZodBoolean>;
10
10
  debug: z.ZodOptional<z.ZodBoolean>;
11
11
  }, "strip", z.ZodTypeAny, {
12
- platform?: "meta" | "instagram_direct" | "instagram" | "instagram-standalone" | "facebook" | "tiktok" | "twitter" | "threads" | "linkedin" | "youtube" | "pinterest" | "google_business" | "x" | "telegram" | "bluesky" | "discord" | "slack" | "mastodon" | "devto" | "hashnode" | "wordpress" | "lemmy" | "reddit" | "medium" | "skool" | "whop" | "gmb" | "google-business" | "google_business_profile" | "linkedin_page" | "facebook_instagram" | "facebook_pages" | "linkedin-company" | "linkedin-page" | "linkedin_company" | "linkedin_personal" | "meta_business" | "x_twitter" | undefined;
12
+ platform?: "meta" | "instagram_direct" | "instagram" | "instagram-standalone" | "facebook" | "tiktok" | "twitter" | "threads" | "linkedin" | "youtube" | "pinterest" | "google_business" | "medium" | "x" | "telegram" | "bluesky" | "discord" | "slack" | "mastodon" | "devto" | "hashnode" | "wordpress" | "lemmy" | "reddit" | "skool" | "whop" | "gmb" | "google-business" | "google_business_profile" | "linkedin_page" | "facebook_instagram" | "facebook_pages" | "linkedin-company" | "linkedin-page" | "linkedin_company" | "linkedin_personal" | "meta_business" | "x_twitter" | undefined;
13
13
  workspace_id?: string | undefined;
14
14
  include_planned?: boolean | undefined;
15
15
  debug?: boolean | undefined;
16
16
  }, {
17
- platform?: "meta" | "instagram_direct" | "instagram" | "instagram-standalone" | "facebook" | "tiktok" | "twitter" | "threads" | "linkedin" | "youtube" | "pinterest" | "google_business" | "x" | "telegram" | "bluesky" | "discord" | "slack" | "mastodon" | "devto" | "hashnode" | "wordpress" | "lemmy" | "reddit" | "medium" | "skool" | "whop" | "gmb" | "google-business" | "google_business_profile" | "linkedin_page" | "facebook_instagram" | "facebook_pages" | "linkedin-company" | "linkedin-page" | "linkedin_company" | "linkedin_personal" | "meta_business" | "x_twitter" | undefined;
17
+ platform?: "meta" | "instagram_direct" | "instagram" | "instagram-standalone" | "facebook" | "tiktok" | "twitter" | "threads" | "linkedin" | "youtube" | "pinterest" | "google_business" | "medium" | "x" | "telegram" | "bluesky" | "discord" | "slack" | "mastodon" | "devto" | "hashnode" | "wordpress" | "lemmy" | "reddit" | "skool" | "whop" | "gmb" | "google-business" | "google_business_profile" | "linkedin_page" | "facebook_instagram" | "facebook_pages" | "linkedin-company" | "linkedin-page" | "linkedin_company" | "linkedin_personal" | "meta_business" | "x_twitter" | undefined;
18
18
  workspace_id?: string | undefined;
19
19
  include_planned?: boolean | undefined;
20
20
  debug?: boolean | undefined;
@@ -8,11 +8,11 @@ export declare const getPlatformSchemaTool: {
8
8
  platform: z.ZodOptional<z.ZodEnum<["bluesky", "devto", "discord", "facebook", "gmb", "google-business", "google_business", "google_business_profile", "hashnode", "instagram", "instagram-standalone", "lemmy", "linkedin", "mastodon", "medium", "pinterest", "reddit", "skool", "slack", "telegram", "threads", "tiktok", "twitter", "whop", "wordpress", "x", "youtube"]>>;
9
9
  include_planned: z.ZodOptional<z.ZodBoolean>;
10
10
  }, "strip", z.ZodTypeAny, {
11
- platform?: "instagram" | "instagram-standalone" | "facebook" | "tiktok" | "twitter" | "threads" | "linkedin" | "youtube" | "pinterest" | "google_business" | "x" | "telegram" | "bluesky" | "discord" | "slack" | "mastodon" | "devto" | "hashnode" | "wordpress" | "lemmy" | "reddit" | "medium" | "skool" | "whop" | "gmb" | "google-business" | "google_business_profile" | undefined;
11
+ platform?: "instagram" | "instagram-standalone" | "facebook" | "tiktok" | "twitter" | "threads" | "linkedin" | "youtube" | "pinterest" | "google_business" | "medium" | "x" | "telegram" | "bluesky" | "discord" | "slack" | "mastodon" | "devto" | "hashnode" | "wordpress" | "lemmy" | "reddit" | "skool" | "whop" | "gmb" | "google-business" | "google_business_profile" | undefined;
12
12
  include_planned?: boolean | undefined;
13
13
  account_id?: string | undefined;
14
14
  }, {
15
- platform?: "instagram" | "instagram-standalone" | "facebook" | "tiktok" | "twitter" | "threads" | "linkedin" | "youtube" | "pinterest" | "google_business" | "x" | "telegram" | "bluesky" | "discord" | "slack" | "mastodon" | "devto" | "hashnode" | "wordpress" | "lemmy" | "reddit" | "medium" | "skool" | "whop" | "gmb" | "google-business" | "google_business_profile" | undefined;
15
+ platform?: "instagram" | "instagram-standalone" | "facebook" | "tiktok" | "twitter" | "threads" | "linkedin" | "youtube" | "pinterest" | "google_business" | "medium" | "x" | "telegram" | "bluesky" | "discord" | "slack" | "mastodon" | "devto" | "hashnode" | "wordpress" | "lemmy" | "reddit" | "skool" | "whop" | "gmb" | "google-business" | "google_business_profile" | undefined;
16
16
  include_planned?: boolean | undefined;
17
17
  account_id?: string | undefined;
18
18
  }>;
@@ -4,15 +4,15 @@ export declare const runVideoFunctionTool: {
4
4
  name: string;
5
5
  description: string;
6
6
  inputSchema: z.ZodObject<{
7
- identifier: z.ZodEnum<["google_veo", "veo3"]>;
7
+ identifier: z.ZodEnum<["google_veo", "veo3", "xai_grok", "grok_imagine"]>;
8
8
  functionName: z.ZodEnum<["list_input_modes", "estimate_cost", "validate_request"]>;
9
9
  params: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
10
10
  }, "strip", z.ZodTypeAny, {
11
- identifier: "google_veo" | "veo3";
11
+ identifier: "google_veo" | "veo3" | "xai_grok" | "grok_imagine";
12
12
  functionName: "list_input_modes" | "estimate_cost" | "validate_request";
13
13
  params?: Record<string, unknown> | undefined;
14
14
  }, {
15
- identifier: "google_veo" | "veo3";
15
+ identifier: "google_veo" | "veo3" | "xai_grok" | "grok_imagine";
16
16
  functionName: "list_input_modes" | "estimate_cost" | "validate_request";
17
17
  params?: Record<string, unknown> | undefined;
18
18
  }>;
@@ -1,10 +1,10 @@
1
1
  import { z } from 'zod';
2
2
  export const runVideoFunctionTool = {
3
3
  name: 'run_video_function',
4
- description: 'Run a read-only Veo helper function before generation: list_input_modes, estimate_cost, or validate_request. This does not generate video or spend credits.',
4
+ description: 'Run a read-only Google Veo or xAI Grok video helper function before generation: list_input_modes, estimate_cost, or validate_request. This does not generate video or spend credits.',
5
5
  inputSchema: z.object({
6
6
  identifier: z
7
- .enum(['google_veo', 'veo3'])
7
+ .enum(['google_veo', 'veo3', 'xai_grok', 'grok_imagine'])
8
8
  .describe('Video generator identifier from get_video_options.'),
9
9
  functionName: z
10
10
  .enum(['list_input_modes', 'estimate_cost', 'validate_request'])
@@ -12,7 +12,7 @@ export const runVideoFunctionTool = {
12
12
  params: z
13
13
  .record(z.unknown())
14
14
  .optional()
15
- .describe('Function parameters. estimate_cost accepts model, duration_seconds, resolution, and output. validate_request accepts a generate_video-style payload.'),
15
+ .describe('Function parameters. estimate_cost accepts model, duration_seconds, resolution, output, and xAI input_image_count. validate_request accepts a generate_video-style payload.'),
16
16
  }),
17
17
  async execute(client, input) {
18
18
  const result = await client.runVideoFunction(input);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "posterly-mcp-server",
3
- "version": "0.34.0",
3
+ "version": "0.35.0",
4
4
  "mcpName": "io.github.awpthorp/posterly",
5
5
  "description": "MCP server for posterly: schedule and publish social media posts across 18 platforms from any MCP client (Claude, ChatGPT, Cursor, Windsurf, Cline, and more)",
6
6
  "license": "MIT",
package/server.json CHANGED
@@ -3,7 +3,7 @@
3
3
  "name": "io.github.awpthorp/posterly",
4
4
  "title": "posterly",
5
5
  "description": "Validate, schedule, publish, and analyze social content across 18 platforms with posterly.",
6
- "version": "0.34.0",
6
+ "version": "0.35.0",
7
7
  "websiteUrl": "https://www.poster.ly/mcp",
8
8
  "repository": {
9
9
  "url": "https://github.com/awpthorp/posterly",
@@ -14,7 +14,7 @@
14
14
  {
15
15
  "registryType": "npm",
16
16
  "identifier": "posterly-mcp-server",
17
- "version": "0.34.0",
17
+ "version": "0.35.0",
18
18
  "transport": {
19
19
  "type": "stdio"
20
20
  },
@@ -841,6 +841,7 @@ export interface PublicSignupSessionResponse {
841
841
  export interface VideoJob {
842
842
  id: string;
843
843
  status: string;
844
+ provider: 'google' | 'xai';
844
845
  prompt: string;
845
846
  model: string;
846
847
  duration_seconds: number;
@@ -1309,12 +1310,15 @@ export class PosterlyClient {
1309
1310
  aspect_ratio?: string;
1310
1311
  style?: string;
1311
1312
  variations?: number;
1313
+ provider?: 'google' | 'xai';
1312
1314
  model?: 'lite' | 'flash' | 'pro';
1313
1315
  resolution?: '512' | '1K' | '2K' | '4K';
1316
+ quality?: 'low' | 'medium';
1314
1317
  }): Promise<{
1315
1318
  urls: string[];
1316
1319
  images: Array<{ url: string; filename: string; path: string }>;
1317
1320
  model: string;
1321
+ provider: 'google' | 'xai';
1318
1322
  credits_used: number;
1319
1323
  warnings?: string[];
1320
1324
  usage: {
@@ -1341,11 +1345,12 @@ export class PosterlyClient {
1341
1345
  }
1342
1346
 
1343
1347
  async generateVideo(data: {
1348
+ provider?: 'google' | 'xai';
1344
1349
  prompt: string;
1345
1350
  negative_prompt?: string;
1346
- aspect_ratio?: '16:9' | '9:16';
1347
- duration_seconds?: 4 | 6 | 8;
1348
- resolution?: '720p' | '1080p';
1351
+ aspect_ratio?: '1:1' | '16:9' | '9:16' | '4:3' | '3:4' | '3:2' | '2:3';
1352
+ duration_seconds?: number;
1353
+ resolution?: '480p' | '720p' | '1080p';
1349
1354
  model?: 'lite' | 'fast' | 'standard';
1350
1355
  image_url?: string;
1351
1356
  end_image_url?: string;
@@ -5,4 +5,4 @@
5
5
  // tool set (minus the intentional pre-auth signup tools that only this stdio
6
6
  // package exposes). `npm run check:mcp-parity` enforces both the version match
7
7
  // and the tool-list match, and runs in the pre-commit hook.
8
- export const POSTERLY_MCP_VERSION = '0.34.0';
8
+ export const POSTERLY_MCP_VERSION = '0.35.0';
@@ -5,7 +5,7 @@ import { mdBullets, mdKeyValue, mdSection, mdTable, mdTitle } from '../lib/forma
5
5
  export const generateImageTool = {
6
6
  name: 'generate_image',
7
7
  description:
8
- 'Generate an AI image via Posterly\'s Nano Banana (Gemini) integration. The image is saved to the user\'s media storage and the returned URL can be passed to `create_post` as `media_url`.\n\n' +
8
+ 'Generate an AI image via Posterly using Nano Banana (Gemini) or Grok Imagine Image 2.0 (xAI). The image is saved to the user\'s media storage and the returned URL can be passed to `create_post` as `media_url`.\n\n' +
9
9
  'COSTS CREDITS. Every call consumes part of the user\'s monthly AI image quota (or purchased credits once the quota is exhausted). Do NOT call speculatively - always describe the image you\'re about to generate (subject, style, aspect ratio) to the user and get confirmation before calling.\n\n' +
10
10
  'If the user is over their plan limit and has no credits, this tool returns a 402 with upgrade info. Surface that message verbatim - do not retry.\n\n' +
11
11
  'Common aspect ratios by platform:\n' +
@@ -40,14 +40,22 @@ export const generateImageTool = {
40
40
  .max(4)
41
41
  .optional()
42
42
  .describe('How many variations to generate. Default 1. Each variation costs credits separately - prefer 1 unless the user explicitly wants options.'),
43
+ provider: z
44
+ .enum(['google', 'xai'])
45
+ .optional()
46
+ .describe('Image provider. Default google. Use xai for Grok Imagine Image 2.0.'),
43
47
  model: z
44
48
  .enum(['lite', 'flash', 'pro'])
45
49
  .optional()
46
- .describe('lite (8 credits, 1K only) is the cheapest and suits drafts and exploration. flash (default, 15 credits at 1K) balances quality and cost. pro (30 credits at 1K) is highest quality for hero imagery. Start with lite or flash unless quality is critical.'),
50
+ .describe('Google-only. lite (8 credits, 1K only) suits drafts; flash (default, 15 at 1K) balances quality and cost; pro (30 at 1K) is highest quality. Ignored for xAI.'),
47
51
  resolution: z
48
52
  .enum(['512', '1K', '2K', '4K'])
49
53
  .optional()
50
- .describe('Output resolution. Default 1K. Higher resolutions cost more credits (flash: 10/15/23/35 for 512/1K/2K/4K; pro: 30 at 1K-2K, 55 at 4K). 512 is flash-only and lite supports 1K only.'),
54
+ .describe('Output resolution. Default 1K. xAI supports 1K/2K only. Google flash: 10/15/23/35 credits at 512/1K/2K/4K; pro: 30 at 1K-2K, 55 at 4K.'),
55
+ quality: z
56
+ .enum(['low', 'medium'])
57
+ .optional()
58
+ .describe('xAI only. Low costs 9/14 credits at 1K/2K; medium (default) costs 14/18 credits and gives better quality.'),
51
59
  confirm: z.literal(true).describe('Must be true after explicit user confirmation of subject, style, aspect ratio, and credit use.'),
52
60
  }),
53
61
 
@@ -58,8 +66,10 @@ export const generateImageTool = {
58
66
  aspect_ratio?: string;
59
67
  style?: string;
60
68
  variations?: number;
69
+ provider?: 'google' | 'xai';
61
70
  model?: 'lite' | 'flash' | 'pro';
62
71
  resolution?: '512' | '1K' | '2K' | '4K';
72
+ quality?: 'low' | 'medium';
63
73
  confirm: true;
64
74
  }
65
75
  ) {
@@ -4,13 +4,14 @@ import type { PosterlyClient } from '../lib/api-client.js';
4
4
  export const generateVideoTool = {
5
5
  name: 'generate_video',
6
6
  description:
7
- 'Queue a Veo AI video generation job. COSTS VEO CREDITS: confirm prompt, model, duration, resolution, aspect ratio, audio choice, and credit cost with the user before calling. Models cost 12 (lite), 35 (fast) or 90 (standard) credits per second; lite supports text-to-video and image-to-video only, not reference_images or source_video_url. Poll get_video_job for status and final video_url.',
7
+ 'Queue an AI video generation job with Google Veo 3.1 or xAI Grok Imagine Video 1.5. COSTS CREDITS: confirm provider, prompt, duration, resolution, aspect ratio, audio choice, and credit cost with the user before calling. Grok supports 1–15 seconds and 480p–1080p; reference-to-video is capped at 720p. Poll get_video_job for status and final video_url.',
8
8
  inputSchema: z.object({
9
+ provider: z.enum(['google', 'xai']).default('google').optional(),
9
10
  prompt: z.string().min(5).max(1024),
10
11
  negative_prompt: z.string().max(500).optional(),
11
- aspect_ratio: z.enum(['16:9', '9:16']).default('16:9').optional(),
12
- duration_seconds: z.union([z.literal(4), z.literal(6), z.literal(8)]).default(8).optional(),
13
- resolution: z.enum(['720p', '1080p']).default('720p').optional(),
12
+ aspect_ratio: z.enum(['1:1', '16:9', '9:16', '4:3', '3:4', '3:2', '2:3']).default('16:9').optional(),
13
+ duration_seconds: z.number().int().min(1).max(15).default(8).optional(),
14
+ resolution: z.enum(['480p', '720p', '1080p']).default('720p').optional(),
14
15
  model: z.enum(['lite', 'fast', 'standard']).default('fast').optional(),
15
16
  image_url: z.string().url().optional(),
16
17
  end_image_url: z.string().url().optional(),
@@ -18,7 +19,7 @@ export const generateVideoTool = {
18
19
  url: z.string().url(),
19
20
  type: z.enum(['character', 'object', 'scene']),
20
21
  })).max(3).optional(),
21
- generate_audio: z.boolean().default(true).optional(),
22
+ generate_audio: z.boolean().default(true).optional().describe('Google can disable generated audio. xAI Grok includes audio and requires this to remain true.'),
22
23
  source_video_url: z.string().url().optional(),
23
24
  confirm: z.literal(true).describe('Must be true after explicit user confirmation of prompt, model, duration, resolution, and credit cost.'),
24
25
  }),
@@ -4,10 +4,10 @@ import type { PosterlyClient } from '../lib/api-client.js';
4
4
  export const runVideoFunctionTool = {
5
5
  name: 'run_video_function',
6
6
  description:
7
- 'Run a read-only Veo helper function before generation: list_input_modes, estimate_cost, or validate_request. This does not generate video or spend credits.',
7
+ 'Run a read-only Google Veo or xAI Grok video helper function before generation: list_input_modes, estimate_cost, or validate_request. This does not generate video or spend credits.',
8
8
  inputSchema: z.object({
9
9
  identifier: z
10
- .enum(['google_veo', 'veo3'])
10
+ .enum(['google_veo', 'veo3', 'xai_grok', 'grok_imagine'])
11
11
  .describe('Video generator identifier from get_video_options.'),
12
12
  functionName: z
13
13
  .enum(['list_input_modes', 'estimate_cost', 'validate_request'])
@@ -15,7 +15,7 @@ export const runVideoFunctionTool = {
15
15
  params: z
16
16
  .record(z.unknown())
17
17
  .optional()
18
- .describe('Function parameters. estimate_cost accepts model, duration_seconds, resolution, and output. validate_request accepts a generate_video-style payload.'),
18
+ .describe('Function parameters. estimate_cost accepts model, duration_seconds, resolution, output, and xAI input_image_count. validate_request accepts a generate_video-style payload.'),
19
19
  }),
20
20
 
21
21
  async execute(