Skip to content

About

A profile of SLA4OAI documenting the x-apis-io extensions for uptime guarantees, observed uptime and limits.

Topics

Resources

Code of conduct

Contributing

Security policy

Stars

0 stars

Watchers

0 watching

Forks

Service Level Agreement

The service levels an API provider publishes — the uptime it promises, the credit it owes when it misses, the response times it commits to, and the uptime its own status page reports — as a profile of SLA4OAI, not a new format.

This is the schema behind the Service Level Agreement property in API Commons.

Why it matters

API Commons was started to make the business side of API onboarding machine-readable. Whether an API will be there when you need it — and what you are owed when it is not — decides whether it can sit in a production path. Today that answer lives in a PDF or a legal page. Expressed against SLA4OAI, it can be compared across providers and read by an agent choosing between them.

What the profile adds

SLA4OAI 1.0.0 Draft describes plans, pricing, quotas and rates against an OpenAPI. It has no field for an uptime figure, a service credit or a response time, and account-wide limits have no path to sit under. Those travel on each plan as x-apis-io-* extensions, which SLA4OAI allows:

Extension Meaning
x-apis-io-guarantees[] What the provider promises, quoted from its SLA page
x-apis-io-observed[] What the provider reports it delivered, quoted from its own status page — never a promise, never measured by APIs.io
x-apis-io-limits[] Limits as documented, verbatim, that name no method + path and so cannot go in rates
context.x-apis-io-derivation How the document was built: synthetic: false, method: searched, read, tool, coverage (promised / reported uptime: found / not found / not checked), statement, sources[]

Each guarantee / observed row is {text, percent, window, component, credits_text, response_time_text, source, read}; text, source and read are required. A limit enters SLA4OAI rates only when the docs name both a method and a path; a price enters pricing only when it is a bare amount. Nothing is inferred to fill a field.

Two document forms

  • <slug>-sla.yml — a conformant SLA4OAI document (sla4oas: 1.0.0), pointing at the provider's OpenAPI.
  • <slug>-service-levels.yml — written when figures were found but the provider has no OpenAPI, which SLA4OAI requires. It carries conformant: false and not_sla4oai_because, and says so in its header. It is not an SLA4OAI document.

Provenance: verbatim text, never synthetic

Every figure is quoted from the provider's own page, with the page and the date on the row. A document built only from plans and rate limits, with no service level found, is never published — a file labelled as a provider's SLA reads as one the provider published, whatever it says inside. The schema rejects synthetic: true.

Artifacts

The figures in the examples are illustrative and are not the service levels of any real company.

pip install jsonschema pyyaml
python3 validate.py service-level-agreement-example-1.yml service-level-agreement-example-2.yml

Upstream

License

Part of API Commons

Related business-layer blocks: terms-of-service · privacy-policy · deprecation-policy · compliance · eligibility · ai-preferences · data-license · plans · rate-limits

About

A profile of SLA4OAI documenting the x-apis-io extensions for uptime guarantees, observed uptime and limits.

Topics

Resources

Code of conduct

Contributing

Security policy

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages