@clipform/mcp-server 1.36.0 → 1.37.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
@@ -75,7 +75,7 @@ You can also pass the key as a CLI flag: `npx -y @clipform/mcp-server --api-key=
75
75
 
76
76
  | Tool | Description |
77
77
  |------|-------------|
78
- | `clipform_upload_node_media` | Attach video or image to one or more nodes (batch, max 10) |
78
+ | `clipform_upload_node_media` | Attach video or image to one or more nodes (batch, max 10); set `fit_media: true` for generated renders |
79
79
  | `clipform_get_node_media` | View a node's media details |
80
80
  | `clipform_delete_node_media` | Remove media from a node (asks the user to confirm) |
81
81
  | `clipform_attach_audio` | Attach audio to a still-image node |
@@ -6,14 +6,14 @@ import {
6
6
  getWorkflowText,
7
7
  objectType,
8
8
  registerPrompts
9
- } from "./chunk-6MLZZSNM.js";
9
+ } from "./chunk-XOYZMNJD.js";
10
10
  import {
11
11
  GUIDE_TYPES,
12
12
  QUIZ_VARIANTS,
13
13
  getGuideContent,
14
14
  getGuideUri,
15
15
  registerResources
16
- } from "./chunk-2AJMWM5W.js";
16
+ } from "./chunk-AZ33QQ4H.js";
17
17
  import {
18
18
  BUSINESS,
19
19
  CONTACT_FIELDS,
@@ -29,7 +29,7 @@ import {
29
29
  errorResult,
30
30
  resolveFormType,
31
31
  textResult
32
- } from "./chunk-BYJMRIB6.js";
32
+ } from "./chunk-UA3MYEUA.js";
33
33
  import {
34
34
  __commonJS,
35
35
  __export,
@@ -16983,8 +16983,7 @@ var _endScreen = NODE_TYPES.end_screen.config_schema.properties;
16983
16983
  var END_SCREEN_ICONS = _endScreen.icon.enum;
16984
16984
  var END_SCREEN_CTA_TYPES = _endScreen.cta_type.enum;
16985
16985
  var PUBLIC_COMPOSITIONS = [
16986
- "GlobeToCity",
16987
- "CityToGlobe",
16986
+ "Map",
16988
16987
  "MapPin",
16989
16988
  "Grid",
16990
16989
  "GridList",
@@ -17782,7 +17781,8 @@ var MediaItemSchema = external_exports.object({
17782
17781
  ).optional().describe("Per-word timestamps within the segment")
17783
17782
  })
17784
17783
  ).optional().describe("Word-level captions from clipform_generate_tts. Required for per-word highlighting - pass the full objects including 'words' arrays."),
17785
- show_captions: external_exports.boolean().optional().default(true).describe("Display captions/subtitles on the node")
17784
+ show_captions: external_exports.boolean().optional().default(true).describe("Display captions/subtitles on the node"),
17785
+ fit_media: external_exports.boolean().optional().describe("Show the whole frame (contain) instead of cover-cropping. ALWAYS set true when attaching renders from clipform_render_composition or clipform_generate_video - they are composed 9:16 frames that must never be cropped. Leave unset for user-supplied media (arbitrary aspect ratios want the cover default).")
17786
17786
  });
17787
17787
  function registerUploadNodeMediaTool(server) {
17788
17788
  server.registerTool(
@@ -17791,7 +17791,7 @@ function registerUploadNodeMediaTool(server) {
17791
17791
  title: "Upload Node Media",
17792
17792
  description: `Upload media for one or more nodes. Pass one item or many (max 10). Multiple items upload sequentially.
17793
17793
 
