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

# Generate video upload URL

> Creates a new video record and returns a presigned URL for uploading the video file to R2 storage. The URL expires after 20 minutes.



## OpenAPI

````yaml /swagger/management-api.json put /api/v1/{team_slug}/{app_slug}/videos
openapi: 3.0.0
info:
  contact:
    email: support@enad.io
    name: API support
    url: http://enad.io/support
  description: This is the documentation for Public API v1
  license:
    name: Apache 2.0
    url: http://www.apache.org/licenses/LICENSE-2.0.html
  termsOfService: http://enad.io/terms/
  title: Public API
  version: '1.0'
servers:
  - url: //api.enad.io
security: []
paths:
  /api/v1/{team_slug}/{app_slug}/videos:
    put:
      tags:
        - Videos
      summary: Generate video upload URL
      description: >-
        Creates a new video record and returns a presigned URL for uploading the
        video file to R2 storage. The URL expires after 20 minutes.
      parameters:
        - description: App slug
          in: path
          name: app_slug
          required: true
          schema:
            type: string
        - description: Team slug
          in: path
          name: team_slug
          required: true
          schema:
            type: string
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/internal_pkg_webserver_v1.UploadVideoUrl'
        description: Video payload
        required: true
      responses:
        '200':
          description: Presigned URL generated successfully
          content:
            application/json:
              schema:
                $ref: >-
                  #/components/schemas/internal_pkg_webserver_v1.OkResponseVideoUrl
        '400':
          description: Invalid request
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/internal_pkg_webserver_v1.ErrorMessage'
        '401':
          description: Unauthorized access
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/internal_pkg_webserver_v1.ErrorMessage'
        '500':
          description: Internal server error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/internal_pkg_webserver_v1.ErrorMessage'
      security:
        - BearerAuth: []
components:
  schemas:
    internal_pkg_webserver_v1.UploadVideoUrl:
      properties:
        content_type:
          type: string
        description:
          type: string
        filename:
          type: string
        size_bytes:
          type: integer
        title:
          type: string
        video_variants:
          items:
            $ref: '#/components/schemas/internal_pkg_webserver_v1.VideoVariant'
          type: array
      required:
        - content_type
        - filename
        - size_bytes
        - title
      type: object
    internal_pkg_webserver_v1.OkResponseVideoUrl:
      properties:
        data:
          $ref: >-
            #/components/schemas/github_com_enadhq_nabbit_internal_pkg_webserver_models.VideoUrl
        details:
          description: >-
            Additional contextual information about the response. Used to
            provide supplementary details beyond the main data payload, such as
            validation warnings or processing notes
          items:
            type: string
          type: array
        success:
          type: boolean
      type: object
    internal_pkg_webserver_v1.ErrorMessage:
      properties:
        details:
          items:
            type: string
          type: array
        message:
          type: string
        success:
          type: boolean
      type: object
    internal_pkg_webserver_v1.VideoVariant:
      properties:
        format:
          type: string
        height:
          type: integer
        width:
          type: integer
      required:
        - format
        - height
        - width
      type: object
    github_com_enadhq_nabbit_internal_pkg_webserver_models.VideoUrl:
      properties:
        constraints:
          $ref: >-
            #/components/schemas/github_com_enadhq_nabbit_internal_pkg_webserver_models.Constraint
        expires_at:
          type: integer
        id:
          type: string
        path:
          type: string
        upload_url:
          type: string
      type: object
    github_com_enadhq_nabbit_internal_pkg_webserver_models.Constraint:
      properties:
        allowed_types:
          items:
            type: string
          type: array
        max_size_bytes:
          type: integer
      type: object

````