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

# Get Project Clips

> Retrieve all clips generated from a video project

> **For AI agents:** a documentation index is at [/llms.txt](/llms.txt). Every page is also available as markdown, just append `.md` to the URL.

## Overview

Get all clips generated from a completed video project. This endpoint returns downloadable URLs for each clip, along with metadata like virality scores, titles, and captions.

## Rate Limiting

This endpoint is rate limited to 10 requests per minute per API key.

## Response

<ResponseField name="clips" type="array">
  Array of clip objects

  <Expandable title="Clip Object">
    <ResponseField name="id" type="string">
      Unique identifier for the clip
    </ResponseField>

    <ResponseField name="projectId" type="string">
      ID of the parent project
    </ResponseField>

    <ResponseField name="clipUrl" type="string">
      Direct download URL for the final clip (includes captions if enabled)
    </ResponseField>

    <ResponseField name="startTime" type="number">
      Start time of the clip in the original video (seconds)
    </ResponseField>

    <ResponseField name="endTime" type="number">
      End time of the clip in the original video (seconds)
    </ResponseField>

    <ResponseField name="duration" type="number">
      Duration of the clip in seconds
    </ResponseField>

    <ResponseField name="topic" type="string">
      Primary topic or theme of the clip
    </ResponseField>

    <ResponseField name="title" type="string">
      AI-generated title for the clip
    </ResponseField>

    <ResponseField name="caption" type="string">
      AI-generated caption/description for the clip
    </ResponseField>

    <ResponseField name="language" type="string">
      Language of the clip content
    </ResponseField>

    <ResponseField name="translateTranscription" type="boolean">
      Whether transcription is translated
    </ResponseField>

    <ResponseField name="translationLanguages" type="array">
      Array of languages for translation
    </ResponseField>

    <ResponseField name="dubbingLanguage" type="string" optional>
      Target dubbing language (for dubbing projects)
    </ResponseField>

    <ResponseField name="transcriptionScript" type="string">
      Script format for transcription ("native" or "roman")
    </ResponseField>

    <ResponseField name="viralityScore" type="number">
      AI-predicted virality score (0-10, higher is better)
    </ResponseField>

    <ResponseField name="exportResolution" type="integer">
      Resolution of the exported clip
    </ResponseField>

    <ResponseField name="exportOrientation" type="string">
      Orientation of the exported clip ("landscape", "portrait", "square")
    </ResponseField>

    <ResponseField name="captionsPreset" type="string">
      Caption style preset used for this clip
    </ResponseField>

    <ResponseField name="enableCaptions" type="boolean">
      Whether captions are enabled for this clip
    </ResponseField>

    <ResponseField name="enableEmojis" type="boolean">
      Whether emojis are added to captions
    </ResponseField>

    <ResponseField name="enableHighlights" type="boolean">
      Whether keyword highlighting is enabled
    </ResponseField>

    <ResponseField name="metadata" type="object">
      Clip metadata including technical details
    </ResponseField>

    <ResponseField name="createdAt" type="integer">
      Unix timestamp when the clip was created
    </ResponseField>

    <ResponseField name="updatedAt" type="integer">
      Unix timestamp when the clip was last updated
    </ResponseField>
  </Expandable>
</ResponseField>

<ResponseField name="currentPage" type="integer">
  Current page number
</ResponseField>

<ResponseField name="totalPages" type="integer">
  Total number of pages available
</ResponseField>

<ResponseField name="totalClips" type="integer">
  Total number of clips in the project
</ResponseField>

## Example Request

