lib/Api/Addon.php
public function getAddon(string $addonCode): array
    {
        $cacheKey = sprintf('addon_%s', $addonCode);
        $hit = $this->getFromCache($cacheKey);

        if (false === $hit) {
            $response = $this->sendRequest('GET', sprintf('addons/%s', $addonCode));

            $data = $this->processResponse($response);
            $addon = $data['addon'];

            $this->saveToCache($cacheKey, $addon);

            return $addon;
        }

        return $hit;
    }
public function getAddon(string $addonCode): array
    {
        $cacheKey = sprintf('addon_%s', $addonCode);
        $hit = $this->getFromCache($cacheKey);

        if (false === $hit) {
            $response = $this->sendRequest('GET', sprintf('addons/%s', $addonCode));

            $data = $this->processResponse($response);
            $addon = $data['addon'];

            $this->saveToCache($cacheKey, $addon);

            return $addon;
        }

        return $hit;
    }
@param string $addonCode

@throws \Exception

@return array