Devblog: A new Golang Native API Framework

by Charlie Brown, CTO

Intention

We’ve historically built and maintained multiple API versions to support rapid access to Anzen’s ASR quantum-safe data security. While this has served users well, over time we encountered growing friction in extending features, updating endpoints, and keeping documentation unified and coherent.

The Challenge? Tooling that simply wasn’t flexible enough. We had been using OpenAPI/Swagger, which struggled to support our hybrid use case of S3-compatible and standard RESTful APIs. Add to that our deep-rooted commitment to Go-native development and it became clear we needed a rethink.

Twelve months ago, we took a blank sheet approach. We set out to design and build an internal API framework from the ground up, with one goal: to create something fast, flexible, secure and future-proof.

Here’s how we did it, what we’ve gained, and where it’s heading


Our Approach

From the outset, we identified three non-negotiables:

  • Strong maintainability across divergent API architectures.
  • Tight safety controls to minimise regression risks.
  • Fully unified, easily deployable documentation for all public APIs.

We adopted a documentation-first model. The public-facing spec of the API became the source of truth. If the implementation doesn’t meet the contract, it simply won’t build. All handlers must exist. All docs must be complete. Tests must pass. No exceptions.

As our microservices architecture has grown and improved we can now complete abstracting all remaining heavy workloads from the API services to their corresponding microservice; increasing maintainability and efficiency across API codebases.


Benefits

The shift has already delivered serious value. Both of our core AnzenStore APIs (S3-Compatible and Management) are now fully replatformed to the new model. Here’s what we’ve gained:

Instant documentation: A single command generates a fresh API doc set as a lightweight JSON object, ready to push to a templated static site. What used to take hours now takes seconds.

Turbocharged development: Creating new endpoints or even whole APIs is faster than ever. Our templated approach strips out boilerplate entirely. Developers focus on behaviour, not scaffolding.

Faster release cycles: Design, test, implement, document. All now happen in a single flow, in a single environment. No tool switching. No rework. Test-driven development feels seamless and intuitive.

Cleaner, more accurate documentation: Unexpected but welcome. By embedding docs directly in the codebase, right next to the logic they describe, we’ve slashed documentation errors. What you see is truly what you get.

Improved internal confidence: The structure enforces quality. There’s less room for error, and more headroom for innovation.


The Future

With the framework now battle-tested and adopted across key APIs, we plan to continue developing it during quieter cycles between major releases.

Eventually, we aim to open-source it. We believe other teams—especially those building secure systems in Go will benefit from the speed, clarity, and precision it enables.

Before that, we’ll polish it further and build in tooling to make it easier to adopt. One example in progress is a generic static site tool for interpreting and serving the auto-generated docs.

If you'd like to follow along, find us on LinkedIn at Anzen.

We’re just getting started.


More articles

Unlocking the Power of Automated Deployment with AnzenStore

Deploy AnzenStore effortlessly with our new Terraform modules! Our S3-compatible object storage solution with ASR-powered security is now easier to set up than ever. Automate deployments for consistency, scalability, and reliability—reducing effort and eliminating human error. The Azure module is available now, with the AWS module coming in April.

Read more

Year in Review: 2024

2024 has been a groundbreaking year for Anzen. Join CEO, Hoon Li, as he reflects on key achievements and milestones from the past 12 months, while sharing our vision for 2025.

Read more

Contact Us

Our offices

  • London
    The Plexal, Here East,
    Queen Elizabeth Olympic Park, London E15 2GW