Scrivio Interview library
ScenarioIntermediate6 min read · updated 13 November 2026

A mobile banking app talks to a public REST API. Telemetry shows 14 percent of requests still come from app versions over 2 years old, which cannot be updated remotely, and a planned change to the account response would crash those versions.

How do you evolve the API while such old clients are in use, and what do you build so this is manageable in future?

For fields that old clients parse, server changes must be additive: new shapes go into new fields, new endpoints, or a new version that only new app versions request. To make this manageable we record the app version and platform on every request and track traffic per version, ship a minimum supported version with a force-upgrade response that old apps already understand, use server-driven capabilities so the server only uses features a client declared, and test every release against recorded responses or contract tests from the oldest supported versions.

Why this question is asked

Web front ends update the moment we deploy, so it is easy to forget that mobile apps do not. A banking app installed two years ago on a phone that never updates still calls our API every day, and if we change a response it cannot parse, it crashes for real customers. With 14 percent of traffic on such versions, this is not an edge case. Interviewers ask this to see whether we design APIs for a long tail of clients we cannot control. In this answer, we will see why old clients crash on changes, how to evolve the account response safely, and what to build so future changes are routine: version telemetry, minimum versions with force upgrade, capability negotiation and contract tests.

1Why Old App Versions Crash on Changes

A mobile app decodes JSON into model classes, for example with Gson, Moshi or Codable on iOS. Different decoders react differently to changes. Removing a field that the app marked as required, changing a number to a string, renaming a field or changing an enum value the app maps with a strict switch can all throw an exception during parsing, and an unhandled exception on the main screen is a crash. Some older apps were also built with strict settings that fail on unknown fields.

And we cannot fix those apps. The code is frozen on the phone, the user may have disabled updates, and the device may be too old for the newest app version. So the server has to keep speaking a language those apps understand for as long as we support them.

2Evolving the Account Response Additively

The rule for anything old clients parse is: only add. If the planned change replaces balance, a number, with an object holding amount and currency, we keep balance exactly as it is and add balance_v2, or available_balance, alongside it. Old apps ignore the new field (assuming they tolerate unknown fields, which we verify), new apps use it. When a change cannot be expressed additively, for example a completely restructured account resource, it goes behind a new endpoint, such as /v2/accounts, or a version parameter that only new app versions send. Old versions keep calling the old shape, which the server continues to produce, often by mapping from the new internal model.

The cost is that the server maintains old shapes for a while, so we also need a way to know when we can stop, which is what the rest of the design gives us.

Java
// Old shape, still served to every client
{ "id": "acc-1", "balance": 1520.75, "status": "ACTIVE" }
// New shape: the old fields unchanged, new data added beside them
{ "id": "acc-1", "balance": 1520.75, "status": "ACTIVE",
"available_balance": { "amount": "1520.75", "currency": "EUR" },
"holds": [ { "amount": "20.00", "reason": "CARD_AUTH" } ] }
// app 3.2 (2 years old): reads balance, ignores the rest
// app 5.0: reads available_balance and holds

3Knowing Who Would Break: Version Telemetry

We cannot manage what we cannot see. Every request from the app should carry its version and platform, for example X-Client-Version: 3.2.1 and X-Client-Platform: ios, or the same in the User-Agent. The API logs them, and dashboards show traffic and active users per version. With that, '14 percent of traffic' turns into a precise list: which versions, how many users, which endpoints and fields each version uses. Before any change, we can say exactly which versions would be affected, and later we can see when the oldest versions finally fade.

The same header lets the server branch when it truly must: serving the old enum mapping to versions below 4.0, for instance. That should be rare and centralised, not scattered through the code.

Example traffic by app version
App versionReleasedShare of requestsHandling
5.x202661 percentfull features
4.x202525 percentfull features, additive fields
3.x202414 percentold shapes only; force-upgrade date announced
below 3.02023 or earlierunder 0.1 percentblocked by minimum version

4Minimum Version and Force Upgrade

