Skip to main content
Glama

get_image

Retrieve metadata and details of a previously generated image by providing its unique ID from RendrKit's AI-powered design API.

Instructions

Get details of a previously generated image

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
idYesThe image ID

Implementation Reference

  • Registers the 'get_image' MCP tool. Takes an image ID, calls client.getImage(), and returns formatted image details (URL, ID, size, style, prompt, brand kit, creation date).
    export function registerGetImageTool(
      server: McpServer,
      client: RendrKitClient,
    ): void {
      server.registerTool(
        "get_image",
        {
          description: "Get details of a previously generated image",
          inputSchema: {
            id: z.string().describe("The image ID"),
          },
        },
        async ({ id }) => {
          try {
            const image = await client.getImage(id);
    
            return {
              content: [
                {
                  type: "text" as const,
                  text: [
                    `Image Details`,
                    ``,
                    `URL: ${image.url}`,
                    `ID: ${image.id}`,
                    `Size: ${image.width}x${image.height}`,
                    `Style: ${image.style}`,
                    `Prompt: ${image.prompt}`,
                    image.brandKitId
                      ? `Brand Kit: ${image.brandKitId}`
                      : null,
                    `Created: ${image.createdAt}`,
                  ]
                    .filter(Boolean)
                    .join("\n"),
                },
              ],
            };
          } catch (error) {
            const message =
              error instanceof Error ? error.message : String(error);
            return {
              content: [
                {
                  type: "text" as const,
                  text: `Failed to get image: ${message}`,
                },
              ],
              isError: true,
            };
          }
        },
      );
    }
  • ImageDetails type definition - the response schema returned by the get-image tool, containing id, url, width, height, prompt, style, optional brandKitId, and createdAt.
    export interface ImageDetails {
      id: string;
      url: string;
      width: number;
      height: number;
      prompt: string;
      style: string;
      brandKitId?: string;
      createdAt: string;
    }
  • API client method that performs the actual HTTP GET request to /api/v1/images/{id} to retrieve image details.
    async getImage(id: string): Promise<ImageDetails> {
      return this.request<ImageDetails>("GET", `/api/v1/images/${id}`);
    }
  • src/server.ts:4-28 (registration)
    Import and registration call for the get_image tool in the main server setup.
    import { registerGetImageTool } from "./tools/get-image.js";
    import { registerListBrandKitsTool } from "./tools/list-brand-kits.js";
    import { registerGetUsageTool } from "./tools/get-usage.js";
    import { registerListTemplatesTool } from "./tools/list-templates.js";
    import { registerUploadImageTool } from "./tools/upload-image.js";
    import { registerBatchRenderTool } from "./tools/batch-render.js";
    import { registerCloneTemplateTool } from "./tools/clone-template.js";
    
    export function createServer(client: RendrKitClient): McpServer {
      const server = new McpServer({
        name: "rendrkit",
        version: "0.3.0",
      });
    
      registerGenerateImageTool(server, client);
      registerGetImageTool(server, client);
      registerListBrandKitsTool(server, client);
      registerGetUsageTool(server, client);
      registerListTemplatesTool(server, client);
      registerUploadImageTool(server, client);
      registerBatchRenderTool(server, client);
      registerCloneTemplateTool(server, client);
    
      return server;
    }
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations provided, so description carries full burden. It states 'Get details' implying read-only, but fails to disclose what details are returned (metadata vs image bytes), auth requirements, or error handling. Minimal transparency beyond the read hint.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Single sentence with no extraneous words. Front-loaded with verb and resource. Every word earns its place.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a simple retrieval tool with one parameter, the description is minimally adequate. However, no output schema means the agent has no idea what 'details' includes. Missing info on error cases or expected response structure.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100% for the single parameter, which is described as 'The image ID' in the schema. The description adds no additional meaning beyond what the schema already provides, so it meets the baseline without adding value.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

Description clearly states verb 'Get' and resource 'details of a previously generated image'. It distinguishes from siblings like generate_image (create) and upload_image (upload), making its purpose unambiguous.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Description implies usage when you have an image ID and need its details, but provides no explicit guidance on when to use this tool versus alternatives like list_templates or batch_render. No when-not scenarios or prerequisites are mentioned.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

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/vbiff/rendr-kit'

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