Is there a way I can print out the full request as a string before or after it is sent?
$res = (new GuzzleHttp\Client())->request('POST', 'https://endpoint.nz/test', [ 'form_params' => [ 'param1'=>1,'param2'=>2,'param3'=3 ] ] );
how can I view that request as a string? (not the response)
The reason is, my request is failing and returning a 403, and I want to know what exactly is being sent; as the same request works when using PostMan.
As per Guzzle documentation there is debug option, here is the link from guzzle documentation http://guzzle.readthedocs.org/en/latest/request-options.html#debug
$client->request('GET', '/get', ['debug' => true]);