Building with AI

What is an API?

In short

An API (application programming interface) is a set of rules that lets two computer systems talk to each other and exchange data without a person in between.

An API works like a waiter: one system sends a request in an agreed format, and the other sends back an answer. Most modern software has an API, which is how tools are connected and how developers use AI models inside their own products.

Mini course

3 short lessons, about 2 minutes in total

  1. A menu for programs
  2. APIs and AI
  3. What to check

Lesson 1

A menu for programs

An API (application programming interface) works like a restaurant menu for software. It lists what you can ask for and how to ask. Your program sends a request in the agreed format and gets an answer back, without needing to know how the other system works inside.

An API is the agreed way one program asks another for data or actions. Every AI model you use from code is reached through one

Tap a box to open that concept

Weather apps, payment buttons and maps on websites all work through APIs.

Lesson 2

APIs and AI

When a company builds AI into its own systems, it calls the model provider's API: it sends the instructions and the text, and gets the model's answer back. The provider counts tokens and bills per use. The same API gives access to tools, files and settings such as which model to use.

  1. Customers find youHow customers and AI tools find the companySEOGEOGoogle AI Overviews
  2. AI in daily workTools staff and customers useChatbotAI copilotVoice AI
  3. Building blocksHow AI connects to data and systemsAPIRAG (retrieval-augmented generation)AI agentMCP (Model Context Protocol)
  4. AI modelsThe models that understand and createLarge language model (LLM)Generative AIMachine learning
  5. DataCompany data, gathered and cleanedData warehouseETLData quality
  6. InfrastructureCloud, networks and systems underneathCloud computingDatabaseAPI key
Trust and rulesSecurity, law and control in every layerGDPR and AIEU AI ActAI guardrails
Where API sits in a company's AI setup

Chat apps are for people. APIs are for building AI into products and processes.

Lesson 3

What to check

Before connecting systems, check that both have an API, what it allows, what it costs and its limits on number of calls. Keep API keys secret on a server. Read the provider's terms on data storage and training. And plan for errors: APIs sometimes fail, so your system should retry or fall back gracefully.

Webhooks are the reverse direction: the other system calls you when something happens.

An everyday example

When a web shop shows the delivery status from the carrier, it fetches it through the carrier's API.

How companies use it

Companies use APIs to connect their CRM, accounting, booking and AI tools, so data moves on its own instead of being copied by hand.

Frequently asked questions

Do we need a developer to use an API?

Using an API usually needs some technical help, but no-code tools such as Zapier or Make connect many APIs without code.

Do APIs cost money?

Some are free, others charge per call or need a paid plan. AI model APIs charge per token.

Is an API safe?

An API can be safe, with keys kept secret, limited access and logging. A leaked API key is a common risk.

In depth: API

The full picture, about 4 minutes of reading

Two systems talking without a person in between

An API, short for application programming interface, is a set of rules that lets one computer system ask another for data or for an action, and get an answer back. No person needs to click, copy or paste. The systems talk directly, in a format both sides have agreed on.

A restaurant menu is a good picture. The menu lists what you can order and how to ask for it. You do not need to know how the kitchen works. In the same way, an API lists what another system can do for you, such as "give me today's exchange rate" or "create a new customer", and how to phrase the request. The other system does the work inside and sends back the result.

Why APIs are everywhere

Almost every modern piece of software has an API, because no program does everything. A web shop needs payments, shipping, stock levels and accounting. Instead of building all of that, it connects to specialist services through their APIs. The map on a contact page, the "pay with card" button and the delivery tracking in an order email all work this way.

For companies, APIs are what stop people from moving data by hand. When the booking system can tell the accounting system about a new sale on its own, nobody has to retype it, and the numbers match. Without APIs, every system is an island, and staff become the bridges.

How a request works, step by step

First, the calling system builds a request. It names what it wants, often as a web address such as one ending in "/orders", and adds any details, such as a date range or a customer number.

Second, it proves who it is. Most APIs require an API key, a long secret code that works like a password for programs, or a login token that expires after a while.

Third, the request travels over the internet, usually encrypted, to the other system. That system checks the key, checks that the caller may do what it asks, and does the work.

Fourth, the answer comes back, usually as structured text that a program can read easily, together with a status code that says whether it worked. A well-built caller checks that status and handles errors, because sometimes the other side is busy, down or answers with something unexpected.

A webhook is the same idea in reverse: instead of asking again and again whether something has happened, you give the other system an address, and it calls you when it happens.

APIs and AI

APIs are how AI gets built into products and processes. Chat apps such as ChatGPT or Claude are made for people. When a company wants AI inside its own website, CRM or document flow, its software calls the model provider's API instead. It sends instructions and text, and gets the model's answer back.

AI providers bill API use by tokens, the small pieces of text a model reads and writes, so long documents and long answers cost more. The same API lets you choose which model to use, send images or files and give the model access to tools.

APIs also work the other way. An AI agent, an AI system that can take steps on its own, uses APIs to look up an order, book a meeting or update a record. The quality of those APIs, and the limits on what they allow, decide what the agent can safely do.

What to check before connecting systems

Start by checking that both systems have an API and that it allows what you need. Some APIs only let you read data, not change it. Read the limits: many APIs cap how many requests you may send per minute or per day, and some charge per call or require a higher plan.

Keep API keys secret, stored on a server and never in a web page, a spreadsheet or an email. A leaked key lets anyone act as your company toward that service. Give each key only the access it needs, and replace it if you suspect it has leaked. Read the provider's terms on where data is stored and, for AI services, whether it is used for training. Finally, plan for failure: decide what should happen when the other system does not answer.

What it means for a small business

A small business rarely needs to write API code itself. No-code tools such as Zapier and Make sit between many popular services and connect them through their APIs with a few clicks. Many systems also have ready-made integrations, which are simply API connections someone else has built.

A good first step is to list where staff copy the same data between systems every week: orders into accounting, form answers into the CRM, bookings into the calendar. Each of those is a candidate for an API connection. When choosing new software, ask whether it has an open, documented API. It keeps your data movable and makes it much easier to add AI later.

Curious what this could mean for your company? Book a call.

Book a call