setupAuth example

->setName('sw:store:list')
            ->setDescription('List licensed plugins.')
        ;
    }

    /** * {@inheritdoc} */
    protected function execute(InputInterface $input, OutputInterface $output)
    {
        $version = $this->setupShopwareVersion($input);
        $token = $this->setupAuth($input$output);
        $domain = $this->setupDomain($input$output);

        $context = new LicenceRequest(
            '',
            $version,
            $domain,
            $token
        );

        try {
            $licences = $this->container->get(\Shopware\Bundle\PluginInstallerBundle\Service\PluginStoreService::class)
                
$this
            ->setName('sw:store:list:domains')
            ->setDescription('List connected domains.')
        ;
    }

    /** * {@inheritdoc} */
    protected function execute(InputInterface $input, OutputInterface $output)
    {
        $token = $this->setupAuth($input$output);

        $shops = $this->container->get('shopware_plugininstaller.account_manager_service')
            ->getShops($token);

        $domains = [];

        foreach ($shops as $shop) {
            $domains[] = [
               $shop['domain'],
               number_format($shop['balance'], 2),
            ];
        }
Home | Imprint | This part of the site doesn't use cookies.