Tool call
Also called function calling or tool use
A request from an AI model to run a named action, such as reading a file, searching, or running a command, whose result goes back to the model.
{
"name": "read_file",
"description": "Read a text file from the project.",
"inputSchema": {
"type": "object",
"properties": {
"path": {
"type": "string",
"description": "Path relative to the project root"
}
},
"required": ["path"]
}
}Add a support assistant to my app that can call two tools: search_orders(query) and get_order(id). Show each tool call in the chat as a collapsible card with its input and result, and never let the assistant state order details that did not come from a tool result.
Paste into Layerwise or any AI coding tool.
What is Tool call?
A model on its own only produces text. A tool call is how it acts: it asks the app to run a named tool with specific inputs, such as read_file with a path or run_command with npm test. The app runs it, sends back the result, and the model decides what to do next.
AI coding tools show tool calls as steps in the conversation, often as cards you can expand to see the exact input and output. Reading them is the quickest way to see what the AI actually did and why it reached its answer.
The app decides which tools exist, and MCP servers can add more. Each tool is described by a name, a description, and a JSON Schema for its inputs, like the MCP-style example below. Many apps ask for your approval before risky calls, such as edits outside the project.
Related terms
All termsAI agent
An AI model that works toward a goal on its own by planning, using tools, checking the results, and repeating until the task is done.
MCP
The Model Context Protocol: an open standard that connects AI apps to outside tools and data, such as files, databases, and design apps.
API
A set of rules that lets one program ask another for data or actions, usually by sending a request to a URL and getting JSON back.
Vibe coding
A way of building software by describing what you want to an AI model and steering the result in conversation, without writing the code yourself.
Build it with Layerwise
Describe your app, watch it run in a live preview, and publish it with a database, storage, and sign-in built in.