public function listListings(array $filters = [])
    {
        $query = '';

        if ($this->config->products) {
            $filters['product__id'] = $this->config->products;
        }

        if ($filters) {
            $query = '?' . preg_replace('/%5B[0-9]+%5D/simU', '', http_build_query($filters));
        }

        $body = $this->sendRequest('GET', '/listings' . $query);

        /** @var Listing[] $models */
        $models = Model::modelize('listings', json_decode($body));
        foreach ($models as $index => $model) {
            $models[$index]->requestProcessor = $this;
        }

        return $models;
    }
public function listListings(array $filters = [])
    {
        $query = '';

        if ($this->config->products) {
            $filters['product__id'] = $this->config->products;
        }

        if ($filters) {
            $query = '?' . preg_replace('/%5B[0-9]+%5D/simU', '', http_build_query($filters));
        }

        $body = $this->sendRequest('GET', '/listings' . $query);

        /** @var Listing[] $models */
        $models = Model::modelize('listings', json_decode($body));
        foreach ($models as $index => $model) {
            $models[$index]->requestProcessor = $this;
        }

        return $models;
    }
public function listListings ( array $ filters = [ ] ) { $ query = '' ; if ( $ this -> config -> products ) { $ filters [ 'product__id' ] = $ this -> config -> products ; } if ( $ filters ) { $ query = '?' . preg_replace ( '/%5B[0-9]+%5D/simU' , '' , http_build_query ( $ filters ) ) ; } $ body = $ this -> sendRequest ( 'GET' , '/listings' . $ query ) ; /** @var Listing[] $models */ $ models = Model :: modelize ( 'listings' , json_decode ( $ body ) ) ; foreach ( $ models as $ index => $ model ) { $ models [ $ index ] -> requestProcessor = $ this ; } return $ models ; }
Lists the product listings
@param array $filters Filter for listing key->value or key->array(value1, value2)
@return Listing[]
@throws GuzzleException
Lists the product listings