---
title: "Review before publishing"
description: "Show which build would go live, what blocks it and the generation to publish against."
canonical: "https://atelier201.com/docs/api/publishing/review"
updated: "2026-11-06"
---

# Review before publishing

Requires `sites:read`. Changes nothing.

Call this before every publish and show the person what it returned. Send `expected_generation` to [Publish a build](/docs/api/publishing/publish) so that only this reviewed state goes live.

A build cannot be published while `blockers` is not empty. Each blocker has a `code` and a `message`: `guest_site`, `site_unavailable`, `plan_required` (the site is a draft: publishing needs the Site plan), `no_build`, `build_not_ready`, `origin_changed`, `manual_check` (this version waits for a quick check on our side: there is nothing to fix) or `older_than_draft`. See [How a site goes live](/docs/platform/drafts-builds-and-publishing).

`warnings` never block. Read them before publishing: `sample_text` names, with file and line, any sample text left, such as Lorem ipsum.

```http
GET https://api.atelier201.com/v1/sites/{site_id}/publish/review
```

## Authorizations

- `Authorization` (bearer, in header, required)

## Path parameters

- `site_id` (`string`, required): The site's id, or its slug (the address before .atelier201.page).

## Query parameters

- `build_id` (`string<uuid>`, pattern: `^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$`)
- `allow_older_build` (`boolean`): Review a build older than the draft as one you mean to put live (older_than_draft is then a warning, not a blocker).

## Response

**200**: Review before publishing

- `data` (`object`, required)
- `data.site_id` (`string`, required)
- `data.url` (`string`, required)
- `data.platform_address` (`object`, required): The address included with the site, which set_site_address changes. is_main: visitors land on it, no custom domain has taken over.
- `data.platform_address.slug` (`string`, required)
- `data.platform_address.domain` (`string`, required)
- `data.platform_address.is_main` (`boolean`, required)
- `data.build` (`object | null`, required)
- `data.build.id` (`string`, required)
- `data.build.site_id` (`string`, required)
- `data.build.revision` (`string`, required, length: `40–40 chars`): A Git commit id (40 hex characters) of the site's repository.
- `data.build.state` (`enum<string>`, required, one of: `queued, building, collecting, ready, failed, cancelled`)
- `data.build.target_origin` (`string`, required)
- `data.build.profile` (`enum<string>`, required, one of: `standard, guest-demo`)
- `data.build.file_count` (`integer | null`, required)
- `data.build.total_bytes` (`integer | null`, required)
- `data.build.duration_ms` (`integer | null`, required)
- `data.build.error` (`object | null`, required)
- `data.build.error.code` (`string`, required)
- `data.build.error.message` (`string,null`, required)
- `data.build.warnings` (`string[]`, required)
- `data.build.created_at` (`string`, required): ISO 8601, UTC.
- `data.build.started_at` (`string | null`, required)
- `data.build.finished_at` (`string | null`, required)
- `data.revision` (`string | null`, required)
- `data.draft_revision` (`string | null`, required)
- `data.is_latest_draft` (`boolean`, required)
- `data.live_build_id` (`string,null`, required)
- `data.expected_generation` (`integer`, required, range: `-9007199254740991–9007199254740991`)
- `data.can_publish` (`boolean`, required)
- `data.blockers` (`object[]`, required)
- `data.blockers.code` (`string`, required)
- `data.blockers.message` (`string`, required)
- `data.warnings` (`object[]`, required): Allowed but worth a decision. older_than_draft here means the reviewed build is older than the draft and was allowed (allow_older_build), or no build_id was named.
- `data.warnings.code` (`string`, required)
- `data.warnings.message` (`string`, required)
- `request_id` (`string`, required)

```json
{
  "data": {
    "site_id": "<string>",
    "url": "<string>",
    "platform_address": {
      "slug": "<string>",
      "domain": "<string>",
      "is_main": true
    },
    "build": {
      "id": "<string>",
      "site_id": "<string>",
      "revision": "<string>",
      "state": "queued",
      "target_origin": "<string>",
      "profile": "standard",
      "file_count": 123,
      "total_bytes": 123,
      "duration_ms": 123,
      "error": {
        "code": "<string>",
        "message": null
      },
      "warnings": [
        "<string>"
      ],
      "created_at": "<string>",
      "started_at": "<string>",
      "finished_at": "<string>"
    },
    "revision": "<string>",
    "draft_revision": "<string>",
    "is_latest_draft": true,
    "live_build_id": null,
    "expected_generation": 123,
    "can_publish": true,
    "blockers": [
      {
        "code": "<string>",
        "message": "<string>"
      }
    ],
    "warnings": [
      {
        "code": "<string>",
        "message": "<string>"
      }
    ]
  },
  "request_id": "<string>"
}
```

