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

# Get an earlier version of subtitles

> The segments of one earlier version, in the shape of `GET .../subtitles`, so it can be compared with the current track or sent back with `PUT .../subtitles` to restore it. Needs read access to the step and language of the track.



## OpenAPI

````yaml /openapi/phrase-studio.json get /v1/projects/{projectId}/recordings/{recordingId}/subtitles/versions/{versionId}
openapi: 3.0.3
info:
  title: Studio API
  description: >-
    Studio turns audio and video into transcriptions, translations, subtitles
    and dubbing. Use this API to create projects, order translation and dubbing,
    follow the progress, and download the results.


    ## Authentication

    Send your Phrase Platform API token with every request, as `X-API-Key:
    <token>` or as `Authorization: Bearer <token>`. A missing, invalid or
    expired token is answered with `401`. `403` means the token is valid but the
    action is not allowed: the item is someone else's, a share does not include
    the step or language, or your organization is blocked.


    ## Typical flow

    1. Create a project with `POST /v1/projects`: upload files, or give direct
    links to media files. It answers with the project `id`. To add a recording
    to a project that exists, call `POST
    /v1/projects/{projectId}/recordings/upload-url`, upload the file to the url
    it returns, then call `POST /v1/projects/{projectId}/recordings`.

    2. Poll `GET /v1/projects/{projectId}/recordings/{recordingId}/status` until
    the transcription is `done`. Every long step answers `202` and runs in the
    background: you poll the status, you do not wait on the call.

    3. Optional: `POST
    /v1/projects/{projectId}/recordings/{recordingId}/estimates` tells what a
    translation costs before you start it.

    4. Order translation with `POST …/translate`, and wait until the status
    shows the language as `done`.

    5. Order dubbing with `POST …/dubbing`. A language must be translated before
    it can be dubbed, otherwise the call answers `400`.

    6. Read and download: `GET …/subtitles` for the text, the result endpoints
    for summary and insights, `POST …/exports` for a file, then `GET
    …/exports/{exportId}` until it is `done`.


    ## Credits

    Credits are minutes. Transcription and every new translation language use
    `ceil(duration / 60)` minutes of the recording. Dubbing, retranscription and
    retranslation use none. The estimate endpoint tells the price in advance.
    When an organization has no credits left, starting work is refused with
    `403` (`No remaining minutes available`): creating a project, adding a
    recording, transcribe, translate, dubbing, sync-dubbing and speech. Reading
    results, estimates and editing the text of subtitles still work. The same
    goes for a re-dub (`PUT .../subtitles` with `segmentsToRedub`), re-syncing a
    dubbing and generating speech with `POST /v1/tts/speech`: they make new
    speech, so a blocked organization is refused for them too.


    ## Errors

    Errors are JSON: `{ "statusCode": 400, "message": "...", "timestamp": "..."
    }`. The `message` says what to change.

    - `400` the request is invalid.

    - `401` the token is missing, invalid or expired.

    - `403` the token is valid but the action is not allowed: your share of a
    project does not include the step or language, the project does not exist or
    is not shared with you (project routes do not tell the two apart), or your
    organization has no credits left for an action that needs them.

    - `404` the item does not exist, or you may not manage it: a recording that
    is not in the project, or a glossary, template, insight, pronunciation set,
    subtitle profile, font or voice of your organization that does not exist.
    Settings of another organization answer `404` too.

    - `409` the request conflicts with what exists: a name that is taken, a
    recording that was added already, a speaker that is still in use, or a
    template that a trigger still uses. The message says which.

    - `429` too many requests; wait and try again.

    - `5xx` a failure on our side or at a provider; try again later.


    ## Where the ids come from

    Ids that Studio accepts but does not list belong to other Phrase products.
    `tmsProjectTemplateUid`, `termBases`, `mtProfileId` and
    `translationMemoryId` are Phrase TMS uids: get them from the Phrase TMS API
    (project templates, term bases, translation memories, machine translation
    profiles). `styleGuides` ids come from the Style Guides API. Both are
    described at https://developers.phrase.com/en/api/overview. Every other id
    (projects, recordings, glossaries, insights, pronunciations, templates,
    subtitle profiles, voices) comes from the list endpoints of this API.
  version: 1.0.0
