Skip to main content
Glama

create-text-item

Add text content to a Miro board by specifying position, style, and dimensions for visual collaboration.

Instructions

Create a new text item on a Miro board

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
boardIdYesUnique identifier (ID) of the board where the text will be created
dataYesThe content of the text item
positionYesPosition of the text item on the board
geometryNoDimensions of the text item
styleNoStyle configuration of the text item

Implementation Reference

  • The handler function that implements the logic to create a text item on a Miro board using the Miro API client.
    fn: async ({ boardId, data, position, geometry, style }) => { try { if (!boardId) { return ServerResponse.error("Board ID is required"); } const createRequest = new TextCreateRequest(); const textData = new TextData(); textData.content = data.content; createRequest.data = textData; createRequest.position = position; if (geometry) { createRequest.geometry = geometry; } if (style) { createRequest.style = style; } const result = await MiroClient.getApi().createTextItem(boardId, createRequest); return ServerResponse.text(JSON.stringify(result, null, 2)); } catch (error) { return ServerResponse.error(error); } }
  • Zod-based input schema defining parameters for the create-text-item tool: boardId, data.content, position, optional geometry.width, and style properties.
    args: { boardId: z.string().describe("Unique identifier (ID) of the board where the text will be created"), data: z.object({ content: z.string().describe("Text content of the text item") }).describe("The content of the text item"), position: z.object({ x: z.number().describe("X coordinate of the text item"), y: z.number().describe("Y coordinate of the text item") }).describe("Position of the text item on the board"), geometry: z.object({ width: z.number().optional().nullish().describe("Width of the text item") }).optional().nullish().describe("Dimensions of the text item"), style: z.object({ color: z.string().optional().nullish().describe("Color of the text"), fontSize: z.number().optional().nullish().describe("Font size of the text"), textAlign: z.string().optional().nullish().describe("Alignment of the text (left, center, right)") }).optional().nullish().describe("Style configuration of the text item") },
  • src/index.ts:146-146 (registration)
    Registers the createTextItemTool (create-text-item) with the ToolBootstrapper instance in the main index file.
    .register(createTextItemTool)
Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/k-jarzyna/mcp-miro'

If you have feedback or need assistance with the MCP directory API, please join our Discord server