Skip to main content
POST
/
collections
Create a new collection to organize and process video files
curl --request POST \
  --url https://api.cloudglue.dev/v1/collections \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "name": "<string>",
  "description": "<string>",
  "describe_config": {
    "enable_summary": true,
    "enable_speech": true,
    "enable_scene_text": true,
    "enable_visual_scene_description": true,
    "enable_audio_description": true
  },
  "extract_config": {
    "prompt": "<string>",
    "schema": {},
    "enable_video_level_entities": true,
    "enable_segment_level_entities": true,
    "enable_transcript_mode": true
  },
  "transcribe_config": {
    "enable_summary": true,
    "enable_speech": true,
    "enable_scene_text": true,
    "enable_visual_scene_description": true,
    "enable_audio_description": true
  },
  "face_detection_config": {
    "thumbnails_config": {
      "enable_frame_thumbnails": true
    }
  }
}
'
import requests

url = "https://api.cloudglue.dev/v1/collections"

payload = {
"name": "<string>",
"description": "<string>",
"describe_config": {
"enable_summary": True,
"enable_speech": True,
"enable_scene_text": True,
"enable_visual_scene_description": True,
"enable_audio_description": True
},
"extract_config": {
"prompt": "<string>",
"schema": {},
"enable_video_level_entities": True,
"enable_segment_level_entities": True,
"enable_transcript_mode": True
},
"transcribe_config": {
"enable_summary": True,
"enable_speech": True,
"enable_scene_text": True,
"enable_visual_scene_description": True,
"enable_audio_description": True
},
"face_detection_config": { "thumbnails_config": { "enable_frame_thumbnails": True } }
}
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({
name: '<string>',
description: '<string>',
describe_config: {
enable_summary: true,
enable_speech: true,
enable_scene_text: true,
enable_visual_scene_description: true,
enable_audio_description: true
},
extract_config: {
prompt: '<string>',
schema: {},
enable_video_level_entities: true,
enable_segment_level_entities: true,
enable_transcript_mode: true
},
transcribe_config: {
enable_summary: true,
enable_speech: true,
enable_scene_text: true,
enable_visual_scene_description: true,
enable_audio_description: true
},
face_detection_config: {thumbnails_config: {enable_frame_thumbnails: true}}
})
};

fetch('https://api.cloudglue.dev/v1/collections', 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.cloudglue.dev/v1/collections",
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([
'name' => '<string>',
'description' => '<string>',
'describe_config' => [
'enable_summary' => true,
'enable_speech' => true,
'enable_scene_text' => true,
'enable_visual_scene_description' => true,
'enable_audio_description' => true
],
'extract_config' => [
'prompt' => '<string>',
'schema' => [

],
'enable_video_level_entities' => true,
'enable_segment_level_entities' => true,
'enable_transcript_mode' => true
],
'transcribe_config' => [
'enable_summary' => true,
'enable_speech' => true,
'enable_scene_text' => true,
'enable_visual_scene_description' => true,
'enable_audio_description' => true
],
'face_detection_config' => [
'thumbnails_config' => [
'enable_frame_thumbnails' => true
]
]
]),
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.cloudglue.dev/v1/collections"

payload := strings.NewReader("{\n \"name\": \"<string>\",\n \"description\": \"<string>\",\n \"describe_config\": {\n \"enable_summary\": true,\n \"enable_speech\": true,\n \"enable_scene_text\": true,\n \"enable_visual_scene_description\": true,\n \"enable_audio_description\": true\n },\n \"extract_config\": {\n \"prompt\": \"<string>\",\n \"schema\": {},\n \"enable_video_level_entities\": true,\n \"enable_segment_level_entities\": true,\n \"enable_transcript_mode\": true\n },\n \"transcribe_config\": {\n \"enable_summary\": true,\n \"enable_speech\": true,\n \"enable_scene_text\": true,\n \"enable_visual_scene_description\": true,\n \"enable_audio_description\": true\n },\n \"face_detection_config\": {\n \"thumbnails_config\": {\n \"enable_frame_thumbnails\": true\n }\n }\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.cloudglue.dev/v1/collections")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"name\": \"<string>\",\n \"description\": \"<string>\",\n \"describe_config\": {\n \"enable_summary\": true,\n \"enable_speech\": true,\n \"enable_scene_text\": true,\n \"enable_visual_scene_description\": true,\n \"enable_audio_description\": true\n },\n \"extract_config\": {\n \"prompt\": \"<string>\",\n \"schema\": {},\n \"enable_video_level_entities\": true,\n \"enable_segment_level_entities\": true,\n \"enable_transcript_mode\": true\n },\n \"transcribe_config\": {\n \"enable_summary\": true,\n \"enable_speech\": true,\n \"enable_scene_text\": true,\n \"enable_visual_scene_description\": true,\n \"enable_audio_description\": true\n },\n \"face_detection_config\": {\n \"thumbnails_config\": {\n \"enable_frame_thumbnails\": true\n }\n }\n}")
.asString();
require 'uri'
require 'net/http'

