Story #10 OpenAPI Conformance · API Governance

The OpenAPI Compliance Drift

"Teams updated the code but forgot the specs. Or updated the specs but forgot the code. For years"

Northstar Business Cloud maintained hundreds of APIs, each with an OpenAPI spec. Over time, implementations and specs gradually diverged as teams updated one without the other. SDK generators produced invalid code, partner integrations failed unpredictably, and customer onboarding became unreliable.

What happened

Northstar Business Cloud’s platform grew to hundreds of internal and partner-facing APIs. Each service published an OpenAPI specification. Teams were expected to keep specs and implementations synchronized.

In practice, this was treated as a documentation task, not an engineering requirement. When developers changed a response field, they sometimes updated the spec weeks later—or not at all. When specs were updated for a planned change, the implementation occasionally shipped differently. Neither divergence triggered any automated failure.

Over time, the cumulative drift became severe. SDK generators consumed the outdated specs and produced client code that failed against the actual APIs. Partner integrations built against published specs encountered fields that didn’t exist or were typed differently. Customer onboarding required manual hand-holding because generated examples didn’t match real responses.

An organization-wide API standardization effort took a full year to remediate the drift and restore confidence in the published specifications.

Root cause

There was no automated test that compared the published OpenAPI specification against the actual API’s behavior. Spec accuracy was enforced by convention, not by tooling.

The fix

The team introduced automated conformance tests that ran on every pull request: the actual API responses were validated against the published OpenAPI schema. Any drift caused a CI failure. Specifications became a first-class deliverable, as required as the code itself.

Lesson learned

An OpenAPI specification that isn’t continuously verified against the implementation is fiction. Automated conformance testing keeps specs and code synchronized—without it, they will inevitably diverge.

The OpenAPI Compliance Drift