API integration in Codex
From nothing to a working call, without leaving the editor.
Adding an API usually means reading docs in one window and writing code in another, then finding out at runtime that a field is named something else. With the MCP server connected, Codex runs from the CLI or the app against your checked-out project, so it can make the call and put the result straight into the file that needs it — so the integration is written against responses it has actually seen.
- 1A KonbiniAPI accountThe free plan includes 100 credits, which is enough to run this a few times.
- 2Codex connectedOAuth or API key.
- 3A real targetA public account, post, or keyword to run it against — the placeholders below are not live values.
Build with it.
Ask Codex for what you need. It calls the tool, sees the real response, and writes code against the shape that came back rather than one it guessed — each call costs the same credits as the matching REST call.
Good for
- Add KonbiniAPI to a project that has never called it
- Generate a typed client from responses rather than from a schema you pasted
- Get auth, pagination, and error handling right the first time
- Wire a second platform into an integration that already handles one
Add KonbiniAPI to this project. Fetch a TikTok profile first so you can see the response shape, then write the client and the types.
Call the Reddit subreddit posts endpoint through MCP, then write a typed wrapper around it that handles the cursor pagination.
I already call the Instagram endpoints. Add LinkedIn company lookups the same way, matching the patterns in [file].
Set up KonbiniAPI auth in this project the way we do other API keys, and add one working call as a smoke test.
Write an integration test for our KonbiniAPI client using a real response you fetch through MCP as the fixture.
Swap the bracketed parts for your own project — the platform, the endpoint, and where the result should land.
Other Codex workflows
Run this in Codex.
One API key works for MCP and the REST API. The free plan includes 100 credits and no credit card.