3 个接口 · 概览
spacesstring200fieldsFacetDef[]必填idstring必填workspace_idstringkeystring必填originstring必填builtinplugincustomnamespacestring必填pathstring必填typestring必填keywordkeywordsenumnumberdatebooloptionsobjectlabelmap<string, string>必填positioninteger必填namespacesobject[]必填namespacestring必填originstring必填builtinpluginotherlabelmap<string, string>必填curl "https://side.space/v1/facets" \
-H "Authorization: Bearer $SIDESPACE_TOKEN"{
"fields": [
{
"id": "id",
"workspace_id": "nod_01JD7Q3A5C7E9G1J3K5M7P9R2S",
"key": "key",
"origin": "builtin",
"namespace": "x-acme.qc",
"path": "Ep01/Shots/A001_C003.mov",
"type": "keyword",
"options": {},
"label": {
"key": "string"
},
"position": 1
}
],
"namespaces": [
{
"namespace": "x-acme.qc",
"origin": "builtin",
"label": {
"key": "string"
}
}
]
}The search of POST /v1/search in its older shape (no filters, pages or counts). Every word must match the name (any part of it), what a sidecar says in the indexed shapes (text fields such as title, description, note and an AI prompt; moments such as transcript segments and chapters; field values such as tags, a site or a codec), or a live comment. Words match whole or by their start; Chinese, Japanese and Korean match as runs of neighbouring characters, and a single CJK character as a substring. Model names, providers and ids are not searched. A name match ranks first, then tags and titles, then descriptions, then transcripts and screen text; newer files first within each. When the server has an embeddings model (SIDESPACE_EMBED_URL, ADR 0018), files close in meaning to the query follow, with matched ["meaning"] and a score. Moments that hold a word, timed comments, and pieces close in meaning are listed as moments. Only spaces the caller is a member of are searched.
qstring必填spacestringtypestringvideoimageaudiofolderothermodestringautokeywordmeaninglimitinteger200itemsSearchHit[]必填space_namestring必填folderstring必填matchedstring[]必填snippetstringmomentsSearchMoment[]at_msinteger (int64)必填until_msinteger (int64)textstring必填sourcestring必填scorenumbercurl "https://side.space/v1/search?q=harbor%20night" \
-H "Authorization: Bearer $SIDESPACE_TOKEN"{
"items": [
{
"node": {},
"space_name": "space_name",
"folder": "folder",
"matched": [],
"snippet": "snippet",
"moments": [],
"score": 0.5
}
]
}Searches the index the server builds from sidecars (library-and-search.md 3.2, 4.1). With q, every word must match somewhere, as in GET /v1/search; without q, it lists what the filters let through. Filters are ANDed, the values of one filter ORed (any), all required (all) or excluded (none). Keys: kind (video, audio, image, document, other, folder), has (namespaces present, "ai." dropped: transcript, tags, media…), language, state (none, waiting, running, done, failed), space, duration_ms, width, height, captured_at, saved_at (Unix ms or RFC 3339), and the fields of facet_defs (tags, rating, label, status, shot_type, people, speakers, video_codec, source.site, …). Relevance lists word hits best field first, newer first within one; files only close in meaning follow, each with a score (never mixed into the word ranking). With group moment each hit is one moment that holds a word (every moment of matching files without q), a file's moments together and in time order. The answer's next is the cursor of the next page.
qstringscopeobjectspacesstring[]folderstringdepthinteger01filtersSearchFilter[]keystring必填isanyanyany[]allany[]noneany[]gteanylteanyexistsbooleangroupstringfilemomentsortstringorderstringascdescmodestringautokeywordmeaningvectorsmap<string, string (byte)>countsstring[]cursorstringlimitintegercurl -X POST "https://side.space/v1/search" \
-H "Authorization: Bearer $SIDESPACE_TOKEN" \
-H "Content-Type: application/json" \
-d '{"q":"harbor night","scope":{"spaces":["space"],"folder":"folder","depth":"0"},"filters":[{}]}'{
"hits": [
{}
],
"counts": {
"key": [
{}
]
},
"coverage": {
"total": 1,
"indexed": 1,
"waiting": 1,
"failed": 1,
"meaning": 1
},
"meaning": {
"state": "used",
"model": "model",
"query": "client",
"reason": "no_query_vector",
"next": "next"
},
"next": "next",
"total": 1,
"total_capped": false,
"ignored": [
{
"kind": "filter",
"key": "key",
"reason": "reason"
}
]
}