azure-storage-file/src/File/FileRestProxy.php
public function getShareStatsAsync($share, FileServiceOptions $options = null)
    {
        Validate::canCastAsString($share, 'share');

        $method      = Resources::HTTP_GET;
        $headers     = array();
        $queryParams = array();
        $postParams  = array();
        $path        = $this->createPath($share);

        if (is_null($options)) {
            $options = new FileServiceOptions();
        }

        $this->addOptionalQueryParam(
            $queryParams,
            Resources::QP_REST_TYPE,
            'share'
        );

        $this->addOptionalQueryParam(
            $queryParams,
            Resources::QP_COMP,
            'stats'
        );

        $this->addOptionalQueryParam(
            $queryParams,
            Resources::QP_TIMEOUT,
            $options->getTimeout()
        );

        $dataSerializer = $this->dataSerializer;

        return $this->sendAsync(
            $method,
            $headers,
            $queryParams,
            $postParams,
            $path,
            Resources::STATUS_OK,
            Resources::EMPTY_STRING,
            $options
        )->then(function ($response) use ($dataSerializer) {
            $parsed = $dataSerializer->unserialize($response->getBody());
            return GetShareStatsResult::create($parsed);
        }, null);
    }
public function getShareStatsAsync($share, FileServiceOptions $options = null)
    {
        Validate::canCastAsString($share, 'share');

        $method      = Resources::HTTP_GET;
        $headers     = array();
        $queryParams = array();
        $postParams  = array();
        $path        = $this->createPath($share);

        if (is_null($options)) {
            $options = new FileServiceOptions();
        }

        $this->addOptionalQueryParam(
            $queryParams,
            Resources::QP_REST_TYPE,
            'share'
        );

        $this->addOptionalQueryParam(
            $queryParams,
            Resources::QP_COMP,
            'stats'
        );

        $this->addOptionalQueryParam(
            $queryParams,
            Resources::QP_TIMEOUT,
            $options->getTimeout()
        );

        $dataSerializer = $this->dataSerializer;

        return $this->sendAsync(
            $method,
            $headers,
            $queryParams,
            $postParams,
            $path,
            Resources::STATUS_OK,
            Resources::EMPTY_STRING,
            $options
        )->then(function ($response) use ($dataSerializer) {
            $parsed = $dataSerializer->unserialize($response->getBody());
            return GetShareStatsResult::create($parsed);
        }, null);
    }
Get the statistics related to the share.

@param  string                  $share   The name of the share.
@param  FileServiceOptions|null $options The request options.

@return \GuzzleHttp\Promise\PromiseInterface

@see https://docs.microsoft.com/en-us/rest/api/storageservices/get-share-stats