Skip to main content
Glama
lumile

MercadoLibre MCP Server

by lumile

product_description

Retrieve product descriptions from MercadoLibre using product IDs to display detailed item information for listings or research.

Instructions

Obtiene la descripción de un producto

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
productIdNoID del producto

Implementation Reference

  • The handler case in callTool method for the 'product_description' tool. Extracts productId from args, calls apiService.productDescription, and returns the result as JSON text content.
    case 'product_description': { const { productId } = args as { productId: string } const description = await this.apiService.productDescription(productId) return { content: [{ type: 'text', text: JSON.stringify(description, null, 2) }] } }
  • Registration of the 'product_description' tool in the listTools method, including name, description, and input schema.
    { name: 'product_description', description: 'Obtiene la descripción de un producto', inputSchema: { type: 'object', properties: { productId: { type: 'string', description: 'ID del producto' } } } }
  • Input schema definition for the 'product_description' tool, requiring a productId string.
    { name: 'product_description', description: 'Obtiene la descripción de un producto', inputSchema: { type: 'object', properties: { productId: { type: 'string', description: 'ID del producto' } } } }
  • Helper method in ApiService that fetches the product description from the MercadoLibre API endpoint.
    async productDescription (productId: string) { const headers = await this.getHeaders() const response = await fetch(`${this.baseURL}items/${productId}/description`, { headers }) if (!response.ok) { throw new Error(`HTTP error! status: ${response.status}`) } const data = await response.json() return data }

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/lumile/mercadolibre-mcp'

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