Skip to content

gazebo

Everything needed to build OGC-style APIs, under one roof.

gazebo packages the recurring machinery of OGC-style services so it doesn't get re-implemented per project. The core depends only on pydantic; framework integration is opt-in.

What's in the box

Feature Module Page
Deferred links (callable hrefs resolved at serialize time) gazebo.link Links
The request-context seam links resolve against gazebo.context Request context
Collection envelopes (items + links + counts) gazebo.collection Collections
Pagination links (next/prev) gazebo.pagination Collections
RFC 7807 problem responses gazebo.problems Problems
Landing pages + conformance gazebo.ogc Landing & conformance
Typed Rel / MediaType / tag constants gazebo.rels, gazebo.tags Constants
Typed, scoped dependency injection gazebo.di Dependency injection
Proxy-aware URLs + pluggable trust gazebo.asgi Proxy & context
FastAPI app, routers, health, composition gazebo.ext.fastapi FastAPI integration

When to use it

gazebo is for OGC-style, hypermedia REST APIs on FastAPI — services where:

  • responses carry links whose URLs depend on the incoming request (and must stay correct behind a proxy);
  • resources have lifetimes worth managing (app-lifetime pools, per-request sessions, request-derived identity);
  • you want OGC shapes — collections, landing pages, conformance, RFC 7807 problems — without rebuilding them each time.

gazebo is a toolkit, not a framework: you build on FastAPI and write your own handlers, and gazebo supplies the OGC plumbing those handlers reach for — so it lives in one place instead of being rebuilt each project. The core is just pydantic, so you can pull in one piece without adopting the rest.

Where to go next

  • Not sold yet? Why gazebo — the three hand-rolled pains, shown breaking and then fixed.
  • New here? Getting started — install + a working app in ~40 lines.
  • Browsing features? Start with the core, then DI, then FastAPI glue.
  • Want the whole thing at once? Gazebo Gardens, the complete example app.
  • Looking up an API? Reference, generated from the source.

Status

Early / pre-1.0. The gazebo.di container is intentionally minimal and extraction-ready (stdlib only); it sits behind a Providers interface so a mature container could be adopted later without changing user code.