url = URI("https://api.cloudglue.dev/v1/collections")

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 \"name\": \"<string>\",\n \"description\": \"<string>\",\n \"describe_config\": {\n \"enable_summary\": true,\n \"enable_speech\": true,\n \"enable_scene_text\": true,\n \"enable_visual_scene_description\": true,\n \"enable_audio_description\": true\n },\n \"extract_config\": {\n \"prompt\": \"<string>\",\n \"schema\": {},\n \"enable_video_level_entities\": true,\n \"enable_segment_level_entities\": true,\n \"enable_transcript_mode\": true\n },\n \"transcribe_config\": {\n \"enable_summary\": true,\n \"enable_speech\": true,\n \"enable_scene_text\": true,\n \"enable_visual_scene_description\": true,\n \"enable_audio_description\": true\n },\n \"face_detection_config\": {\n \"thumbnails_config\": {\n \"enable_frame_thumbnails\": true\n }\n }\n}"

response = http.request(request)
puts response.read_body
{
  "id": "<string>",
  "object": "collection",
  "name": "<string>",
  "created_at": 123,
  "file_count": 123,
  "description": "<string>",
  "extract_config": {
    "prompt": "<string>",
    "schema": {},
    "enable_video_level_entities": true,
    "enable_segment_level_entities": true,
    "enable_transcript_mode": true
  },
  "transcribe_config": {
    "enable_summary": true,
    "enable_speech": true,
    "enable_scene_text": true,
    "enable_visual_scene_description": true,
    "enable_audio_description": true
  },
  "describe_config": {
    "enable_summary": true,
    "enable_speech": true,
    "enable_scene_text": true,
    "enable_visual_scene_description": true,
    "enable_audio_description": true
  },
  "default_segmentation_config": {
    "uniform_config": {
      "window_seconds": 60.5,
      "hop_seconds": 60.5
    },
    "shot_detector_config": {
      "threshold": 123,
      "min_seconds": 300.3,
      "max_seconds": 300.5,
      "fill_gaps": true
    },
    "manual_config": {
      "segments": [
        {
          "start_time": 123,
          "end_time": 123
        }
      ]
    },
    "narrative_config": {
      "prompt": "<string>",
      "number_of_chapters": 2,
      "min_chapters": 2,
      "max_chapters": 2
    },
    "keyframe_config": {
      "frames_per_segment": 4,
      "max_width": 2232
    },
    "start_time_seconds": 1,
    "end_time_seconds": 1
  },
  "default_thumbnails_config": {
    "enable_segment_thumbnails": true
  },
  "face_detection_config": {
    "frame_extraction_config": {
      "strategy": "uniform",
      "uniform_config": {
        "frames_per_second": 15.05,
        "max_width": 2080
      }
    },
    "thumbnails_config": {
      "enable_frame_thumbnails": true
    }
  }
}
{
"error": "<string>"
}
{
"error": "<string>"
}
{
"error": "<string>"
}
{
"error": "<string>"
}

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Body

application/json

Collection creation parameters

collection_type
enum<string>
required

Type of collection, determines how videos are processed and what data is extracted.

Collection Types:

  • media-descriptions: Generate comprehensive media descriptions with speech, visual, and text analysis (use describe_config)
  • entities: Extract structured data/entities from videos (requires extract_config)
  • rich-transcripts: Generate rich transcriptions with speech and visual descriptions (use transcribe_config). For backward compatibility only, new collections should use media-descriptions instead.
  • face-analysis: Detect and index faces in videos for face matching and search (use face_detection_config)

⚠️ Important: Only provide the config that matches your collection_type. Other configs will be ignored.

Available options:
media-descriptions,
entities,
rich-transcripts,
face-analysis
name
string
required

Name of the collection (must be unique within an organization)

description
string | null

Description of the collection's purpose or contents, null if none provided

describe_config
object

🎯 Use ONLY when collection_type = 'media-descriptions'

Configuration for comprehensive media description from videos. Optional - if not provided, default values will be used. This config will be ignored for other collection types.

extract_config
object

🎯 Use ONLY when collection_type = 'entities'

Configuration for automatic entity extraction from videos. Required for entities collections. This config will be ignored for other collection types.

transcribe_config
object

🎯 Use ONLY when collection_type = 'rich-transcripts'

Configuration for rich transcription from videos. Optional - if not provided, default values will be used. This config will be ignored for other collection types.

default_segmentation_config
object

Default segmentation configuration to use for files added to this collection. If not provided, a default uniform segmentation will be used.

default_thumbnails_config
object

Default thumbnails configuration to use for files added to this collection. If not provided, a default thumbnails configuration will be used.

face_detection_config
object

🎯 Use ONLY when collection_type = 'face-analysis'

Configuration for face detection in videos. Optional - if not provided, default values will be used. This config will be ignored for other collection types.

Response

Successful collection creation

id
string
required

Unique identifier for the collection

object
enum<string>
required

Object type, always 'collection'

Available options:
collection
name
string
required

Name of the collection

collection_type
enum<string>
required

Type of collection, determines how videos are processed and what data is extracted

Available options:
media-descriptions,
entities,
rich-transcripts,
face-analysis
created_at
integer
required

Unix timestamp in milliseconds when the collection was created

file_count
integer
required

Number of files in the collection

description
string | null

Description of the collection's purpose or contents, null if none provided

extract_config
object

Configuration for automatic entity extraction from videos. Required when collection_type is 'entities'.

transcribe_config
object

Configuration for rich transcription from videos. Used when collection_type is 'rich-transcripts'. If not provided, default values will be used.

describe_config
object

Configuration for comprehensive media description from videos. Used when collection_type is 'media-descriptions'. If not provided, default values will be used.

default_segmentation_config
object

Default segmentation configuration used for files in this collection

default_thumbnails_config
object

Default thumbnails configuration used for files in this collection

face_detection_config
object | null

Configuration for face detection in videos. Only present when collection_type is 'face-analysis'.