Container tags are optional tags (array of strings) to group memories.
You can chain container tags to filter memories by multiple tags.
["user_123", "org_123", "channel_123"]
would mean “user_123 AND org_123 AND channel_123”.
curl https://api.supermemory.ai/v3/search \
--request POST \
--header 'Content-Type: application/json' \
--header 'Authorization: Bearer YOUR_SECRET_TOKEN' \
--data '{
"q": "machine learning",
"containerTags": ["user_123", "project_abc"]
}'
Sometimes, you might want to add metadata and do advanced filtering based on it.
Using metadata filtering, you can search based on:
- AND and OR conditions
- String matching
- Numeric matching
- Date matching
- Time range queries
curl https://api.supermemory.ai/v3/search \
--request POST \
--header 'Content-Type: application/json' \
--header 'Authorization: Bearer YOUR_SECRET_TOKEN' \
--data '{
"q": "machine learning",
"filters": {
"AND": [
{
"key": "category",
"value": "technology",
"negate": false
},
{
"filterType": "numeric",
"key": "readingTime",
"value": "5",
"negate": false,
"numericOperator": "<="
}
]
}
}'
Document
You can also find chunks within a specific, large document.
This can be particularly useful for extremely large documents like Books, Podcasts, etc.
curl https://api.supermemory.ai/v3/search \
--request POST \
--header 'Content-Type: application/json' \
--header 'Authorization: Bearer YOUR_SECRET_TOKEN' \
--data '{
"q": "machine learning",
"docId": "doc_123"
}'