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

# Obter layout de checkout

> Consulta um layout pelo ID

Permissão: `checkout_layout.read` (chave secreta).

## Endpoint

<CodeGroup>
  ```bash cURL theme={null}
  curl https://api.upag.dev/v1/checkout/layouts/c1d2e3f4-5a6b-4c7d-8e9f-0a1b2c3d4e5f \
    -H "Authorization: Bearer sk_test_your_api_key"
  ```

  ```javascript Node.js SDK theme={null}
  import { Upag } from 'upag';

  const upag = new Upag('sk_test_your_api_key');

  const layout = await upag.checkoutLayouts.retrieve('c1d2e3f4-5a6b-4c7d-8e9f-0a1b2c3d4e5f');
  ```
</CodeGroup>

<Note>
  Em produção use `https://api.upag.io/v1` com `sk_live_...`.
</Note>

## Parâmetros

<ParamField path="layoutId" type="string (uuid)" required>
  ID do layout.
</ParamField>

## Resposta

`200 OK` — objeto descrito na [referência](./reference).

```json Response theme={null}
{
  "id": "c1d2e3f4-5a6b-4c7d-8e9f-0a1b2c3d4e5f",
  "name": "Tema escuro",
  "theme": { "radius": "0.65rem", "background": "oklch(0.985 0 0)", "...": "demais chaves do tema" },
  "favicon": "https://example.com/favicon.png",
  "desktop": null,
  "mobile": null,
  "createdAt": "2026-03-18T11:15:00.000Z",
  "updatedAt": "2026-03-18T11:15:00.000Z"
}
```

`404` (`CHECKOUT_LAYOUT_NOT_FOUND`) se o layout não existir ou pertencer a outra conta.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.