**400**: Possible codes: invalid_request, unknown_field, invalid_parameter, invalid_cursor

- `error` (`object`, required)
- `error.type` (`string`, required)
- `error.code` (`string`, required)
- `error.message` (`string`, required)
- `error.param` (`string`)
- `error.docs_url` (`string`, required)
- `error.action_url` (`string<uri>`)
- `error.details` (`Record<string, object>`)
- `request_id` (`string`, required)

```json
{
  "error": {
    "type": "<string>",
    "code": "<string>",
    "message": "<string>",
    "param": "<string>",
    "docs_url": "<string>",
    "action_url": "<string>",
    "details": {}
  },
  "request_id": "<string>"
}
```

**401**: Possible codes: authentication_required, invalid_api_key, api_key_expired, api_key_revoked

- `error` (`object`, required)
- `error.type` (`string`, required)
- `error.code` (`string`, required)
- `error.message` (`string`, required)
- `error.param` (`string`)
- `error.docs_url` (`string`, required)
- `error.action_url` (`string<uri>`)
- `error.details` (`Record<string, object>`)
- `request_id` (`string`, required)

```json
{
  "error": {
    "type": "<string>",
    "code": "<string>",
    "message": "<string>",
    "param": "<string>",
    "docs_url": "<string>",
    "action_url": "<string>",
    "details": {}
  },
  "request_id": "<string>"
}
```

**402**: Possible codes: insufficient_credits

- `error` (`object`, required)
- `error.type` (`string`, required)
- `error.code` (`string`, required)
- `error.message` (`string`, required)
- `error.param` (`string`)
- `error.docs_url` (`string`, required)
- `error.action_url` (`string<uri>`)
- `error.details` (`Record<string, object>`)
- `request_id` (`string`, required)

```json
{
  "error": {
    "type": "<string>",
    "code": "<string>",
    "message": "<string>",
    "param": "<string>",
    "docs_url": "<string>",
    "action_url": "<string>",
    "details": {}
  },
  "request_id": "<string>"
}
```

**403**: Possible codes: insufficient_scope, feature_not_available, admin_required

- `error` (`object`, required)
- `error.type` (`string`, required)
- `error.code` (`string`, required)
- `error.message` (`string`, required)
- `error.param` (`string`)
- `error.docs_url` (`string`, required)
- `error.action_url` (`string<uri>`)
- `error.details` (`Record<string, object>`)
- `request_id` (`string`, required)

```json
{
  "error": {
    "type": "<string>",
    "code": "<string>",
    "message": "<string>",
    "param": "<string>",
    "docs_url": "<string>",
    "action_url": "<string>",
    "details": {}
  },
  "request_id": "<string>"
}
```

**404**: Possible codes: resource_not_found

- `error` (`object`, required)
- `error.type` (`string`, required)
- `error.code` (`string`, required)
- `error.message` (`string`, required)
- `error.param` (`string`)
- `error.docs_url` (`string`, required)
- `error.action_url` (`string<uri>`)
- `error.details` (`Record<string, object>`)
- `request_id` (`string`, required)

```json
{
  "error": {
    "type": "<string>",
    "code": "<string>",
    "message": "<string>",
    "param": "<string>",
    "docs_url": "<string>",
    "action_url": "<string>",
    "details": {}
  },
  "request_id": "<string>"
}
```

**409**: Possible codes: conflict, result_not_ready, idempotency_key_reused

- `error` (`object`, required)
- `error.type` (`string`, required)
- `error.code` (`string`, required)
- `error.message` (`string`, required)
- `error.param` (`string`)
- `error.docs_url` (`string`, required)
- `error.action_url` (`string<uri>`)
- `error.details` (`Record<string, object>`)
- `request_id` (`string`, required)

