What is the Library?
The Library is a unified file system that holds every file MemoryLake can see. Project documents are always created by referencing a file that already lives in the Library. Your top-level writable folder isMY_SPACE — treat it as the root of your workspace. Every file or folder you create is placed under MY_SPACE (directly or nested inside a subfolder).
A typical integration flow looks like this:
Pick a destination folder
Use the alias
MY_SPACE to target your workspace root directly, or pass the item_id of any subfolder you’ve created under it.Upload the file into the Library
Chunked upload: create an upload session, PUT each chunk, then create the file item.
Import the file into a project
Call Add Documents with the
item_id returned from the previous step.Base URL
Item ID Aliases
Anywhere anitem_id is accepted, you can pass the alias MY_SPACE instead of a concrete ID.
MY_SPACE always resolves to your workspace root. Pass it directly whenever you would otherwise have to look up the root folder — for example as parent_item_id when creating a top-level file or folder.
Uploading a File (End-to-End)
File uploads are chunked. You receive one pre-signed PUT URL per chunk, upload each chunk, then finalize by creating afile item that references the upload.
Create the upload session
POST /api/v1/drives/items/upload with file_size in bytes. Returns an upload_id and a list of part_items — one pre-signed URL per chunk.Upload every chunk
PUT each chunk’s bytes to its upload_url. Save the ETag header from each response — you need them all.Python example
Name Conflicts
When creating a file or folder, pick a conflict strategy on the request:| Strategy | Behavior | item_id |
|---|---|---|
rename (default) | Append _N suffix (report_1.pdf). Always succeeds. | New |
deny | Return 409 DRIVE_ITEM_CONFLICT if the name is taken. | — |
overwrite | File-only. Overwrite the existing file’s content in place. | Preserved |
replace | File-only. Delete the existing file and create a new one. | New |
Endpoints
Get Item
Look up a file or folder by
item_id.List Items
Page through the contents of a folder.
Create Upload
Start a chunked upload session and get pre-signed URLs.
Create Item
Create a folder, or finalize an upload as a file item.
Delete Item
Delete a file or folder (recursive for folders).