All URIs are relative to https://api.aspose.cloud/v4.0
Method | HTTP request | Description |
---|---|---|
createFolder | PUT /html/storage/folder/{path} | Create the folder |
deleteFolder | DELETE /html/storage/folder/{path} | Delete folder |
getFilesList | GET /html/storage/folder/{path} | Get all files and folders within a folder |
createFolder($path, $storage_name) : void
Create the folder
<?php
require_once(__DIR__ . '/vendor/autoload.php');
$configuration = array(
"basePath" => "https://api.aspose.cloud/v4.0",
"authPath" => "https://api.aspose.cloud/oauth2/token",
"apiKey" => "XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",
"appSID" => "XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX",
"defaultUserAgent" => "Webkit"
);
$apiInstance = new Client\Invoker\Api\StorageApi($configuration);
$path = "path_example"; // string | Folder path to create e.g. 'folder_1/folder_2/'
$storage_name = "storage_name_example"; // string | Storage name
try {
$apiInstance->createFolder($path, $storage_name);
} catch (Exception $e) {
echo 'Exception when calling FolderApi->createFolder: ', $e->getMessage(), PHP_EOL;
}
?>
Name | Type | Description | Notes |
---|---|---|---|
path | string | Folder path to create e.g. 'folder_1/folder_2/' | |
storage_name | string | Storage name | [optional] |
void (empty response body)
[Back to top] [Back to API list] [Back to Model list] [Back to README]
deleteFolder($path, $storage_name, $recursive)
Delete folder
<?php
require_once(__DIR__ . '/vendor/autoload.php');
$configuration = array(
"basePath" => "https://api.aspose.cloud/v4.0",
"authPath" => "https://api.aspose.cloud/oauth2/token",
"apiKey" => "XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",
"appSID" => "XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX",
"defaultUserAgent" => "Webkit"
);
$apiInstance = new Client\Invoker\Api\StorageApi($configuration);
$path = "path_example"; // string | Folder path e.g. '/folder'
$storage_name = "storage_name_example"; // string | Storage name
$recursive = 'false'; // string | Enable to delete folders, subfolders and files
try {
$apiInstance->deleteFolder($path, $storage_name, $recursive);
} catch (Exception $e) {
echo 'Exception when calling FolderApi->deleteFolder: ', $e->getMessage(), PHP_EOL;
}
?>
Name | Type | Description | Notes |
---|---|---|---|
path | string | Folder path e.g. '/folder' | |
storage_name | string | Storage name | [optional] |
recursive | string | Enable to delete folders, subfolders and files | [optional] [default to false] |
void (empty response body)
[Back to top] [Back to API list] [Back to Model list] [Back to README]
\Client\Invoker\Model\FilesList getFilesList($path, $storage_name)
Get all files and folders within a folder
<?php
require_once(__DIR__ . '/vendor/autoload.php');
$configuration = array(
"basePath" => "https://api.aspose.cloud/v4.0",
"authPath" => "https://api.aspose.cloud/oauth2/token",
"apiKey" => "XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",
"appSID" => "XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX",
"defaultUserAgent" => "Webkit"
);
$apiInstance = new Client\Invoker\Api\StorageApi($configuration);
$path = "path_example"; // string | Folder path e.g. '/folder'
$storage_name = "storage_name_example"; // string | Storage name
try {
$result = $apiInstance->getFilesList($path, $storage_name);
print_r($result);
} catch (Exception $e) {
echo 'Exception when calling FolderApi->getFilesList: ', $e->getMessage(), PHP_EOL;
}
?>
Name | Type | Description | Notes |
---|---|---|---|
path | string | Folder path e.g. '/folder' | |
storage_name | string | Storage name | [optional] |
\Client\Invoker\Model\FilesList
[Back to top] [Back to API list] [Back to Model list] [Back to README]