It would be really useful to add the ability to set up the client to use basic auth via:
Http::withBasicAuth($user, $password)
I've hacked something together, which extends Client with an auth method, and also exposes that method on the WordPress class, but not sure if this is the tidiest approach. It perhaps would be better to use .env / config as WORDPRESS_URL does.
Happy to work on this and submit a PR if we can agree on the correct approach!
It would be really useful to add the ability to set up the client to use basic auth via:
I've hacked something together, which extends
Clientwith an auth method, and also exposes that method on theWordPressclass, but not sure if this is the tidiest approach. It perhaps would be better to use.env/ config asWORDPRESS_URLdoes.Happy to work on this and submit a PR if we can agree on the correct approach!