
# Providers and catalogs

Four reference endpoints that return lists of cloud providers and the plans, regions, and OS images available on them. Call them before creating a server to obtain the correct identifiers for `provider`, `plan`, `region`, `image` in [`POST /v1/infra/servers`](/docs/infra/servers/create).

## Operations

- [List of providers](./providers/list.md) — `GET /v1/infra/providers`
- [Provider plans](./providers/plans.md) — `GET /v1/infra/providers/:providerId/plans`
- [Provider regions](./providers/regions.md) — `GET /v1/infra/providers/:providerId/regions`
- [Provider OS images](./providers/images.md) — `GET /v1/infra/providers/:providerId/images`

## Typical scenario

Before creating a server for the first time, request all four catalogs and pick suitable values:

```javascript
const providers = await api('GET', '/infra/providers')
const providerId = providers.data.find(p => p.available).id   // 'bitrix-cloud'

const [plans, regions, images] = await Promise.all([
  api('GET', `/infra/providers/${providerId}/plans`),
  api('GET', `/infra/providers/${providerId}/regions`),
  api('GET', `/infra/providers/${providerId}/images`),
])

const body = {
  provider: providerId,
  name: 'my-app',
  plan: plans.data.find(p => p.id === 'bc-small').id,
  region: regions.data[0].id,
  image: images.data[0].id,
}
```

## See also

- [Creating a server](/docs/infra/servers/create) — where the chosen identifiers go.
- [Root section — Infrastructure](/docs/infra) — overview, quick start, full example.
