Skip to content

Hi Coactive team!

This is a sample of what your docs might look like on Starport, based on your public docs.

Take a look! Ask AI, search, the MCP server, and Markdown copies all work.

Starport is a free and open-source docs framework based on Starlight and maintained by Promptless. Promptless is the AI agent that automatically updates your customer-facing docs.

Every annual Promptless plan comes with white-glove migration to Starport, where we migrate the content, tune the result with you, and you own the repository so you're never locked in.

Book a 15-minute walkthrough

Sample migration of Coactive docs to Starport, prepared by PromptlessBook 15-minute call

Create a metadata value

POST https://api.coactive.ai/api/v0/video-narrative-metadata/metadata
Content-Type: application/json

Create a metadata value.

  • Genre: The overall story category or narrative style of the content.
  • Mood: The emotional tone or feeling the content creates.
  • Subject: The main topic or theme the content focuses on.
  • Format: The structural style or production type of the content.
  • Authorization header (bearer token, required) — Bearer authentication of the form Bearer <token>, where token is your auth token.

This endpoint expects an object.

  • metadata_type (enum, required) — Supported metadata types.
    • Allowed values: genre, mood, subject, format
  • name (string, required)
  • description (string, required)
  • examples (list of string, required)

Successful Response

  • item (object, required) — A metadata value.
    • id (string, required)
    • metadata_type (enum, required) — Supported metadata types.
      • Allowed values: genre, mood, subject, format
    • name (string, required)
    • description (string, required)
    • examples (list of string, required)

Validation Error

  • detail (list of object, optional)
    • loc (list of string or integer, required)
    • msg (string, required)
    • type (string, required)

Request

{
"metadata_type": "genre",
"name": "Action",
"description": "A genre characterized by physical feats, stunts, combat, and high-paced sequences.",
"examples": [
"Die Hard (1988)",
"Terminator 2: Judgment Day (1991)",
"The Matrix (1999)",
"Gladiator (2000)",
"The Dark Knight (2008)",
"Inception (2010)",
"Mad Max: Fury Road (2015)",
"John Wick (2014)",
"Mission: Impossible - Fallout (2018)"
]
}

Response

{
"item": {
"id": "d4e5f678-9012-3456-ab56-f78901234567",
"metadata_type": "genre",
"name": "Action",
"description": "A genre characterized by physical feats, stunts, combat, and high-paced sequences.",
"examples": [
"Die Hard (1988)",
"Terminator 2: Judgment Day (1991)",
"The Matrix (1999)",
"Gladiator (2000)",
"The Dark Knight (2008)",
"Inception (2010)",
"Mad Max: Fury Road (2015)",
"John Wick (2014)",
"Mission: Impossible - Fallout (2018)"
]
}
}

SDK Code

