Unbnd logoUnbnd

Function Calling

Use the same tools as MCP in OpenAI-compatible format for chat completions. This server exposes all registered tools (holiday, fuel, exchange-rate, etc.).

The same tools as MCP are exposed in OpenAI-compatible format. Send the tools list to an LLM so it can return tool_calls; your gateway then executes them (e.g. via POST /api/mcp).

Endpoints

GET/api/function-calling/tools

Returns all tools as { tools: [...] } in OpenAI Chat Completions format.

GET/api/function-calling/[category]/tools

Returns only tools for one category. [category]: dns, holiday, fuel-price, geo, exchange-rate, movies, weather, finance, prices, proxy-rule . Use when the caller needs a subset of tools.

POST/api/function-calling/chat

Body: { messages, model? }. Requires OPENAI_API_KEY. The server sends messages + tools to OpenAI, runs tool_calls via MCP tools, and returns the final reply.

Playground

Send requests and view responses.

RequestGET /api/function-calling/tools
Response
Click "Fetch tools" to load the OpenAI-compatible tools list.