Sooner or later we must stop supporting very old versions, for security or because the old shapes become too costly. For that, the app needs a force-upgrade mechanism: on startup, or on a specific response such as 426 Upgrade Required with a defined body, it shows a screen that says the version is no longer supported and links to the store. The server compares the version header with a configurable minimum supported version per platform.

The crucial point is that this mechanism only works for versions that already contain it. An app version without the force-upgrade handling will just see an error or crash. So it must ship early, years before we need it. Before enforcing a new minimum, we announce the date inside the app, as a banner in versions that support remote messages, so users have weeks to update.

5Capabilities and Contract Tests

Instead of the server guessing what an old version can handle from its number, the client can say it. With server-driven capabilities, the app sends a list of features it supports, for example X-Client-Capabilities: rich-balance, card-controls-v2, and the server only uses response features the client declared. New features are invisible to old clients by construction, and the server does not need a table of which version supports what.

Finally, we test against reality. For each supported app version, we keep recorded API responses or consumer-driven contracts, for example Pact contracts that describe the fields and types each app version relies on. Every server release runs these tests, so a change that would break version 3.2 fails CI instead of crashing phones. Some teams also keep a device lab with the oldest supported app versions installed and run smoke tests before each release.

Step throughRequest handling with version and capabilities
  1. Read X-Client-Version and capabilities
  2. Version below the minimum supported?
    YesReturn 426 with upgrade bodyNoContinue
  3. Client declared the new feature?
    YesReturn new fields and behaviourNoReturn the old shape only
  4. Log version, platform and endpointfeeds the per-version dashboard

4 steps in order. Play them, or step through them one at a time.

6Follow-up questions

Why is a force-upgrade mechanism something you must ship before you need it?

Because the only apps it can control are the ones that already contain it. If we add it in version 6.0, versions 3, 4 and 5 still do not understand the 426 response, and when we finally need to stop supporting them, they will simply break instead of showing an upgrade screen. Shipping it in every version from now on, and testing it regularly, means that two years from now we will have a clean way to retire the versions we release today.

Should we version the whole API with /v2?

Only for changes that cannot be made additively. A new major version doubles the surface to maintain. Most changes can be additive fields or capability-gated features; a version bump is for the rare redesign.

7Conclusion

In this answer, we saw that frozen mobile apps crash when a response they parse changes, so changes must be additive, with new shapes in new fields, new endpoints or versions that only new apps request. We recorded the app version and platform on every request to know who would break, shipped a minimum supported version with a force-upgrade response early, let clients declare capabilities so the server only uses supported features, and tested each release against contracts from the oldest supported versions.

What to say in the interviewAbout 90 seconds aloud

Open with

Old app versions are frozen on people's phones, so the server has to keep speaking their language. For anything those apps parse, I would only make additive changes.

Then, if they want more

If the account response needs a new structure, the old fields stay exactly as they are and the new data goes into new fields beside them, or, if it cannot be additive, behind a new endpoint or version that only new app versions request. To make this manageable, the first thing I would build is telemetry.

Every request carries the app version and platform in a header, and we track traffic per version and per endpoint, so before any change we know exactly who would break, and later we can see when old versions disappear.

Second, a minimum supported version with a force-upgrade response, such as 426 with a defined body that the app turns into an update screen, plus in-app announcements of the date before we enforce it. That only works for versions that already contain it, so it has to ship long before we need it.

Third, server-driven capabilities: the app sends the features it supports and the server only uses those, so new features are invisible to old apps by construction. And fourth, contract tests: recorded responses or Pact contracts from the oldest supported versions run against every server release, so a breaking change fails CI instead of crashing phones.

About this answer

Last updated
13 November 2026
Checked
Its structure and format are checked automatically. Use it as a carefully prepared study note: where a detail matters, confirm it against the official documentation for the version you use. What the checks cover
Where the question comes from
Written by Scrivio for practice. It is not taken from an interview.
Report an issue with this answer

Copy the line below and send it to the author with what you found. It carries the address of this page.

Issue with "How do you evolve the API while such old clients are in use, and what do you build so...": https://scrivio-interview-library.netlify.app/architecture/api-design-at-scale/fa25974d8c/