SpringImport\Swagger\Magento2\Client\ConfigurableProductOptionRepositoryV1Api
May 18, 2017 ยท View on GitHub
All URIs are relative to http://t213.vg/rest/default
| Method | HTTP request | Description |
|---|---|---|
| configurableProductOptionRepositoryV1DeleteByIdDelete | DELETE /V1/configurable-products/{sku}/options/{id} | |
| configurableProductOptionRepositoryV1GetGet | GET /V1/configurable-products/{sku}/options/{id} | |
| configurableProductOptionRepositoryV1GetListGet | GET /V1/configurable-products/{sku}/options/all | |
| configurableProductOptionRepositoryV1SavePost | POST /V1/configurable-products/{sku}/options | |
| configurableProductOptionRepositoryV1SavePut | PUT /V1/configurable-products/{sku}/options/{id} |
configurableProductOptionRepositoryV1DeleteByIdDelete
bool configurableProductOptionRepositoryV1DeleteByIdDelete(id)
Remove option from configurable product
Example
<?php
require_once(__DIR__ . '/vendor/autoload.php');
$api_instance = new SpringImport\Swagger\Magento2\Client\Api\ConfigurableProductOptionRepositoryV1Api();
$sku = "sku_example"; // string |
$id = 56; // int |
try {
$result = $api_instance->configurableProductOptionRepositoryV1DeleteByIdDelete($sku, $id);
print_r($result);
} catch (Exception $e) {
echo 'Exception when calling ConfigurableProductOptionRepositoryV1Api->configurableProductOptionRepositoryV1DeleteByIdDelete: ', $e->getMessage(), PHP_EOL;
}
?>
Parameters
| Name | Type | Description | Notes |
|---|---|---|---|
| sku | string | ||
| id | int |
Return type
bool
Authorization
No authorization required
HTTP request headers
- Content-Type: Not defined
- Accept: Not defined
[Back to top] [Back to API list] [Back to Model list] [Back to README]
configurableProductOptionRepositoryV1GetGet
\SpringImport\Swagger\Magento2\Client\Model\ConfigurableProductDataOptionInterface configurableProductOptionRepositoryV1GetGet(id)
Get option for configurable product
Example
<?php
require_once(__DIR__ . '/vendor/autoload.php');
$api_instance = new SpringImport\Swagger\Magento2\Client\Api\ConfigurableProductOptionRepositoryV1Api();
$sku = "sku_example"; // string |
$id = 56; // int |
try {
$result = $api_instance->configurableProductOptionRepositoryV1GetGet($sku, $id);
print_r($result);
} catch (Exception $e) {
echo 'Exception when calling ConfigurableProductOptionRepositoryV1Api->configurableProductOptionRepositoryV1GetGet: ', $e->getMessage(), PHP_EOL;
}
?>
Parameters
| Name | Type | Description | Notes |
|---|---|---|---|
| sku | string | ||
| id | int |
Return type
\SpringImport\Swagger\Magento2\Client\Model\ConfigurableProductDataOptionInterface
Authorization
No authorization required
HTTP request headers
- Content-Type: Not defined
- Accept: Not defined
[Back to top] [Back to API list] [Back to Model list] [Back to README]
configurableProductOptionRepositoryV1GetListGet
\SpringImport\Swagger\Magento2\Client\Model\ConfigurableProductDataOptionInterface[] configurableProductOptionRepositoryV1GetListGet($sku)
Get all options for configurable product
Example
<?php
require_once(__DIR__ . '/vendor/autoload.php');
$api_instance = new SpringImport\Swagger\Magento2\Client\Api\ConfigurableProductOptionRepositoryV1Api();
$sku = "sku_example"; // string |
try {
$result = $api_instance->configurableProductOptionRepositoryV1GetListGet($sku);
print_r($result);
} catch (Exception $e) {
echo 'Exception when calling ConfigurableProductOptionRepositoryV1Api->configurableProductOptionRepositoryV1GetListGet: ', $e->getMessage(), PHP_EOL;
}
?>
Parameters
| Name | Type | Description | Notes |
|---|---|---|---|
| sku | string |
Return type
\SpringImport\Swagger\Magento2\Client\Model\ConfigurableProductDataOptionInterface[]
Authorization
No authorization required
HTTP request headers
- Content-Type: Not defined
- Accept: Not defined
[Back to top] [Back to API list] [Back to Model list] [Back to README]
configurableProductOptionRepositoryV1SavePost
int configurableProductOptionRepositoryV1SavePost(body)
Save option
Example
<?php
require_once(__DIR__ . '/vendor/autoload.php');
$api_instance = new SpringImport\Swagger\Magento2\Client\Api\ConfigurableProductOptionRepositoryV1Api();
$sku = "sku_example"; // string |
$body = new \SpringImport\Swagger\Magento2\Client\Model\Body111(); // \SpringImport\Swagger\Magento2\Client\Model\Body111 |
try {
$result = $api_instance->configurableProductOptionRepositoryV1SavePost($sku, $body);
print_r($result);
} catch (Exception $e) {
echo 'Exception when calling ConfigurableProductOptionRepositoryV1Api->configurableProductOptionRepositoryV1SavePost: ', $e->getMessage(), PHP_EOL;
}
?>
Parameters
| Name | Type | Description | Notes |
|---|---|---|---|
| sku | string | ||
| body | \SpringImport\Swagger\Magento2\Client\Model\Body111 | [optional] |
Return type
int
Authorization
No authorization required
HTTP request headers
- Content-Type: Not defined
- Accept: Not defined
[Back to top] [Back to API list] [Back to Model list] [Back to README]
configurableProductOptionRepositoryV1SavePut
int configurableProductOptionRepositoryV1SavePut(id, $body)
Save option
Example
<?php
require_once(__DIR__ . '/vendor/autoload.php');
$api_instance = new SpringImport\Swagger\Magento2\Client\Api\ConfigurableProductOptionRepositoryV1Api();
$sku = "sku_example"; // string |
$id = "id_example"; // string |
$body = new \SpringImport\Swagger\Magento2\Client\Model\Body110(); // \SpringImport\Swagger\Magento2\Client\Model\Body110 |
try {
$result = $api_instance->configurableProductOptionRepositoryV1SavePut($sku, $id, $body);
print_r($result);
} catch (Exception $e) {
echo 'Exception when calling ConfigurableProductOptionRepositoryV1Api->configurableProductOptionRepositoryV1SavePut: ', $e->getMessage(), PHP_EOL;
}
?>
Parameters
| Name | Type | Description | Notes |
|---|---|---|---|
| sku | string | ||
| id | string | ||
| body | \SpringImport\Swagger\Magento2\Client\Model\Body110 | [optional] |
Return type
int
Authorization
No authorization required
HTTP request headers
- Content-Type: Not defined
- Accept: Not defined
[Back to top] [Back to API list] [Back to Model list] [Back to README]