Course · Codex · Getting started
Getting started
This chapter gets you from nothing installed to one real, reviewed change in a small Python repo, using Codex from the terminal first and your editor second. You do not need prior experience with Codex; you do need a shell you are comfortable in, basic Git (clone, commit, read a diff), and an OpenAI account or API access for sign-in.
What you will do
Section titled “What you will do”The lessons stand alone, but in order they build a sensible first hour:
- Install Codex and see the surfaces - global CLI install, verify
codex --version, launch inside a project directory. - Authenticate - ChatGPT sign-in vs API key, and why the choice matters for later automation.
- Understand one turn of the loop - read, propose, approve, apply; a read-only question before any writes.
- Ship your first reviewed change - fix a CSV date bug, read the diff, commit only what you reviewed.
- Connect Codex to your editor - integrated terminal or IDE extension, without abandoning inline completion.
Later chapters deepen context, control, and cost. This one focuses on seeing one turn clearly and reviewing before you trust a diff.
The example repo: budgetcli
Section titled “The example repo: budgetcli”Where a concrete codebase helps, these lessons use budgetcli: a small self-hosted personal-finance API, about 230 lines all told (Python, tests, and docs), with a pytest suite and an AGENTS.md at the repo root. Money is stored as integer cents; CSV import lives in app/importers/csv.py. Treat it as a disposable teaching checkout, not a product you must deploy.
The examples were checked against a local authoring fixture named codex-budgetcli, but that fixture is not published with the site and has no per-lesson tags. To follow along, use a disposable FastAPI project with the stated paths or adapt the exercise to your own repo, then run its real baseline before changing anything. Each lesson restates the files and facts it needs, so you can still start on any page.
How this chapter connects to the rest of the track
Section titled “How this chapter connects to the rest of the track”Codex is one agent with several surfaces (CLI, IDE, headless). Habits you form here - start in the repo root, describe outcomes, read diffs, commit at green checkpoints - carry forward. Sessions start cold except for what is written where Codex reads by default. The gap between what the model can figure out (its capability) and what is written down where it reads (the durable context every session starts with) is the through-line of the course.
Start with install if codex --version is not already on your machine; otherwise jump to authenticate or the loop if you only need a refresher on one beat.