All URIs are relative to https://api.upcloud.com/1.3
Method | HTTP request | Description |
---|---|---|
getListObjectStorage | GET /object-storage | List all Object Storage |
getObjectStorageDetails | GET /object-storage/{uuid} | Get Object Storage details |
createObjectStorage | POST /object-storage | Create a new Object Storage |
modifyObjectStorage | PATCH /object-storage/{id} | Modify Object Storage |
deleteObjectStorage | DELETE /object-storage/{id} | Release Object Storage |
\Upcloud\ApiClient\Model\ObjectStorageListResponse getListObjectStorage()
List Object Storage
<?php
require_once(__DIR__ . '/vendor/autoload.php');
// Configure HTTP basic authorization: baseAuth
Upcloud\ApiClient\Configuration::getDefaultConfiguration()->setUsername('YOUR_USERNAME');
Upcloud\ApiClient\Configuration::getDefaultConfiguration()->setPassword('YOUR_PASSWORD');
$api_instance = new Upcloud\ApiClient\Upcloud\ObjectStorageApi();
try {
$result = $api_instance->getListObjectStorage();
print_r($result);
} catch (Exception $e) {
echo 'Exception when calling ObjectStorageApi->getListObjectStorage: ', $e->getMessage(), PHP_EOL;
}
?>
This endpoint does not need any parameter.
\Upcloud\ApiClient\Model\ObjectStorageListResponse
- Content-Type: application/json
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
\Upcloud\ApiClient\Model\ObjectStorageResponse getObjectStorageDetails($uuid)
Get Object Storage details
Returns detailed information about a specific object storage.
<?php
require_once(__DIR__ . '/vendor/autoload.php');
// Configure HTTP basic authorization: baseAuth
Upcloud\ApiClient\Configuration::getDefaultConfiguration()->setUsername('YOUR_USERNAME');
Upcloud\ApiClient\Configuration::getDefaultConfiguration()->setPassword('YOUR_PASSWORD');
$api_instance = new Upcloud\ApiClient\Upcloud\ObjectStorageApi();
$uuid = "uuid_example"; // string | ObjectStorage uuid
try {
$result = $api_instance->getObjectStorageDetails($uuid);
print_r($result);
} catch (Exception $e) {
echo 'Exception when calling ObjectStorageApi->getObjectStorageDetails: ', $e->getMessage(), PHP_EOL;
}
?>
Name | Type | Description | Notes |
---|---|---|---|
uuid | string | ObjectStorage uuid |
\Upcloud\ApiClient\Model\ObjectStorageResponse
- Content-Type: application/json
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
\Upcloud\ApiClient\Model\ObjectStorageResponse createObjectStorage($storage)
Create a new Object Storage
<?php
require_once(__DIR__ . '/vendor/autoload.php');
// Configure HTTP basic authorization: baseAuth
Upcloud\ApiClient\Configuration::getDefaultConfiguration()->setUsername('YOUR_USERNAME');
Upcloud\ApiClient\Configuration::getDefaultConfiguration()->setPassword('YOUR_PASSWORD');
$api_instance = new Upcloud\ApiClient\Upcloud\ObjectStorageApi();
$storage = new \Upcloud\ApiClient\Model\CreateObjectStorageRequest(); // \Upcloud\ApiClient\Model\CreateObjectStorageRequest |
try {
$result = $api_instance->createObjectStorage($storage);
print_r($result);
} catch (Exception $e) {
echo 'Exception when calling ObjectStorageApi->createObjectStorage: ', $e->getMessage(), PHP_EOL;
}
?>
Name | Type | Description | Notes |
---|---|---|---|
storage | \Upcloud\ApiClient\Model\CreateObjectStorageRequest |
\Upcloud\ApiClient\Model\ObjectStorageResponse
- Content-Type: application/json
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
\Upcloud\ApiClient\Model\ObjectStorageResponse modifyObjectStorage($uuid, $storage)
Modify Object Storage
Modifies description of a specific Object Storage.
<?php
require_once(__DIR__ . '/vendor/autoload.php');
// Configure HTTP basic authorization: baseAuth
Upcloud\ApiClient\Configuration::getDefaultConfiguration()->setUsername('YOUR_USERNAME');
Upcloud\ApiClient\Configuration::getDefaultConfiguration()->setPassword('YOUR_PASSWORD');
$api_instance = new Upcloud\ApiClient\Upcloud\ObjectStorageApi();
$uuid = "uuid_example"; // string | ObjectStorage uuid
$storage = new \Upcloud\ApiClient\Model\ModifyObjectStorageRequest(); // \Upcloud\ApiClient\Model\ModifyObjectStorageRequest |
try {
$result = $api_instance->modifyObjectStorage($uuid, $storage);
print_r($result);
} catch (Exception $e) {
echo 'Exception when calling ObjectStorageApi->modifyObjectStorage: ', $e->getMessage(), PHP_EOL;
}
?>
Name | Type | Description | Notes |
---|---|---|---|
uuid | string | ObjectStorage uuid | |
storage | \Upcloud\ApiClient\Model\ModifyObjectStorageRequest |
\Upcloud\ApiClient\Model\ObjectStorageResponse
- Content-Type: application/json
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
deleteObjectStorage($uuid)
Delete Object Storage
Note that deleting the storage will permanently delete any data on the device and which cannot be reverted.
<?php
require_once(__DIR__ . '/vendor/autoload.php');
// Configure HTTP basic authorization: baseAuth
Upcloud\ApiClient\Configuration::getDefaultConfiguration()->setUsername('YOUR_USERNAME');
Upcloud\ApiClient\Configuration::getDefaultConfiguration()->setPassword('YOUR_PASSWORD');
$api_instance = new Upcloud\ApiClient\Upcloud\ObjectStorageApi();
$uuid = "uuid_example"; // string | ObjectStorage uuid
try {
$api_instance->deleteObjectStorage($uuid);
} catch (Exception $e) {
echo 'Exception when calling ObjectStorageApi->deleteObjectStorage: ', $e->getMessage(), PHP_EOL;
}
?>
Name | Type | Description | Notes |
---|---|---|---|
uuid | string | ObjectStorage uuid |
void (empty response body)
- Content-Type: application/json
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]