Files
Nemera/docs/technical/api/file-system-management/Api.Directories.md
T

4.3 KiB

Lumina API

File System Management

Directories

Get Directories

Get Directories Request
GET api/v1/directories/get-directories?path=C%3A%5CUsers%5C&includeHiddenElements=true
Get Directories Response
200 Ok
[
  {
    "Items": [],
    "Path": "/media/movies/The Matrix (1999)/",
    "Name": "The Matrix",
    "DateCreated": "2025-01-01T13:50:38.3183787Z",
    "DateModified": "2025-01-01T13:40:38.3183791Z"
  },
  {
    "Items": [],
    "Path": "/media/movies/The Lord of the Rings - The Fellowship of the Ring (2001)/",
    "Name": "The Lord of the Rings - The Fellowship of the Ring (2001)",
    "DateCreated": "2025-01-01T13:50:38.3184681Z",
    "DateModified": "2025-01-01T13:40:38.3184683Z"
  }
]

Get Directory Tree

Get Directory Tree Request
GET api/v1/directories/get-directory-tree?path=C%3A%5CUsers%5C&includeFiles=true&includeHiddenElements=true
Get Directory Tree Response
200 Ok
[
  {
    "Path": "/",
    "Name": "The Lord of the Rings - The Fellowship of the Ring (2001)",
    "ItemType": "Root",
    "IsExpanded": true,
    "ChildrenLoaded": true,
    "Children": [
      {
        "Path": "/media/",
        "Name": "media",
        "ItemType": "Directory",
        "IsExpanded": true,
        "ChildrenLoaded": true,
        "Children": [
          {
            "Path": "/media/movies/",
            "Name": "movies",
            "ItemType": "Directory",
            "IsExpanded": true,
            "ChildrenLoaded": true,
            "Children": [
              {
                "Path": "/media/movies/The Lord of the Rings - The Fellowship of the Ring (2001)/",
                "Name": "The Lord of the Rings - The Fellowship of the Ring (2001)",
                "ItemType": "Directory",
                "IsExpanded": true,
                "ChildrenLoaded": true,
                "Children": [
                  {
                    "Path": "/media/movies/The Lord of the Rings - The Fellowship of the Ring (2001)/Extras/",
                    "Name": "Extras",
                    "ItemType": "Directory",
                    "IsExpanded": false,
                    "ChildrenLoaded": false,
                    "Children": []
                  },
                  {
                    "Path": "/media/movies/The Matrix (1999)/The Matrix.mkv",
                    "Name": "The Matrix.mkv",
                    "ItemType": "File",
                    "IsExpanded": false,
                    "ChildrenLoaded": false,
                    "Children": []
                  },
                  {
                    "Path": "/media/movies/The Matrix (1999)/The Matrix.en.srt",
                    "Name": "The Matrix.en.srt",
                    "ItemType": "File",
                    "IsExpanded": false,
                    "ChildrenLoaded": false,
                    "Children": []
                  }
                ]
              }
            ]
          }
        ]
      }
    ]
  }
]

Get Tree Directories

Get Tree Directories Request
GET api/v1/directories/get-tree-directories?path=C%3A%5CUsers%5C&includeHiddenElements=true
Get Tree Directories Response
200 Ok
[
  {
    "Path": "/media/movies/The Matrix (1999)/",
    "Name": "The Matrix (1999)",
    "ItemType": "Directory",
    "IsExpanded": false,
    "ChildrenLoaded": false,
    "Children": []
  },
  {
    "Path": "/media/movies/The Lord of the Rings - The Fellowship of the Ring (2001)/",
    "Name": "The Lord of the Rings - The Fellowship of the Ring (2001)",
    "ItemType": "Directory",
    "IsExpanded": false,
    "ChildrenLoaded": false,
    "Children": []
  }
]