---
title: "Check whether card content fits at a given font"
method: POST
path: "/cards/preview_fit"
tags: ["Cards"]
---

# Check whether card content fits at a given font

`POST /cards/preview_fit`

## Request

- Base URL: `https://api.echtpost.de/v2`
- URL: `https://api.echtpost.de/v2/cards/preview_fit`
- Auth: one of:
  - OAuth 2 (authorization code, authorization URL `https://my.echtpost.de/oauth/authorize`, token URL `https://my.echtpost.de/oauth/token`, scopes: `mcp`)
  - API key in header `X-Api-Key`
  - HTTP bearer

## Request body

- object
  - `content` string, required: Plain text in the same shape as POST /v2/cards content; use JSON line breaks (\n) between paragraphs.
  - `sample_greeting` string: Optional greeting prefix to prepend for fit-check.
  - `font` PreviewFitFont: Optional. Omitted `family` defaults to architects_daughter; omitted `size` defaults to the middle allowed value for the family. Only these fields affect the fit check (no `color`).
    - `family` string: Font slug. Allowed `architects_daughter`, `reenie_beanie`, `special_elite`.
    - `size` integer: Absolute font size within the valid range for the chosen family.

## Response `200`

OK

- object
  - `fits` boolean
  - `lines_used` integer
  - `max_lines` integer
  - `overflow_line` integer, nullable
  - `suggested_font_size` integer, nullable

## Other responses

- `401`: Authentication required

---

[API](https://skmtc.dev/echtpost/apis/echtpost-api.md) · [All operations](https://skmtc.dev/echtpost/apis/echtpost-api/llms.txt) · [OpenAPI document](https://skmtc.dev/echtpost/apis/echtpost-api/revisions/6935f24e4c33?raw)
