---
title: "Export a screenplay as Fountain, Final Draft or PDF."
method: GET
path: "/scripts/{scriptUploadId}/export"
tags: ["Scripts"]
---

# Export a screenplay as Fountain, Final Draft or PDF.

`GET /scripts/{scriptUploadId}/export`

## Request

- Base URL: `https://docs.sleeperhit.studio/api/v1`
- URL: `https://docs.sleeperhit.studio/api/v1/scripts/{scriptUploadId}/export`
- Auth: HTTP bearer

The Writers Lab's export menu, through its core. Fountain and Final Draft (`fdx`) come back as text (`encoding: utf8`); a PDF base64-encoded (`encoding: base64`) — all in one JSON envelope with a filename and content type. The title page is kept unless `includeTitlePage=false`; `fromPage` / `toPage` pick a page range; `font` sets a PDF's typeface. Refused with 409 `script_state_invalid` for a version not parsed yet. Read-only; costs no credits.

## Query parameters

- `format` 'fountain' | 'fdx' | 'pdf', required
- `includeTitlePage` boolean
- `fromPage` integer
- `toPage` integer
- `font` 'screenplay-sim' | 'courier-prime' | 'courier-new' | 'final-draft'

## Response `200`

The exported screenplay.

- ScriptExportResponse
  - `scriptUploadId` string, required: The version exported.
  - `format` 'fountain' | 'fdx' | 'pdf', required
  - `filename` string, required
  - `contentType` string, required
  - `encoding` 'utf8' | 'base64', required: `utf8` for fountain and fdx (the text itself), `base64` for a PDF.
  - `content` string, required

## Other responses

- `400`: Request payload failed validation. The error message names the offending field.
- `401`: Missing, malformed, revoked, or expired API key.
- `403`: API key is valid but lacks the scope, is blocked by IP allowlist, or the account is disabled.
- `404`: The named project or source does not exist or is owned by another account.
- `409`: This version has not been parsed yet (`script_state_invalid`); export it once its parse has finished.
- `429`: Rate limit for this API key + IP + route family was exceeded.
- `500`: The API failed unexpectedly. Safe to retry with the same Idempotency-Key.

---

[API](https://skmtc.dev/sleeperhit/apis/sleeper-hit-studio-story-api.md) · [All operations](https://skmtc.dev/sleeperhit/apis/sleeper-hit-studio-story-api/llms.txt) · [OpenAPI document](https://skmtc.dev/sleeperhit/apis/sleeper-hit-studio-story-api/revisions/64c1102ccb2f?raw)
