public function extract(?string $id, string $path, bool $noOverwriteDirNonDir, string $request)
    {
        $id = $id ?? $this->container_id;

        $url = self::$base_url.'/'.$id.'/archive?'.http_build_query(compact(
                'path',
                'noOverwriteDirNonDir'
            ));

        $output = self::$curl->put($url, $request);

        $http_return_code = self::$curl->getCode();

        if (200 === $http_return_code) {
            return null;
        }

        throw new Exception(json_decode($output)->message, $http_return_code);
    }