Getting full information from a certain MediaStorage

Format

MethodGET
URL

/mediastorages/$MEDIA_STORAGE_ID

Request contentsEmpty
Successful answerMediaStorageInfo Object
Non-successful answerErrorMessage Object
Unexpected errorHTTP 500

MediaStorageInfo Object

Schema

media_storage_idStringMediaStorage's unique identifier
host_listString ArrayList of Hosts linked to this MediaStorage
ip_addressStringCIFS IP Server
pathStringCIFS resource path
usernameStringCIFS username
statusStringMediaStorage's current status. Either "unknown", "error", "ok" or "disabled"
status_msgStringMediaStorage's current status message, obtained from last pool
file_listFileInfo ArrayList of all files present on the CIFS resource

JSON example

 

{
    "path": "/cifs",
    "username": "flexvdi",
    "host_list": ["flexdev01"],
    "file_list": [{
        "size": 96468992,
        "ctime": "2016-01-14 12:17:21",
        "filepath": "openSUSE-Tumbleweed-NET-x86_64-Snapshot20151113-Media.iso"
    }, {
        "size": 3722847964,
        "ctime": "2016-01-28 10:02:31",
        "filepath": "flexvdi-webportal-2.2.4.fvm"
    }, {
        "size": 632291328,
        "ctime": "2016-01-26 11:02:10",
        "filepath": "CentOS-7-x86_64-Minimal-1511.iso"
    }],
    "media_storage_id": "cifs",
    "ip_address": "127.0.0.1",
    "status": "ok",
    "status_msg": ""
}

 

FileInfo Object

Schema

 

filepathStringFilename
ctimeStringFile creation time
sizeIntegerFile size (bytes)

JSON example

 

{
    "size": 1487339520,
    "ctime": "2016-01-05 09:45:21",
    "filepath": "xenial-desktop-amd64.iso"
}