- Can I use acseo/profiler-cli directly in a Laravel project without Symfony?
- No, this package is designed for Symfony 5/6 and requires the Symfony Profiler to be enabled. For Laravel, you’d need a workaround like embedding a Symfony microkernel or scraping Profiler data from a shared database if you’re using both frameworks.
- How do I install this in a Laravel + Symfony hybrid app?
- Install via Composer as usual, then enable the bundle in Symfony’s `bundles.php`. Ensure Symfony Profiler is active in your dev environment. Laravel won’t interact with it directly unless you bridge the two systems (e.g., via API or shared storage).
- What Laravel alternatives exist for inspecting HTTP requests like this?
- For Laravel, consider `laravel-debugbar`, `barryvdh/debugbar`, or custom Artisan commands using `dd()`, `Log::debug()`, or `tightenco/ziggy` for route inspection. These provide similar debugging without Symfony dependencies.
- Does this package support filtering requests by Laravel’s route names or middleware?
- No, it filters only by Symfony Profiler metadata (IP, URL, method, dates). To filter by Laravel routes or middleware, you’d need to extend the package or pre-process tokens in a custom integration layer.
- How do I handle sensitive data (e.g., API keys) in exported curl commands?
- The package exports raw request data, including headers and bodies. For Laravel, sanitize or redact sensitive fields before exporting, or use environment variables to mask credentials in curl commands.
- Will this slow down my Laravel application if I integrate it?
- Only if you’re scraping Profiler data in real-time. For minimal impact, cache tokens or use a separate Symfony micro-service to avoid coupling with Laravel’s request lifecycle.
- Can I use this to debug API calls in a Laravel API resource?
- Indirectly, if your Laravel API is part of a Symfony hybrid stack. For pure Laravel APIs, use `Log::debug()` or `laravel-debugbar` to inspect requests without Symfony overhead.
- How do I filter tokens by a specific Laravel request ID or timestamp?
- This package doesn’t natively support Laravel’s request IDs. You’d need to map Symfony Profiler timestamps to Laravel’s `request()->id` or log timestamps manually for correlation.
- Is there a way to batch-export curl commands for all POST requests in a date range?
- Yes, use the `--method=POST`, `--start`, and `--end` flags with `--export` to generate curl commands for all matching tokens. For Laravel, you’d need to replicate this logic with a custom Artisan command.
- How often is this package updated, and is it actively maintained?
- Check the GitHub repository for recent commits or issues. Given its Symfony-centric focus, updates may lag behind Laravel’s ecosystem. For critical projects, consider alternatives or fork the package for Laravel compatibility.