I know it's not technically solving your problem, but you should really not be dispatching requests from artisan commands, and I don't think it'll work, or if it does it'll have some difficult-to-debug side effects.
You need to abstract your controller code into a service and then just call the service from both your command and controller instead of trying to use an artisan command to send HTTP requests to your own application.
Sign in to participate in this thread!
The Laravel portal for problem solving, knowledge sharing and community building.
The community