<CodeGroup>
  ```bash cURL theme={"system"}
  curl -X GET "https://public.reap.video/api/v1/automation/get-project-clips?projectId=65f1a2b3c4d5e6f7a8b9c0d2&page=1&pageSize=10" \
    -H "Authorization: Bearer YOUR_API_KEY" \
    -H "Content-Type: application/json"
  ```

  ```javascript JavaScript theme={"system"}
  const projectId = '65f1a2b3c4d5e6f7a8b9c0d2';
  const response = await fetch(`https://public.reap.video/api/v1/automation/get-project-clips?projectId=${projectId}&page=1&pageSize=10`, {
    method: 'GET',
    headers: {
      'Authorization': 'Bearer YOUR_API_KEY',
      'Content-Type': 'application/json'
    }
  });

  const data = await response.json();
  console.log(`Found ${data.totalClips} clips`);
  data.clips.forEach(clip => {
    console.log(`${clip.title} (Score: ${clip.viralityScore})`);
  });
  ```

  ```python Python theme={"system"}
  import requests

  headers = {
      'Authorization': 'Bearer YOUR_API_KEY',
      'Content-Type': 'application/json'
  }

  project_id = '65f1a2b3c4d5e6f7a8b9c0d2'
  response = requests.get(
      f'https://public.reap.video/api/v1/automation/get-project-clips?projectId={project_id}&page=1&pageSize=10',
      headers=headers
  )

  data = response.json()
  print(f"Found {data['totalClips']} clips")
  for clip in data['clips']:
      print(f"{clip['title']} (Score: {clip['viralityScore']})")
  ```

  ```php PHP theme={"system"}
  <?php
  $projectId = '65f1a2b3c4d5e6f7a8b9c0d2';
  $url = 'https://public.reap.video/api/v1/automation/get-project-clips?projectId=' . $projectId . '&page=1&pageSize=10';
  $ch = curl_init($url);
  curl_setopt($ch, CURLOPT_HTTPHEADER, [
      'Authorization: Bearer YOUR_API_KEY',
      'Content-Type: application/json'
  ]);
  curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
  $response = curl_exec($ch);
  curl_close($ch);
  $data = json_decode($response, true);
  echo 'Found ' . $data['totalClips'] . " clips\n";
  foreach ($data['clips'] as $clip) {
      echo $clip['title'] . ' (Score: ' . $clip['viralityScore'] . ")\n";
  }
  ?>
  ```

  ```go Go theme={"system"}
  package main
  import (
      "encoding/json"
      "fmt"
      "io/ioutil"
      "net/http"
  )
  type Clip struct {
      Title         string  `json:"title"`
      ViralityScore float64 `json:"viralityScore"`
  }
  type Response struct {
      TotalClips int    `json:"totalClips"`
      Clips      []Clip `json:"clips"`
  }
  func main() {
      projectId := "65f1a2b3c4d5e6f7a8b9c0d2"
      url := fmt.Sprintf("https://public.reap.video/api/v1/automation/get-project-clips?projectId=%s&page=1&pageSize=10", projectId)
      req, _ := http.NewRequest("GET", url, nil)
      req.Header.Set("Authorization", "Bearer YOUR_API_KEY")
      req.Header.Set("Content-Type", "application/json")
      client := &http.Client{}
      resp, _ := client.Do(req)
      defer resp.Body.Close()
      body, _ := ioutil.ReadAll(resp.Body)
      var result Response
      json.Unmarshal(body, &result)
      fmt.Printf("Found %d clips\n", result.TotalClips)
      for _, clip := range result.Clips {
          fmt.Printf("%s (Score: %.1f)\n", clip.Title, clip.ViralityScore)
      }
  }
  ```

  ```java Java theme={"system"}
  import java.io.BufferedReader;
  import java.io.InputStreamReader;
  import java.net.HttpURLConnection;
  import java.net.URL;
  public class GetProjectClipsExample {
      public static void main(String[] args) throws Exception {
          String projectId = "65f1a2b3c4d5e6f7a8b9c0d2";
          URL url = new URL("https://public.reap.video/api/v1/automation/get-project-clips?projectId=" + projectId + "&page=1&pageSize=10");
          HttpURLConnection conn = (HttpURLConnection) url.openConnection();
          conn.setRequestMethod("GET");
          conn.setRequestProperty("Authorization", "Bearer YOUR_API_KEY");
          conn.setRequestProperty("Content-Type", "application/json");
          BufferedReader br = new BufferedReader(new InputStreamReader(conn.getInputStream()));
          StringBuilder response = new StringBuilder();
          String line;
          while ((line = br.readLine()) != null) {
              response.append(line);
          }
          br.close();
          System.out.println(response.toString());
      }
  }
  ```
</CodeGroup>

## Example Response

<CodeGroup>
  <CodeGroup.Tab label="200 OK">
    ```json theme={"system"}
    {
      "clips": [
        {
          "id": "65f1a2b3c4d5e6f7a8b9c0d4",
          "projectId": "65f1a2b3c4d5e6f7a8b9c0d2",
          "clipUrl": "https://cdn.reap.video/clips/65f1a2b3c4d5e6f7a8b9c0d4.mp4",
          "startTime": 45.2,
          "endTime": 75.8,
          "duration": 30.6,
          "topic": "AI Technology",
          "title": "The Future of Artificial Intelligence",
          "caption": "Exploring how AI will transform our daily lives and work in the next decade",
          "language": "en",
          "translateTranscription": false,
          "translationLanguages": [],
          "transcriptionScript": "native",
          "viralityScore": 8.7,
          "exportResolution": 1080,
          "exportOrientation": "portrait",
          "captionsPreset": "system_beasty",
          "enableCaptions": true,
          "enableEmojis": true,
          "enableHighlights": true,
          "metadata": {
            "duration": 30.6,
            "width": 1080,
            "height": 1920,
            "fps": 30,
            "bitrate": 4000000,
            "size": 25000000,
            "codec": "h264"
          },
          "createdAt": 1710001800,
          "updatedAt": 1710001800
        },
        {
          "id": "65f1a2b3c4d5e6f7a8b9c0d5",
          "projectId": "65f1a2b3c4d5e6f7a8b9c0d2",
          "clipUrl": "https://cdn.reap.video/clips/65f1a2b3c4d5e6f7a8b9c0d5.mp4",
          "startTime": 120.5,
          "endTime": 180.2,
          "duration": 59.7,
          "topic": "Machine Learning",
          "title": "Understanding Neural Networks",
          "caption": "A beginner-friendly explanation of how neural networks process information",
          "language": "en",
          "translateTranscription": false,
          "translationLanguages": [],
          "transcriptionScript": "native",
          "viralityScore": 7.3,
          "exportResolution": 1080,
          "exportOrientation": "portrait",
          "captionsPreset": "system_beasty",
          "enableCaptions": true,
          "enableEmojis": true,
          "enableHighlights": true,
          "metadata": {
            "duration": 59.7,
            "width": 1080,
            "height": 1920,
            "fps": 30,
            "bitrate": 4000000,
            "size": 48000000,
            "codec": "h264"
          },
          "createdAt": 1710001800,
          "updatedAt": 1710001800
        }
      ],
      "currentPage": 1,
      "totalPages": 3,
      "totalClips": 12
    }
    ```
  </CodeGroup.Tab>

  <CodeGroup.Tab label="400 Bad Request">
    ```json theme={"system"}
    {
      "detail": "Missing required parameter: projectId"
    }
    ```
  </CodeGroup.Tab>

  <CodeGroup.Tab label="401 Unauthorized">
    ```json theme={"system"}
    {
      "detail": "Unauthorized - Invalid or missing API key"
    }
    ```
  </CodeGroup.Tab>

  <CodeGroup.Tab label="404 Not Found">
    ```json theme={"system"}
    {
      "detail": "Project not found or no clips available"
    }
    ```
  </CodeGroup.Tab>

  <CodeGroup.Tab label="429 Too Many Requests">
    ```json theme={"system"}
    {
      "detail": "Too Many Requests - Rate limit of 10 requests per minute exceeded"
    }
    ```
  </CodeGroup.Tab>

  <CodeGroup.Tab label="500 Internal Server Error">
    ```json theme={"system"}
    {
      "detail": "Internal Server Error - Something went wrong on our end"
    }
    ```
  </CodeGroup.Tab>
</CodeGroup>

## Virality Score

The virality score is an AI-predicted metric (0-10) that indicates how likely a clip is to perform well on social media:

* **9-10**: Exceptional content with viral potential
* **7-8**: High-quality content likely to perform well
* **5-6**: Good content suitable for regular posting
* **3-4**: Average content that may need optimization
* **1-2**: Lower-quality content requiring review

## Clip Status

Clips are only returned when the parent project status is `completed`. If the project is still `processing`, this endpoint will return an empty clips array.

## Use Cases

<CardGroup cols={2}>
  <Card title="Content Distribution" icon="share">
    Download clips for posting across social platforms
  </Card>

  <Card title="Performance Analysis" icon="chart-line">
    Use virality scores to prioritize high-potential content
  </Card>

  <Card title="Batch Processing" icon="cubes">
    Retrieve all clips for automated publishing workflows
  </Card>

  <Card title="Quality Control" icon="search">
    Review clip titles and captions before publishing
  </Card>
</CardGroup>


## OpenAPI

````yaml GET /automation/get-project-clips
openapi: 3.1.0
info:
  title: Reap Automation API
  description: AI-powered video processing automation API
  version: 1.0.0
servers:
  - url: https://public.reap.video/api/v1
security:
  - bearerAuth: []
paths:
  /automation/get-project-clips:
    get:
      summary: Get Project Clips
      description: Retrieve all clips generated from a video project
      operationId: getProjectClips
      parameters:
        - $ref: '#/components/parameters/projectId'
        - $ref: '#/components/parameters/page'
        - name: pageSize
          in: query
          schema:
            type: integer
            default: 20
          description: Number of clips per page (max 100)
      responses:
        '200':
          description: Successful response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/GetClipsResponse'
components:
  parameters:
    projectId:
      name: projectId
      in: query
      required: true
      schema:
        type: string
      description: Unique identifier of the project
    page:
      name: page
      in: query
      schema:
        type: integer
        default: 1
      description: Page number for pagination
  schemas:
    GetClipsResponse:
      type: object
      properties:
        clips:
          type: array
          items:
            $ref: '#/components/schemas/AutomationClip'
        currentPage:
          type: integer
        totalPages:
          type: integer
        totalClips:
          type: integer
    AutomationClip:
      type: object
      properties:
        id:
          type: string
        projectId:
          type: string
        clipUrl:
          type: string
          nullable: true
          description: >-
            Direct download URL for the final clip (includes captions if
            enabled)
        startTime:
          type: number
        endTime:
          type: number
        duration:
          type: number
        topic:
          type: string
          nullable: true
        title:
          type: string
          nullable: true
        caption:
          type: string
          nullable: true
        language:
          type: string
          nullable: true
        translateTranscription:
          type: boolean
        translationLanguages:
          type: array
          items:
            type: string
        transcriptionScript:
          $ref: '#/components/schemas/TranscriptionScript'
        viralityScore:
          type: number
          nullable: true
        exportResolution:
          type: integer
        exportOrientation:
          $ref: '#/components/schemas/VideoOrientation'
        captionsPreset:
          type: string
          nullable: true
        enableCaptions:
          type: boolean
        enableEmojis:
          type: boolean
        enableHighlights:
          type: boolean
        metadata:
          $ref: '#/components/schemas/VideoFileMeta'
        createdAt:
          type: integer
        updatedAt:
          type: integer
    TranscriptionScript:
      type: string
      enum:
        - native
        - roman
      default: native
    VideoOrientation:
      type: string
      enum:
        - landscape
        - portrait
        - square
    VideoFileMeta:
      type: object
      properties:
        width:
          type: integer
        height:
          type: integer
        aspectRatio:
          type: string
        size:
          type: number
        bitrate:
          type: number
        fps:
          type: number
        duration:
          type: number
        rotation:
          type: integer
        resolution:
          type: integer
        codec:
          type: string
        codecFullName:
          type: string
        codecTag:
          type: string
        format:
          type: string
        formatFullName:
          type: string
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer

````