- What does muhammadhuzaifa/telescope-guzzle-watcher do?
- It is a custom Laravel Telescope watcher that hooks Guzzle's on_stats request option and writes outgoing HTTP client calls into Telescope's http_client entries. It helps you see third-party API calls, headers, responses, and timing next to your other Telescope data. It is an extension of Telescope, not a standalone monitoring tool.
- How is it different from Laravel Telescope's built-in HTTP Client Watcher?
- Telescope's native HTTP Client Watcher only records requests made through Laravel's Http facade. This package targets Guzzle clients you instrument directly, which is where many third-party SDK calls happen. Use both carefully, because facade traffic may be recorded twice if you instrument the underlying Guzzle client.
- How do I install telescope-guzzle-watcher in a Laravel app?
- Install it with Composer using composer require muhammadhuzaifa/telescope-guzzle-watcher, then publish any provided config if the package requires it. Register the custom watcher in the watchers array in config/telescope.php and clear your config cache. After that, attach the watcher's on_stats option where you construct Guzzle clients.
- How do I enable the Guzzle watcher for a specific client?
- You opt in per client by passing the package's on_stats callback in the Guzzle client config, or by wiring it through a shared handler or config hook if the package supports one. Clients that are not instrumented are not captured. This is the main limitation for SDKs that create their own Guzzle client internally.
- Which Laravel, Telescope, and Guzzle versions are supported?
- It is built for Laravel apps with Telescope installed and Guzzle 7, with practical targets around Laravel 10, 11, and 12 with Telescope 5.x. Check the repository's composer.json and CI matrix before adopting it, because Telescope watcher contracts and entry types can change between majors. Confirm that your Telescope version has the http_client entry type the watcher writes into.
- Will telescope-guzzle-watcher double-log requests made through Laravel's Http facade?
- Yes, that is a real risk: Laravel's Http facade runs on Guzzle, so broadly instrumenting those clients can create duplicate entries, one from Telescope's native watcher and one from this package. Deduplication is not clearly documented. Prefer instrumenting direct Guzzle and SDK clients, and verify duplicate behavior in staging before enabling it widely.
- Does it capture full request and response bodies, or only timing?
- The package uses Guzzle's on_stats option, which primarily provides transfer statistics such as timing and sizes, and it logs an http_client entry into Telescope. The overview also says it extracts request and response data, so confirm in your installed version what is actually serialized. If you rely on streamed downloads, SSE, or large binary responses, test whether bodies are read or truncated.
- Is it safe to use with API tokens and secrets in production?
- Outbound Guzzle calls often carry bearer tokens and API keys in headers, query strings, or bodies, and Telescope's hide-parameter config is scoped to its own watchers. A custom watcher must implement its own redaction, so verify what the package redacts and get security sign-off before enabling it against production credentials. For most teams, keep Telescope disabled or restricted outside local and staging.
- Does it work with third-party SDKs like AWS, Stripe, or Elasticsearch?
- Only if the SDK lets you inject Guzzle options, a handler, or a client config that includes the watcher's on_stats hook. Many SDKs build their own Guzzle client internally and do not expose that seam, so those calls stay invisible. Validate coverage against the specific SDKs on your critical path before relying on it.
- How do I test telescope-guzzle-watcher and assess its maintenance risk?
- Trigger an instrumented Guzzle call in local or staging and confirm a new http_client entry appears in Telescope with the expected request data and timing. Also test streamed, large, and error responses, and check for duplicates against Telescope's native Http watcher. Maintenance risk is real because this is a small, single-maintainer package coupled to Telescope internals, so pin versions and re-verify after Laravel or Telescope upgrades. If that risk is unacceptable, alternatives include the native watcher, custom Guzzle middleware, or a broader APM tool.