Skip to content

Latest commit

 

History

History
137 lines (94 loc) · 4.27 KB

ConfiguratorServiceApi.md

File metadata and controls

137 lines (94 loc) · 4.27 KB

OpenAPI\Client\ConfiguratorServiceApi

All URIs are relative to https://api.beget.com, except if the operation defines another base path.

Method HTTP request Description
configuratorServiceGetCalculation() GET /v1/vps/configurator/calculation
configuratorServiceGetConfiguratorInfo() GET /v1/vps/configurator/info

configuratorServiceGetCalculation()

configuratorServiceGetCalculation($params_cpu_count, $params_disk_size, $params_memory, $region, $vps_id, $software_id, $snapshot_id): \OpenAPI\Client\Model\ConfiguratorGetCalculationResponse

Example

<?php
require_once(__DIR__ . '/vendor/autoload.php');


// Configure Bearer (JWT) authorization: bearerAuth
$config = OpenAPI\Client\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_ACCESS_TOKEN');


$apiInstance = new OpenAPI\Client\Api\ConfiguratorServiceApi(
    // 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
);
$params_cpu_count = 56; // int
$params_disk_size = 56; // int
$params_memory = 56; // int
$region = 'region_example'; // string
$vps_id = 'vps_id_example'; // string
$software_id = 56; // int
$snapshot_id = 'snapshot_id_example'; // string

try {
    $result = $apiInstance->configuratorServiceGetCalculation($params_cpu_count, $params_disk_size, $params_memory, $region, $vps_id, $software_id, $snapshot_id);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling ConfiguratorServiceApi->configuratorServiceGetCalculation: ', $e->getMessage(), PHP_EOL;
}

Parameters

Name Type Description Notes
params_cpu_count int [optional]
params_disk_size int [optional]
params_memory int [optional]
region string [optional]
vps_id string [optional]
software_id int [optional]
snapshot_id string [optional]

Return type

\OpenAPI\Client\Model\ConfiguratorGetCalculationResponse

Authorization

bearerAuth

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to README]

configuratorServiceGetConfiguratorInfo()

configuratorServiceGetConfiguratorInfo($region): \OpenAPI\Client\Model\ConfiguratorGetConfiguratorInfoResponse

Example

<?php
require_once(__DIR__ . '/vendor/autoload.php');


// Configure Bearer (JWT) authorization: bearerAuth
$config = OpenAPI\Client\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_ACCESS_TOKEN');


$apiInstance = new OpenAPI\Client\Api\ConfiguratorServiceApi(
    // 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
);
$region = 'region_example'; // string

try {
    $result = $apiInstance->configuratorServiceGetConfiguratorInfo($region);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling ConfiguratorServiceApi->configuratorServiceGetConfiguratorInfo: ', $e->getMessage(), PHP_EOL;
}

Parameters

Name Type Description Notes
region string [optional]

Return type

\OpenAPI\Client\Model\ConfiguratorGetConfiguratorInfoResponse

Authorization

bearerAuth

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to README]