---
title: "Render a private firm-branded engagement-letter PDF preview"
method: POST
path: "/client-onboarding/engagement-letter/preview-pdf"
tags: ["Client Onboarding"]
---

# Render a private firm-branded engagement-letter PDF preview

`POST /client-onboarding/engagement-letter/preview-pdf`

## Request

- Base URL: `https://ledgerhq.pro/api/v1`
- URL: `https://ledgerhq.pro/api/v1/client-onboarding/engagement-letter/preview-pdf`
- Auth: one of:
  - HTTP bearer and API key in header `x-organization-id`
  - HTTP bearer and API key in header `x-organization-id`

Renders the submitted unsaved structured document with the authenticated firm's report branding and safe sample merge values. It does not save or publish the document. Requires Firm Owner or Admin access.

## Request body

- ClientOnboardingLoePreviewRequest
  - `document` ClientOnboardingLoeDocument, required
    - `type` 'doc', required
    - `content` ClientOnboardingLoeNode[], required
      - union
        - object
          - `type` 'text', required
          - `text` string, required
          - `marks` ClientOnboardingLoeMark[]
            - union
              - …
        - object
          - `type` 'mergeField', required
          - `attrs` object, required
            - `key` 'firm.name' | 'firm.email' | 'firm.phone' | 'firm.website' | 'client.name' | 'client.title' | 'client.email' | 'business.legalName' | 'package.name' | 'package.services' | 'package.monthlyPrice' | 'package.setupFee' | 'agreement.signingDate' | 'contact.name' | 'contact.title' | 'contact.email' | 'contact.phone', required
            - `label` string
        - object
          - `type` 'hardBreak', required
        - object
          - `type` 'paragraph', required
          - `content` ClientOnboardingLoeNode[]
        - object
          - `type` 'heading', required
          - `attrs` object, required
            - `level` 2 | 3, required
          - `content` ClientOnboardingLoeNode[]
        - object
          - `type` 'bulletList' | 'orderedList' | 'listItem', required
          - `content` ClientOnboardingLoeNode[], required
  - `packageId` string, uuid

## Response `200`

Private engagement-letter PDF preview

## Other responses

- `default`: Error response

---

[API](https://skmtc.dev/ledgerhq-pro/apis/ledgerhq-bookkeeping-api.md) · [All operations](https://skmtc.dev/ledgerhq-pro/apis/ledgerhq-bookkeeping-api/llms.txt) · [OpenAPI document](https://skmtc.dev/ledgerhq-pro/apis/ledgerhq-bookkeeping-api/revisions/9a8269f0a586?raw)
