Skip to main content

List Templates

GET /api/templates
Returns a paginated list of available video templates.

Query parameters

ParameterTypeDefaultDescription
limitinteger50Number of templates to return (max 100)
offsetinteger0Pagination offset
categorystringFilter by template category

Request

curl "https://prismvideos.com/api/templates?limit=10&category=beauty" \
  -H "Authorization: Bearer prism_sk_your_key_here"

Response

{
  "data": [
    {
      "id": "abc123",
      "title": "UGC Product Pitch",
      "description": "Creator talks to camera and shows product with CTA",
      "category": "beauty",
      "duration_sec": 20,
      "input_variables": [
        {
          "key": "hook",
          "label": "Hook",
          "type": "text",
          "required": true,
          "max_length": 140
        },
        {
          "key": "productImage",
          "label": "Product Image",
          "type": "image",
          "required": true
        },
        {
          "key": "benefit",
          "label": "Key Benefit",
          "type": "text",
          "required": false,
          "placeholder": "e.g. 2x faster results"
        }
      ],
      "prompt_template": "Create a UGC ad with {{hook}}. Show {{productImage}}. Highlight: {{benefit}}."
    }
  ],
  "pagination": {
    "offset": 0,
    "limit": 10,
    "has_more": true
  }
}

Response fields

Template object

FieldTypeDescription
idstringUnique template identifier
titlestringDisplay name
descriptionstring or nullBrief description
categorystringTemplate category
duration_secnumber or nullTarget video duration in seconds
input_variablesarrayList of input variable definitions
prompt_templatestring or nullText template with {{key}} tokens

Input variable object

FieldTypeDescription
keystringUnique variable identifier (used in prompt template)
labelstringHuman-readable label
typestringtext, image, or video
requiredbooleanWhether the input must be provided
placeholderstringSuggested placeholder text (optional)
descriptionstringHelp text for the variable (optional)
default_valuestringDefault S3 key or URL for image/video variables (optional)
max_lengthnumberMaximum text length (optional)
min_lengthnumberMinimum text length (optional)
slotstringGeneration slot mapping (optional)

Pagination object

FieldTypeDescription
offsetnumberCurrent offset
limitnumberRequested limit
has_morebooleanWhether more results exist beyond this page