# Chapter 12: Integrations

Part of the course “AI from Zero to Autonomous Agents” (https://llm.yoga/en). Page for humans: https://llm.yoga/en/12-integrationen

*The model only writes text. How that turns into weather lookups, calendar entries and whole workflows: APIs, tool use, structured output, MCP, n8n and A2A.*

About 40 min to read · about 20 min hands-on exercise

**Start with the missions**

This chapter also comes as 3 short missions with a case, a decision and feedback, about 10 minutes each:

- [12.1 Does the model check the weather itself?](https://llm.yoga/en/einsatz-12-1.md)
- [12.2 We need guaranteed JSON](https://llm.yoga/en/einsatz-12-2.md)
- [12.3 MCP, n8n or a direct call for the CRM note?](https://llm.yoga/en/einsatz-12-3.md)

For agents, this page is split into 6 parts so that each part can be fetched in full. Read the parts the question needs.

## Parts

### Part 1: https://llm.yoga/en/12-integrationen-1.md

- **Getting started**: Picture a very well-read expert sitting in a room with no phone and no internet.
- **API basics: a letter over HTTP**: An API (application programming interface) is an agreed way for two programs to talk to each other.
- **Tool use: the model fills out forms**: A language model without tools can only draw on its training knowledge and the context.

### Part 2: https://llm.yoga/en/12-integrationen-2.md

- **Walkthrough: a weather question with one tool**: Now the whole flow with the real messages in the format of the Claude Messages API.
- **How hard the model is pushed toward a tool: tool_choice**: With the tool_choice parameter, you set how free the model is in its choice.

### Part 3: https://llm.yoga/en/12-integrationen-3.md

- **Structured output: JSON you can rely on**: Many integrations don’t need a nice answer, they need data: the sender, date and request pulled out of an email, a list of open tasks from a meeting transcript.

### Part 4: https://llm.yoga/en/12-integrationen-4.md

- **MCP: one plug for all tools**: So far you’ve defined and run tools yourself.

### Part 5: https://llm.yoga/en/12-integrationen-5.md

- **n8n: workflows with AI agents**: Not every integration has to be programmed.
- **A2A: when agents talk to agents**: MCP connects an agent to tools.
- **Which way when?**: You now know five ways to connect a model to the world.

### Part 6: https://llm.yoga/en/12-integrationen-6.md

- **Exercise: a tool call with a local model**: Goal: you play through the flow from the diagram “How a tool call runs” yourself, with a local model instead of Claude.
- **Common misconceptions**: With function calling, the model runs the function itself.
- **Review questions**: 1. Your agent calls a tool, and the tool throws an error.
- **Go further**: Anthropic docs: Tool use with Claude, with client and server tools, flow and token costs.
