<?xml version="1.0" ?>

<container xmlns="http://symfony.com/schema/dic/services"
           xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
           xsi:schemaLocation="http://symfony.com/schema/dic/services http://symfony.com/schema/dic/services/services-1.0.xsd">

    <parameters>
        <parameter key="env(SHOPWARE_ADMINISTRATION_PATH_NAME)">admin</parameter>
        <parameter key="shopware_administration.path_name">%env(resolve:SHOPWARE_ADMINISTRATION_PATH_NAME)%</parameter>
    </parameters>

    <services>
        <service id="Shopware\Administration\Command\DeleteAdminFilesAfterBuildCommand">
            <tag name="console.command"/>
        </service>

        <service id="Shopware\Administration\Command\DeleteExtensionLocalPublicFilesCommand">
            <argument type="service" id="kernel"/>
            <tag name="console.command"/>
        </service>

        <service id="Shopware\Administration\Controller\AdminAuthController" public="true">
            <argument type="service" id="shopware.api.authorization_server"/>
            <argument type="service" id="Symfony\Bridge\PsrHttpMessage\Factory\PsrHttpFactory"/>
            <argument type="service" id="Shopware\Administration\Login\Config\LoginConfigService"/>
            <argument type="service" id="Shopware\Administration\Login\LoginResponseService"/>
            <argument type="service" id="Shopware\Administration\Login\StateValidator"/>

            <call method="setContainer">
                <argument type="service" id="service_container"/>
            </call>
        </service>

        <service id="Shopware\Administration\Controller\AdminSsoController" public="true">
            <argument type="service" id="Shopware\Core\Framework\Sso\SsoUser\SsoUserService"/>
            <argument type="service" id="Shopware\Core\Framework\Sso\SsoUser\SsoUserInvitationMailService"/>
            <argument type="service" id="Shopware\Core\Framework\Sso\SsoService"/>

            <call method="setContainer">
                <argument type="service" id="service_container"/>
            </call>
        </service>

        <service id="Shopware\Administration\Controller\AdminExtensionApiController" public="true">
            <argument type="service" id="Shopware\Core\Framework\App\ActionButton\Executor"/>
            <argument type="service" id="Shopware\Core\Framework\App\Payload\AppPayloadServiceHelper"/>
            <argument type="service" id="app.repository"/>
            <argument type="service" id="Shopware\Core\Framework\App\Hmac\QuerySigner"/>

            <call method="setContainer">
                <argument type="service" id="service_container"/>
            </call>
        </service>

        <service id="Shopware\Administration\Controller\AdministrationController"
                 public="true">
            <argument type="service" id="Shopware\Core\Framework\Adapter\Twig\TemplateFinder"/>
            <argument type="service" id="Shopware\Core\Framework\Store\Services\FirstRunWizardService"/>
            <argument type="service" id="Shopware\Administration\Snippet\SnippetFinder"/>
            <argument>%kernel.supported_api_versions%</argument>
            <argument type="service" id="Shopware\Administration\Framework\Routing\KnownIps\KnownIpsCollector"/>
            <argument type="service" id="Doctrine\DBAL\Connection"/>
            <argument type="service" id="event_dispatcher"/>
            <argument>%kernel.shopware_core_dir%</argument>
            <argument type="service" id="customer.repository"/>
            <argument type="service" id="currency.repository"/>
            <argument type="service" id="Shopware\Core\Framework\Util\HtmlSanitizer"/>
            <argument type="service" id="Shopware\Core\Framework\DataAbstractionLayer\DefinitionInstanceRegistry"/>
            <argument type="service" id="parameter_bag"/>
            <argument type="service" id="Shopware\Core\System\SystemConfig\SystemConfigService"/>
            <argument type="service" id="shopware.filesystem.asset"/>
            <argument type="string">%env(SERVICE_REGISTRY_URL)%</argument>
            <argument type="service" id="Shopware\Administration\Login\Config\LoginConfigService"/>
            <argument type="string">%shopware.api.refresh_token_ttl%</argument>

            <call method="setContainer">
                <argument type="service" id="service_container"/>
            </call>
        </service>

        <service id="Shopware\Administration\Controller\AdminSearchController" public="true">
            <argument type="service" id="Shopware\Core\Framework\DataAbstractionLayer\Search\RequestCriteriaBuilder"/>
            <argument type="service" id="Shopware\Core\Framework\DataAbstractionLayer\DefinitionInstanceRegistry"/>
            <argument type="service" id="Shopware\Administration\Service\AdminSearcher"/>
            <argument type="service" id="serializer"/>
            <argument type="service" id="Shopware\Core\Framework\Api\Acl\AclCriteriaValidator"/>
            <argument type="service" id="Shopware\Core\Framework\DataAbstractionLayer\DefinitionInstanceRegistry"/>
            <argument type="service" id="Shopware\Core\Framework\Api\Serializer\JsonEntityEncoder"/>

            <call method="setContainer">
                <argument type="service" id="service_container"/>
            </call>
        </service>

        <service id="Shopware\Administration\Controller\UserConfigController" public="true">
            <argument type="service" id="user_config.repository"/>
            <argument type="service" id="Doctrine\DBAL\Connection"/>

            <call method="setContainer">
                <argument type="service" id="service_container"/>
            </call>
        </service>

        <service id="Shopware\Administration\Controller\AdminProductStreamController"
                 public="true">
            <argument type="service" id="Shopware\Core\Content\Product\ProductDefinition"/>
            <argument type="service" id="sales_channel.product.repository"/>
            <argument type="service" id="Shopware\Core\System\SalesChannel\Context\SalesChannelContextService"/>
            <argument type="service" id="Shopware\Core\Framework\DataAbstractionLayer\Search\RequestCriteriaBuilder"/>

            <call method="setContainer">
                <argument type="service" id="service_container"/>
            </call>
        </service>

        <service id="Shopware\Administration\Controller\AdminTagController"
                 public="true">
            <argument type="service" id="Shopware\Core\System\Tag\Service\FilterTagIdsService"/>

            <call method="setContainer">
                <argument type="service" id="service_container"/>
            </call>
        </service>

        <service id="Shopware\Administration\Controller\NotificationController" public="true">
            <argument type="service" id="shopware.rate_limiter"/>
            <argument type="service" id="Shopware\Core\Framework\Notification\NotificationService"/>

            <call method="setContainer">
                <argument type="service" id="service_container"/>
            </call>
        </service>

        <service id="Shopware\Administration\Service\AdminSearcher">
            <argument type="service" id="Shopware\Core\Framework\DataAbstractionLayer\DefinitionInstanceRegistry"/>
        </service>

        <service id="Shopware\Administration\Framework\Routing\NotFound\AdministrationNotFoundSubscriber">
            <argument>%shopware_administration.path_name%</argument>
            <argument type="service" id="service_container" />

            <tag name="kernel.event_subscriber"/>
        </service>

        <service id="Shopware\Administration\Framework\Routing\AdministrationRouteScope">
            <argument>%shopware_administration.path_name%</argument>
            <tag name="shopware.route_scope"/>
        </service>

        <service id="Shopware\Administration\Snippet\AppAdministrationSnippetDefinition">
            <tag name="shopware.entity.definition"/>
        </service>

        <service id="Shopware\Administration\Snippet\AppAdministrationSnippetPersister">
            <argument type="service" id="app_administration_snippet.repository"/>
            <argument type="service" id="locale.repository"/>
            <argument type="service" id="Shopware\Core\Framework\Adapter\Cache\CacheInvalidator"/>
        </service>

        <service id="Shopware\Administration\Snippet\SnippetFinder">
            <argument type="service" id="kernel" />
            <argument type="service" id="Doctrine\DBAL\Connection"/>
            <argument type="service" id="shopware.filesystem.private"/>
            <argument type="service" id="Shopware\Core\System\Snippet\Struct\TranslationConfig"/>
            <argument type="service" id="Shopware\Core\System\Snippet\Service\TranslationLoader"/>
        </service>

        <service id="Shopware\Administration\Snippet\CachedSnippetFinder" decorates="Shopware\Administration\Snippet\SnippetFinder">
            <argument type="service" id="Shopware\Administration\Snippet\CachedSnippetFinder.inner" />
            <argument type="service" id="cache.object" />
        </service>

        <service id="Shopware\Administration\Framework\Routing\KnownIps\KnownIpsCollector"/>

        <!-- @deprecated tag:v6.8.0 Will be removed -->
        <service id="Shopware\Administration\Notification\NotificationDefinition">
            <deprecated package="shopware/administration" version="6.8.0" />
        </service>

        <service id="Shopware\Administration\System\SalesChannel\Subscriber\SalesChannelUserConfigSubscriber">
            <argument type="service" id="user_config.repository" />
            <tag name="kernel.event_subscriber"/>
        </service>

        <service id="Shopware\Administration\Dashboard\OrderAmountService">
            <argument type="service" id="Doctrine\DBAL\Connection"/>
            <argument type="service" id="Shopware\Core\Checkout\Cart\Price\CashRounding"/>
            <argument>%shopware.dbal.time_zone_support_enabled%</argument>
        </service>

        <service id="Shopware\Administration\Controller\DashboardController" public="true">
            <argument type="service" id="Shopware\Administration\Dashboard\OrderAmountService"/>
            <call method="setContainer">
                <argument type="service" id="service_container"/>
            </call>
        </service>

        <service id="Shopware\Administration\Framework\Twig\ViteFileAccessorDecorator" decorates="pentatrion_vite.file_accessor">
            <argument>%pentatrion_vite.configs%</argument>
            <argument type="service" id="shopware.asset.asset"/>
            <argument type="service" id="kernel"/>
            <argument type="service" id="filesystem"/>
        </service>

        <service id="Shopware\Administration\Login\UserService\UserService">
            <argument type="service" id="Doctrine\DBAL\Connection"/>
            <argument type="service" id="Shopware\Administration\Login\TokenService\IdTokenParser"/>
            <argument type="service" id="user.repository"/>
        </service>

        <service id="Shopware\Administration\Login\TokenService\ExternalTokenService">
            <argument type="service" id="http_client"/>
            <argument type="service" id="Shopware\Administration\Login\Config\LoginConfigService"/>
        </service>

        <service id="Shopware\Administration\Login\Config\LoginConfigService">
            <argument>%shopware.admin_login%</argument>
            <argument>%APP_URL%</argument>
            <argument>%shopware_administration.path_name%</argument>
        </service>

        <service id="Shopware\Administration\Login\LoginResponseService">
            <argument type="service" id="Symfony\Component\Routing\RouterInterface"/>
        </service>

        <service id="Shopware\Administration\Login\TokenService\IdTokenParser">
            <argument type="service" id="Shopware\Administration\Login\TokenService\PublicKeyLoader"/>
            <argument type="service" id="Shopware\Administration\Login\Config\LoginConfigService"/>
            <argument type="service" id="Symfony\Component\Clock\ClockInterface"/>
        </service>

        <service id="Shopware\Administration\Login\TokenService\PublicKeyLoader">
            <argument type="service" id="http_client"/>
            <argument type="service" id="Shopware\Administration\Login\Config\LoginConfigService"/>
            <argument type="service" id="cache.object" />
        </service>

        <service id="Shopware\Administration\Login\StateValidator" />

        <service id="Shopware\Core\Framework\Sso\SsoUser\SsoUserService">
            <argument type="service" id="user.repository"/>
        </service>

        <service id="Shopware\Core\Framework\Sso\SsoUser\SsoUserInvitationMailService">
            <argument type="service" id="Shopware\Core\Content\Mail\Service\MailService"/>
            <argument type="service" id="Shopware\Core\System\SystemConfig\SystemConfigService" />
            <argument type="service" id="Shopware\Administration\Login\Config\LoginConfigService"/>
            <argument type="service" id="mail_template.repository"/>
            <argument type="service" id="mail_template_type.repository"/>
            <argument type="service" id="user.repository"/>
            <argument type="service" id="language.repository"/>
            <argument type="service" id="locale.repository"/>
        </service>

        <service id="Shopware\Core\Framework\Sso\SsoService">
            <argument type="service" id="Shopware\Administration\Login\Config\LoginConfigService"/>
        </service>

        <service id="Shopware\Administration\Framework\App\Subscriber\SystemLanguageChangedSubscriber">
            <argument type="service" id="locale.repository"/>
            <argument type="service" id="app_administration_snippet.repository"/>

            <tag name="kernel.event_subscriber"/>
        </service>
    </services>
</container>
