ExitAPI Versioning: Side-by-side API contracts1 / 9
Explanationassociate9 steps · 4 exercises

A breaking change is measured against the old contract

How to recognize a breaking contract change and route requests to the version whose validation rules and payload mappings preserve the client's expected behavior.

An API contract says what a client can send and what it can rely on getting back. It covers more than field names: required inputs, data types, units, status codes, and error bodies can all be part of the contract. A change is breaking if a previously supported client can no longer make a valid request or correctly use the result.

Take an order API whose v1 client sends and reads a decimal total in US dollars. Replacing that response field with amount breaks a reader that expects total. Requiring currency on the existing route also breaks callers that never had to send it. In contrast, adding an optional response field is compatible if supported readers ignore unknown fields; it can break readers that reject them.

Next up: Sort the statements on what you just read.

AWS architecture icons are the property of Amazon Web Services. BlowStack is not affiliated with or endorsed by AWS.