Quick revision
The short answer
We publish a short API style guide with examples (naming, problem details for errors, pagination, versioning), turn as much of it as possible into automatic lint rules for OpenAPI and AsyncAPI specs in CI, and reserve human review for new public or widely used APIs, done by people from several teams. A catalogue records every API with its owner, versions and consumers, and compatibility checks, such as OpenAPI diff tools and schema registry rules for events, stop breaking changes before they ship.
What to remember
In this answer, we designed API governance for 150 APIs around automation: a short style guide with examples, Spectral linting of OpenAPI and AsyncAPI specs in CI, human review limited to new public or widely used APIs by a cross-team group, a catalogue of owners, versions and consumers fed from CI, and compatibility checks with oasdiff and schema registry rules that stop breaking changes. Most changes then flow on green checks alone.
Your turn
Answer it aloud as you would in the interview, or type your answer below. Then show one part at a time and compare.
We publish a short API style guide with examples (naming, problem details for errors, pagination, versioning), turn as much of it as possible into automatic lint rules for OpenAPI and AsyncAPI specs in CI, and reserve human review for new public or widely used APIs, done by people from several teams. A catalogue records every API with its owner, versions and consumers, and compatibility checks, such as OpenAPI diff tools and schema registry rules for events, stop breaking changes before they ship.
Why this question is asked
With 150 APIs, consistency matters because every consumer pays for every inconsistency, but a review board that looks at every change becomes a queue that teams learn to avoid. The trick is to spend human attention only where it pays and let machines check the rest. Interviewers ask this to see whether we can design a process that scales. In this answer, we will cover the style guide, automated linting, risk-based review, the API catalogue and compatibility checks, and how they fit into one pipeline.
1A Short Style Guide With Examples
The style guide is the source of truth, and it should be short enough to read in twenty minutes. It covers resource naming (plural nouns, kebab-case paths), errors as problem details following RFC 9457, one pagination model, versioning rules, date and money formats, and for events, naming of topics and the required envelope fields. Each rule has a good and a bad example, because people copy examples far more than they read rules.
Notice that the guide also says what is allowed to vary. If teams know which choices are theirs, they accept the rules that are not.
2Linting Specifications Automatically
Every API is described by a specification in its repository: OpenAPI for REST, AsyncAPI for events. A linter such as Spectral checks the spec against rules written from the style guide, in CI, on every pull request. Most of the guide can become rules.
Because the check runs in seconds, teams find out about problems while they are still writing the API, not in a review meeting weeks later. For Spring services, the spec can be generated from the code with springdoc-openapi in a build step, or written first and used to generate code; either way, CI lints the result.
3Human Review Only Where It Pays
A linter checks form, not judgement. It cannot tell whether a resource model makes sense or whether an event leaks internal details. So we keep human review, but only for APIs where mistakes are expensive: new APIs exposed outside the company, and APIs that many teams will consume. Reviewers come from several teams, for example a rotating group of three, which spreads knowledge and prevents one team's taste from becoming the standard.
Everything else, such as internal APIs with one consumer or additive changes to existing APIs, relies on automated checks alone. In practice that means most of the weekly changes flow without waiting for a person.
- Pull request changes a specOpenAPI or AsyncAPI
- Lint against the style guidefails fast in CI
- Compatibility checkagainst the published version
- New public or widely used API?YesReview by a cross-team groupNoMerge on green checks
- Publish to the catalogueowner, version, consumers
5 steps in order. Play them, or step through them one at a time.
4A Catalogue of APIs, Owners and Consumers
A catalogue, for example in a developer portal such as Backstage, lists every API with its owner team, current versions, specification, status (preview, stable, deprecated) and known consumers. Specs are registered automatically from CI, so the catalogue stays current without manual work.
The catalogue answers questions that otherwise cost days: who owns this API, who will break if we change it, which APIs are still on version 1. It is also how a team discovers an existing API before building a duplicate.
5Compatibility Checks for Every Change
The most damaging API mistake is a breaking change shipped without warning: a removed field, a newly required parameter, a renamed event attribute. For REST, a diff tool such as oasdiff compares the new spec with the published one and fails the build on breaking changes, unless the change is in a new major version. For events, a schema registry enforces compatibility rules: with BACKWARD compatibility, a new schema version must be readable by consumers using the new schema against old data, so fields can be added with defaults but not removed carelessly; FULL compatibility checks both directions.
| Concern | Checked by | When |
|---|---|---|
| Naming, error format, pagination | Spectral lint rules | every pull request |
| Breaking REST changes | oasdiff against released spec | every pull request |
| Breaking event schema changes | schema registry compatibility mode | on schema registration |
| Model quality, domain fit | cross-team reviewers | new public or widely used APIs |
| Ownership and consumers | API catalogue | updated from CI |
Notice that both checks give the team a precise reason. The fix is usually easy: make the new field optional, or add a default. When a breaking change is truly needed, the catalogue tells us exactly which consumers to coordinate with.
6Follow-up questions
How do we handle the 150 existing APIs that break the guide?
We do not force a rewrite. Linting applies to changed lines or new APIs first, with existing violations recorded as a baseline. Old APIs move to the standard when they get a new major version, and the catalogue tracks how many are compliant.
Who owns the style guide?
A small group from several teams, with a public change process: anyone can propose a rule change by pull request, and the group decides. Changes to rules also update the lint ruleset, so the guide and the checks never drift apart.
What does the schema registry not protect against?
It checks schema shape, not meaning. If a team keeps a field's type but changes what it means, such as amount in cents instead of euros, compatibility checks pass. Clear field documentation and review for widely used events cover that gap.
7Conclusion
In this answer, we designed API governance for 150 APIs around automation: a short style guide with examples, Spectral linting of OpenAPI and AsyncAPI specs in CI, human review limited to new public or widely used APIs by a cross-team group, a catalogue of owners, versions and consumers fed from CI, and compatibility checks with oasdiff and schema registry rules that stop breaking changes. Most changes then flow on green checks alone.
Open with
I'd make governance mostly automatic so it doesn't become a queue. First, a short style guide with good and bad examples: naming, problem details for errors, one pagination model, versioning rules, and conventions for event topics and envelopes.
Then, if they want more
Then I'd turn as much of it as possible into Spectral lint rules that run in CI on every OpenAPI and AsyncAPI spec, so teams get feedback in seconds.
Human review would only be for new public APIs or ones many teams will consume, done by a rotating group from several teams, because that's where design judgement pays off; internal and additive changes go through on green checks.
I'd keep a catalogue, say in Backstage, fed automatically from CI, with owner, versions, status and consumers, so we can see who's affected by a change and avoid duplicate APIs. And I'd enforce compatibility: oasdiff fails a pull request with breaking REST changes outside a new major version, and the schema registry's compatibility mode rejects breaking event schemas.
Existing APIs that don't comply get a baseline and move over when they next have a major version, rather than a forced rewrite.
About this answer
- Last updated
- 12 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 "Design an API governance process for 150 internal REST and event APIs that keeps APIs...": https://scrivio-interview-library.netlify.app/architecture/platform-and-governance/9476f154d8/