Getting Folders by Storage Account ID and Container Name
This section explains how to get a list of folders in the specified Azure storage account and container.
Request
GET https://<hostname>/api/v1/cloudInfrastructure/storageAccounts/{azureStorageId}/containers/{containerName}/folders |
Request Headers
The request header must contain an authorization token of the current session.
Request Parameters
The following parameters must be posted as URL.
Parameter | Description |
storageAccountId | The identification numbers of the Azure storage account. Can be obtained as described in Getting Storage Accounts. |
containerName | The name if the Azure container. Can be obtained as described in Getting Containers by Storage ID. |
Request Body
None.
Response
The server returns the following response to the client.
Response Codes
A successfully completed operation returns a response code 200 (OK).
Response Headers
The response to this request contains the following headers. The response may also include additional standard HTTPS headers.
Header | Description |
Content-length | The length of the response body. |
Content-type | The media type and syntax of the response body message: application/json; charset=utf-8 |
Response Body
Property | Type | Description |
|---|---|---|
offset | integer | Shows the offset value. |
limit | integer | Shows the offset limit. |
totalCount | integer | Shows the number of records in the results array. |
results | Contains the result object. | |
_links | Dictionary of string [key] and Object [value] | Links to related resources (navigation property). |
Property | Type | Description |
|---|---|---|
name | string | The name of the folder. |
_links | Dictionary of string [key] and Object [value] | Links to related resources (navigation property). |
Example
Request: GET https://abc.ukwest.cloudapp.azure.com/api/v1/cloudInfrastructure/storageAccounts/yxnykc5zsmiah7efqx3maof1qgi8zp6bfojsnpdqp9xbz5pef3do/containers/storagecontainer/folders
Request Header: Authorization: Bearer <Access-Token>
Response: 200 OK
Response Body: { "offset": 0, "limit": 30, "totalCount": 5, "results": [ { "name": "Folder1", "_links": { "self": {"href": "https://abc.ukwest.cloudapp.azure.com/api/v1/cloudInfrastructure/storageAccounts/yxnykc5zsmiah7efqx3maof1qgi8zp6bfojsnpdqp9xbz5pef3do/containers/storagecontainer/folders/Folder1"}, "state": {"href": "https://abc.ukwest.cloudapp.azure.com/api/v1/cloudInfrastructure/storageAccounts/yxnykc5zsmiah7efqx3maof1qgi8zp6bfojsnpdqp9xbz5pef3do/containers/storagecontainer/folderState?folderName=Folder1"} } }, { "name": "Folder2", "_links": { "self": {"href": "https://abc.ukwest.cloudapp.azure.com/api/v1/cloudInfrastructure/storageAccounts/yxnykc5zsmiah7efqx3maof1qgi8zp6bfojsnpdqp9xbz5pef3do/containers/storagecontainer/folders/Folder2"}, "state": {"href": "https://abc.ukwest.cloudapp.azure.com/api/v1/cloudInfrastructure/storageAccounts/yxnykc5zsmiah7efqx3maof1qgi8zp6bfojsnpdqp9xbz5pef3do/containers/storagecontainer/folderState?folderName=Folder2"} } }, { "name": "Folder3", "_links": { "self": {"href": "https://abc.ukwest.cloudapp.azure.com/api/v1/cloudInfrastructure/storageAccounts/yxnykc5zsmiah7efqx3maof1qgi8zp6bfojsnpdqp9xbz5pef3do/containers/storagecontainer/folders/Folder3"}, "state": {"href": "https://abc.ukwest.cloudapp.azure.com/api/v1/cloudInfrastructure/storageAccounts/yxnykc5zsmiah7efqx3maof1qgi8zp6bfojsnpdqp9xbz5pef3do/containers/storagecontainer/folderState?folderName=Folder3"} } }, { "name": "Folder4", "_links": { "self": {"href": "https://abc.ukwest.cloudapp.azure.com/api/v1/cloudInfrastructure/storageAccounts/yxnykc5zsmiah7efqx3maof1qgi8zp6bfojsnpdqp9xbz5pef3do/containers/storagecontainer/folders/Folder4"}, "state": {"href": "https://abc.ukwest.cloudapp.azure.com/api/v1/cloudInfrastructure/storageAccounts/yxnykc5zsmiah7efqx3maof1qgi8zp6bfojsnpdqp9xbz5pef3do/containers/storagecontainer/folderState?folderName=Folder4"} } }, { "name": "Folder5", "_links": { "self": {"href": "https://abc.ukwest.cloudapp.azure.com/api/v1/cloudInfrastructure/storageAccounts/yxnykc5zsmiah7efqx3maof1qgi8zp6bfojsnpdqp9xbz5pef3do/containers/storagecontainer/folders/Folder5"}, "state": {"href": "https://abc.ukwest.cloudapp.azure.com/api/v1/cloudInfrastructure/storageAccounts/yxnykc5zsmiah7efqx3maof1qgi8zp6bfojsnpdqp9xbz5pef3do/containers/storagecontainer/folderState?folderName=Folder5"} } } ], "_links": {"self": {"href": "https://abc.ukwest.cloudapp.azure.com:443/api/v1/cloudInfrastructure/storageAccounts/yxnykc5zsmiah7efqx3maof1qgi8zp6bfojsnpdqp9xbz5pef3do/containers/storagecontainer/folders?offset=0&limit=30"}} } |