POST
/
add
curl --request POST \
  --url https://v2.api.supermemory.ai/add \
  --header 'Content-Type: application/json' \
  --header 'x-api-key: <api-key>' \
  --data '{
  "content": "This is a detailed article about machine learning concepts..",
  "metadata": {
    "source": "web",
    "category": "technology",
    "tag_1": "ai",
    "tag_2": "machine-learning",
    "readingTime": 5,
    "isPublic": true
  }
}'
{
  "id": "<string>",
  "status": "<string>"
}

Authorizations

x-api-key
string
header
required

Body

application/json
content
string
required

The content to extract and process into a memory. This can be a URL to a website, a PDF, an image, or a video.

Plaintext: Any plaintext format

URL: A URL to a website, PDF, image, or video

We automatically detect the content type from the url's response format.

Minimum length: 1
Example:

"This is a detailed article about machine learning concepts.."

userId
string

Optional end user ID this memory belongs to. This is used to group memories by user. You should use the same ID stored in your external system where the user is stored

Example:

"user_123"

metadata
object

Optional metadata for the memory. This is used to store additional information about the memory. You can use this to store any additional information you need about the memory. Metadata can be filtered through. Keys must be strings and are case sensitive. Values can be strings, numbers, or booleans. You cannot nest objects.

Example:
{
  "source": "web",
  "category": "technology",
  "tag_1": "ai",
  "tag_2": "machine-learning",
  "readingTime": 5,
  "isPublic": true
}
id
string

Response

200
application/json
Memory added successfully
id
string
required
status
string
required