It’s throwing me an error
PHP Error: Cannot instantiate interface GuzzleHttp\ClientInterface in vendor/magento/framework/ObjectManager/Factory/AbstractFactory.php on line 111, referer: http://127.0.0.1/local_m2/admin/admin/system_config/edit/section/active_campaign/key/6a9ce672c9414c57acd889eb50fb82020e13e651b74cf3a81b9cd8b30da45306/ here
I have already run all Magento required commands Like Setup: upgrade, di:compile and deploy but still it’s throwing me this error.
I have already checked GuzzleHttp in the vendor folder, it’s already installed in Magento 2.2.9
I have tried the composer require guzzlehttp/guzzle:^6.0 to reinstall the library but having no luck.
2
Answers
import this library:
on __construct use:
and then call:
try this way to create an instance of GuzzleClient, im currently using a similar in a magento 2.4.4 and works fine, you donĀ“t have to inyect that on __construct()