WordPress / WordPress/php-ai-client
Improve documentation for HTTPlug HTTP client requirement
Nobody has claimed this yet.
- Dominant language
- PHP
- Stars
- 308
- Forks
- 84
- Avg merge
- 7d 21h
- Merged PRs (30d)
- 2
Description
Background
The WordPress PHP AI Client correctly uses HTTPlug for HTTP client abstraction and auto-discovery. However, new users aren't aware they need to install an HTTPlug-compatible HTTP client adapter.
Current Experience
- User installs: composer require wordpress/php-ai-client
- User runs code and gets: DiscoveryFailedException: Could not find resource...
- User must research HTTPlug and PSR-18 to understand the solution
Proposed Documentation Improvements
Add to README.md:
HTTP Client Requirement
This package uses HTTPlug for HTTP client abstraction. You need to install a compatible HTTP client adapter:
# Choose one HTTP client adapter:
composer require php-http/guzzle7-adapter # Guzzle 7 (recommended)
composer require php-http/curl-client # cURL
composer require symfony/http-client # Symfony
Add composer.json suggestions:
"suggest": {
"php-http/guzzle7-adapter": "HTTPlug adapter for Guzzle 7 (recommended)",
"php-http/curl-client": "HTTPlug adapter for cURL"
}
This maintains the correct HTTPlug architecture while improving the developer experience.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Review README.md and composer.json first, focusing on the installation guidance and existing dependency suggestions. Confirm the documented HTTPlug-compatible adapters and package names, then verify that the README explains the requirement and composer.json communicates the optional dependencies clearly.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- php
- Domain
- documentation
- Issue type
- Documentation
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Activity status
- Stale
- Clarity
- Clearly specified
- Newbie friendliness
- 45/100