Designing APIs for the Long Run

By Salvador Pereira

APIs outlive the teams that build them — so we design them to be typed, versioned and observable from day one.

Schema first

Contracts are defined before code; typed clients are generated, not hand-written.

Model for invariants

The data model enforces what must always be true; migrations are reviewed like any other code.

Scale deliberately

Caching, queues and rate limits are sized to real traffic, not guesses.