```json
{
  "error": {
    "type": "<string>",
    "code": "<string>",
    "message": "<string>",
    "param": "<string>",
    "docs_url": "<string>",
    "action_url": "<string>",
    "details": {}
  },
  "request_id": "<string>"
}
```

**410**: Possible codes: result_expired

- `error` (`object`, required)
- `error.type` (`string`, required)
- `error.code` (`string`, required)
- `error.message` (`string`, required)
- `error.param` (`string`)
- `error.docs_url` (`string`, required)
- `error.action_url` (`string<uri>`)
- `error.details` (`Record<string, object>`)
- `request_id` (`string`, required)

```json
{
  "error": {
    "type": "<string>",
    "code": "<string>",
    "message": "<string>",
    "param": "<string>",
    "docs_url": "<string>",
    "action_url": "<string>",
    "details": {}
  },
  "request_id": "<string>"
}
```

**413**: Possible codes: request_too_large

- `error` (`object`, required)
- `error.type` (`string`, required)
- `error.code` (`string`, required)
- `error.message` (`string`, required)
- `error.param` (`string`)
- `error.docs_url` (`string`, required)
- `error.action_url` (`string<uri>`)
- `error.details` (`Record<string, object>`)
- `request_id` (`string`, required)

```json
{
  "error": {
    "type": "<string>",
    "code": "<string>",
    "message": "<string>",
    "param": "<string>",
    "docs_url": "<string>",
    "action_url": "<string>",
    "details": {}
  },
  "request_id": "<string>"
}
```

**422**: Possible codes: request_too_large_for_plan

- `error` (`object`, required)
- `error.type` (`string`, required)
- `error.code` (`string`, required)
- `error.message` (`string`, required)
- `error.param` (`string`)
- `error.docs_url` (`string`, required)
- `error.action_url` (`string<uri>`)
- `error.details` (`Record<string, object>`)
- `request_id` (`string`, required)

```json
{
  "error": {
    "type": "<string>",
    "code": "<string>",
    "message": "<string>",
    "param": "<string>",
    "docs_url": "<string>",
    "action_url": "<string>",
    "details": {}
  },
  "request_id": "<string>"
}
```

**429**: Possible codes: rate_limited

- `error` (`object`, required)
- `error.type` (`string`, required)
- `error.code` (`string`, required)
- `error.message` (`string`, required)
- `error.param` (`string`)
- `error.docs_url` (`string`, required)
- `error.action_url` (`string<uri>`)
- `error.details` (`Record<string, object>`)
- `request_id` (`string`, required)

```json
{
  "error": {
    "type": "<string>",
    "code": "<string>",
    "message": "<string>",
    "param": "<string>",
    "docs_url": "<string>",
    "action_url": "<string>",
    "details": {}
  },
  "request_id": "<string>"
}
```

**500**: Possible codes: internal_error

- `error` (`object`, required)
- `error.type` (`string`, required)
- `error.code` (`string`, required)
- `error.message` (`string`, required)
- `error.param` (`string`)
- `error.docs_url` (`string`, required)
- `error.action_url` (`string<uri>`)
- `error.details` (`Record<string, object>`)
- `request_id` (`string`, required)

```json
{
  "error": {
    "type": "<string>",
    "code": "<string>",
    "message": "<string>",
    "param": "<string>",
    "docs_url": "<string>",
    "action_url": "<string>",
    "details": {}
  },
  "request_id": "<string>"
}
```

**503**: Possible codes: service_unavailable

- `error` (`object`, required)
- `error.type` (`string`, required)
- `error.code` (`string`, required)
- `error.message` (`string`, required)
- `error.param` (`string`)
- `error.docs_url` (`string`, required)
- `error.action_url` (`string<uri>`)
- `error.details` (`Record<string, object>`)
- `request_id` (`string`, required)

```json
{
  "error": {
    "type": "<string>",
    "code": "<string>",
    "message": "<string>",
    "param": "<string>",
    "docs_url": "<string>",
    "action_url": "<string>",
    "details": {}
  },
  "request_id": "<string>"
}
```

**Example request**

```bash
curl --request GET \
  --url 'https://api.atelier201.com/v1/sites/<site_id>/publish/review' \
  --header 'Authorization: <api-key>'
```