import requests
url = "https://api.coactive.ai/api/v0/video-narrative-metadata/metadata"
payload = {
"metadata_type": "genre",
"name": "Action",
"description": "A genre characterized by physical feats, stunts, combat, and high-paced sequences.",
"examples": ["Die Hard (1988)", "Terminator 2: Judgment Day (1991)", "The Matrix (1999)", "Gladiator (2000)", "The Dark Knight (2008)", "Inception (2010)", "Mad Max: Fury Road (2015)", "John Wick (2014)", "Mission: Impossible - Fallout (2018)"]
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.json())
const url = 'https://api.coactive.ai/api/v0/video-narrative-metadata/metadata';
const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: '{"metadata_type":"genre","name":"Action","description":"A genre characterized by physical feats, stunts, combat, and high-paced sequences.","examples":["Die Hard (1988)","Terminator 2: Judgment Day (1991)","The Matrix (1999)","Gladiator (2000)","The Dark Knight (2008)","Inception (2010)","Mad Max: Fury Road (2015)","John Wick (2014)","Mission: Impossible - Fallout (2018)"]}'
};
try {
const response = await fetch(url, options);
const data = await response.json();
console.log(data);
} catch (error) {
console.error(error);
}
package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.coactive.ai/api/v0/video-narrative-metadata/metadata"
payload := strings.NewReader("{\n \"metadata_type\": \"genre\",\n \"name\": \"Action\",\n \"description\": \"A genre characterized by physical feats, stunts, combat, and high-paced sequences.\",\n \"examples\": [\n \"Die Hard (1988)\",\n \"Terminator 2: Judgment Day (1991)\",\n \"The Matrix (1999)\",\n \"Gladiator (2000)\",\n \"The Dark Knight (2008)\",\n \"Inception (2010)\",\n \"Mad Max: Fury Road (2015)\",\n \"John Wick (2014)\",\n \"Mission: Impossible - Fallout (2018)\"\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(res)
fmt.Println(string(body))
}
require 'uri'
require 'net/http'
url = URI("https://api.coactive.ai/api/v0/video-narrative-metadata/metadata")
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 \"metadata_type\": \"genre\",\n \"name\": \"Action\",\n \"description\": \"A genre characterized by physical feats, stunts, combat, and high-paced sequences.\",\n \"examples\": [\n \"Die Hard (1988)\",\n \"Terminator 2: Judgment Day (1991)\",\n \"The Matrix (1999)\",\n \"Gladiator (2000)\",\n \"The Dark Knight (2008)\",\n \"Inception (2010)\",\n \"Mad Max: Fury Road (2015)\",\n \"John Wick (2014)\",\n \"Mission: Impossible - Fallout (2018)\"\n ]\n}"
response = http.request(request)
puts response.read_body
import com.mashape.unirest.http.HttpResponse;
import com.mashape.unirest.http.Unirest;
HttpResponse<String> response = Unirest.post("https://api.coactive.ai/api/v0/video-narrative-metadata/metadata")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"metadata_type\": \"genre\",\n \"name\": \"Action\",\n \"description\": \"A genre characterized by physical feats, stunts, combat, and high-paced sequences.\",\n \"examples\": [\n \"Die Hard (1988)\",\n \"Terminator 2: Judgment Day (1991)\",\n \"The Matrix (1999)\",\n \"Gladiator (2000)\",\n \"The Dark Knight (2008)\",\n \"Inception (2010)\",\n \"Mad Max: Fury Road (2015)\",\n \"John Wick (2014)\",\n \"Mission: Impossible - Fallout (2018)\"\n ]\n}")
.asString();
<?php
require_once('vendor/autoload.php');
$client = new \GuzzleHttp\Client();
$response = $client->request('POST', 'https://api.coactive.ai/api/v0/video-narrative-metadata/metadata', [
'body' => '{
"metadata_type": "genre",
"name": "Action",
"description": "A genre characterized by physical feats, stunts, combat, and high-paced sequences.",
"examples": [
"Die Hard (1988)",
"Terminator 2: Judgment Day (1991)",
"The Matrix (1999)",
"Gladiator (2000)",
"The Dark Knight (2008)",
"Inception (2010)",
"Mad Max: Fury Road (2015)",
"John Wick (2014)",
"Mission: Impossible - Fallout (2018)"
]
}',
'headers' => [
'Authorization' => 'Bearer <token>',
'Content-Type' => 'application/json',
],
]);
echo $response->getBody();
using RestSharp;
var client = new RestClient("https://api.coactive.ai/api/v0/video-narrative-metadata/metadata");
var request = new RestRequest(Method.POST);
request.AddHeader("Authorization", "Bearer <token>");
request.AddHeader("Content-Type", "application/json");
request.AddParameter("application/json", "{\n \"metadata_type\": \"genre\",\n \"name\": \"Action\",\n \"description\": \"A genre characterized by physical feats, stunts, combat, and high-paced sequences.\",\n \"examples\": [\n \"Die Hard (1988)\",\n \"Terminator 2: Judgment Day (1991)\",\n \"The Matrix (1999)\",\n \"Gladiator (2000)\",\n \"The Dark Knight (2008)\",\n \"Inception (2010)\",\n \"Mad Max: Fury Road (2015)\",\n \"John Wick (2014)\",\n \"Mission: Impossible - Fallout (2018)\"\n ]\n}", ParameterType.RequestBody);
IRestResponse response = client.Execute(request);
import Foundation
let headers = [
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
]
let parameters = [
"metadata_type": "genre",
"name": "Action",
"description": "A genre characterized by physical feats, stunts, combat, and high-paced sequences.",
"examples": ["Die Hard (1988)", "Terminator 2: Judgment Day (1991)", "The Matrix (1999)", "Gladiator (2000)", "The Dark Knight (2008)", "Inception (2010)", "Mad Max: Fury Road (2015)", "John Wick (2014)", "Mission: Impossible - Fallout (2018)"]
] as [String : Any]
let postData = JSONSerialization.data(withJSONObject: parameters, options: [])
let request = NSMutableURLRequest(url: NSURL(string: "https://api.coactive.ai/api/v0/video-narrative-metadata/metadata")! as URL,
cachePolicy: .useProtocolCachePolicy,
timeoutInterval: 10.0)
request.httpMethod = "POST"
request.allHTTPHeaderFields = headers
request.httpBody = postData as Data
let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
if (error != nil) {
print(error as Any)
} else {
let httpResponse = response as? HTTPURLResponse
print(httpResponse)
}
})
dataTask.resume()