I'm trying to test an API route, but I always get 404 Not Found
.
I'm using this command:
curl http://localhost:8000/api/veip
This is my routes/api.php
<?php
use Illuminate\Http\Request;
Route::get('/veip', function () {
return 'Hello World';
});
And this is my php artisan route:list
output:
+--------+----------+----------+------+---------+------------+
| Domain | Method | URI | Name | Action | Middleware |
+--------+----------+----------+------+---------+------------+
| | GET|HEAD | / | | Closure | web |
| | GET|HEAD | api/veip | | Closure | api |
+--------+----------+----------+------+---------+------------+
So the route does exists
I don't know what's going on here...
try php artisan route:clear may work for you
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With