Skip to content

Create a folder

POST
/folders
curl --request POST \
--url https://api.engram.page/folders \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{ "folder": "Projects/Engram" }'

Creates an explicit folder marker so the folder can exist while empty. Returns 201 with the folder (count 0). An empty or root folder path is rejected with 422.

Folder path

Media typeapplication/json
CreateFolderRequest
object
folder
required
string
Example
{
"folder": "Projects/Engram"
}

Created

Media typeapplication/json
FolderResponse
object
folder
required
Folder
object
count
integer
id
string format: uuid
nullable
name
required
string
parent_id
string format: uuid
nullable
Examplegenerated
{
"folder": {
"count": 1,
"id": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0",
"name": "example",
"parent_id": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0"
}
}

Empty/root folder rejected

Media typeapplication/json
Error
object
errors
One of:
string
Examplegenerated
{
"errors": {}
}