Structure
GET /structure
Get the structure of the Foundry world
Retrieves the folder and compendium structure for the specified Foundry world.
Parameters
| Name | Type | Required | Source | Description |
|---|---|---|---|---|
| clientId | string | query | Client ID for the Foundry world | |
| includeEntityData | boolean | query | Whether to include full entity data or just UUIDs and names | |
| path | string | query | Path to read structure from (null = root) | |
| recursive | boolean | query | Whether to read down the folder tree | |
| recursiveDepth | number | query | Depth to recurse into folders (default 5) | |
| types | string | query | Types to return (Scene/Actor/Item/JournalEntry/RollTable/Cards/Macro/Playlist), can be comma-separated or JSON array | |
| userId | string | query, body | Foundry user ID or username to scope permissions (omit for GM-level access) |
Returns
object - The folder and compendium structure
Try It Out
GET /get-folder
Get a specific folder by name
Parameters
| Name | Type | Required | Source | Description |
|---|---|---|---|---|
| name | string | ✓ | body, query | Name of the folder to retrieve |
| clientId | string | query | Client ID for the Foundry world | |
| userId | string | query, body | Foundry user ID or username to scope permissions (omit for GM-level access) |
Returns
object - The folder information and its contents
Try It Out
POST /create-folder
Create a new folder
Parameters
| Name | Type | Required | Source | Description |
|---|---|---|---|---|
| name | string | ✓ | body, query | Name of the new folder |
| folderType | string | ✓ | body, query | Type of folder (Scene, Actor, Item, JournalEntry, RollTable, Cards, Macro, Playlist) |
| clientId | string | query | Client ID for the Foundry world | |
| parentFolderId | string | body, query | ID of the parent folder (optional for root level) | |
| userId | string | query, body | Foundry user ID or username to scope permissions (omit for GM-level access) |
Returns
object - The created folder information
Try It Out
DELETE /delete-folder
Delete a folder
Parameters
| Name | Type | Required | Source | Description |
|---|---|---|---|---|
| folderId | string | ✓ | body, query | ID of the folder to delete |
| clientId | string | query | Client ID for the Foundry world | |
| deleteAll | boolean | body, query | Whether to delete all entities in the folder | |
| userId | string | query, body | Foundry user ID or username to scope permissions (omit for GM-level access) |
Returns
object - Confirmation of deletion
Try It Out
GET /contents/:path
This route is deprecated
Use /structure with the path query parameter instead.
Returns
object - Error message directing to use /structure endpoint