Documentation Index
Fetch the complete documentation index at: https://api-tools.memories.ai/llms.txt
Use this file to discover all available pages before exploring further.
Prerequisites
- You’re familiar with the concepts described on the Platform overview.
- You have created a memories.ai API key.
- Supported file extensions:
.mp4, .avi, .mkv, .mov. The request’s Content-Type on the file part must start with video/.
- Video and audio codecs: h264, h265, vp9, or hevc.
- Audio track: Required if you intend to use the audio transcription feature.
- Max file size: 3 GB per upload.
Host URL
Endpoint
POST /serve/api/v1/upload
Authentication
Pass your API key in the Authorization request header. Requests without a valid API key are rejected.
Content Type
The endpoint expects multipart/form-data. All non-file parameters must be sent as form fields (not JSON).
Request Example
import os
import requests
headers = {"Authorization": "<API_KEY>"}
file_path = "<VIDEO_FILE_PATH>"
files = {
"file": (os.path.basename(file_path), open(file_path, 'rb'), "video/mp4")
}
data = {
"callback": "<CallBack URL>",
"unique_id": "test1020",
"datetime_taken": "2025-10-20 11:00:00",
"camera_model": "Canon EOS 5D",
"latitude": "66.66",
"longitude": "66.66",
"tags": ["test1", "test2", "test3", "test4", "test5"],
"retain_original_video": True,
"video_transcription_prompt": "<YOUR_CUSTOMIZED_PROMPT_FOR_VIDEO_FOCUS>"
}
response = requests.post(
"https://api.memories.ai/serve/api/v1/upload",
files=files,
data=data,
headers=headers
)
print(response.json())
Callback Notification Payload
If you provide a callback, memories.ai will send a POST request to it once the video has been uploaded or parsed.
{
"videoNo": "VI554046065381212160",
"status": "PARSE"
}
Request Parameters
The video file to upload. Must not be empty. The file extension must be one of .mp4, .avi, .mkv, .mov (case-insensitive) and the Content-Type of the file part must start with video/. Maximum size 3 GB.
Scope identifier used to group videos under a logical folder for the authenticated account. If the folder for this unique_id does not exist yet, it is created automatically on the first upload. Must be non-empty when explicitly provided.
Callback URL that will receive a POST notification when the video moves to the parsing stage. Maximum length 299 characters.
Capture time of the video in the exact format yyyy-MM-dd HH:mm:ss (e.g. 2025-10-20 11:00:00). Invalid formats are rejected.
Camera/device model name. Maximum length 200 characters.
Latitude where the video was captured. Must be a valid decimal number (e.g. 66.66).
Longitude where the video was captured. Must be a valid decimal number (e.g. 66.66).
List of user-defined tags (e.g. ["test1", "test2"]). Maximum 20 tags per request. The server automatically appends an api tag to every upload.
Whether to retain the original uploaded video file. Defaults to true.
video_transcription_prompt
Custom prompt that steers the video transcription/understanding focus.
Notes & Limits
- Rate limiting: The endpoint is protected by a per-account upload rate limit. Exceeding the limit returns an error indicating the request has exceeded the limit.
- Concurrent indexing limit: There is a per-user cap on the number of videos that can be in the “indexing/unparsed” state within a rolling 2-hour window. New uploads are rejected once this cap is reached until previous videos finish parsing.
- Billing: This endpoint is metered — the cost of the upload is checked and deducted from your account balance at request time. Insufficient balance will cause the request to fail.
- m3u8: Only accounts on a dedicated allow-list may upload
m3u8 sources via this endpoint; the standard file-upload flow is for regular video files.
Response Example
{
"code": "0000",
"msg": "success",
"data": {
"videoNo": "VI568102998803353600",
"videoName": "1be6a69f3c6e49bf986235d68807ab1f",
"videoStatus": "UNPARSE",
"uploadTime": "1744905509814"
}
}
Response Fields
Business status code. 0000 indicates success; any other value indicates an error and msg will describe it.
Human-readable status message.
Unique identifier assigned to the uploaded video. Use this value for all subsequent operations (status queries, transcription, summary, chat, delete, etc.).
Internal name assigned to the stored video.
Initial processing status. Typically UNPARSE immediately after upload; the video will transition to parsing asynchronously.
Upload timestamp in milliseconds since epoch (as a string).
Video file to upload. Allowed extensions: .mp4, .avi, .mkv, .mov. Content-Type must start with video/. Max size 3 GB.
Callback URL invoked when the video moves to the parsing stage. Max 299 characters.
Maximum string length: 299
Example:"https://your.app/callback"
Scope identifier. A folder is auto-created on first use for the authenticated account.
Capture time in format yyyy-MM-dd HH:mm:ss.
Camera/device model. Max 200 characters.
Maximum string length: 200
User-defined tags. Max 20. The server automatically appends an 'api' tag.
Maximum array length: 20
video_transcription_prompt
Example:"Focus on the speaker and major scene changes."
Business status code. 0000 indicates success.
Example:{
"videoNo": "VI568102998803353600",
"videoName": "1be6a69f3c6e49bf986235d68807ab1f",
"videoStatus": "UNPARSE",
"uploadTime": "1744905509814"
}