---
title: "API"
description: "The EZGH Cloud APIs, their hosts, versioning and OpenAPI documents."
---

> Documentation Index
> Fetch the complete documentation index at: https://docs.ezghcloud.com/llms.txt
> Use this file to discover all available pages before exploring further.

# API

Each EZGH Cloud product has its own HTTPS API host. The APIs share authentication, errors,
pagination and other conventions, described in this section.

- [Authentication](/api/authentication): API keys, CLI logins and console sessions.
- [Errors](/api/errors): the error body and status codes.
- [Requests](/api/requests): pagination, idempotency keys, conditional writes, timestamps and money.

## Hosts

| Product | Base URL | Reference |
| --- | --- | --- |
| Organizations and IAM | `https://orgs.ezghcloud.com` | [Organizations API](/orgs-api) |
| Billing | `https://billing.ezghcloud.com` | [Billing API](/billing-api) |
| Trails | `https://audit.ezghcloud.com` | [Trails API](/trails-api) |
| Service quotas | `https://quotas.ezghcloud.com` | [Service quotas API](/quotas-api) |
| OCR | `https://ocr.ezghcloud.com` | [OCR API](/ocr-api) |

## Paths

- Paths start with the major version, `/v1`.
- Almost every path names the organization: `/v1/organizations/{orgId}/…`. Project-scoped
  resources add the project: `/v1/organizations/{orgId}/projects/{projectId}/…`. Listing and
  creating organizations (`/v1/organizations`) are the exceptions.
- IDs in paths are UUIDs, not slugs. A malformed ID returns `404`, like an unknown one.

## Versioning

Within `/v1`, changes are additive: new endpoints, new optional request fields, new response
fields, new error codes, and new values in enums that are open to extension. Ignore response
fields you don't recognize. A breaking change gets a new major version.

## OpenAPI documents

Each host serves an OpenAPI 3.1 document of its API at `/openapi.json`, without authentication:

```sh
curl https://ocr.ezghcloud.com/openapi.json
```

Operation IDs match the `eventName` of the operation's [Trails](/trails) events, such as
`CreateProject`.

Source: https://docs.ezghcloud.com/api/index.mdx
