Skip to content

MCP OData Connect

Connect your AIs directly to Mercado Eletrônico's OData Connect. Procurement queries, order tracking, and financial analysis in natural language — for Genius sub-agents and external tools like Claude and Cursor.


MCP OData Connect exposes Mercado Eletrônico's OData Connect tools via the Model Context Protocol (MCP). AI agents can query purchase requests, orders, quotations, contracts, invoices, and other entities using natural language, without building OData calls manually.

  • 16 tools available
  • 8 domains covered
  • 50+ OData entities
  • Authentication with dynamic tokens

How to connect

Choose the agent type below and use the indicated configuration. Client ID and Client Secret are the Key and Secret you get from the Partner's portal when you create an API Key (the same credentials used for our APIs). See Credentials to create and manage your keys.

Genius sub-agents (ME platform)

For agents that run inside the Mercado Eletrônico platform (native sub-agents):

  • Protocol: HTTP · /mcp
  • Server URL: https://mcp.mercadoe.rocks/mcp
  • Authentication: Automatic header forwarding

Configure on the Mercado Eletrônico platform in the MCP fields:

FieldValue
Serverhttps://mcp.mercadoe.rocks/mcp
AuthenticationAutomatic header forwarding

Claude Desktop

In Claude Desktop (and other SSE connections), edit the MCP config file (on Windows: %APPDATA%\Claude\claude_desktop_config.json; on macOS: ~/Library/Application Support/Claude/claude_desktop_config.json). Add the server with the SSE URL and required headers: credentials and environment (x-odata-env). Example:

json
{
  "mcp_servers": {
    "me-odata": {
      "url": "https://mcp.mercadoe.rocks/mcp/sse",
      "headers": {
        "x-client-id": "YOUR_KEY",
        "x-client-secret": "YOUR_SECRET",
        "x-odata-env": "prod"
      }
    }
  }
}

Replace YOUR_KEY and YOUR_SECRET with your Client ID (Key) and Client Secret (Secret) from the Partner's portal. The x-odata-env header is required for SSE connections (Claude Desktop and similar); choose one of: trunk, stg, prod. Restart Claude Desktop after changing the file.

cURL / HTTP (testing)

To test the HTTP endpoint directly (e.g. with cURL), use the base URL and send the authentication headers and environment (x-odata-env):

bash
curl -X POST "https://mcp.mercadoe.rocks/mcp" \
  -H "x-client-id: YOUR_KEY" \
  -H "x-client-secret: YOUR_SECRET" \
  -H "x-odata-env: prod" \
  -H "Content-Type: application/json" \
  -d '{"method":"tools/list"}'

Replace YOUR_KEY, YOUR_SECRET, and the x-odata-env value (e.g. prod, trunk, stg) as needed.

Authentication

Two mechanisms are available, depending on the agent context.

MechanismHeadersUsage
Highest priorityx-access-tokenUser JWT token (obtained via platform/Genius)
External agent modex-client-id + x-client-secretGenerates token automatically (Claude, Cursor, etc.)
Required (SSE/external)x-odata-envOData environment. Must be sent for Claude Desktop and SSE connections. Values: trunk, stg, prod

📘 Note

In external agent mode, Client ID = Key and Client Secret = Secret — the same values you get from the Partner's portal when you create an API Key (and use for our APIs). Use the Key in the x-client-id header and the Secret in the x-client-secret header. For SSE connections (Claude Desktop and similar), the x-odata-env header is required.

Available tools

All OData Connect tools from Mercado Eletrônico are available via natural language:

ToolDescription
query_odataUniversal query on any OData entity with advanced filters
get_requestsPurchase requests with status tracking
get_ordersPurchase orders with lifecycle analysis
get_procurement_flowFull flow tracking: Request → RFQ → Order → Invoice
get_order_detail360° order view: items, deliveries and borgs in one call
get_request_detailFull request with approvers and cost objects
get_request_items_trackingReal delivery forecast combining RFQs and logistics
get_invoicesInvoices for financial reconciliation
get_contractsContracts with balance, links and approvals
get_productsProduct catalog with description search
get_rfqsQuotations and supplier responses
global_searchCross-domain search for any ID across multiple domains

For details on the data exposed via OData, see the OData feed and Schemas.


Playground

Test the connection to the MCP server: List tools does not require credentials; to Call a tool, fill in Key and Secret from the Partner's portal.

Listar tools

Clique para ver as tools disponíveis.

A resposta aparecerá aqui ao listar tools ou chamar uma tool.