Failing to install Guzzle PHP

Hello! I am working with an API that recommends uses Guzzle for HTTP requests. I tried to install it using composer require guzzlehttp/guzzle:^7.0, but I get this error:

Your requirements could not be resolved to an installable set of packages.

  Problem 1
    - php-http/guzzle6-adapter v1.1.1 requires guzzlehttp/guzzle ^6.0 -> satisfiable by guzzlehttp/guzzle[6.0.0, 6.0.1, 6.0.2, 6.1.0, 6.1.1, 6.2.0, 6.2.1, 6.2.2, 6.2.3, 6.3.0, 6.3.1, 6.3.2, 6.3.3, 6.4.0, 6.4.1, 6.5.0, 6.5.1, 6.5.2, 6.5.3, 6.5.4, 6.5.5, 6.5.x-dev] but these conflict with your requirements or minimum-stability.
    - php-http/guzzle6-adapter v1.1.1 requires guzzlehttp/guzzle ^6.0 -> satisfiable by guzzlehttp/guzzle[6.0.0, 6.0.1, 6.0.2, 6.1.0, 6.1.1, 6.2.0, 6.2.1, 6.2.2, 6.2.3, 6.3.0, 6.3.1, 6.3.2, 6.3.3, 6.4.0, 6.4.1, 6.5.0, 6.5.1, 6.5.2, 6.5.3, 6.5.4, 6.5.5, 6.5.x-dev] but these conflict with your requirements or minimum-stability.
    - php-http/guzzle6-adapter v1.1.1 requires guzzlehttp/guzzle ^6.0 -> satisfiable by guzzlehttp/guzzle[6.0.0, 6.0.1, 6.0.2, 6.1.0, 6.1.1, 6.2.0, 6.2.1, 6.2.2, 6.2.3, 6.3.0, 6.3.1, 6.3.2, 6.3.3, 6.4.0, 6.4.1, 6.5.0, 6.5.1, 6.5.2, 6.5.3, 6.5.4, 6.5.5, 6.5.x-dev] but these conflict with your requirements or minimum-stability.
    - Installation request for php-http/guzzle6-adapter (locked at v1.1.1, required as ^1.1) -> satisfiable by php-http/guzzle6-adapter[v1.1.1].


Installation failed, reverting ./composer.json to its original content.

Troubleshooting composer version issues are so much fun.

The php-http/guzzle6-adapter package has a dependency on “guzzlehttp/guzzle”: “^6.0”. That caret in the version means only 6.x versions can be loaded. You are trying to load 7.x.

You could try editing composer.json to “guzzlehttp/guzzle”: “>=6.0” and see what happens. It might let you load 7.x though who knows if the code is actually compatible.

Unless you have a really good reason then just install 6.x.

Does not look like guzzle6-adapter has been touched in a couple of years now. Might consider trying something else completely.

I installed guzzle @ version 6.
That seemed to do the trick. Thanks!

This topic was automatically closed 91 days after the last reply. New replies are no longer allowed.