GuzzleHttp php how to make a "pre-request"

In Postman, there are "pre-request scripts" you can configure that will allow you to do stuff before you make any requests. I'm sure you can do that with Guzzle. In my scenario, I need to make a GET request before every POST/PATCH/PUT request in order to get a CSRF token from my server. Then, I want to add the token to my headers of my POST request. How would I accomplish this?

I am using Guzzle 6 and I am creating my client like so:

private static function buildClient(array $config = array())
{
    $stack = new HandlerStack();
    $stack->setHandler(Utils::chooseHandler());

    $stack->push(Middleware::prepareBody(), 'prepare_body');
    $config = array_merge(array('handler' => $stack), $config);

    return new GuzzleClient($config);
}