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

# Looping Video

> Turns a single still image into a seamless 5-15 second looping MP4 video. Subtle, natural motion brings the image to life while the subject, composition, and lighting are preserved, and the video loops endlessly with no visible jump or cut. The camera stays fixed - no pans, zooms, tilts, or reframing. Processing is asynchronous: poll the job status endpoint returned in the `Location` header to retrieve the result.<br/><br/>
Provide exactly one image source: a multipart `image` file, a base64/data-URL `image`, or a remote `image_url`. Requests with no image source or more than one are rejected.<br/><br/>
**Pricing:**
  - 480p: 8 credits (\$0.08) per second
  - 768p: 16 credits (\$0.16) per second
  - Audio does not change the price.<br/><br/>

**Input Image Limits:**
  - Max size: 25MB
  - Min resolution: 64x64px
  - Max resolution: 6000x6000px
  - Supported formats: JPEG, PNG




## OpenAPI

````yaml POST /v1/video/loop
openapi: 3.1.0
info:
  description: >-
    The Pixelcut API specification, learn more about the API at at
    https://www.pixelcut.ai/docs
  version: 0.0.2
  title: Pixelcut API
  termsOfService: >-
    https://pixelcut.notion.site/Pixelcut-API-Terms-of-Service-11b3b550490080d89a91e943d010efdf
  contact:
    name: API Support
    email: api@pixelcut.ai
servers:
  - url: https://api.developer.pixelcut.ai
    description: Pixelcut API server
security: []
paths:
  /v1/video/loop:
    post:
      tags:
        - Endpoints
      summary: Looping Video
      description: >
        Turns a single still image into a seamless 5-15 second looping MP4
        video. Subtle, natural motion brings the image to life while the
        subject, composition, and lighting are preserved, and the video loops
        endlessly with no visible jump or cut. The camera stays fixed - no pans,
        zooms, tilts, or reframing. Processing is asynchronous: poll the job
        status endpoint returned in the `Location` header to retrieve the
        result.<br/><br/>

        Provide exactly one image source: a multipart `image` file, a
        base64/data-URL `image`, or a remote `image_url`. Requests with no image
        source or more than one are rejected.<br/><br/>

        **Pricing:**
          - 480p: 8 credits (\$0.08) per second
          - 768p: 16 credits (\$0.16) per second
          - Audio does not change the price.<br/><br/>

        **Input Image Limits:**
          - Max size: 25MB
          - Min resolution: 64x64px
          - Max resolution: 6000x6000px
          - Supported formats: JPEG, PNG
      operationId: video-loop
      requestBody:
        content:
          application/json:
            schema:
              type: object
              properties:
                image_url:
                  $ref: '#/components/schemas/ImageURLParameter'
                image:
                  $ref: '#/components/schemas/Base64ImageParameter'
                prompt:
                  $ref: '#/components/schemas/LoopPromptParameter'
                duration:
                  $ref: '#/components/schemas/LoopDurationParameter'
                resolution:
                  $ref: '#/components/schemas/LoopResolutionParameter'
                include_audio:
                  $ref: '#/components/schemas/LoopIncludeAudioParameter'
          multipart/form-data:
            schema:
              type: object
              properties:
                image:
                  $ref: '#/components/schemas/BinaryImageParameter'
                image_url:
                  $ref: '#/components/schemas/ImageURLParameter'
                prompt:
                  $ref: '#/components/schemas/LoopPromptParameter'
                duration:
                  $ref: '#/components/schemas/LoopDurationParameter'
                resolution:
                  $ref: '#/components/schemas/LoopResolutionParameter'
                include_audio:
                  $ref: '#/components/schemas/LoopIncludeAudioParameter'
      responses:
        '202':
          description: Accepted - processing has started
          content:
            application/json:
              schema:
                type: object
                properties:
                  job_id:
                    type: string
                    description: >-
                      A unique identifier for this job that can be used to check
                      status.
                    example: 6ba7b810-9dad-11d1-80b4-00c04fd430c8
                  status:
                    type: string
                    enum:
                      - pending
                    description: Initial job status.
                    example: pending
          headers:
            Location:
              description: Endpoint to poll for job status
              schema:
                type: string
                example: /v1/video/loop/job/6ba7b810-9dad-11d1-80b4-00c04fd430c8
        '400':
          $ref: '#/components/responses/Error400'
        '401':
          $ref: '#/components/responses/Error401'
        '403':
          $ref: '#/components/responses/Error403'
        '429':
          $ref: '#/components/responses/Error429'
        '500':
          $ref: '#/components/responses/Error500'
      security:
        - ApiKeyAuth: []
