code: protected function doRequest(FormRequest $request)
      {
          $request->setMethod('POST');
          $request->fromUrl($this->getApiEndpoint());
  
          $this->client->send($request, $response = new Response);
  
          if (false == $response->isSuccessful()) 
  		{
              throw HttpException::factory($request, $response);
          }
  		else
  		{
  			return $response->toArray();
  		}
      }
docs: @param FormRequest $request
  
  @throws HttpException
  
  @return array