Skip to main content
POST
/
api
/
v1
/
search
Search Memories
curl --request POST \
  --url https://api.example.com/api/v1/search \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "query": "<string>",
  "space_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
  "limit": 10,
  "recency_bias": 0.5,
  "rerank": true,
  "graph": true,
  "diversify": false,
  "include_source": true
}
'
{
  "query": "<string>",
  "candidates": [
    {
      "memory_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
      "content": "<string>",
      "memory_type": "<string>",
      "score": 123,
      "created_at": "2023-11-07T05:31:56Z",
      "recorded_at": "2023-11-07T05:31:56Z",
      "event_time": "2023-11-07T05:31:56Z",
      "source": "<string>"
    }
  ],
  "total": 123,
  "took_ms": 123
}

Documentation Index

Fetch the complete documentation index at: https://docs.crosmos.dev/llms.txt

Use this file to discover all available pages before exploring further.

Authorizations

Authorization
string
header
required

JWT access token or API key (csk_…)

Body

application/json
query
string
required

The search query text

Required string length: 1 - 3000
space_id
string<uuid>
required

The memory space to search within

limit
integer
default:10

Max number of results to return

Required range: 1 <= x <= 50
recency_bias
number | null

Override recency weighting. 0.0 disables recency, higher values favor recent memories.

Required range: 0 <= x <= 1
rerank
boolean
default:true

Apply cross-encoder reranking. Disable for lower latency.

graph
boolean
default:true

Include graph traversal signal. Disable for semantic + keyword only.

diversify
boolean
default:false

Apply MMR diversity post-rerank. Enable for broad/summarization intents.

include_source
boolean
default:true

Include original source text in results.

Response

Successful Response

query
string
required
candidates
MemoryCandidate · object[]
required
total
integer
required

Total number of candidates returned

took_ms
number
required

Search execution time in milliseconds