contentful/core
Core components shared by Contentful’s PHP Delivery and Management SDKs. Provides foundational utilities and abstractions for interacting with Contentful APIs. Requires PHP 8.0+. Intended for internal SDK use, not for direct third‑party consumption.
Accepted
The library needs to make HTTP requests to Contentful REST APIs. Options considered:
file_get_contents — too low-level; no PSR-7 support, no middleware/handler stack, hard to test.The test suite relies on Guzzle's HandlerStack to inject mock responses, making it important that the HTTP client is injectable and testable without a real network.
guzzlehttp/guzzle (^6.5|^7.0) and guzzlehttp/psr7 (^1.6|^2.1.1) are require dependencies. BaseClient accepts an optional ?HttpClient $httpClient constructor argument, allowing consumers to substitute a custom-configured Guzzle instance (e.g., with custom middleware, retry logic, or mock handlers for testing).
psr/http-message ^2.0 (added in 4.0.2 changelog).How can I help you explore Laravel packages today?