---
title: "Price, then render, one chapter's text / motion-graphic layer."
method: POST
path: "/pitch-decks/{jobId}/storyboard/regenerate-text"
tags: ["Pitch Deck"]
---

# Price, then render, one chapter's text / motion-graphic layer.

`POST /pitch-decks/{jobId}/storyboard/regenerate-text`

## Request

- Base URL: `https://docs.sleeperhit.studio/api/v1`
- URL: `https://docs.sleeperhit.studio/api/v1/pitch-decks/{jobId}/storyboard/regenerate-text`
- Auth: HTTP bearer

Renders one chapter's on-screen text / motion-graphic layer with its current caption + treatment: a text-only chapter on its own, a text-over-footage chapter composited over its cut. Metered — charges a single per-text credit (returned as `credits`). Poll GET /pitch-decks/{jobId}/chapters. TWO CALLS, PRICE FIRST: sent WITHOUT `confirmed` it prices the render and reserves nothing (`quotedOnly: true`); sent again with `confirmed: true` it reserves the single credit line and queues the render. The flag is optional rather than a required `true` because a field that must be true to validate cannot separate a confirmed call from an unconfirmed one, and it would force the price to be announced after the money moved. Preconditions run above the price: a footage-only chapter carries no on-screen text and is refused with no quote at all. Review or complete only. A confirmed call returns `reviewUrl` + a shareable per-chapter `previewUrl`. Requires `Idempotency-Key`. Scope: `artifact:publish` — a read-only key can neither spend nor ask what spending would cost.

## Headers

- `Idempotency-Key` string, required

## Request body

- PitchDeckChapterIndexRequest: Target one chapter by index, and say whether this call is the price or the purchase.
  - `chapterIndex` integer, required: The chapter whose text layer to render. The chapter's `chapterIndex`, exactly as the chapters read returns it: a key, not a position — a plan may key its chapters from 0 or from 1. A person's "chapter 2" is the chapter whose `chapterNumber` is 2; pass that chapter's `chapterIndex`.
  - `confirmed` boolean: Omit (or false) to get the price WITHOUT spending anything — nothing is reserved and nothing is queued. Send true only after the writer has seen that price and said go. It is optional rather than a required `true` because a field that must be true to validate cannot separate a confirmed call from an unconfirmed one.

## Response `200`

The price (no `confirmed`) or the queued render, plus a shareable chapter preview link.

- PitchDeckTextRenderAnswer: Either the PRICE of a chapter's text-layer render or the queued render itself — branch on `quotedOnly`. Sent without `confirmed`, the call quotes and nothing is reserved; sent with `confirmed: true`, the credit is held and the render is queued.
  - `quotedOnly` boolean, required: True when this was a price and NOTHING was spent; false when the render was reserved and queued.
  - `chapterIndex` integer
  - `previewUrl` string: Shareable link to watch this chapter's current cut.
  - `reviewUrl` string, nullable: Logged-in browser link to the deck. Present on a confirmed call.
  - `credits` number: Credits charged for this render, or — when `quotedOnly` is true — what a confirmed call would charge.
  - `costLabel` string, nullable: The rate-card line the price came from (quote only).
  - `balanceAfter` integer: Quote only. Studio Credits the writer would have left once this is spent: the balance available now (as Billing shows it) minus the price. Negative means they are that many short.
  - `sufficient` boolean: Quote only. True when the available balance covers the price. False means the writer must top up first (the note names the Billing link) — do not confirm; the reserve would refuse.
  - `note` string: The price in the writer's own words, what it would leave (or how short they are, with the top-up link), and how to proceed (quote only).

## Other responses

- `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`: The pitch deck exists and the request is well-formed, but the deck, its chapter, its cast or its plates are not in a state that allows it (`pitch_deck_state_invalid`), and nothing was reserved: a plan approved outside draft, a take chosen, a chapter edited or rendered outside review/complete, an export before the finish, a finish while a call has no selected take or a footage chapter has not rendered, a text-only chapter asked for footage, a changed chapter asked for one call, a delivery class changed mid-pass, a render the compile blocked, or a finish while the master failed its video coverage (`pitch_deck_video_coverage_failed`, with `details.videoCoverage`). `details.refusal` is `{ code, action, fix }` (see PitchDeckRefusalDetails): `action` is what unblocks it — `recast_figure`, `add_signature_items`, `recast_voice` or `remake_location_plate` — and `fix` names the MCP tool and CLI command that take it; `details.blocked[]` lists every chapter a blocked compile could not render. The identical request succeeds once the deck is put right.
- `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/4534f5d25540?raw)
