All URIs are relative to https://truenas.local/api/v2.0.
Method | HTTP request | Description |
---|---|---|
poolResilverGet() | GET /pool/resilver | |
poolResilverPut() | PUT /pool/resilver |
poolResilverGet()
<?php
require_once(__DIR__ . '/vendor/autoload.php');
// Configure HTTP basic authorization: basic
$config = RMoore\Truenas\Configuration::getDefaultConfiguration()
->setUsername('YOUR_USERNAME')
->setPassword('YOUR_PASSWORD');
$apiInstance = new RMoore\Truenas\Api\PoolResilverApi(
// If you want use custom http client, pass your client which implements `GuzzleHttp\ClientInterface`.
// This is optional, `GuzzleHttp\Client` will be used as default.
new GuzzleHttp\Client(),
$config
);
try {
$apiInstance->poolResilverGet();
} catch (Exception $e) {
echo 'Exception when calling PoolResilverApi->poolResilverGet: ', $e->getMessage(), PHP_EOL;
}
This endpoint does not need any parameter.
void (empty response body)
- Content-Type: Not defined
- Accept: Not defined
[Back to top] [Back to API list] [Back to Model list] [Back to README]
poolResilverPut($pool_resilver_update0)
Configure Pool Resilver Priority. If begin
time is greater than end
time it means it will rollover the day, e.g. begin = "19:00", end = "05:00" will increase pool resilver priority from 19:00 of one day until 05:00 of the next day. weekday
follows crontab(5) values 0-7 (0 or 7 is Sun).
<?php
require_once(__DIR__ . '/vendor/autoload.php');
// Configure HTTP basic authorization: basic
$config = RMoore\Truenas\Configuration::getDefaultConfiguration()
->setUsername('YOUR_USERNAME')
->setPassword('YOUR_PASSWORD');
$apiInstance = new RMoore\Truenas\Api\PoolResilverApi(
// If you want use custom http client, pass your client which implements `GuzzleHttp\ClientInterface`.
// This is optional, `GuzzleHttp\Client` will be used as default.
new GuzzleHttp\Client(),
$config
);
$pool_resilver_update0 = new \RMoore\Truenas\Model\PoolResilverUpdate0(); // \RMoore\Truenas\Model\PoolResilverUpdate0
try {
$apiInstance->poolResilverPut($pool_resilver_update0);
} catch (Exception $e) {
echo 'Exception when calling PoolResilverApi->poolResilverPut: ', $e->getMessage(), PHP_EOL;
}
Name | Type | Description | Notes |
---|---|---|---|
pool_resilver_update0 | \RMoore\Truenas\Model\PoolResilverUpdate0 | [optional] |
void (empty response body)
- Content-Type:
application/json
- Accept: Not defined
[Back to top] [Back to API list] [Back to Model list] [Back to README]