components:
  schemas:
    ImageURLParameter:
      type: string
      format: url
      description: URL of the image to be processed.
      example: https://cdn3.pixelcut.app/product.jpg
    Base64ImageParameter:
      type: string
      format: base64
      description: Base64 encoded representation of the image to be processed.
      example: data:image/jpeg;base64,/9j/4AAQSkZJRgABAQAAAQABAAD/......
    LoopPromptParameter:
      type: string
      maxLength: 1000
      description: >-
        Optional creative direction for the motion (e.g. what should move
        subtly). Directions requesting camera movement, cuts, new objects, or
        scene changes are ignored.
      example: clothes blowing subtly in the wind, person slightly moving
    LoopDurationParameter:
      type: integer
      format: int32
      minimum: 5
      maximum: 15
      default: 5
      description: Length of the looping video in whole seconds (5-15).
      example: 5
    LoopResolutionParameter:
      type: string
      enum:
        - 480p
        - 768p
      default: 768p
      description: >-
        Output resolution of the looping video. 480p costs 8 credits per second;
        768p costs 16 credits per second.
      example: 768p
    LoopIncludeAudioParameter:
      type: boolean
      default: true
      description: >-
        Whether the generated MP4 keeps its audio track. When false, the audio
        track is stripped and the result is guaranteed to contain no audio
        stream. Audio does not change the price.
      example: true
    BinaryImageParameter:
      type: string
      format: binary
      description: >-
        Binary file of the image to be processed, this is mutually exclusive
        with image_url, if both are provided the image will be used.
  responses:
    Error400:
      description: >-
        The input could not be processed, often returned when the input image
        exceeds API limits.
      content:
        application/json:
          schema:
            type: object
            properties:
              error:
                type: string
                description: A description of the error.
                example: File size too large
              error_code:
                type: string
                enum:
                  - invalid_request_body
                  - missing_parameter
                  - invalid_parameter
                  - unsupported_content_type
                  - malformed_image
                  - unsupported_image_format
                  - file_size_too_large
                  - resolution_too_high
                  - unknown_foreground
                example: file_size_too_large
                description: >
                  The error codes provide a way to programmatically handle
                  errors.  


                  The following error codes are currently in use:  

                  - `invalid_request_body`: The request body was empty or
                  invalid.

                  - `missing_parameter`: A required parameter was not provided.

                  - `invalid_parameter`: A parameter was provided but it was
                  invalid.

                  - `unsupported_content_type`: The content type of the request
                  was not application/json or multipart/form-data.

                  - `malformed_image`: The image could not be decoded.

                  - `unsupported_image_format`: The image format is not
                  supported.

                  - `file_size_too_large`: The image file size is too large.

                  - `resolution_too_high`: The image resolution is too high.

                  - `unknown_foreground`: The foreground subject of the image
                  could not be detected.
    Error401:
      description: The authentication token is missing or invalid.
      content:
        application/json:
          schema:
            type: object
            properties:
              error:
                type: string
                example: API Token not found
              error_code:
                type: string
                enum:
                  - invalid_auth_token
    Error403:
      description: >-
        Returned when you have insufficient credits to perform the requested
        action.
      content:
        application/json:
          schema:
            type: object
            properties:
              error:
                type: string
                example: Insufficient credits available
              error_code:
                type: string
                enum:
                  - insufficient_api_credits
    Error429:
      description: Rate limit exceeded
      content:
        application/json:
          schema:
            type: object
            properties:
              error:
                type: string
                example: Too many requests
              error_code:
                type: string
                enum:
                  - rate_limit_exceeded
    Error500:
      description: Internal service error
  securitySchemes:
    ApiKeyAuth:
      description: >
        All API requests require a valid api key. Include your token as a HTTP
        request header in the following format: `X-API-Key: skXXXXXXXXXXXXXXXX`.
        You can obtain an api key by signing up for developer access in your
        Pixelcut account.
      type: apiKey
      name: X-API-KEY
      in: header

````