Hello guys before few days i was working on laravel project and that time my laravel version was 5.7.36 and i maked api in 5.7.36 but now i have updated my project and now my laravel version is 5.8.36 but api is not working in it in 5.7 my all api is working perfectly please see my code and tell me what i need to do for this issue
here is the error that i am getting
<title>404 Not Found
Not Found
The requested URL was not found on this server.
Additionally, a 404 Not Found
error was encountered while trying to use an ErrorDocument to handle the request.
Thanks.
What I have tried:
here is my api.php code:
get('/user', function (Request $request) {
return $request->user();
});
// routes/api.php
// POST /api/post?api_token=UNIQUE_TOKEN
Route::post('post', 'Api\PostController@store')->middleware('auth:api');
Route::get('/get/{business_id}','GetController@databybusinessid');
here is my model code:
get();
return response()->json($users);
}
}