Skip to main content

Hesedvid v1.0 is here!

Learn more

Getting Started

Getting Started with HesedVid

Welcome to HesedVid! This guide will help you get up and running with our video API in just a few minutes.

What is HesedVid?

HesedVid is a comprehensive video infrastructure platform that provides:

  • Video Upload & Processing: Direct upload to cloud storage with automatic transcoding
  • Adaptive Streaming: HLS delivery with multiple quality levels
  • Global CDN: Fast video delivery worldwide
  • Analytics: Detailed usage and performance metrics
  • Player Integration: Embeddable video player for any website

Prerequisites

Before you begin, you’ll need:

  • A HesedVid account (sign up at app.hesedvid.com)
  • Basic knowledge of HTTP APIs
  • Your preferred programming language (JavaScript, Python, cURL, etc.)

Step 1: Create Your API Key

API keys are created through the HesedVid dashboard:

  1. Log in to your HesedVid dashboard
  2. Navigate to Settings → API Keys
  3. Click “Create New Key”
  4. Configure the key:
    • Name: Give it a descriptive name (e.g., “My App Production”)
    • Environment: Choose your target environment
    • Permissions: Select appropriate access level
  5. Copy the generated key immediately

Caution

API keys are only shown once when created. Save them securely - they cannot be retrieved again.

Step 2: Upload Your First Video

Let’s upload a video to test your setup:

Using cURL

Terminal window
# 1. Get an upload URL
curl -X POST "https://api.hesedvid.com/v1/api/{orgID}/environments/{envID}/videos/upload-url" \
-H "X-Api-Key: YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"filename": "my-first-video.mp4",
"fileSize": 10485760,
"contentType": "video/mp4"
}'
# 2. Upload your video file to the returned URL
curl -X PUT "UPLOAD_URL_FROM_STEP_1" \
-H "Content-Type: video/mp4" \
--data-binary @my-first-video.mp4
# 3. Start processing
curl -X POST "https://api.hesedvid.com/v1/api/{orgID}/environments/{envID}/videos/{videoID}/process" \
-H "X-Api-Key: YOUR_API_KEY"

Using JavaScript

async function uploadVideo(file) {
// 1. Get upload URL
const uploadResponse = await fetch(
'https://api.hesedvid.com/v1/api/{orgID}/environments/{envID}/videos/upload-url',
{
method: 'POST',
headers: {
'X-Api-Key': 'YOUR_API_KEY',
'Content-Type': 'application/json'
},
body: JSON.stringify({
filename: file.name,
fileSize: file.size,
contentType: file.type
})
}
);
const { body: uploadData } = await uploadResponse.json();
// 2. Upload file to cloud storage
await fetch(uploadData.uploadUrl, {
method: 'PUT',
headers: {
'Content-Type': file.type
},
body: file
});
// 3. Start processing
await fetch(
`https://api.hesedvid.com/v1/api/{orgID}/environments/{envID}/videos/${uploadData.videoID}/process`,
{
method: 'POST',
headers: {
'X-Api-Key': 'YOUR_API_KEY'
}
}
);
return uploadData.videoID;
}

Step 3: Stream Your Video

Once your video is processed, you can stream it:

Public Videos

<!-- Embed the HesedVid player -->
<iframe
src="https://player.hesedvid.com/{publicID}"
width="800"
height="450"
frameborder="0"
allowfullscreen>
</iframe>

Private Videos

For private videos, you’ll need to generate signed URLs:

async function getSignedUrl(videoID) {
const response = await fetch(
`https://api.hesedvid.com/v1/api/{orgID}/videos/${videoID}/signed-url?expiration=2h`,
{
headers: {
'X-Api-Key': 'YOUR_API_KEY'
}
}
);
const { body } = await response.json();
return body.signedUrl;
}

Step 4: Monitor Your Usage

Check your video analytics:

Terminal window
curl -X GET "https://api.hesedvid.com/v1/api/{orgID}/analytics/usage" \
-H "X-Api-Key: YOUR_API_KEY"

Common Use Cases

E-learning Platform

// Upload course videos
const courseVideo = await uploadVideo(courseFile);
// Generate signed URLs for enrolled students
const signedUrl = await getSignedUrl(courseVideo);
// Track viewing analytics
const analytics = await fetch(
`https://api.hesedvid.com/v1/api/{orgID}/analytics/video/${courseVideo}`,
{ headers: { 'X-Api-Key': 'YOUR_API_KEY' } }
);

Marketing Website

<!-- Embed promotional videos -->
<iframe
src="https://player.hesedvid.com/{promoVideoID}?autoplay=true&muted=true"
width="100%"
height="400"
frameborder="0">
</iframe>

Mobile App

// React Native example
import Video from 'react-native-video';
function VideoPlayer({ videoID }) {
const [signedUrl, setSignedUrl] = useState(null);
useEffect(() => {
getSignedUrl(videoID).then(setSignedUrl);
}, [videoID]);
return (
<Video
source={{ uri: signedUrl }}
style={{ width: 300, height: 200 }}
controls={true}
/>
);
}

Next Steps

Now that you’ve uploaded your first video, explore these resources:

Need Help?

Tip

Start with small test videos to understand the workflow before uploading large files. Most videos process within 2-5 minutes.