Search for context data in the context processor
Changed onThis endpoint sends a search request to the context processor to retrieve relevant context data based on the provided query.
Request
- Base URLhttps://platform-backend.getalchemystai.com
- AuthHTTP bearer
- TypeScriptA function with typed inputs. Its response is checked against the schema.
Query parameters
Controls whether metadata is included in the response:
- metadata=true → metadata will be included in each context item in the response.
- metadata=false (or omitted) → metadata will be excluded from the response for better performance.
Controls the search mode:
- mode=fast → prioritizes speed over completeness.
- mode=standard → performs a comprehensive search (default if omitted).
Request body
Example request
{
"user_id": "user123",
"query": "search query for user preferences",
"similarity_threshold": 0.8,
"minimum_similarity_threshold": 0.5,
"body_metadata": {
"fileName": "support_thread_TCK-1234.txt",
"lastModifiedAt": "2025-01-10T12:34:56.000Z"
},
"magic_key": "sk_context_share_nC0KUEF9T6UGDHYVUiMU"
}Response
Context search request successfully processed. Response structure varies based on metadata query parameter: if metadata=true, each context includes metadata; if metadata=false or omitted, metadata is excluded from the response.
Changes
- info
added the new optional request property
/ - info
added the new optional request property
/ - info
added the new optional request property
/ - info
added the new optional request property
/ - info
added the new optional request property
- info
added the new optional request property
- info
- warning
removed the request property
- info
api operation id
searchUserContextwas added - info
added the new optional request property
- info
added the media type
application/jsonfor the response with the status - info
added the media type
application/jsonfor the response with the status - info
added the media type
application/jsonfor the response with the status
- warning