Help CenterAPI reference from an OpenAPI spec

Help Center

API reference from an OpenAPI spec

Add a tab to your Help Center made from your OpenAPI spec: a page per endpoint with a Try it playground, kept in step with the spec and published automatically.

If your product has an OpenAPI (or Swagger) spec, your Help Center can build its API reference from it. Workover adds a tab with one page per endpoint, grouped by the spec's tags, and each page has a Try it playground for sending a real request. You point Workover at the spec once, and from then on the tab follows it.

Add the tab

The spec has to be at an https:// address, because Workover reads it again every time it checks for changes. A file on your computer will not work.

With the Workover CLI, signed in with workover login --site:

workover site api add --project <projectId> --spec https://api.example.com/openapi.json

This adds a tab called API reference and creates its pages. To use another tab, pass --tab "<name>". To put the pages in a group inside an existing tab, add --group "<name>". The pages' addresses start with api-reference/ unless you pass --directory <prefix>, and the prefix on its own opens the tab's first page.

If you import your docs from a folder, you can name the spec in the folder's config instead. In Workover's _site.json, give the tab an openapi field and no dir:

{ "title": "API reference", "icon": "braces", "openapi": "https://api.example.com/openapi.json" }

In a Mintlify docs.json, an openapi URL on a tab or a group works the same way. workover site import --dir then adds the tab along with the rest of the folder.

AI agents connected through the Workover MCP server use the workover_add_api_reference tool.

How the tab stays up to date

Each time Workover checks the spec, it compares it with the pages it made last time:

  • A new endpoint gets a new page.

  • An endpoint that changed has its page rewritten.

  • An endpoint that is no longer in the spec has its page removed, and that page's address redirects to the tab's first page, so old links keep working.

Pages are matched by method and path, so renaming an endpoint's summary or moving it to another tag updates its page rather than making a new one.

If the spec cannot be loaded, or loads with no endpoints in it, nothing changes. A spec that is down for a minute, or a deploy that served an empty file, never empties your tab.

To stop following the spec, run workover site api remove --project <projectId> (with --tab and --group if you placed the pages elsewhere). The pages stay, as ordinary pages you can edit, publish or delete. Deleting the tab from the navigation on its own is not enough, because the next check puts it back.

Workover checks the spec:

  • Every hour, on its own.

  • When you ask it to, with workover site api sync --project <projectId> or the workover_sync_api_reference MCP tool. This is the call to add to your API's deploy, after it succeeds, so the docs change minutes after the API does. Use a token from workover login --site.

workover site api list --project <projectId> shows each spec-backed tab and what its last check did.

These pages publish themselves

Other pages in a Help Center go live only when a person publishes them. API reference pages made from a spec are different: they are generated from your spec, so Workover publishes them itself each time they change. Nothing else on the site is published with them, and pages you wrote by hand keep waiting for a person.

A few things follow from that:

  • Until the site has been published for the first time, the generated pages wait for that first publish, like every other page.

  • An edit made by hand to a generated page lasts only until the next change to its endpoint. To change what a page says, change the spec.

  • Pages you add to the tab yourself, such as an overview, stay where you put them, ahead of the generated pages, and are published the usual way.

  • An endpoint marked x-hidden in the spec gets no page.

Workover's own API reference

The API reference tab of these docs is made this way, from Workover's own spec. Its config names the spec as {api}/openapi.json, which means "the API of the Workover environment these docs are imported into", so the same docs folder makes the right reference on every environment. Workover's API also checks the tab each time a new version of it starts, so the reference changes with each deploy.