# Sylius\ProductTaxonApi

Resource &#39;ProductTaxon&#39; operations.

All URIs are relative to http://localhost, except if the operation defines another base path.

| Method | HTTP request | Description |
| ------------- | ------------- | ------------- |
| [**syliusApiAdminProductTaxonDelete()**](ProductTaxonApi.md#syliusApiAdminProductTaxonDelete) | **DELETE** /api/v2/admin/product-taxons/{id} | Removes the ProductTaxon resource. |
| [**syliusApiAdminProductTaxonGet()**](ProductTaxonApi.md#syliusApiAdminProductTaxonGet) | **GET** /api/v2/admin/product-taxons/{id} | Retrieves a ProductTaxon resource. |
| [**syliusApiAdminProductTaxonGetCollection()**](ProductTaxonApi.md#syliusApiAdminProductTaxonGetCollection) | **GET** /api/v2/admin/product-taxons | Retrieves the collection of ProductTaxon resources. |
| [**syliusApiAdminProductTaxonPost()**](ProductTaxonApi.md#syliusApiAdminProductTaxonPost) | **POST** /api/v2/admin/product-taxons | Creates a ProductTaxon resource. |
| [**syliusApiAdminProductTaxonPut()**](ProductTaxonApi.md#syliusApiAdminProductTaxonPut) | **PUT** /api/v2/admin/product-taxons/{id} | Replaces the ProductTaxon resource. |
| [**syliusApiShopProductTaxonGet()**](ProductTaxonApi.md#syliusApiShopProductTaxonGet) | **GET** /api/v2/shop/product-taxons/{id} | Retrieves a ProductTaxon resource. |


## `syliusApiAdminProductTaxonDelete()`

```php
syliusApiAdminProductTaxonDelete($id, $accept_language)
```

Removes the ProductTaxon resource.

Removes the ProductTaxon resource.

### Example

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


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


$apiInstance = new Sylius\Api\ProductTaxonApi(
    // 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
);
$id = 'id_example'; // string | ProductTaxon identifier
$accept_language = 'accept_language_example'; // string | Locales in this enum are all locales defined in the shop and only enabled ones will work in the given channel in the shop.

try {
    $apiInstance->syliusApiAdminProductTaxonDelete($id, $accept_language);
} catch (Exception $e) {
    echo 'Exception when calling ProductTaxonApi->syliusApiAdminProductTaxonDelete: ', $e->getMessage(), PHP_EOL;
}
```

### Parameters

| Name | Type | Description  | Notes |
| ------------- | ------------- | ------------- | ------------- |
| **id** | **string**| ProductTaxon identifier | |
| **accept_language** | **string**| Locales in this enum are all locales defined in the shop and only enabled ones will work in the given channel in the shop. | [optional] |

### Return type

void (empty response body)

### Authorization

[JWT](../../README.md#JWT)

### HTTP request headers

- **Content-Type**: Not defined
- **Accept**: `application/ld+json`, `application/problem+json`, `application/json`

[[Back to top]](#) [[Back to API list]](../../README.md#endpoints)
[[Back to Model list]](../../README.md#models)
[[Back to README]](../../README.md)

## `syliusApiAdminProductTaxonGet()`

```php
syliusApiAdminProductTaxonGet($id, $accept_language): \Sylius\Model\ProductTaxonJsonldSyliusAdminProductTaxonShow
```

Retrieves a ProductTaxon resource.

Retrieves a ProductTaxon resource.

### Example

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


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


$apiInstance = new Sylius\Api\ProductTaxonApi(
    // 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
);
$id = 'id_example'; // string | ProductTaxon identifier
$accept_language = 'accept_language_example'; // string | Locales in this enum are all locales defined in the shop and only enabled ones will work in the given channel in the shop.

try {
    $result = $apiInstance->syliusApiAdminProductTaxonGet($id, $accept_language);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling ProductTaxonApi->syliusApiAdminProductTaxonGet: ', $e->getMessage(), PHP_EOL;
}
```

### Parameters

| Name | Type | Description  | Notes |
| ------------- | ------------- | ------------- | ------------- |
| **id** | **string**| ProductTaxon identifier | |
| **accept_language** | **string**| Locales in this enum are all locales defined in the shop and only enabled ones will work in the given channel in the shop. | [optional] |

### Return type

[**\Sylius\Model\ProductTaxonJsonldSyliusAdminProductTaxonShow**](../Model/ProductTaxonJsonldSyliusAdminProductTaxonShow.md)

### Authorization

[JWT](../../README.md#JWT)

### HTTP request headers

- **Content-Type**: Not defined
- **Accept**: `application/ld+json`, `application/json`, `application/problem+json`

[[Back to top]](#) [[Back to API list]](../../README.md#endpoints)
[[Back to Model list]](../../README.md#models)
[[Back to README]](../../README.md)

## `syliusApiAdminProductTaxonGetCollection()`

```php
syliusApiAdminProductTaxonGetCollection($page, $items_per_page, $order_position, $product_code, $product_code2, $taxon_code, $taxon_code2, $accept_language): \Sylius\Model\SyliusApiAdminProductTaxonGetCollection200Response
```

Retrieves the collection of ProductTaxon resources.

Retrieves the collection of ProductTaxon resources.

### Example

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


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


$apiInstance = new Sylius\Api\ProductTaxonApi(
    // 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
);
$page = 1; // int | The collection page number
$items_per_page = 30; // int | The number of items per page
$order_position = ''; // string | 
$product_code = 'product_code_example'; // string | 
$product_code2 = array('product_code_example'); // string[] | 
$taxon_code = 'taxon_code_example'; // string | 
$taxon_code2 = array('taxon_code_example'); // string[] | 
$accept_language = 'accept_language_example'; // string | Locales in this enum are all locales defined in the shop and only enabled ones will work in the given channel in the shop.

try {
    $result = $apiInstance->syliusApiAdminProductTaxonGetCollection($page, $items_per_page, $order_position, $product_code, $product_code2, $taxon_code, $taxon_code2, $accept_language);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling ProductTaxonApi->syliusApiAdminProductTaxonGetCollection: ', $e->getMessage(), PHP_EOL;
}
```

### Parameters

| Name | Type | Description  | Notes |
| ------------- | ------------- | ------------- | ------------- |
| **page** | **int**| The collection page number | [optional] [default to 1] |
| **items_per_page** | **int**| The number of items per page | [optional] [default to 30] |
| **order_position** | **string**|  | [optional] [default to &#39;&#39;] |
| **product_code** | **string**|  | [optional] |
| **product_code2** | [**string[]**](../Model/string.md)|  | [optional] |
| **taxon_code** | **string**|  | [optional] |
| **taxon_code2** | [**string[]**](../Model/string.md)|  | [optional] |
| **accept_language** | **string**| Locales in this enum are all locales defined in the shop and only enabled ones will work in the given channel in the shop. | [optional] |

### Return type

[**\Sylius\Model\SyliusApiAdminProductTaxonGetCollection200Response**](../Model/SyliusApiAdminProductTaxonGetCollection200Response.md)

### Authorization

[JWT](../../README.md#JWT)

### HTTP request headers

- **Content-Type**: Not defined
- **Accept**: `application/ld+json`, `application/json`

[[Back to top]](#) [[Back to API list]](../../README.md#endpoints)
[[Back to Model list]](../../README.md#models)
[[Back to README]](../../README.md)

## `syliusApiAdminProductTaxonPost()`

```php
syliusApiAdminProductTaxonPost($product_taxon_sylius_admin_product_taxon_create, $accept_language): \Sylius\Model\ProductTaxonJsonldSyliusAdminProductTaxonShow
```

Creates a ProductTaxon resource.

Creates a ProductTaxon resource.

### Example

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


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


$apiInstance = new Sylius\Api\ProductTaxonApi(
    // 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
);
$product_taxon_sylius_admin_product_taxon_create = new \Sylius\Model\ProductTaxonSyliusAdminProductTaxonCreate(); // \Sylius\Model\ProductTaxonSyliusAdminProductTaxonCreate | The new ProductTaxon resource
$accept_language = 'accept_language_example'; // string | Locales in this enum are all locales defined in the shop and only enabled ones will work in the given channel in the shop.

try {
    $result = $apiInstance->syliusApiAdminProductTaxonPost($product_taxon_sylius_admin_product_taxon_create, $accept_language);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling ProductTaxonApi->syliusApiAdminProductTaxonPost: ', $e->getMessage(), PHP_EOL;
}
```

### Parameters

| Name | Type | Description  | Notes |
| ------------- | ------------- | ------------- | ------------- |
| **product_taxon_sylius_admin_product_taxon_create** | [**\Sylius\Model\ProductTaxonSyliusAdminProductTaxonCreate**](../Model/ProductTaxonSyliusAdminProductTaxonCreate.md)| The new ProductTaxon resource | |
| **accept_language** | **string**| Locales in this enum are all locales defined in the shop and only enabled ones will work in the given channel in the shop. | [optional] |

### Return type

[**\Sylius\Model\ProductTaxonJsonldSyliusAdminProductTaxonShow**](../Model/ProductTaxonJsonldSyliusAdminProductTaxonShow.md)

### Authorization

[JWT](../../README.md#JWT)

### HTTP request headers

- **Content-Type**: `application/ld+json`, `application/json`
- **Accept**: `application/ld+json`, `application/json`, `application/problem+json`

[[Back to top]](#) [[Back to API list]](../../README.md#endpoints)
[[Back to Model list]](../../README.md#models)
[[Back to README]](../../README.md)

## `syliusApiAdminProductTaxonPut()`

```php
syliusApiAdminProductTaxonPut($id, $product_taxon_sylius_admin_product_taxon_update, $accept_language): \Sylius\Model\ProductTaxonJsonldSyliusAdminProductTaxonShow
```

Replaces the ProductTaxon resource.

Replaces the ProductTaxon resource.

### Example

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


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


$apiInstance = new Sylius\Api\ProductTaxonApi(
    // 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
);
$id = 'id_example'; // string | ProductTaxon identifier
$product_taxon_sylius_admin_product_taxon_update = new \Sylius\Model\ProductTaxonSyliusAdminProductTaxonUpdate(); // \Sylius\Model\ProductTaxonSyliusAdminProductTaxonUpdate | The updated ProductTaxon resource
$accept_language = 'accept_language_example'; // string | Locales in this enum are all locales defined in the shop and only enabled ones will work in the given channel in the shop.

try {
    $result = $apiInstance->syliusApiAdminProductTaxonPut($id, $product_taxon_sylius_admin_product_taxon_update, $accept_language);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling ProductTaxonApi->syliusApiAdminProductTaxonPut: ', $e->getMessage(), PHP_EOL;
}
```

### Parameters

| Name | Type | Description  | Notes |
| ------------- | ------------- | ------------- | ------------- |
| **id** | **string**| ProductTaxon identifier | |
| **product_taxon_sylius_admin_product_taxon_update** | [**\Sylius\Model\ProductTaxonSyliusAdminProductTaxonUpdate**](../Model/ProductTaxonSyliusAdminProductTaxonUpdate.md)| The updated ProductTaxon resource | |
| **accept_language** | **string**| Locales in this enum are all locales defined in the shop and only enabled ones will work in the given channel in the shop. | [optional] |

### Return type

[**\Sylius\Model\ProductTaxonJsonldSyliusAdminProductTaxonShow**](../Model/ProductTaxonJsonldSyliusAdminProductTaxonShow.md)

### Authorization

[JWT](../../README.md#JWT)

### HTTP request headers

- **Content-Type**: `application/ld+json`, `application/json`
- **Accept**: `application/ld+json`, `application/json`, `application/problem+json`

[[Back to top]](#) [[Back to API list]](../../README.md#endpoints)
[[Back to Model list]](../../README.md#models)
[[Back to README]](../../README.md)

## `syliusApiShopProductTaxonGet()`

```php
syliusApiShopProductTaxonGet($id, $accept_language): \Sylius\Model\ProductTaxonJsonldSyliusShopProductTaxonShow
```

Retrieves a ProductTaxon resource.

Retrieves a ProductTaxon resource.

### Example

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


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


$apiInstance = new Sylius\Api\ProductTaxonApi(
    // 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
);
$id = 'id_example'; // string | ProductTaxon identifier
$accept_language = 'accept_language_example'; // string | Locales in this enum are all locales defined in the shop and only enabled ones will work in the given channel in the shop.

try {
    $result = $apiInstance->syliusApiShopProductTaxonGet($id, $accept_language);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling ProductTaxonApi->syliusApiShopProductTaxonGet: ', $e->getMessage(), PHP_EOL;
}
```

### Parameters

| Name | Type | Description  | Notes |
| ------------- | ------------- | ------------- | ------------- |
| **id** | **string**| ProductTaxon identifier | |
| **accept_language** | **string**| Locales in this enum are all locales defined in the shop and only enabled ones will work in the given channel in the shop. | [optional] |

### Return type

[**\Sylius\Model\ProductTaxonJsonldSyliusShopProductTaxonShow**](../Model/ProductTaxonJsonldSyliusShopProductTaxonShow.md)

### Authorization

[JWT](../../README.md#JWT)

### HTTP request headers

- **Content-Type**: Not defined
- **Accept**: `application/ld+json`, `application/json`, `application/problem+json`

[[Back to top]](#) [[Back to API list]](../../README.md#endpoints)
[[Back to Model list]](../../README.md#models)
[[Back to README]](../../README.md)
