# Sylius\AdministratorApi

Resource &#39;Administrator&#39; operations.

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

| Method | HTTP request | Description |
| ------------- | ------------- | ------------- |
| [**postAdministratorCredentialsItem()**](AdministratorApi.md#postAdministratorCredentialsItem) | **POST** /api/v2/admin/administrators/token | Retrieves the JWT token. |
| [**syliusApiAdminAdminUserDelete()**](AdministratorApi.md#syliusApiAdminAdminUserDelete) | **DELETE** /api/v2/admin/administrators/{id} | Removes the Administrator resource. |
| [**syliusApiAdminAdminUserGet()**](AdministratorApi.md#syliusApiAdminAdminUserGet) | **GET** /api/v2/admin/administrators/{id} | Retrieves a Administrator resource. |
| [**syliusApiAdminAdminUserGetCollection()**](AdministratorApi.md#syliusApiAdminAdminUserGetCollection) | **GET** /api/v2/admin/administrators | Retrieves the collection of Administrator resources. |
| [**syliusApiAdminAdminUserPost()**](AdministratorApi.md#syliusApiAdminAdminUserPost) | **POST** /api/v2/admin/administrators | Creates a Administrator resource. |
| [**syliusApiAdminAdminUserPut()**](AdministratorApi.md#syliusApiAdminAdminUserPut) | **PUT** /api/v2/admin/administrators/{id} | Replaces the Administrator resource. |
| [**syliusApiAdminResetPasswordPatch()**](AdministratorApi.md#syliusApiAdminResetPasswordPatch) | **PATCH** /api/v2/admin/administrators/reset-password/{token} | Updates the Administrator resource. |
| [**syliusApiAdminResetPasswordPost()**](AdministratorApi.md#syliusApiAdminResetPasswordPost) | **POST** /api/v2/admin/administrators/reset-password | Creates a Administrator resource. |


## `postAdministratorCredentialsItem()`

```php
postAdministratorCredentialsItem($administrator_admin_administrator_token_create): \Sylius\Model\AdministratorAdminAdministratorTokenRead
```

Retrieves the JWT token.

### 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\AdministratorApi(
    // 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
);
$administrator_admin_administrator_token_create = new \Sylius\Model\AdministratorAdminAdministratorTokenCreate(); // \Sylius\Model\AdministratorAdminAdministratorTokenCreate | Retrieves the JWT token.

try {
    $result = $apiInstance->postAdministratorCredentialsItem($administrator_admin_administrator_token_create);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AdministratorApi->postAdministratorCredentialsItem: ', $e->getMessage(), PHP_EOL;
}
```

### Parameters

| Name | Type | Description  | Notes |
| ------------- | ------------- | ------------- | ------------- |
| **administrator_admin_administrator_token_create** | [**\Sylius\Model\AdministratorAdminAdministratorTokenCreate**](../Model/AdministratorAdminAdministratorTokenCreate.md)| Retrieves the JWT token. | [optional] |

### Return type

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

### Authorization

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

### HTTP request headers

- **Content-Type**: `application/json`
- **Accept**: `application/json`

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

## `syliusApiAdminAdminUserDelete()`

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

Removes the Administrator resource.

Removes the Administrator 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\AdministratorApi(
    // 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 | Administrator 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->syliusApiAdminAdminUserDelete($id, $accept_language);
} catch (Exception $e) {
    echo 'Exception when calling AdministratorApi->syliusApiAdminAdminUserDelete: ', $e->getMessage(), PHP_EOL;
}
```

### Parameters

| Name | Type | Description  | Notes |
| ------------- | ------------- | ------------- | ------------- |
| **id** | **string**| Administrator 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)

## `syliusApiAdminAdminUserGet()`

```php
syliusApiAdminAdminUserGet($id, $image_filter, $accept_language): \Sylius\Model\AdministratorJsonldSyliusAdminAdminUserShow
```

Retrieves a Administrator resource.

Retrieves a Administrator 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\AdministratorApi(
    // 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 | Administrator identifier
$image_filter = 'image_filter_example'; // string | Image filter to be applied on image resources.
$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->syliusApiAdminAdminUserGet($id, $image_filter, $accept_language);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AdministratorApi->syliusApiAdminAdminUserGet: ', $e->getMessage(), PHP_EOL;
}
```

### Parameters

| Name | Type | Description  | Notes |
| ------------- | ------------- | ------------- | ------------- |
| **id** | **string**| Administrator identifier | |
| **image_filter** | **string**| Image filter to be applied on image resources. | [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\AdministratorJsonldSyliusAdminAdminUserShow**](../Model/AdministratorJsonldSyliusAdminAdminUserShow.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)

## `syliusApiAdminAdminUserGetCollection()`

```php
syliusApiAdminAdminUserGetCollection($page, $items_per_page, $image_filter, $accept_language): \Sylius\Model\SyliusApiAdminAdminUserGetCollection200Response
```

Retrieves the collection of Administrator resources.

Retrieves the collection of Administrator 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\AdministratorApi(
    // 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
$image_filter = 'image_filter_example'; // string | Image filter to be applied on image resources.
$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->syliusApiAdminAdminUserGetCollection($page, $items_per_page, $image_filter, $accept_language);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AdministratorApi->syliusApiAdminAdminUserGetCollection: ', $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] |
| **image_filter** | **string**| Image filter to be applied on image resources. | [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\SyliusApiAdminAdminUserGetCollection200Response**](../Model/SyliusApiAdminAdminUserGetCollection200Response.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)

## `syliusApiAdminAdminUserPost()`

```php
syliusApiAdminAdminUserPost($administrator_sylius_admin_admin_user_create, $accept_language): \Sylius\Model\AdministratorJsonldSyliusAdminAdminUserShow
```

Creates a Administrator resource.

Creates a Administrator 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\AdministratorApi(
    // 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
);
$administrator_sylius_admin_admin_user_create = new \Sylius\Model\AdministratorSyliusAdminAdminUserCreate(); // \Sylius\Model\AdministratorSyliusAdminAdminUserCreate | The new Administrator 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->syliusApiAdminAdminUserPost($administrator_sylius_admin_admin_user_create, $accept_language);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AdministratorApi->syliusApiAdminAdminUserPost: ', $e->getMessage(), PHP_EOL;
}
```

### Parameters

| Name | Type | Description  | Notes |
| ------------- | ------------- | ------------- | ------------- |
| **administrator_sylius_admin_admin_user_create** | [**\Sylius\Model\AdministratorSyliusAdminAdminUserCreate**](../Model/AdministratorSyliusAdminAdminUserCreate.md)| The new Administrator 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\AdministratorJsonldSyliusAdminAdminUserShow**](../Model/AdministratorJsonldSyliusAdminAdminUserShow.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)

## `syliusApiAdminAdminUserPut()`

```php
syliusApiAdminAdminUserPut($id, $administrator_sylius_admin_admin_user_update, $accept_language): \Sylius\Model\AdministratorJsonldSyliusAdminAdminUserShow
```

Replaces the Administrator resource.

Replaces the Administrator 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\AdministratorApi(
    // 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 | Administrator identifier
$administrator_sylius_admin_admin_user_update = new \Sylius\Model\AdministratorSyliusAdminAdminUserUpdate(); // \Sylius\Model\AdministratorSyliusAdminAdminUserUpdate | The updated Administrator 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->syliusApiAdminAdminUserPut($id, $administrator_sylius_admin_admin_user_update, $accept_language);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AdministratorApi->syliusApiAdminAdminUserPut: ', $e->getMessage(), PHP_EOL;
}
```

### Parameters

| Name | Type | Description  | Notes |
| ------------- | ------------- | ------------- | ------------- |
| **id** | **string**| Administrator identifier | |
| **administrator_sylius_admin_admin_user_update** | [**\Sylius\Model\AdministratorSyliusAdminAdminUserUpdate**](../Model/AdministratorSyliusAdminAdminUserUpdate.md)| The updated Administrator 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\AdministratorJsonldSyliusAdminAdminUserShow**](../Model/AdministratorJsonldSyliusAdminAdminUserShow.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)

## `syliusApiAdminResetPasswordPatch()`

```php
syliusApiAdminResetPasswordPatch($token, $administrator_sylius_admin_reset_password_update_json_merge_patch, $accept_language)
```

Updates the Administrator resource.

Updates the Administrator 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\AdministratorApi(
    // 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
);
$token = 'token_example'; // string | Administrator identifier
$administrator_sylius_admin_reset_password_update_json_merge_patch = new \Sylius\Model\AdministratorSyliusAdminResetPasswordUpdateJsonMergePatch(); // \Sylius\Model\AdministratorSyliusAdminResetPasswordUpdateJsonMergePatch | The updated Administrator 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 {
    $apiInstance->syliusApiAdminResetPasswordPatch($token, $administrator_sylius_admin_reset_password_update_json_merge_patch, $accept_language);
} catch (Exception $e) {
    echo 'Exception when calling AdministratorApi->syliusApiAdminResetPasswordPatch: ', $e->getMessage(), PHP_EOL;
}
```

### Parameters

| Name | Type | Description  | Notes |
| ------------- | ------------- | ------------- | ------------- |
| **token** | **string**| Administrator identifier | |
| **administrator_sylius_admin_reset_password_update_json_merge_patch** | [**\Sylius\Model\AdministratorSyliusAdminResetPasswordUpdateJsonMergePatch**](../Model/AdministratorSyliusAdminResetPasswordUpdateJsonMergePatch.md)| The updated Administrator 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

void (empty response body)

### Authorization

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

### HTTP request headers

- **Content-Type**: `application/merge-patch+json`
- **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)

## `syliusApiAdminResetPasswordPost()`

```php
syliusApiAdminResetPasswordPost($administrator_request_reset_password_email_sylius_admin_reset_password_create, $accept_language)
```

Creates a Administrator resource.

Creates a Administrator 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\AdministratorApi(
    // 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
);
$administrator_request_reset_password_email_sylius_admin_reset_password_create = new \Sylius\Model\AdministratorRequestResetPasswordEmailSyliusAdminResetPasswordCreate(); // \Sylius\Model\AdministratorRequestResetPasswordEmailSyliusAdminResetPasswordCreate | The new Administrator 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 {
    $apiInstance->syliusApiAdminResetPasswordPost($administrator_request_reset_password_email_sylius_admin_reset_password_create, $accept_language);
} catch (Exception $e) {
    echo 'Exception when calling AdministratorApi->syliusApiAdminResetPasswordPost: ', $e->getMessage(), PHP_EOL;
}
```

### Parameters

| Name | Type | Description  | Notes |
| ------------- | ------------- | ------------- | ------------- |
| **administrator_request_reset_password_email_sylius_admin_reset_password_create** | [**\Sylius\Model\AdministratorRequestResetPasswordEmailSyliusAdminResetPasswordCreate**](../Model/AdministratorRequestResetPasswordEmailSyliusAdminResetPasswordCreate.md)| The new Administrator 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

void (empty response body)

### Authorization

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

### HTTP request headers

- **Content-Type**: `application/ld+json`, `application/json`
- **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)
