cURL
curl --request POST \
--url https://api.opus.pro/api/clip-projects \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"videoUrl": "https://www.youtube.com/watch?v=LXvv6CbGg8A",
"conclusionActions": [
{
"type": "EMAIL",
"notifyFailure": true,
"email": "opusclip@opus.pro"
}
],
"curationPref": {
"range": {
"startSec": 28,
"endSec": 636
},
"topicKeywords": [
"OpusClip"
],
"genre": "Auto"
},
"importPref": {
"sourceLang": "auto"
},
"brandTemplateId": "preset-fancy-Karaoke"
}
'import requests
url = "https://api.opus.pro/api/clip-projects"
payload = {
"videoUrl": "https://www.youtube.com/watch?v=LXvv6CbGg8A",
"conclusionActions": [
{
"type": "EMAIL",
"notifyFailure": True,
"email": "opusclip@opus.pro"
}
],
"curationPref": {
"range": {
"startSec": 28,
"endSec": 636
},
"topicKeywords": ["OpusClip"],
"genre": "Auto"
},
"importPref": { "sourceLang": "auto" },
"brandTemplateId": "preset-fancy-Karaoke"
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
videoUrl: 'https://www.youtube.com/watch?v=LXvv6CbGg8A',
conclusionActions: [{type: 'EMAIL', notifyFailure: true, email: 'opusclip@opus.pro'}],
curationPref: {range: {startSec: 28, endSec: 636}, topicKeywords: ['OpusClip'], genre: 'Auto'},
importPref: {sourceLang: 'auto'},
brandTemplateId: 'preset-fancy-Karaoke'
})
};
fetch('https://api.opus.pro/api/clip-projects', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.opus.pro/api/clip-projects",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'videoUrl' => 'https://www.youtube.com/watch?v=LXvv6CbGg8A',
'conclusionActions' => [
[
'type' => 'EMAIL',
'notifyFailure' => true,
'email' => 'opusclip@opus.pro'
]
],
'curationPref' => [
'range' => [
'startSec' => 28,
'endSec' => 636
],
'topicKeywords' => [
'OpusClip'
],
'genre' => 'Auto'
],
'importPref' => [
'sourceLang' => 'auto'
],
'brandTemplateId' => 'preset-fancy-Karaoke'
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.opus.pro/api/clip-projects"
payload := strings.NewReader("{\n \"videoUrl\": \"https://www.youtube.com/watch?v=LXvv6CbGg8A\",\n \"conclusionActions\": [\n {\n \"type\": \"EMAIL\",\n \"notifyFailure\": true,\n \"email\": \"opusclip@opus.pro\"\n }\n ],\n \"curationPref\": {\n \"range\": {\n \"startSec\": 28,\n \"endSec\": 636\n },\n \"topicKeywords\": [\n \"OpusClip\"\n ],\n \"genre\": \"Auto\"\n },\n \"importPref\": {\n \"sourceLang\": \"auto\"\n },\n \"brandTemplateId\": \"preset-fancy-Karaoke\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.opus.pro/api/clip-projects")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"videoUrl\": \"https://www.youtube.com/watch?v=LXvv6CbGg8A\",\n \"conclusionActions\": [\n {\n \"type\": \"EMAIL\",\n \"notifyFailure\": true,\n \"email\": \"opusclip@opus.pro\"\n }\n ],\n \"curationPref\": {\n \"range\": {\n \"startSec\": 28,\n \"endSec\": 636\n },\n \"topicKeywords\": [\n \"OpusClip\"\n ],\n \"genre\": \"Auto\"\n },\n \"importPref\": {\n \"sourceLang\": \"auto\"\n },\n \"brandTemplateId\": \"preset-fancy-Karaoke\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.opus.pro/api/clip-projects")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"videoUrl\": \"https://www.youtube.com/watch?v=LXvv6CbGg8A\",\n \"conclusionActions\": [\n {\n \"type\": \"EMAIL\",\n \"notifyFailure\": true,\n \"email\": \"opusclip@opus.pro\"\n }\n ],\n \"curationPref\": {\n \"range\": {\n \"startSec\": 28,\n \"endSec\": 636\n },\n \"topicKeywords\": [\n \"OpusClip\"\n ],\n \"genre\": \"Auto\"\n },\n \"importPref\": {\n \"sourceLang\": \"auto\"\n },\n \"brandTemplateId\": \"preset-fancy-Karaoke\"\n}"
response = http.request(request)
puts response.read_body{
"id": "P0000000demo",
"userId": "google-oauth2|100000000000000000001",
"orgId": "org_Example00000001",
"isDeleted": false,
"isPurged": false,
"projectId": "P0000000demo",
"sourcePlatform": "YOUTUBE",
"sourceId": "YT_tEXaoozFRes",
"labels": [],
"productTier": "PRO",
"stage": "QUEUED",
"storageSize": 0,
"storageStatus": "TEMPORARY",
"storageExpireAt": "2024-12-19T08:17:42.832Z",
"createdAt": "2024-11-19T08:17:42.832Z",
"updatedAt": "2024-11-19T08:17:42.860Z",
"clusterJobId": "FP.P0000000demo:20241119081742853.FP",
"cluster": "gold",
"visibility": "DEFAULT",
"permissions": [
"PROJECT_SHARE",
"PROJECT_EDIT",
"PROJECT_VIEW"
],
"promptRecommendations": [
"Foo",
"Boo"
],
"sourceUri": null,
"model": "ClipBasic",
"error": null,
"stallCount": null,
"workerUrl": null,
"curationPref": {
"range": {
"startSec": 28,
"endSec": 636
},
"clipDurations": [
[
0,
90
]
],
"topicKeywords": [
"OpusClip"
],
"genre": "Auto"
},
"renderPref": {
"enableSplitLayout": true,
"enableFitLayout": false,
"enableFillLayout": false,
"enableScreenLayout": true,
"enableThreeLayout": true,
"enableFourLayout": true,
"enableAutoLayout": false,
"fitLayoutCropRatio": "4:3",
"enableCrop": true,
"layoutAspectRatio": "portrait",
"enableVisualHook": false,
"enableCaption": true,
"enableHighlight": true,
"enableEmoji": true,
"enableUppercase": true,
"highlightColor": {
"primary": "#04f827",
"secondary": "#FFFD03"
},
"font": {
"id": null,
"type": null,
"name": null,
"path": null,
"size": "Large",
"numericalSize": 50,
"color": "#ffffff",
"style": [
"900"
],
"textDecoration": "",
"family": "Komika-axis",
"stroke": {
"enabled": true,
"color": "#000000FF",
"width": 16
},
"shadow": {
"enabled": true,
"color": "#FFFFFFFF",
"x": 2,
"y": 2,
"blur": 16,
"useWordHighlightColor": false
}
},
"enableBroll": null,
"enableWatermark": false
},
"refundStatus": null,
"importPref": {
"sourceLang": "en"
}
}Playground
Create a New Project
Submit a long-form video to create a new clipping project.
POST
/
api
/
clip-projects
cURL
curl --request POST \
--url https://api.opus.pro/api/clip-projects \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"videoUrl": "https://www.youtube.com/watch?v=LXvv6CbGg8A",
"conclusionActions": [
{
"type": "EMAIL",
"notifyFailure": true,
"email": "opusclip@opus.pro"
}
],
"curationPref": {
"range": {
"startSec": 28,
"endSec": 636
},
"topicKeywords": [
"OpusClip"
],
"genre": "Auto"
},
"importPref": {
"sourceLang": "auto"
},
"brandTemplateId": "preset-fancy-Karaoke"
}
'import requests
url = "https://api.opus.pro/api/clip-projects"
payload = {
"videoUrl": "https://www.youtube.com/watch?v=LXvv6CbGg8A",
"conclusionActions": [
{
"type": "EMAIL",
"notifyFailure": True,
"email": "opusclip@opus.pro"
}
],
"curationPref": {
"range": {
"startSec": 28,
"endSec": 636
},
"topicKeywords": ["OpusClip"],
"genre": "Auto"
},
"importPref": { "sourceLang": "auto" },
"brandTemplateId": "preset-fancy-Karaoke"
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
videoUrl: 'https://www.youtube.com/watch?v=LXvv6CbGg8A',
conclusionActions: [{type: 'EMAIL', notifyFailure: true, email: 'opusclip@opus.pro'}],
curationPref: {range: {startSec: 28, endSec: 636}, topicKeywords: ['OpusClip'], genre: 'Auto'},
importPref: {sourceLang: 'auto'},
brandTemplateId: 'preset-fancy-Karaoke'
})
};
fetch('https://api.opus.pro/api/clip-projects', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.opus.pro/api/clip-projects",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'videoUrl' => 'https://www.youtube.com/watch?v=LXvv6CbGg8A',
'conclusionActions' => [
[
'type' => 'EMAIL',
'notifyFailure' => true,
'email' => 'opusclip@opus.pro'
]
],
'curationPref' => [
'range' => [
'startSec' => 28,
'endSec' => 636
],
'topicKeywords' => [
'OpusClip'
],
'genre' => 'Auto'
],
'importPref' => [
'sourceLang' => 'auto'
],
'brandTemplateId' => 'preset-fancy-Karaoke'
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.opus.pro/api/clip-projects"
payload := strings.NewReader("{\n \"videoUrl\": \"https://www.youtube.com/watch?v=LXvv6CbGg8A\",\n \"conclusionActions\": [\n {\n \"type\": \"EMAIL\",\n \"notifyFailure\": true,\n \"email\": \"opusclip@opus.pro\"\n }\n ],\n \"curationPref\": {\n \"range\": {\n \"startSec\": 28,\n \"endSec\": 636\n },\n \"topicKeywords\": [\n \"OpusClip\"\n ],\n \"genre\": \"Auto\"\n },\n \"importPref\": {\n \"sourceLang\": \"auto\"\n },\n \"brandTemplateId\": \"preset-fancy-Karaoke\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.opus.pro/api/clip-projects")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"videoUrl\": \"https://www.youtube.com/watch?v=LXvv6CbGg8A\",\n \"conclusionActions\": [\n {\n \"type\": \"EMAIL\",\n \"notifyFailure\": true,\n \"email\": \"opusclip@opus.pro\"\n }\n ],\n \"curationPref\": {\n \"range\": {\n \"startSec\": 28,\n \"endSec\": 636\n },\n \"topicKeywords\": [\n \"OpusClip\"\n ],\n \"genre\": \"Auto\"\n },\n \"importPref\": {\n \"sourceLang\": \"auto\"\n },\n \"brandTemplateId\": \"preset-fancy-Karaoke\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.opus.pro/api/clip-projects")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"videoUrl\": \"https://www.youtube.com/watch?v=LXvv6CbGg8A\",\n \"conclusionActions\": [\n {\n \"type\": \"EMAIL\",\n \"notifyFailure\": true,\n \"email\": \"opusclip@opus.pro\"\n }\n ],\n \"curationPref\": {\n \"range\": {\n \"startSec\": 28,\n \"endSec\": 636\n },\n \"topicKeywords\": [\n \"OpusClip\"\n ],\n \"genre\": \"Auto\"\n },\n \"importPref\": {\n \"sourceLang\": \"auto\"\n },\n \"brandTemplateId\": \"preset-fancy-Karaoke\"\n}"
response = http.request(request)
puts response.read_body{
"id": "P0000000demo",
"userId": "google-oauth2|100000000000000000001",
"orgId": "org_Example00000001",
"isDeleted": false,
"isPurged": false,
"projectId": "P0000000demo",
"sourcePlatform": "YOUTUBE",
"sourceId": "YT_tEXaoozFRes",
"labels": [],
"productTier": "PRO",
"stage": "QUEUED",
"storageSize": 0,
"storageStatus": "TEMPORARY",
"storageExpireAt": "2024-12-19T08:17:42.832Z",
"createdAt": "2024-11-19T08:17:42.832Z",
"updatedAt": "2024-11-19T08:17:42.860Z",
"clusterJobId": "FP.P0000000demo:20241119081742853.FP",
"cluster": "gold",
"visibility": "DEFAULT",
"permissions": [
"PROJECT_SHARE",
"PROJECT_EDIT",
"PROJECT_VIEW"
],
"promptRecommendations": [
"Foo",
"Boo"
],
"sourceUri": null,
"model": "ClipBasic",
"error": null,
"stallCount": null,
"workerUrl": null,
"curationPref": {
"range": {
"startSec": 28,
"endSec": 636
},
"clipDurations": [
[
0,
90
]
],
"topicKeywords": [
"OpusClip"
],
"genre": "Auto"
},
"renderPref": {
"enableSplitLayout": true,
"enableFitLayout": false,
"enableFillLayout": false,
"enableScreenLayout": true,
"enableThreeLayout": true,
"enableFourLayout": true,
"enableAutoLayout": false,
"fitLayoutCropRatio": "4:3",
"enableCrop": true,
"layoutAspectRatio": "portrait",
"enableVisualHook": false,
"enableCaption": true,
"enableHighlight": true,
"enableEmoji": true,
"enableUppercase": true,
"highlightColor": {
"primary": "#04f827",
"secondary": "#FFFD03"
},
"font": {
"id": null,
"type": null,
"name": null,
"path": null,
"size": "Large",
"numericalSize": 50,
"color": "#ffffff",
"style": [
"900"
],
"textDecoration": "",
"family": "Komika-axis",
"stroke": {
"enabled": true,
"color": "#000000FF",
"width": 16
},
"shadow": {
"enabled": true,
"color": "#FFFFFFFF",
"x": 2,
"y": 2,
"blur": 16,
"useWordHighlightColor": false
}
},
"enableBroll": null,
"enableWatermark": false
},
"refundStatus": null,
"importPref": {
"sourceLang": "en"
}
}👆Use above tools to generate API request code snippets.
Authorizations
Body
application/json
This parameter defines the url of the long-form video. OpusClip can import public videos from the following platforms:
- YouTube, Google Drive, Vimeo, Zoom, Rumble, Twitch, Facebook, LinkedIn, X, Dropbox, Riverside, Loom, Frame.io, StreamYard
- Any public video s3 link of an mp4 file (up to 10GB per video)
Example:
"https://www.youtube.com/watch?v=LXvv6CbGg8A"
Response
201 - application/json
Preferences for rendering the video, including layout and overlay options.
Show child attributes
Show child attributes
Example:
{
"enableSplitLayout": true,
"enableFitLayout": false,
"enableFillLayout": false,
"enableScreenLayout": true,
"enableThreeLayout": true,
"enableFourLayout": true,
"enableAutoLayout": false,
"fitLayoutCropRatio": "4:3",
"enableCrop": true,
"layoutAspectRatio": "portrait",
"enableVisualHook": false,
"enableCaption": true,
"enableHighlight": true,
"enableEmoji": true,
"enableUppercase": true,
"highlightColor": {
"primary": "#04f827",
"secondary": "#FFFD03"
},
"font": {
"id": null,
"type": null,
"name": null,
"path": null,
"size": "Large",
"numericalSize": 50,
"color": "#ffffff",
"style": ["900"],
"textDecoration": "",
"family": "Komika-axis",
"stroke": {
"enabled": true,
"color": "#000000FF",
"width": 16
},
"shadow": {
"enabled": true,
"color": "#FFFFFFFF",
"x": 2,
"y": 2,
"blur": 16,
"useWordHighlightColor": false
}
},
"enableBroll": null,
"enableWatermark": false
}
Was this page helpful?