servers:
  - url: https://api.studio.us.phrase.com
    description: Production US Environment
  - url: https://api.studio.eu.phrase.com
    description: Production EU Environment
security: []
tags:
  - name: Projects
    description: >-
      Create, list, open, rename, archive, copy and delete projects. A project
      holds one or more recordings. Start here with `POST /v1/projects`.
  - name: Recordings
    description: >-
      The recordings of a project: add one, follow its status, order translation
      and dubbing, manage its speakers, delete it. Long steps answer `202`; poll
      `GET …/status` for the result.
  - name: Subtitle Profiles
    description: >-
      Subtitle layout rules (line length, reading speed and so on). Pick one per
      language when you create a project. Members of your organization can read
      them; the owner or a manager changes them.
  - name: Fonts
    description: >-
      The custom fonts of your organization, the same as the Custom Fonts
      settings of Studio: list, rename, delete and download them. Fonts are
      uploaded in Studio, where you confirm that you have the right to use them.
      Use the `fontFamily` value of a family (`custom:<id>`) in a subtitle
      profile to burn subtitles in that font.
  - name: Pronunciations
    description: >-
      Sets of words with the way to say them, used when text is turned into
      speech. Members of your organization can read them; the owner or a manager
      changes them.
  - name: Glossaries
    description: >-
      Terms and their translations, applied when a recording is translated.
      Members of your organization can read them; the owner or a manager changes
      them.
  - name: Insights
    description: >-
      Questions Studio answers about a recording, such as topics or action
      items. Members of your organization can read them; the owner or a manager
      changes them.
  - name: Safe Communications
    description: >-
      The safe communication checks Studio can run on a recording. List them
      here, then use their ids when you create a project.
  - name: Subtitles
    description: >-
      Read and replace the subtitle tracks of a recording (transcription,
      translation, dubbing), and read their saved versions.
  - name: Templates
    description: >-
      Saved sets of project settings: languages, preferences and translation
      settings. Members of your organization can read them; the owner or a
      manager changes them.
  - name: Voices
    description: >-
      The saved voices ("My voices") of your organization. Use a voice id to dub
      a speaker with it.
  - name: Exports
    description: >-
      Get the results as files: subtitles as text or documents, the source
      media, and the dubbed audio of a segment. A file export can run in the
      background; poll `GET …/exports/{exportId}` until it is `done`.
  - name: Results
    description: >-
      The saved results of a recording: summary, custom attributes, insights and
      safe communications. Order them with `summarize` and `transcribe`; they
      run in the background.
  - name: Dubbing audio
    description: >-
      Work on the audio of a dubbed language: bring the dubbing back in line
      with the translation, merge, split and change the speed of segments,
      replace the background audio, and read the state of those jobs.
  - name: Credits
    description: >-
      What an action would cost in credits, before you start it. Nothing is
      started and nothing is charged.
  - name: Text to speech
    description: >-
      Turn text into speech with a voice and an engine, and browse the voices:
      all, recommended and favorites. It does not need a project.
  - name: Preferences
    description: >-
      Your default settings for new projects: models, translation memory,
      machine translation profile and text-to-speech engine. A project can
      change them for itself.
