POST
/
v1
/
teams
/
{teamId}
/
assets
/
agentic-search
TypeScript client
import { OctosparkClient } from '@octospark/sdk'

const client = new OctosparkClient({
  token: process.env.OCTOSPARK_TOKEN
})

const response = await client.assets.searchAgenticAssets({
  teamId: process.env.OCTOSPARK_TEAM_ID ?? "teamId",
  body: {},
})
{
  "total": 123,
  "data": [
    {
      "score": 123,
      "rankingReasons": [
        "<string>"
      ],
      "asset": {
        "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
        "teamId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
        "originalFilename": "<string>",
        "fileSize": 123,
        "mimeType": "<string>",
        "assetTypeData": {
          "type": "image",
          "width": 123,
          "height": 123,
          "format": "<string>",
          "colorSpace": "<string>",
          "aspectRatio": "<string>"
        },
        "storagePath": "<string>",
        "thumbnailPath": "<string>",
        "aiTitle": "<string>",
        "aiDescription": "<string>",
        "aiTags": [
          "<string>"
        ],
        "contentHash": "<string>",
        "processingError": "<string>",
        "isDeleted": true,
        "deletedAt": "<string>",
        "hardDeletedAt": "<string>",
        "sharedWithOrg": true,
        "folderId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
        "folderName": "<string>",
        "displayName": "<string>",
        "aspectRatio": "<string>",
        "isProcessing": true,
        "createdAt": "<string>",
        "updatedAt": "<string>"
      },
      "assetUrl": "<string>",
      "thumbnailUrl": "<string>"
    }
  ],
  "costResult": {
    "name": "<string>",
    "costInCreditsDecimillicents": 123,
    "costInDollars": 123,
    "marginCostInCreditsDecimillicents": 123,
    "marginCostInDollars": 123
  },
  "embeddingStatus": {
    "embeddingsReady": true,
    "totalAssets": 123,
    "withEmbeddings": 123,
    "withoutEmbeddings": 123,
    "message": "<string>"
  }
}

Authorizations

Authorization
string
header
required

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

Path Parameters

teamId
string
required

Team (workspace) id (UUID). Discover ids via the list teams endpoint or the agent context.

Body

application/json
query
string
required

Natural-language search query over the team media library, 1 to 512 characters.

Required string length: 1 - 512
Example:

"green screen clip of someone pointing upward"

mode
enum<string>
default:metadata

Search strategy: metadata (keyword scoring), semantic (vector embeddings), or hybrid (both); defaults to metadata.

Available options:
metadata,
semantic,
hybrid
Example:

"hybrid"

limit
integer
default:10

Maximum number of results to return, 1 to 50; defaults to 10.

Required range: 1 <= x <= 50
Example:

10

includeSeedLibrary
boolean

Whether to also search the shared Octospark seed template library alongside team assets.

assetTypes
enum<string>[]

Restrict results to these asset types (image, video, audio, gif, document).

Available options:
image,
video,
audio,
gif,
document
Example:
["image", "video"]
assetCategories
enum<string>[]

Restrict results to these asset categories, e.g. user_upload, render, green_screen_template, music.

Available options:
user_upload,
render,
template,
green_screen_template,
sound_effect,
music,
brand_asset,
ai_image,
ai_video,
other
Example:
["user_upload"]

Response

Success

mode
enum<string>
required
Available options:
metadata,
semantic,
hybrid
total
number
required
data
object[]
required
costResult
object
required
embeddingStatus
object
required