17794
- When a public URL is provided, the media is fetched and stored automatically. Only works on node types that support media (${MEDIA_SUPPORTED_TYPES.join(", ")}). For video: ingested via Mux. For image: stored in Supabase. Captions from clipform_generate_tts enable per-word highlighting in the viewer.`,
17794
+ When a public URL is provided, the media is fetched and stored automatically. Only works on node types that support media (${MEDIA_SUPPORTED_TYPES.join(", ")}). For video: ingested via Mux. For image: stored in Supabase. Captions from clipform_generate_tts enable per-word highlighting in the viewer. When attaching renders from clipform_render_composition or clipform_generate_video, set fit_media: true on each item.`,
17795
17795
  inputSchema: {
17796
17796
  form_id: external_exports.string().uuid().describe("The form UUID (returned by clipform_create_form, not the short share_id from the URL)"),
17797
17797
  items: external_exports.array(MediaItemSchema).min(1).max(10).describe("One or more media items to upload")
@@ -17816,6 +17816,7 @@ When a public URL is provided, the media is fetched and stored automatically. On
17816
17816
  if (item.url) body.url = item.url;
17817
17817
  if (item.captions) body.captions = item.captions;
17818
17818
  if (item.show_captions !== void 0) body.show_captions = item.show_captions;
17819
+ if (item.fit_media !== void 0) body.fit_media = item.fit_media;
17819
17820
  const result = await callApi(
17820
17821
  `/forms/${form_id}/nodes/${item.node_id}/media`,
17821
17822
  { method: "POST", body }
@@ -18380,7 +18381,7 @@ For multi-render builds (e.g. composition quizzes with a clue + reveal clip per
18380
18381
  inputSchema: {
18381
18382
  compositionId: external_exports.string().describe(`The composition ID. Call clipform_list_compositions to see available options (e.g. ${EXPOSED_COMPOSITIONS.map((id) => `'${id}'`).join(", ")})`),
18382
18383
  outputFormat: external_exports.enum(["mp4", "png"]).default("mp4").describe("Output format (default: mp4)"),
18383
- inputProps: external_exports.record(external_exports.unknown()).optional().describe("Props object matching the composition's schema from clipform_list_compositions. Validated STRICTLY - unknown or missing props fail with the schema in the error, nothing renders silently with defaults. For map compositions (GlobeToCity, CityToGlobe), round lat/lng to 1 decimal place (e.g. 48.9 instead of 48.8566) \u2014 this improves cache hit rates."),
18384
+ inputProps: external_exports.record(external_exports.unknown()).optional().describe("Props object matching the composition's schema from clipform_list_compositions. Validated STRICTLY - unknown or missing props fail with the schema in the error, nothing renders silently with defaults. For map compositions (Map), round lat/lng to 1 decimal place (e.g. 48.9 instead of 48.8566) \u2014 this improves cache hit rates."),
18384
18385
  wait: external_exports.boolean().optional().default(true).describe("true (default) blocks until the render is ready and returns its URL. false returns a job ID immediately - fire all renders first, then poll clipform_check_render. Use false whenever rendering more than one clip.")
18385
18386
  },
18386
18387
  annotations: { readOnlyHint: false, destructiveHint: false, idempotentHint: false, openWorldHint: false }
@@ -18416,7 +18417,10 @@ For multi-render builds (e.g. composition quizzes with a clue + reveal clip per
18416
18417
  if (!result.ok) return errorResult(result.error);
18417
18418
  const data = result.data;
18418
18419
  return textResult(
18419
- `Render complete. Public URL: ${data.public_url}`
18420
+ [
18421
+ `Render complete. Public URL: ${data.public_url}`,
18422
+ `Attach via clipform_upload_node_media with fit_media: true (composed 9:16 frame - contain, never crop).`
18423
+ ].join("\n")
18420
18424
  );
18421
18425
  }
18422
18426
  );
@@ -18639,7 +18643,8 @@ For multi-question builds, pass wait: false on every render: each call returns a
18639
18643
  [
18640
18644
  `Video rendered (${items.length} item${items.length > 1 ? "s" : ""}).`,
18641
18645
  `Public URL: ${data.public_url}`,
18642
- data.duration_seconds ? `Duration: ${data.duration_seconds}s` : ""
18646
+ data.duration_seconds ? `Duration: ${data.duration_seconds}s` : "",
18647
+ `Attach via clipform_upload_node_media with fit_media: true (composed 9:16 frame - contain, never crop).`
18643
18648
  ].filter(Boolean).join("\n")
18644
18649
  );
18645
18650
  }
@@ -18685,7 +18690,8 @@ Returns the current status and, when complete, the output URL. Typical render ti
18685
18690
  [
18686
18691
  `Render complete.`,
18687
18692
  ...data.public_url ? [`Public URL: ${data.public_url}`] : [],
18688
- ...data.duration_seconds ? [`Duration: ${data.duration_seconds}s`] : []
18693
+ ...data.duration_seconds ? [`Duration: ${data.duration_seconds}s`] : [],
18694
+ `Attach via clipform_upload_node_media with fit_media: true (composed 9:16 frame - contain, never crop).`
18689
18695
  ].join("\n")
18690
18696
  );
18691
18697
  }
@@ -18718,7 +18724,7 @@ function registerFetchBoundaryTool(server) {
18718
18724
  "clipform_fetch_boundary",
18719
18725
  {
18720
18726
  title: "Fetch Geographic Boundary",
18721
- description: `Fetch a GeoJSON boundary polygon for a country, city, or region. Returns simplified GeoJSON ready to use as the 'boundary' prop in GlobeToCity/CityToGlobe compositions.
18727
+ description: `Fetch a GeoJSON boundary polygon for a country, city, or region. Returns simplified GeoJSON ready to use as the 'boundary' prop in the Map composition.
18722
18728
 
18723
18729
  mainlandOnly excludes small islands and overseas territories (e.g. Corsica for France, Hawaii for USA).`,
18724
18730
  inputSchema: {
@@ -18793,7 +18799,7 @@ mainlandOnly excludes small islands and overseas territories (e.g. Corsica for F
18793
18799
  `Size: ${sizeKb} KB`,
18794
18800
  mainlandOnly ? `Mainland filter: applied (islands < 5% of largest landmass removed)` : `Mainland filter: off`,
18795
18801
  ``,
18796
- `Use this as the boundary.geojson prop in GlobeToCity:`,
18802
+ `Use this as the boundary.geojson prop in Map:`,
18797
18803
  ``,
18798
18804
  "```json",
18799
18805
  geojsonStr,
@@ -18998,4 +19004,4 @@ export {
18998
19004
  JSONRPCMessageSchema,
18999
19005
  createServer
19000
19006
  };
19001
- //# sourceMappingURL=chunk-CN4XBVFD.js.map
19007
+ //# sourceMappingURL=chunk-5L2KPKOE.js.map