paths:
  /v1/projects/{projectId}/recordings/{recordingId}/subtitles/versions/{versionId}:
    get:
      tags:
        - Subtitles
      summary: Get an earlier version of subtitles
      description: >-
        The segments of one earlier version, in the shape of `GET
        .../subtitles`, so it can be compared with the current track or sent
        back with `PUT .../subtitles` to restore it. Needs read access to the
        step and language of the track.
      operationId: getSubtitleVersion
      parameters:
        - name: projectId
          in: path
          required: true
          description: Project ID.
          schema:
            type: string
            format: uuid
        - name: recordingId
          in: path
          required: true
          description: Recording ID.
          schema:
            type: string
            format: uuid
        - name: versionId
          in: path
          required: true
          description: Version ID from the list of versions.
          schema:
            type: string
        - name: language
          in: query
          required: true
          description: Language of the track.
          schema:
            type: string
        - name: source
          in: query
          required: false
          description: Read the source-language track.
          schema:
            type: boolean
        - name: dubbing
          in: query
          required: false
          description: Read the dubbing track.
          schema:
            type: boolean
      responses:
        '200':
          description: Version
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/SubtitleSegmentResponse'
              examples:
                example:
                  summary: Example
                  value:
                    subtitles: []
                    participantNames:
                      - Alice
        '400':
          description: 'Bad request: a field is missing, empty or has the wrong type.'
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
              examples:
                e400:
                  summary: >-
                    Bad request: a field is missing, empty or has the wrong
                    type.
                  value:
                    statusCode: 400
                    message: name must be a string
                    timestamp: '2026-01-01T00:00:00.000Z'
        '401':
          description: Unauthorized (invalid API key).
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
              examples:
                e401:
                  summary: Unauthorized (invalid API key).
                  value:
                    statusCode: 401
                    message: Authorization failed
                    timestamp: '2026-01-01T00:00:00.000Z'
        '403':
          description: >-
            Forbidden: the project does not exist or is not shared with you, or
            your share of the project does not include this step or language.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
              examples:
                e403:
                  summary: 'Forbidden: you may not change this item.'
                  value:
                    statusCode: 403
                    message: You are not authorized to modify this item
                    timestamp: '2026-01-01T00:00:00.000Z'
        '404':
          description: The recording does not exist in this project.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
              examples:
                e404:
                  summary: Not found, or not visible to you.
                  value:
                    statusCode: 404
                    message: Not found
                    timestamp: '2026-01-01T00:00:00.000Z'
        '500':
          description: Internal server error.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
              examples:
                e500:
                  summary: Internal server error.
                  value:
                    statusCode: 500
                    message: Internal server error
                    timestamp: '2026-01-01T00:00:00.000Z'
      security:
        - apiKeyAuth: []
        - bearerAuth: []
