Controller/Adminhtml/FastlyCdn/Domains/GetDomains.php
public function execute()
    {
        $result = $this->resultJson->create();
        try {
            $activeVersion = $this->getRequest()->getParam('active_version');
            $domains = $this->api->getAllDomains($activeVersion);
            $storeBaseUrl = $this->storeManager->getStore()->getBaseUrl();

            if (!$domains) {
                return $result->setData([
                    'status'    => false,
                    'msg'       => 'Failed to check Domain details.'
                ]);
            }

            return $result->setData([
                'status'    => true,
                'domains'   => $domains,
                'store'     => $storeBaseUrl
            ]);
        } catch (\Exception $e) {
            return $result->setData([
                'status'    => false,
                'msg'       => $e->getMessage()
            ]);
        }
    }
public function execute()
    {
        $result = $this->resultJson->create();
        try {
            $activeVersion = $this->getRequest()->getParam('active_version');
            $domains = $this->api->getAllDomains($activeVersion);
            $storeBaseUrl = $this->storeManager->getStore()->getBaseUrl();

            if (!$domains) {
                return $result->setData([
                    'status'    => false,
                    'msg'       => 'Failed to check Domain details.'
                ]);
            }

            return $result->setData([
                'status'    => true,
                'domains'   => $domains,
                'store'     => $storeBaseUrl
            ]);
        } catch (\Exception $e) {
            return $result->setData([
                'status'    => false,
                'msg'       => $e->getMessage()
            ]);
        }
    }
Get all domains for active version

@return $this|ResponseInterface|ResultInterface