cicora.ai
API specificationFunction calling

Tools and function calling

Describe functions with JSON Schema, execute the call in your application, and return the result to the conversation.

Integration reference: choose parameters and available capabilities from your account API settings and the model catalogue for your environment.

Describe a function contract

A tool contains a name, a clear description, and a JSON Schema for parameters. The description says when the tool should be selected, while the schema constrains arguments.

The model proposes a call; it does not gain access to your network, database, or files by itself.

Function tool in a chat request
json
{
  "model": "openai/gpt-5.6-sol",
  "messages": [{"role": "user", "content": "What is the weather in Tashkent?"}],
  "tools": [{
    "type": "function",
    "function": {
      "name": "get_weather",
      "description": "Read current weather for a city.",
      "parameters": {
        "type": "object",
        "properties": {"city": {"type": "string"}},
        "required": ["city"],
        "additionalProperties": false
      }
    }
  }],
  "tool_choice": "auto"
}

Execute on your side

  • Check the tool name against an allowlist.
  • Validate arguments against the schema before calling an internal service.
  • Apply your own authorization, timeouts, and idempotency to the tool action.

Return the result

Add a tool message with the tool_call_id and a compact serialized result, then continue the conversation with the same context.

Keep a tool execution failure distinct from a model failure: return a structured reason the model can explain to the user.