Swipe
SwipeSwipe
Swipe Apps

Paths

Motivation

Information

Reading the Response · Lesson 8 of 9

Finding the Field You Need

A free lesson from Swipe AI · Building With AI APIs, level 2 · updated October 2026

By the Swipe team, founded by Colin · how we make lessons

🤖
Different provider, different field name — same job for your code. 🏷️

The exact name of the field holding the real answer differs between providers — one might call it output, another might call it text or result. Whatever it's called, your code needs to know that specific field name to correctly pull out the actual content, the same way it needs the right endpoint address.

This is why reading a provider's documentation matters before writing anything that depends on the response: guessing the wrong field name means your code either crashes or, worse, silently grabs something that isn't the actual answer.

Two providers, two different field names for the same idea:

Provider A response: { output: "Here is your summary." }
Provider B response: { text:   "Here is your summary." }

Same concept, different label — your code has to match whichever field the specific provider actually uses.
The field name is part of what you learn from a provider's documentation, not something you can assume.
Quick check

What's the risk of assuming a response field name without checking documentation?

Fill in the blank

The exact field name holding the real answer in a response ____ between different providers.

True or false

Every AI provider uses the exact same field name for the response field containing the actual answer.

Keep your streak going in Swipe AI

Swipe through every level of Building With AI APIs on your iPhone — with XP, stars, streaks, a personal advisor and the full track beyond these free levels.

Get the Swipe apps →