components:
  schemas:
    SubtitleSegmentResponse:
      type: object
      required:
        - subtitles
        - participantNames
      properties:
        participantNames:
          type: array
          items:
            type: string
          description: Names of the speakers that appear in the track.
        bgVolume:
          type: number
          minimum: 0
          maximum: 2
          description: Volume of the background audio of a dubbing track, from 0 to 2.
        speakerVolumes:
          type: object
          additionalProperties:
            type: number
          description: Volume of each speaker of a dubbing track, by speaker identifier.
        speakerVoiceSettings:
          type: object
          additionalProperties:
            type: object
            additionalProperties: true
          description: >-
            Voice settings of each speaker of a dubbing track, by speaker
            identifier.
        subtitles:
          type: array
          items:
            $ref: '#/components/schemas/SubtitleSegmentResponseItem'
          description: The segments of the track.
        expandToContent:
          type: boolean
          description: >-
            Audio-only dubbing tracks only, present when it is on: each segment
            grows to the natural length of its speech instead of fitting the
            original timing. Read only: it is chosen with `expandToContent` of
            the dubbing request, and `PUT .../subtitles` does not accept it.
    ErrorResponse:
      type: object
      properties:
        success:
          type: boolean
          example: false
          description: >-
            `false`. Only errors of the upload service (`POST /v1/projects`)
            carry it; other errors have just `statusCode`, `message` and
            `timestamp`.
        statusCode:
          type: integer
          example: 400
          description: HTTP status code of the error.
        message:
          type: string
          example: Bad Request
          description: What went wrong, in words that can be shown to the caller.
        timestamp:
          type: string
          format: date-time
          example: '2025-01-01T00:00:00.000Z'
          description: When the error happened.
      required:
        - statusCode
        - message
        - timestamp
    SubtitleSegmentResponseItem:
      type: object
      required:
        - id
        - time_begin
        - time_end
        - words
        - speaker
        - language
      properties:
        id:
          type: string
          description: Segment identifier, stable across edits.
        speaker:
          type: string
          description: Speaker identifier (voice id or label).
        time_begin:
          type: number
          minimum: 0
          description: Segment start time in seconds.
        time_end:
          type: number
          minimum: 0
          description: Segment end time in seconds.
        words:
          type: array
          items:
            $ref: '#/components/schemas/SubtitleWord'
          description: >-
            Word-level text and timings. A word can carry `<b>`, `<i>` and `<u>`
            styling tags (for example `<i>really</i>`).
        language:
          type: string
          description: Language code of the segment.
        text:
          type: string
          description: >-
            Human-readable mirror of the segment text. `words` is the source of
            truth.
        metadata:
          allOf:
            - $ref: '#/components/schemas/SegmentMetadata'
          description: Review state and per-segment dubbing settings
        cue_settings:
          allOf:
            - $ref: '#/components/schemas/CueSettings'
          description: >-
            Position of this segment's subtitle on the video. Absent when the
            subtitle profile position is used.
        style:
          allOf:
            - $ref: '#/components/schemas/SubtitleStyle'
          description: >-
            Optional style of this segment's subtitle, overriding the subtitle
            profile (font, size, colors, background, position). Omit it to use
            the subtitle profile; a segment sent without `style` loses the style
            it had.
        comments:
          type: array
          maxItems: 200
          items:
            $ref: '#/components/schemas/SegmentComment'
          description: Reviewer comments of the segment. Absent when the segment has none.
    SubtitleWord:
      type: object
      required:
        - word
        - time_begin
        - time_end
      properties:
        word:
          type: string
          description: >-
            Word text, at most 500 characters. In a language that separates
            words with spaces, send one word per entry and keep the space that
            separates it from its neighbour at the start or end of the entry
            (`Hello ` then `world`); a whole sentence in one entry works for
            export but gives up word-level timing. In a language written without
            spaces (for example Japanese, Chinese or Thai) entries are joined
            exactly as sent.
          maxLength: 500
        time_begin:
          type: number
          minimum: 0
          description: Start time in seconds
        time_end:
          type: number
          minimum: 0
          description: End time in seconds
        is_eos:
          type: boolean
          description: Whether this word ends a sentence
    SegmentMetadata:
      type: object
      description: >-
        Editorial metadata of a segment. Fields that are not listed here are
        ignored by `PUT`.
      properties:
        review:
          $ref: '#/components/schemas/SegmentReview'
        dubbing:
          $ref: '#/components/schemas/SegmentDubbingMetadata'
        onScreenText:
          type: boolean
          description: >-
            True when the segment is text shown in the video rather than speech.
            On-screen text uses the speaker `On Screen Text`, is placed by
            `cue_settings` (the top centre when none is sent), is never dubbed
            and may overlap other segments.
        autoPlaced:
          type: boolean
          description: >-
            True when Studio moved this subtitle automatically so it does not
            cover on-screen text. Resetting the position in the editor clears
            it.
        detectedStyle:
          allOf:
            - $ref: '#/components/schemas/SubtitleStyle'
          description: >-
            How the video analysis saw an on-screen text drawn (font, size,
            colors, background). Studio's editor returns the segment's `style`
            to it on reset. Send it back unchanged; it is not an override and
            does not affect rendering.
    CueSettings:
      type: object
      description: >-
        Where a segment's subtitle is placed on the video, in WebVTT cue-setting
        notation. Every field is optional; a segment without `cue_settings` uses
        the position of the subtitle profile. Examples: top left
        `{"align":"left","line":"8%","position":"5%"}`, bottom center
        `{"line":"85%"}`. Studio's burn-in and the editor preview place the top
        of the subtitle box at `line` and the edge picked by `align` at
        `position`; vertical subtitle profiles ignore the position. Percentages
        outside 0–100% are clamped to the video when the subtitle is rendered.
      additionalProperties: false
      properties:
        align:
          type: string
          enum:
            - start
            - center
            - end
            - left
            - right
          description: Horizontal text alignment
        line:
          type: string
          pattern: ^-?\d{1,10}(\.\d{1,6})?%?$
          description: >-
            Vertical position: a percentage of the video height (`"8%"`,
            `"85%"`) or a WebVTT line number (`"0"`, `"-1"`)
        position:
          type: string
          pattern: ^\d{1,10}(\.\d{1,6})?%$
          description: >-
            Horizontal position as a percentage of the video width (`"5%"`,
            `"95%"`)
        size:
          type: string
          pattern: ^\d{1,10}(\.\d{1,6})?%$
          description: Width of the subtitle box as a percentage of the video width
        vertical:
          type: string
          enum:
            - rl
            - lr
          description: Vertical writing direction
        region:
          type: string
          pattern: ^[A-Za-z0-9_-]{1,64}$
          description: WebVTT region identifier
    SubtitleStyle:
      type: object
      description: >-
        Style of one segment's subtitle, overriding the matching fields of the
        subtitle profile. Every field is optional: a field that is left out
        follows the subtitle profile, and a segment sent without `style` loses
        the style it had. `delta` and `deltaX` (and `subtitlePosition`) place
        the subtitle the way the subtitle profile does; when any of them is set,
        the segment's `cue_settings` position is ignored for that segment.
        Studio's editor preview and burn-in follow the style; SRT and WebVTT
        exports carry no style. Vertical subtitle profiles ignore it.
      additionalProperties: false
      properties:
        fontFamily:
          type: string
          minLength: 1
          maxLength: 128
          description: >-
            Font name, or `custom:<id>` for an uploaded custom font. Must not
            contain commas, braces, backslashes or line breaks.
          pattern: >-
            ^(custom:[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}|(?!custom:)[^,\r\n{}\\]{1,128})$
        fontSize:
          type: number
          minimum: 8
          maximum: 100
          description: >-
            Font size, relative to a 720px-high video like the subtitle
            profile's
        fontWeight:
          type: string
          enum:
            - normal
            - bold
          description: Font weight.
        fontStyle:
          type: string
          enum:
            - normal
            - italic
          description: Font style.
        subtitlePosition:
          type: string
          enum:
            - top
            - bottom
            - center
            - right
            - middle
            - left
          description: >-
            Where the subtitle is anchored horizontally (`left`, `center`,
            `right`), as in the subtitle profile
        textAlign:
          type: string
          enum:
            - left
            - center
            - right
          description: Text alignment.
        textColor:
          type: string
          maxLength: 25
          description: >-
            `#RRGGBB`, or `rgb()` / `rgba()` for a color with transparency, e.g.
            `rgba(0, 0, 0, 0.7)` for a 70% opaque black. Eight-digit hex is not
            accepted.
          pattern: >-
            ^(#[0-9a-fA-F]{6}|rgba?\((25[0-5]|2[0-4]\d|1?\d?\d),
            ?(25[0-5]|2[0-4]\d|1?\d?\d), ?(25[0-5]|2[0-4]\d|1?\d?\d)(,
            ?(0|1|0?\.\d+|1\.0+))?\))$
        backgroundType:
          type: string
          enum:
            - none
            - box
            - outline
            - wrap
          description: How the text is separated from the video.
        backgroundColor:
          type: string
          maxLength: 25
          description: >-
            `#RRGGBB`, or `rgb()` / `rgba()` for a color with transparency, e.g.
            `rgba(0, 0, 0, 0.7)` for a 70% opaque black. Eight-digit hex is not
            accepted.
          pattern: >-
            ^(#[0-9a-fA-F]{6}|rgba?\((25[0-5]|2[0-4]\d|1?\d?\d),
            ?(25[0-5]|2[0-4]\d|1?\d?\d), ?(25[0-5]|2[0-4]\d|1?\d?\d)(,
            ?(0|1|0?\.\d+|1\.0+))?\))$
        delta:
          type: number
          minimum: 0
          maximum: 100
          description: >-
            Distance from the bottom, in percent of the video height. Higher
            moves the subtitle up.
        deltaX:
          type: number
          minimum: -50
          maximum: 50
          description: >-
            Shift from the center, in percent of the video width. Negative moves
            it left.
    SegmentComment:
      type: object
      description: A reviewer comment on a segment, as written in the Studio editor.
      required:
        - id
        - authorId
        - authorName
        - text
        - createdAt
      properties:
        id:
          type: string
          maxLength: 64
          description: >-
            Comment identifier, unique within the segment. Use a new UUID for a
            comment you create.
        authorId:
          type: string
          maxLength: 64
          description: Identifier of the author. Stored as sent and not verified.
        authorName:
          type: string
          maxLength: 200
          description: Display name of the author. Stored as sent and not verified.
        text:
          type: string
          maxLength: 2000
          description: Comment text
        createdAt:
          type: string
          format: date-time
          description: ISO 8601 creation time
        resolved:
          type: boolean
          description: True once the comment is resolved; omit for an open comment
    SegmentReview:
      type: object
      description: >-
        Review state of a segment. `PUT` stores it exactly as sent and the
        reviewer is not verified. Unlike the Studio editor, the API does not set
        a segment back to `PENDING` when its text changes, so send `PENDING`
        yourself for segments you rewrite.
      required:
        - status
      properties:
        status:
          type: string
          enum:
            - PENDING
            - REVIEWED
          description: >-
            `REVIEWED` once a reviewer approved the segment, `PENDING`
            otherwise.
        reviewedBy:
          type: object
          description: The reviewer
          required:
            - id
            - name
          properties:
            id:
              type: string
              format: uuid
              description: Identifier of the reviewer.
            name:
              type: string
              description: Display name of the reviewer.
        reviewedAt:
          type: string
          format: date-time
          description: When the segment was reviewed
    SegmentDubbingMetadata:
      type: object
      description: >-
        Per-segment dubbing settings. Only used on dubbing tracks. Fields that
        are not listed here are ignored by `PUT`.
      properties:
        volume:
          type: number
          minimum: 0
          maximum: 2
          description: Gain of this segment's dubbing audio, from 0 (mute) to 2 (double)
        stability:
          type: number
          minimum: 0
          maximum: 1
          description: >-
            Voice stability of this segment, from 0 to 1. Lower values give a
            more varied, expressive delivery, higher values a more even one.
            Overrides the speaker's setting for this segment. Only providers
            that support it use it (ElevenLabs); others ignore it. A value
            outside 0–1 is rejected with `400`.
        similarity:
          type: number
          minimum: 0
          maximum: 1
          description: >-
            How closely this segment follows the voice it clones, from 0 to 1.
            Higher values stay closer to the original voice, which can also
            reproduce its accent. Overrides the speaker's setting for this
            segment. Only providers that support it use it (ElevenLabs); others
            ignore it. A value outside 0–1 is rejected with `400`.
        needsRedub:
          type: boolean
          description: >-
            True when the text changed after the audio of this segment was
            generated
        ttsDuration:
          type: number
          readOnly: true
          description: >-
            Duration of the generated audio in seconds. Returned by `GET`;
            accepted and ignored on `PUT`, so a `GET` response can be sent back
            unchanged.
        originalTtsDuration:
          type: number
          readOnly: true
          description: >-
            Duration of the audio before it was fitted to the segment, in
            seconds. Returned by `GET`; ignored on `PUT`.
        estimatedTtsDuration:
          type: number
          readOnly: true
          description: >-
            Estimated audio duration before synthesis, in seconds. Returned by
            `GET`; ignored on `PUT`.
        ttsEstimationError:
          type: number
          readOnly: true
          nullable: true
          description: >-
            Difference between the estimate and the generated audio. Returned by
            `GET`; ignored on `PUT`.
  securitySchemes:
    apiKeyAuth:
      type: apiKey
      in: header
      name: X-API-Key
      description: >-
        Your Phrase Platform API token in the `X-API-Key` header. A missing,
        invalid or expired token is answered with `401`. `403` means the token
        is valid but the action is not allowed for it.
    bearerAuth:
      type: http
      scheme: bearer
      description: >-
        The same Phrase Platform API token as `Authorization: Bearer <token>`.
        Use either this or `X-API-Key`, not both. Errors are the same: `401` for
        a token that is missing, invalid or expired, `403` for an action that is
        not allowed.

````

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