Skip to Content
API

Versioning and stability

What the v1 contract guarantees, what counts as a breaking change, the six-month notice period, and what your client has to do to stay covered.

View as Markdown

The contract is the OpenAPI 3.1 document served at:

https://app.vitalsentinel.com/api/public/v1/openapi.json

Nothing outside that document is promised. If a field is not in the schema, do not depend on it.

What the contract covers

  • Every path and HTTP method under /api/public/v1
  • Request parameters and bodies, including which are required
  • Response schemas, including field names, types, and nullability
  • The type URI on every error, and the HTTP status that accompanies it
  • Scope strings, and which scope each operation requires
  • The pagination envelope, the cursor parameter, and the time-range parameters

What it does not cover

  • The prose in an error's detail field. Written to be acted on, and reworded whenever a better wording exists. Branch on type.
  • The exact value of a cursor. Opaque by design.
  • Ordering of results where an endpoint does not document one.
  • Response timing, or whether a given answer came from cache.

What counts as a breaking change

Breaking, and requires /api/public/v2 plus the notice period below:

  • Removing an endpoint, a field, or a scope
  • Renaming anything
  • Making an optional request parameter required
  • Changing the type or the unit of a field, or making a field that was always present optional or nullable
  • Changing the default value of an optional parameter
  • Changing which scope an operation requires
  • Changing the HTTP status or type URI for an existing error condition

Additive, and ships inside v1 at any time with a changelog entry:

  • A new endpoint
  • A new response field
  • A new optional query parameter
  • A new enum member
  • A new scope
  • A new error type for a condition that could not occur before

The commitment

A breaking change requires a new major version in the path, and the version being retired stays available for a minimum of six months after its successor is generally available.

Six months is a minimum, not a target. The period starts when you can call v2, not when VitalSentinel announces it. You cannot migrate to a version that does not exist yet.

Individual operations are not deprecated inside a major version. If an operation has to go, it goes in the next major version, on the same schedule as everything else in it. A surface where any single endpoint can vanish on its own timetable is one nobody can plan around.

How a retirement is signaled

ChannelWhat it carries
Response header DeprecationThe instant the deprecation takes effect, as an RFC 9745 structured-field Date: Deprecation: @1794355200
Response header SunsetThe instant the operation stops being served, as an HTTP-date: Sunset: Tue, 11 May 2027 23:59:59 GMT
Response header Link with rel="deprecation"A documentation URL for that specific retirement
Release notesThe authoritative record of what changed and what to move to

The two date headers have different formats on purpose. RFC 9745 defines Deprecation as a structured-field Date. RFC 8594 is older than structured fields and defines Sunset as an HTTP-date.

Nothing in v1 is deprecated today, so no response currently carries any of these three headers. The mechanism ships live and dormant, which means you can build against it now and it will work when it is first used.

Detecting a change yourself

Two mechanisms are worth wiring into CI:

Poll and diff the OpenAPI document. It needs no credential and is the same for the same deployed state. Its paths and operations are sorted, so a diff shows only real changes.

curl -sS https://app.vitalsentinel.com/api/public/v1/openapi.json \
  | jq -S . > openapi.new.json
diff -u openapi.json openapi.new.json

Watch info.version. It moves only when the published contract moves.

VitalSentinel keeps a snapshot of the same document, and an automated test compares it. A schema change to a live endpoint cannot ship unless someone updates the snapshot on purpose. This makes sure that a person sees each change. It does not classify the change automatically.

What your client must do to stay covered

The guarantees above are written against clients that follow five rules. A client that does not follow them can be broken by a change this policy calls additive:

  1. Ignore unknown fields. A new response field is additive and will appear without warning. A client that rejects unknown keys will break on it.
  2. Tolerate unknown enum values. Treat an unrecognized value as "something new", not as a fatal error.
  3. Branch on the error type URI, never on the prose in detail or on the status code alone. Two different 403s need two different responses from your code.
  4. Treat cursors as opaque. Do not parse, construct, or persist one across a deployment.
  5. Honor Retry-After. A client that ignores it is indistinguishable from one that is attacking us.

Scope stability

Scope strings are part of the contract.

  • Adding a scope is additive.
  • Removing one, or changing which scope an operation requires, is breaking.
  • Removed scope strings never come back. They are permanently blocked, so a future endpoint cannot be quietly authorized by resurrecting a string that an explicit decision removed. See Scopes that do not exist.

Kill switches are not deprecations

A 503 carrying api-disabled or read-only-mode is an operational lever, not a contract change. Retry after the interval in Retry-After. Neither means anything is going away.

On this page

VitalSentinel

Know what changed before it costs you revenue

A stray noindex, a robots.txt change, a slower LCP, a Googlebot crawl drop: one alert, with what to fix first.

  • Free plan for 1 domain
  • Set up in minutes
  • No credit card required