2024-09-16 22:22:24 +05:00
|
|
|
<?php declare(strict_types=1);
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Copyright (c) 2024
|
|
|
|
* author: Leonid Nikitin - i@kor-elf.net
|
|
|
|
* web: https://git.kor-elf.net/kor-elf
|
|
|
|
* Initial version created on: 15.09.2024
|
|
|
|
* MIT license: https://git.kor-elf.net/kor-elf/translate-laravel/src/branch/main/LICENSE
|
|
|
|
*/
|
|
|
|
|
|
|
|
return [
|
|
|
|
/*
|
|
|
|
|--------------------------------------------------------------------------
|
|
|
|
| Default Translate Service
|
|
|
|
|--------------------------------------------------------------------------
|
|
|
|
|
|
|
|
|
| This option controls the default translate service that will be used by the
|
|
|
|
| framework. This connection is utilized if another isn't explicitly
|
|
|
|
| specified when running a translation operation inside the application.
|
|
|
|
|
|
|
|
|
*/
|
|
|
|
|
|
|
|
'default' => env('TRANSLATE_SERVICE', 'yandex'),
|
|
|
|
|
|
|
|
'services' => [
|
|
|
|
'yandex' => [
|
2024-10-11 00:22:46 +05:00
|
|
|
'driver' => '\KorElf\TranslateLaravel\Translate\YandexDriver',
|
2024-09-16 22:22:24 +05:00
|
|
|
'config' => [
|
|
|
|
'folder_id' => env('TRANSLATE_YANDEX_FOLDER_ID'),
|
|
|
|
'authorized_key_path' => base_path(env('TRANSLATE_YANDEX_AUTHORIZED_KEY_PATH')),
|
2024-10-11 00:22:46 +05:00
|
|
|
'limit' => [
|
|
|
|
'max_request' => (int) env('TRANSLATE_YANDEX_LIMIT_MAX_REQUEST', 20),
|
|
|
|
'rate_seconds' => (int) env('TRANSLATE_YANDEX_LIMIT_RATE_SECONDS', 1),
|
|
|
|
'max_symbols' => (int) env('TRANSLATE_YANDEX_LIMIT_MAX_SYMBOLS', 9000),
|
|
|
|
],
|
2024-09-16 22:22:24 +05:00
|
|
|
],
|
|
|
|
],
|
|
|
|
],
|
|
|
|
];
|