src/Newscoop/API/Client.php
public function makeRequest($path, $params)
    {
        $this->dispatcher->dispatch('api.createUri', 
            new GenericEvent($this, array(
                'path' => $path,
                'params' => $params
            ))
        );

        $this->response = $this->browser->get($this->getUri());       

        $parsedResponse = json_decode($this->response->getContent(), true);
        if (array_key_exists('errors', $parsedResponse)) {
            throw new NewscoopApiException($parsedResponse);
        }

        return $this;
    }
public function makeRequest($path, $params)
    {
        $this->dispatcher->dispatch('api.createUri', 
            new GenericEvent($this, array(
                'path' => $path,
                'params' => $params
            ))
        );

        $this->response = $this->browser->get($this->getUri());       

        $parsedResponse = json_decode($this->response->getContent(), true);
        if (array_key_exists('errors', $parsedResponse)) {
            throw new NewscoopApiException($parsedResponse);
        }

        return $this;
    }
public function makeRequest ( $ path , $ params ) { $ this -> dispatcher -> dispatch ( 'api.createUri' , new GenericEvent ( $ this , array ( 'path' => $ path , 'params' => $ params ) ) ) ; $ this -> response = $ this -> browser -> get ( $ this -> getUri ( ) ) ; $ parsedResponse = json_decode ( $ this -> response -> getContent ( ) , true ) ; if ( array_key_exists ( 'errors' , $ parsedResponse ) ) { throw new NewscoopApiException ( $ parsedResponse ) ; } return $ this ; }
Make request to resource

@return object Client
Make request to resource