DynTube API
  • Welcome!
  • Key Concepts
  • Quick Start
  • Reference
    • Videos
      • Video Upload via File (Server Side)
      • Video Upload via URL (server side)
      • HTML-Form Client Side Video Uploads
      • Get Video Status
      • Get Videos
      • Get Video
      • Update Video
      • Delete Video
      • Download Original Video
      • Get Video for Mobile App/Custom Player
      • Update Video Image
      • Add Video Captions/Chapters/Subtitles
      • Delete Video Captions/Subtitles/Chapters
      • Create Expirable Links
      • Get Collected Emails
      • Setting Up Webhooks
      • Copy call-to-action (CTA) to Videos
      • Token Authentication
    • Projects
      • Create Project
      • Update a Project
      • Get Projects
      • Get a Project
      • Delete a Project
      • Set default CTA for Project
    • Live Streaming
      • Create a Live Stream
      • Update a Live Stream
      • Get Live Streams
      • Get a Live Stream
      • Count Live Streams
      • Live Streams Limit
      • Get Live Streaming Recording
      • Delete a Live Stream
      • Service and Regions for live streams
    • Channels
      • Get Channels
      • Get Channel
      • Delete Channel
    • Subscriptions
      • Create a Plan
      • Create a Member
      • Attach Plan To Member
      • Get Plans
      • Get Members
      • Get Member's Plans
      • Delete a Plan
    • Analytics
      • Use your User Ids in Analytics
      • Get Video Analytics
    • Javascript Events Methods
      • Plain Javascript Events & Methods
      • Control the Player using React
      • Control the Player in Vue.js
    • Developer Resources
      • How to embed DynTube player in Next.Js
      • How to embed the video player in React
      • How to play DynTube videos in React Native
      • ExoPlayer app to play HLS videos
      • How to embed videos & channels dynamically
      • How to Import Vimeo Videos into DynTube
Powered by GitBook
On this page
  • 1. Generate Upload URL on Server Side
  • 2. Upload Videos using HTML From
  • Upload by file
  1. Reference
  2. Videos

HTML-Form Client Side Video Uploads

Utilize this approach to enable video uploads from the client side through your browser-based HTML website.

Please don't use your API key on the client/browser side. Use this method to upload videos directly from the client side of your web app.

1. Generate Upload URL on Server Side

Please keep in mind that the URL generated by this endpoint has a validity period of 24 hours. To ensure uninterrupted functionality, remember to call this endpoint every 24 hours to regenerate the upload URL.

GET https://api.dyntube.com/v1/uploads/browser-upload-url

Use this endpoint to get a URL using the API key on the server side of your app. The returned URL can be used to POST the files from your HTML FORM in the browser.

Headers

Name
Type
Description

Authorization

String

Bearer [API TOKEN]

2. Upload Videos using HTML From

  • The file can be added to form into an input named "file".

  • The Content-Type should be multipart/form-data.

  • You can optionally provide other fields, such as projectId.

Upload by file

POST ...GENERATED URL IN STEP 1...

Request Body

Name
Type
Description

projectId

String

Project Id

file*

File

File to upload

title

String

Video Title

description

String

Video description

tags

String

Video tags, add multiple tags by adding the 'tags' field multiple times in your POST request with different values.

{
    "videoKey": "hgor6PnFQ",
    "uploadId": "3060c035-95ec-76495564",
    "videoId": "DTQ5It1KwNg",
    "channelKey": "u3u0iNPlL1Bg",
    "privateLink": "pheF3ukFQQ",
    "iframeLink": "klGiWrxW0nPzxw"
}
PreviousVideo Upload via URL (server side)NextGet Video Status

Last updated 1 year ago