Why your API description belongs in Git, not next to it
Application code has lived in Git for fifteen years. API descriptions often still do not: they sit in a design tool's database, and Git gets an exported copy now and then. APIGit was built on the opposite idea. The repository is the product: your OpenAPI, AsyncAPI and GraphQL files, the Markdown guides and the mock scripts are files in a Git repository, and every feature works on those files. This post explains what that buys you.
The problem with "Git integration"
Many API tools offer a Git integration. In practice it is a sync: the tool keeps its own copy of the API in its own format, and pushes an export to GitHub when you ask. Three things follow from that.
- Two sources of truth. The file in Git and the object in the tool drift apart. Which one did the last release use?
- Review happens in the wrong place. A pull request on the exported file reviews a copy. The real change was made in the tool, without review.
- History belongs to the vendor. Stop paying, and the versions, comments and change log stay behind.
What native Git means in APIGit
There is no second copy. When you edit a spec in the form editor, the result is a change to a YAML or JSON file, and saving it is a commit.

Everything else is ordinary Git:
- Clone and push over HTTPS or SSH, from your machine or from CI, with the tools you already use.
- Every change is a commit with an author, a time and a message. You can open the spec as it was at any commit, not only read a diff.
- Branches and tags for work in progress and for releases.
- Pull requests with a file tree for the diff, comments and required approvals.

What you can do because of it
Review an API change like a code change. A pull request shows what changed in the description and the discussion around it; in an organization repository it also has a Governance tab with the findings for each changed spec. Branch protection can require approvals before a merge into main.

See what a change breaks before it ships. Because both versions are in the history, comparing them is one command:
apigit breaking origin/main HEAD openapi.yaml
It lists the changes that can break a client and exits 1 when there is one, which makes it a CI check.
Publish from a point in history. A published document version or a mock server is tied to a commit, or follows a branch. Readers of v1 keep seeing v1 while you work on v2, and you can always say which commit a customer is reading.
Edit several files and commit once. A rename that touches a schema file, two specs and a guide is one commit, not four saves. See Edit many files, commit once.
Let agents and scripts work on it. A coding agent, the apigit CLI and your CI all read and write the same files through the same Git history, with tokens you can limit to a repository.
Leave whenever you want. A clone on your laptop holds the complete history. Push it to any Git server and nothing is lost.
Where the repository lives
The repository can be hosted on APIGit, mirrored to another platform, or kept on your own Git provider with two-way synchronization. Where should your API repository live? compares the three.
Where to start
Create a repository, add or import a spec, and make your first change on a branch. The Git documentation covers repositories, branches, commits and pull requests.