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

# API introduction

> Golain Platform HTTP API — base URL, auth, and OpenAPI reference.

The **Golain Platform API** is the HTTP surface for orgs, projects, fleets, devices, integrations, edge SQLite replication, OTA, and more. It is implemented by [ilyama](https://github.com/golain-io/ilyama) (`services/apis`).

Edge sync governance routes live under `/projects/{project_id}/edge/*` and are served by the **edge worker** (dedicated `edge_exchange` / `edge_rpc_queue`), not the integration platform substrate.

## Base URL

| Environment   | Base URL                                   |
| ------------- | ------------------------------------------ |
| Production    | `https://api.ilyama.golain.io/core/api/v1` |
| Self-hosted   | `https://api.<your-domain>/core/api/v1`    |
| Local vm-edge | `http://localhost:19090/core/api/v1`       |

Paths in this reference are relative to `/core/api/v1`. Endpoints are grouped by resource (Organizations, Projects, Devices, Edge replication, Integrations, OTA, and more) in the sidebar — all **351** operations from the mounted ilyama route surface are included.

## OpenAPI specification

Interactive endpoint pages below are generated from `api-reference/ilyama.v1.json`, synced from `ilyama/services/apis/openapi/ilyama.v1.yaml`.

To refresh after API changes in ilyama:

```bash theme={null}
cd ../ilyama/services/apis
go run ./openapi/cmd/sync
cp openapi/ilyama.v1.json ../../docs/api-reference/ilyama.v1.json
```

## Quick links

<CardGroup cols={2}>
  <Card title="Authentication" icon="key" href="/api-reference/authentication">
    Bearer token, ORG-ID header, idempotency keys.
  </Card>

  <Card title="Edge sync API" icon="database" href="/edge/data-sync/api-reference">
    Operator-focused summary of `/edge/*` routes.
  </Card>
</CardGroup>

## Response format

Successful JSON responses follow the ilyama v1 envelope conventions (resource wrappers, list pagination meta). Errors use structured `core/errs` payloads with stable error codes.

See the [platform CLI](/tools/platform-tui/overview) and [console](/console/overview) guides for user-facing workflows that call these endpoints.
