page not found - except route proplem

Posted 1 month ago by yafeearun

Hi

i have tried to add a url product/test without csrf token verification and i done the following steps

added route in routes

Route::post('product/test', '[email protected]');

and also added a url in app/Http/Middleware/VerifyCsrfToken.php

protected $except = [
    'webhook/stripe',  // this url works fine
         'product/test' // but this one returns 404
    ];

ProductController

namespace App\Http\Controllers;

use Illuminate\Http\Request;
use App\Models\companyDomain;
use App\Models\Lead;

class ProductsController extends Controller
{

    public function getCompanyDetails(Request $request,$id){
        $companyDomain = companyDomain::with(['lead.contact','lead.account',        'assigned_to','product','billing_account','billing_branch'])->where('id', $id)->firstOrFail();

    return $companyDomain;
}

but while i tried to call the URL i got 404 status. guys help me to solve this.. and my old URL works fine

Please sign in or create an account to participate in this conversation.